News:

MASM32 SDK Description, downloads and other helpful links
MASM32.com New Forum Link
masmforum WebSite

Driving a mono display adapter

Started by Roger, April 08, 2006, 12:24:28 AM

Previous topic - Next topic

Roger

Hello All,

I have uploaded a programme that uses WinIo to talk to a mono display adapter. I have tested in under Win95 which is where I will use it but tha vidio card on my XP machine uses A0000 to BFFFF so I can't put the adapter in at B000 to try it under XP.

I want it for testing a serial link and then developing a real time system using the link.

The aim is to display quick messages by inserting a simple call to a subroutine without having to use API calls. These can then be used in a similar way to breakpoints in a debugger put without having to stop the programme running.

Regards Roger

[attachment deleted by admin]

hutch--

Roger,

From memory the monochrome memory range is B000 - B7FF so it looks like you are trying to use the VGA, Monochrome and CGA memory address range which will not work.
Download site for MASM32      New MASM Forum
https://masm32.com          https://masm32.com/board/index.php

Roger

Hi Hutch

You are right The monochrome is B0000 - B7FFF and theCGA and EGA used B8000 - BFFFF. VGA used A0000 -AFFFF.  I checked my old Win 95 Machine B0000 - B7FFF was not used when I looked in device manager. so I put the monochrome card in. It works, does not upset the SVGA card and I can even switch a dos command window onto it using theDOS command MODE MONO

However between Win95 and WinXP the MODE command has lost the MONO and CO80 parameters and i assume the vidio card designers have forgotten that B0000 - B7FFF was rwserved for monochrome because device manager lists the card as using A0000- BFFFF.

I note that wWin95 device manager now sees B0000 - B7FFF as being used buy the SVGA card but I think this must be because it detects the memory as present and erroniously assumes that it must belong to the SVGA. However it still works and I am pleased that I will still be able to use the second screen we I can get to understand windows APIs

The other quirk I fould is in WinIO.  In MapPhysToLin it wants the number of bytes to map into linear memory  but then maps a far larger block. I assume that there must be some minimum size block that it works with and that this is bigger than the 4K needed for text.


Regards Roger

MichaelW

Roger,

I think the memory range A0000-BFFFF specified in the resources is likely just a convenient simplification. The VGA hardware does not use addresses in the range B0000-B7FFF because it was specifically designed to coexist with a monochrome adapter. Beyond VGA support, I can see no reason for a video adapter designed primarily to support a PM OS to use any memory addresses in this range.

I don't understand the need for the MONO or CO80 parameters. As nearly as I can recall, the MDA had only one mode, and the HGA defaulted to MDA behavior.

eschew obfuscation