Hello Robert,
> Does anybody know, from his/her own experience (on hardware), if "Int
> 10/AH=01h" always works on the active/current page only?
It seems that there is only one cursor shape, which is "shared" by all the different display pages.
The IBM BIOS data area keeps track of different cursor positions for each page (0x40:0x50--0x40:0x5f), but only one cursor shape (0x40:0x60--0x61).
(Also, I looked at the original IBM PC BIOS listings. Apparently there is really only one hardware cursor, at least on the CGA --- and when you switch the active display page (via int 0x10, ah = 5), the BIOS will actually move the cursor to the correct place, according to what 0x40:0x50 etc. says.)
ACT_DISP_PAGE PROC NEAR
MOV ACTIVE_PAGE,AL ; SAVE ACTIVE PAGE VALUE
MOV CX,CRT_LEN ; GET SAVED LENGTH OF REGEN BUFFER
CBW ; CONVERT AL TO WORD
PUSH AX ; SAVE PAGE VALUE
MUL CX ; DISPLAY PAGE TIMES REGEN LENGTH
MOV CRT_START,AX ; SAVE START ADDRESS FOR
; LATER REQUIREMENTS
MOV CX,AX ; START ADDRESS TO CX
SAR CX,1 ; DIVIDE BY 2 FOR 6845 HANDLING
MOV AH,12 ; 6845 REGISTER FOR START ADDRESS
CALL M16
POP BX ; RECOVER PAGE VALUE
SAL BX,1 ; *2 FOR WORD OFFSET
MOV AX,[BX+OFFSET CURSOR_POSN] ; GET CURSOR FOR THIS PAGE
CALL M18 ; SET THE CURSOR POSITION
JMP SHORT VIDEO_RETURN
ACT_DISP_PAGE ENDP
Thank you! --- https://gitlab.com/tkchia · https://codeberg.org/tkchia · 😴 "MOV AX,0D500H+CMOS_REG_D+NMI" |