resman
Veteran Member
An annoyance back in the '80s and presently an annoyance now that I have my backup Compaq Deskpro hooked up to an Amdek 300A: CGA firmware that doesn't disable color when you ask it. Back in the day with my PC XT clone, I always had to issue a 'mode bw80' to get the CGA to disable composite color so I could read the text on my cheap green screen monitor. With the Compaq CGA card, it's even worse - it won't disable color even when you ask it. You have to force the BW bit in the mode select register. To add insult to injury, I hooked up a color composite monitor (from my Apple IIe) and it only displays in black and white - no color burst signal. Another color monitor had the same result. I don't even get to play with NTSC color artifacting! I suppose nobody ever used the composite output on a Deskpro. I guess if you were going to lay out that kind of money for a Compaq, you'd get their fancy monochrome dual-mode monitor. In fact, I have one on my main Deskpro, and it works great, but the backup Deskpro has to deal with the composite video.
Here is what I had to look at:

Unusable. Since I had just finished a fresh install of Compaq DOS 3.31, MASM 5.1, and MCS 5.1, I needed a coding project and this fit the bill: write a TSR to hook Video INT 10 and fix up the CRT mode register when a mode set happens. Hours later, after pouring over BIOS listings, CGA registers, and MS-DOS functions, I get this:

Interestingly, the Compaq CGA card only outputs three levels on composite: black, medium intensity, and high intensity. No 16 shades of grey. So none of the fun video modes are really worth playing with. Even 160x100 mode looks horrible.
For anyone interested, here is the code for my simple TSR MONOCGA.COM:
Finally, here is a glamour shot for that cool '80s vibe:

Dave...
Here is what I had to look at:

Unusable. Since I had just finished a fresh install of Compaq DOS 3.31, MASM 5.1, and MCS 5.1, I needed a coding project and this fit the bill: write a TSR to hook Video INT 10 and fix up the CRT mode register when a mode set happens. Hours later, after pouring over BIOS listings, CGA registers, and MS-DOS functions, I get this:

Interestingly, the Compaq CGA card only outputs three levels on composite: black, medium intensity, and high intensity. No 16 shades of grey. So none of the fun video modes are really worth playing with. Even 160x100 mode looks horrible.
For anyone interested, here is the code for my simple TSR MONOCGA.COM:
Code:
INTSEG SEGMENT AT 0
INT10VEC EQU 40H
INTSEG ENDS
BIOSDATA SEGMENT AT 40H
CRT_MODE_SET EQU 65H
BIOSDATA ENDS
COMSEG SEGMENT
ASSUME CS:COMSEG
ORG 100H
START: JMP INIT
INT10: OR AH, AH ; Mode set if AH == 0
PUSHF
CALL DWORD PTR CS:OINT10
JNZ EXIT
MONO: PUSH AX
PUSH DX
PUSH DS
MOV AX, BIOSDATA
MOV DS, AX
ASSUME DS:BIOSDATA
OR BYTE PTR BIOSDATA:CRT_MODE_SET, 04H ; Force BW
MOV AL, BIOSDATA:CRT_MODE_SET
MOV DX, 3D8H
OUT DX, AL
POP DS
POP DX
POP AX
EXIT: IRET
OINT10: DD ?
INIT: MOV AX, CS
MOV DS, AX
ASSUME DS:COMSEG
MOV DX, OFFSET HELLOS
MOV AH, 9
INT 21H
XOR AX, AX
MOV ES, AX
MOV AX, ES:INT10VEC
MOV WORD PTR OINT10, AX
MOV AX, ES:INT10VEC+2
MOV WORD PTR OINT10+2,AX
MOV AX, OFFSET INT10
MOV ES:INT10VEC, AX
MOV AX, CS
MOV ES:INT10VEC+2, AX
PUSHF ; Set up return by IRET
PUSH CS
CALL MONO
MOV DX, OFFSET INIT
INT 27H ; Terminate but Stay Resident
HELLOS: DB "Monochrome CGA override TSR.$"
COMSEG ENDS
END START
Finally, here is a glamour shot for that cool '80s vibe:

Dave...