home *** CD-ROM | disk | FTP | other *** search
- ; WINDOWS3.A86
- title 'WINDOW Data and Primitives'
- pagesize 60+11
- ;****************************************
- ;* *
- ;* PRIMITIVE CRT ROUTINES *
- ;* WINDOW DATA *
- ;* CDOS 6.0 XIOS *
- ;* DRI OS ENGR, JMB, GMS, PAR *
- ;* *
- ;****************************************
- ; Major mods:
- ; 6.x
- ; 25 SEP 88 -- extra params to VS_ for background video support GMS
- ; 11 APR 88 -- Data variable moved into PUBDATA.A86 GMS
- ; 4 FEB 88 -- VS_CUR_TYPE_HW updated in trans_cur_type GMS
- ; 11 JAN 88 -- new VS_ variable to hold PC equipment word GMS
- ; 7 DEC 87 -- VS_SCREEN_MODE now uses ROS video mode values GMS
- ; 2 DEC 87 -- replaced ega$ with redefined video$ GMS
- ; 6.0
- ; 18 NOV 87 -- re-enable AST color card support GMS
- ; 2 NOV 87 -- changed graphics error msg GMS
- ; 17 JUL 87 -- converted XIOS to small model JW
- ; 5.2
- ; 26 MAY 87 -- changed graphics error message - to suspended - GMS
- ; 13 APR 87 -- added message for serial terminal process abort - GMS
- ; 27 FEB 87 -- VS_ structure increased for EGA blink toggle - GMS
- ; 5.1
- ; 27 OCT 86 -- VS_ structure increased for Hercules support - PAR
- ; 15 OCT 86 -- VS_ structure increased for ANSI support - GMS
- ; 15 JUL 86 -- trans_cur_type pop bug
- ; 18 APR 86 -- add VS_CUR_TYPE_HW to vs_
- ; 3 JAN 85 -- add graphics mode error msg
- ; 22 NOV 85 -- add VS_COLORSEL entry
- ; 8 NOV 85 -- support AST "Colorgraphplus" in video_out@
- ; 12 SEP 85 -- don't sti in video_out@
- ; 19 JUL 85 -- support io_devio w/ put_crt_dev@
- ; 14 JUN 85 -- update 4.1 ASM86 XIOS to RASM86
-
- ; include COPYRITE.TXT
-
- nolist
- include CDOS.EQU
- include XIOS.EQU
- include PCHW.EQU
- include ROSDATA.EQU
- list
- ; These were included:
- ; include CDOS.EQU
- ; include XIOS.EQU
- ; include PCHW.EQU
- ; include ROSDATA.EQU
-
- CGROUP group CODE
- DGROUP group DATA,w3dseg0
-
- public draw_frame_s@, draw_frame_d@, draw_frame@
- public put_if_ours@, copy_full_top@, put_crt_s@
- public put_mon_c@, put_crt_c@, get_crt_c@
- public video_out@, put_crt_m@, erase_crt@
- public put_crt_dev@, trans_cur_type@
-
-
- public scroll_mode$
- public s_lines$, d_lines$
- public var_cursor$, var_sync$
-
-
- public table_vs$, first_vs$
- public fatal_gr_msg$, FATAL_GR_MSG_LENGTH
- public fatal_ser_msg$, FATAL_SER_MSG_LENGTH
- public mono_params$, MONO_PARAMS_LEN$
-
- cseg
- extrn sysdat$ :word ; in HEADER.A86
- extrn con_normal@ :near, old_cursor_off@ :near ; in WINDOWS1.A86
- extrn point_vs@ :near, point_cursor@ :near ; in WINDOWS2.A86
- extrn xlat_priority@ :near, check_full_top@ :near
-
- dseg
- extrn pfk_tbl0$ :byte, pfk_tbl1$ :byte ; in CONIN.A86
- extrn pfk_tbl2$ :byte, pfk_tbl3$ :byte
- extrn ast_enhanced$ :word, video$ :byte ; in WINDOWS1.A86
- extrn ast_flag$:byte
- extrn pc_at$ :byte ; in FLOPPY.A86
- extrn blank$ :word ; in PUBDATA.A86
- extrn vc_map_seg$ :word
- extrn mode_reg$ :byte, top_screen_mode$:byte
- extrn im_here$ :byte, vc_priority$ :byte
- extrn top_screen$ :byte, vc_list$ :word
- extrn mono_xlat$ :byte, color_xlat$ :byte
-
- eject
-
- ;********************************************************
- ;* *
- ;* CHARACTER OUT PRIMITIVES *
- ;* *
- ;********************************************************
-
- cseg
-
- draw_frame_s@:
- ;------------
- ; Draw a single line frame:
- ; save: dx for double frame
-
- push dx
- mov dl,top_screen$ ; old top frame
- call point_vs@ ; bx -> old vs_
- call copy_full_top@ ; if full, copy to image
- call old_cursor_off@ ; for 2 monitor switch
- mov si,offset s_lines$
- call draw_frame@ ; single line frame
- pop dx
- ret
-
- draw_frame_d@:
- ;------------
- ; Draw a double line frame:
- ; entry: bx -> vs_
-
- mov si,offset d_lines$
- ; jmps draw_frame@ ; double line frame
-
-
- draw_frame@:
- ;-----------
- ; Draw frame around the window
- ; entry: bx -> vs_
- ; si -> line data
-
- mov dx,VS_TOP_LEFT
- mov cx,VS_COLS ; column count
- dec dh ; up one row
- js draw_f1 ; skip if top row
- mov ax,TOP_CORNERS
- call hline ; top line + corners
- draw_f1:
- mov dh,VS_BOTTOM
- inc dh ; down on row
- cmp dh,CRT_ROWS_C ; never draw the frame
- jae draw_f2 ; below line 23
- mov ax,BOT_CORNERS
- call hline ; bottom line + corners
- draw_f2:
- mov dx,VS_TOP_LEFT
- mov cx,VS_ROWS ; row count
- dec dl ; left one column
- js draw_f3 ; skip if 1st column
-
- call vline ; left line only
- draw_f3:
- mov dl,VS_RIGHT
- inc dl ; right one column
- cmp dl,CRT_COLS
- jz draw_f4 ; skip if last column
-
- call vline ; right line only
- draw_f4:
- ret
- eject
-
- hline:
- ;-----
- ; Draw a horizontal line with corners:
- ; entry: dx=row,col cx=col count ax=corners
-
- push es
- push si
- push dx
- push cx
- push ax ; save corners
- mov ax,HORIZ ; horiz line + attrib
- mov h_copy,ax ; save for draw
-
- call point_cursor@ ; di -> line start
- xchg ax,si ; si -> map
- mov es,vc_map_seg$ ; for owner check
- cmp dl,0 ; if at left edge
- jz hline1 ; skip first corner
-
- pop ax
- push ax
- dec di ; back up for corner
- dec di
- dec si ; on the map too
- mov ah,a_copy ; frame attribute
- call put_if_ours@ ; to the screen
- hline1:
- add dl,cl ; get to right column
- dec dl
- mov ax,h_copy ; horiz line + attrib
- hline2:
- call put_if_ours@ ; to the screen
- loop hline2 ; cx times
-
- pop ax ; corners again
- cmp dl,CRT_COLS-1 ; if at right edge
- jz hline3 ; skip last corner
- mov al,a_copy ; frame attribute
- xchg al,ah
- call put_if_ours@ ; to the screen
- hline3:
- pop cx
- pop dx
- pop si
- pop es
- ret
-
- eject
-
- vline:
- ;-----
- ; Draw a vertical line (no corners):
- ; entry: dx=row,col cx=row count
-
- push es
- push si
- push cx
- push VERT ; save vert line
- call point_cursor@ ; di -> line start
- xchg ax,si ; si -> map
- mov es,vc_map_seg$ ; for owner check
- pop ax ; vert line + attrib
- vline1:
- call put_if_ours@ ; to the screen
- add di,2*(CRT_COLS-1)
- add si,CRT_COLS-1
- loop vline1 ; num of rows times
- pop cx
- pop si
- pop es
- ret
-
-
- put_if_ours@:
- ;-----------
- ; Put a frame char to screen if we own it:
- ; entry: ax = char + attrib
- ; es:si -> vc_map
- ; di -> crt
-
- push ax ; save char
- mov al,es:[si] ; get map code
- inc si ; to next char
- call xlat_priority@ ; who owns it?
- cmp al,VS_NUMBER ; if not us
- pop ax ; then skip
- jnz put_if1
- jmp put_crt_c@ ; print one char
- put_if1:
- inc di ; bump destination
- inc di
- ret
- eject
-
- erase_crt@:
- ;---------
- ; Clear the unowned portions of the screen:
- ; entry: dh = vc bit mask
- ; dl = VS_MODE (08 to sync)
- ; bx = crt_segment
-
- push es
- sub si,si ; start at top left
- sub di,di
- mov es,vc_map_seg$
- mov cx,CRT_ROWS_C * CRT_COLS
- mov ax,blank$ ; space + attrib
- erase_crt1:
- test es:byte ptr [si],dh
- jnz erase_crt2 ; skip if owned
- call put_mon_c@ ; straight to monitor
- jmps erase_crt3 ; di taken care of
-
- erase_crt2:
- inc di ; next crt char
- inc di
- erase_crt3:
- inc si ; next map char
- loop erase_crt1
-
- pop es ; restore extra seg
- ret
- eject
-
- copy_full_top@:
- ;-------------
- ; Copy crt back to vc image when full screen on top:
- ; entry: bx -> vs_
-
- call check_full_top@ ; if not full top screen
- jnz copy_f_done ; then skip
-
- ; Top screen is full, save it:
- push cx
- push dx
- push ds ! push es
- sub si,si ; top left
- sub di,di ; of both
- mov al,CRT_COLS
- mul VS_CRT_ROWS ; ax = our crt size
- mov cx,ax
- mov es,VS_VC_SEG ; image is destination
- mov ds,VS_CRT_SEG
- mov ah,IN_SYNC ; sync for reading
- call put_crt_m@ ; general mover
- pop es ! pop ds
- pop dx
- pop cx
- or VS_MODE,MATCH_BIT
- copy_f_done:
- ret
- eject
-
- put_crt_s@:
- ;---------
- ; Store characters to crt (like a rep stosw):
- ; entry: di -> cursor location
- ; ax = attribute, character
- ; bx -> vs_
- ; cx = char count
-
- push bx ! push dx ! push es
- mov es,VS_CRT_SEG ; get our segment
-
- test VS_MODE,SYNC_BIT
- jz put_s_all ; skip if not syncing
- cmp cx,STOS_BURST ; if less than one burst
- jbe put_s_slow ; then sneak it in
- cmp scroll_mode$,0 ; if we're default scroll mode
- jz put_s_fast ; then blast it
- cmp scroll_mode$,2 ; if we're wide open
- jz put_s_all ; then just ship it
-
-
- put_s_slow:
- ;----------
- ; Slow non-flickering erase:
-
- mov dx,COLOR_PORT+6
- put_s_top:
- mov bx,ax ; save char in bx
- put_s_wait:
- sti ; allow an interrupt
- nop
- cli ;; hold the ints
- in al,dx
- test al,VRT ;; if vertical retrace
- jnz put_s_burst ;; then store a burst
- test al,HRT ;; if horiz retrace
- jnz put_s_wait ;; then stay here
- put_s_no_hrt:
- in al,dx
- test al,HRT
- jz put_s_no_hrt ; wait for fresh HRT
- xchg ax,bx ; char back to ax
- stosw ; put it out
- loop put_s_top ; more if you've got 'em
- jmps put_s_done ; done if not
-
- put_s_fast:
- ;----------
- ; Fast flickering erase:
-
- call disable_video
- rep stosw ; get it over with
- call enable_video
- jmps put_s_done
-
-
- put_s_burst:
- ; Vertical retrace, put a burst:
- ; Now we're sure to have less than STOS_BURST.
-
- xchg ax,bx ; char back to ax
-
- put_s_all:
- rep stosw ; store them all
-
- put_s_done:
- ; Finished with the store:
- sti ; allow interrupts
- pop es ! pop dx ! pop bx
- ret
- eject
-
- put_crt_m@:
- ;---------
- ; Generalized move to/from crt:
- ; entry: ds:si -> source
- ; es:di -> destination
- ; cx = char count
- ; ah = sync flag
-
- push bx
- push dx
- push bp
-
- push ds
- mov ds,sysdat$
- test VS_MODE,SYNC_BIT
- pop ds
- jz put_m_all ; skip if not syncing
- test ah,ah ; if no sync bits
- jz put_m_all ; then just move
-
- cmp cx,MOVS_BURST ; if less than one burst
- jbe put_m_slow ; then sneak it in
- push ds
- mov ds,sysdat$
- mov al,scroll_mode$
- pop ds
- cmp al,0 ; use al for speed
- jz put_m_fast ; blast it if default
- cmp al,2 ; if we're wide open
- jz put_m_all ; then just ship it
- ; jmps put_m_slow
-
- put_m_slow:
- ; Slow non-flickering scroll:
- mov dx,COLOR_PORT+6
- mov bh,ah ; sync bits live here
- put_m_top:
- test bh,IN_SYNC ; do we wait on input?
- jz put_m2 ; if not, skip
- put_m0:
- sti ; allow an interrupt
- nop
- cli ;; hold the ints
- in al,dx
- test al,VRT ;; if vertical retrace
- jnz put_m_burst ;; then move a burst
- in al,dx ;; get a fresh one
- test al,HRT ;; if no horiz retrace
- jnz put_m0 ;; then stay here
- put_m1:
- in al,dx
- test al,HRT
- jz put_m1 ; wait for fresh HRT
- put_m2:
- mov ax,[si] ; get crt character, keep ptr
- test bh,OUT_SYNC ; do we wait on ouput?
- jz put_m5 ; if not, skip
- xchg ax,bp ; save char in bp
- put_m3:
- sti ; allow an interrupt
- nop
- cli ;; hold the ints
- in al,dx
- test al,VRT ;; if vertical retrace
- jnz put_m_burst ;; then move a burst
- test al,HRT ;; if no horiz retrace
- jnz put_m3 ;; then stay here
- put_m4:
- in al,dx
- test al,HRT
- jz put_m4 ; wait for fresh HRT
- xchg ax,bp ; char back to ax
- put_m5:
- stosw ; put it out
- lods cs:ax ; incs or decs si leaving screen alone
- loop put_m_top ; more if you've got 'em
- jmps put_m_done ; done if not
-
- put_m_burst:
- ; Vertical retrace, put a burst:
- mov ax,MOVS_BURST ;; move count
- cmp cx,ax ;; if count is too big
- jbe put_m_all ;; then do a burst
- ;; at a time
- sub cx,ax ;; first correct the count
- xchg ax,cx ;; cx = burst count
- rep movsw ;; move a burst
- xchg ax,cx ;; corrected count to cx
- jmps put_m_top ;; go back for more
-
- put_m_fast:
- ; Fast flickering scroll:
- call disable_video
- rep movsw ; get it over with
- call enable_video
- jmps put_m_done
-
- put_m_all:
- ; If EGA and AT, move by bytes...the card is not fast enough for word moves.
- push ds
- mov ds,sysdat$
- test video$,EGA+VGA
- jz not_ega
- test pc_at$,1
- jz not_at
- pop ds
-
- shl cx,1 ; 2 bytes per word
- rep movsb ; move 8 bits at a time
- jmps put_m_done
-
- not_ega:
- not_at:
- pop ds
- rep movsw ; move them all
-
- put_m_done:
- ; Finished with the move:
- sti ; allow interrupts
- pop bp
- pop dx
- pop bx
- ret
-
-
-
- enable_video:
- ;------------
- ; Enable the video beam:
- push ax
- push ds
- mov ds,sysdat$
- mov al,mode_reg$ ; bit on
- pop ds
- jmps shared_video
-
- disable_video:
- ;-------------
- ; Disable the video beam:
- push ax
- mov ah,21h ; bit off
- mov dx,COLOR_PORT+6
- disable_video_loop:
- in al,dx
- test al,VRT ; wait for vertical
- jz disable_video_loop
- mov al,ah ; recover value
- shared_video:
- mov dx,COLOR_PORT+4
- out dx,al ; and blast it
- pop ax
- ret
-
-
- put_mon_c@:
- ;---------
- push es
- push dx
- push bx
- mov es,bx ; set crt segment
- jmps put_crt_c0 ; sneak in
- eject
-
- put_crt_c@:
- ;---------
- ; Store one character to crt (like a stosw):
- ; entry: di -> cursor location
- ; ax = attribute, character
-
- push es
- push dx
- push bx
-
- mov es,VS_CRT_SEG ; mono or color
- mov dl,VS_MODE
- put_crt_c0:
- test dl,SYNC_BIT
- jnz put_c0 ; if sync, skip
- stosw ; just ship it
- jmps put_c_done
- put_c0:
- xchg ax,bx ; save char in bx
-
- mov dx,COLOR_PORT+6 ; crt status
- put_c1:
- sti ; allow an interrupt
- nop
- cli ;; hold the ints
- in al,dx
- test al,VRT ;; if vert retrace
- jnz put_c3 ;; just do it
- in al,dx ;; get a fresh one
- test al,HRT ;; if horiz retrace on
- jnz put_c1 ;; wait for it to go away
- put_c2:
- in al,dx
- test al,HRT ;; wait for fresh horiz rt
- jz put_c2
- put_c3:
- xchg ax,bx ;; char back to ax
- stosw ;; the fastest
- sti
- put_c_done:
- pop bx
- pop dx
- pop es
- ret
- eject
-
- get_crt_c@:
- ; Get one character from crt (like a lodsw):
- ; entry: si -> cursor location
- ; exit: ax = attribute, character
-
- push ds
- push dx
- mov dl,VS_MODE
- mov ds,VS_CRT_SEG ; mono or color
- get_crt_c0:
- test dl,SYNC_BIT
- jz get_c3 ; if no sync, skip
- mov dx,COLOR_PORT+6 ; crt status
- get_c1:
- sti ; allow an interrupt
- nop
- cli ;; hold the ints
- in al,dx
- test al,VRT ;; if vert retrace
- jnz get_c3 ;; just do it
- in al,dx ;; get a fresh one
- test al,HRT ;; if horiz retrace on
- jnz get_c1 ;; wait for it to go away
- get_c2:
- in al,dx
- test al,HRT ;; wait for fresh horiz rt
- jz get_c2
- get_c3:
- lodsw ;; grab it
- sti ; and get out
- pop dx
- pop ds
- ret
- eject
-
- put_crt_dev@:
- ;------------
- ; Write a string to crt (padding w/ current attribute)
- ; Entry: bx = vs_ structure
- ; bp = dev_ parameter for io_devio
- ; di = cursor location (word ptr)
- ; ah = current attribute
- ; cx = character count
-
- push es ! push si ! push di ! push ds ! push cx
- mov es,VS_VC_SEG ; point to virtual buffer
- lds si,DEV_BUF_BP ; get string address
- shr cx,1 ; div. char. cnt. by 2
- jcxz put_cdev_15 ; skip if no pairs
- put_cdev_10:
- lodsb ! stosw ; get byte, store byte+attr
- lodsb ! stosw ; two per loop for speed
- loop put_cdev_10 ; repeat for all pairs
- put_cdev_15:
- jnc put_cdev_20 ; skip if no odd one left
- lodsb ! stosw ; else do the last one
- put_cdev_20:
- pop cx ! pop ds ! pop di ; restore SYSDAT and cursor
- mov es,VS_CRT_SEG ; move into phys. screen RAM
- push di ! push ds ; keep SYSDAT safe
- mov si,di ; source and dest. offset match
- test VS_MODE,SYNC_BIT ; need to sync?
- mov ds,VS_VC_SEG ; from virtual plane
- jnz put_cdev_30 ; jmp if yes
- rep movsw ; else do it
- jmps put_cdev_40 ; finished
- put_cdev_30:
- mov ah,OUT_SYNC ; sync on writes
- call put_crt_m@ ; do optimized move
- put_cdev_40:
- pop ds ! pop di ! pop si ! pop es
- ret
- eject
-
- video_out@:
- ;---------
- ; Video controller port output:
- ; entry: al = first data register number
- ; bx -> vs_
- ; cx = two data bytes
-
- push dx
- mov dx,MONO_PORT ; assume monochrome
- cmp VS_CRT_SEG,MONO_SEG
- jz video_out1 ; skip if true
- mov dx,COLOR_PORT ; color port if false
- video_out1:
- pushf ; save interrupt flag
- cli ; critical section
- out dx,al ;; set port number
- inc dx ;; data register
- xchg al,ch ;; al = first data
- out dx,al ;;
- dec dx ;; back to set port
- xchg al,ch ;;
- inc ax ;; next port
- out dx,al ;;
- inc dx ;;
- mov al,cl ;; second data
- out dx,al ;;
-
- ; Support the AST "Colorgraphplus" card:
- ; (Most every hit of the CRTC registers seems to require a re-hit here:)
-
- if not QXM
- test ast_flag$,0ffh ; make sure it is possibly AST
- jz not_ast
-
- mov dx,AST_ENHANCED_PORT ;;
- mov al,byte ptr ast_enhanced$ ;; toggled by keyboard
- out dx,al ;;
- not_ast:
- endif
- popff iret_op@ ;; section done
- pop dx
- ret
- eject
-
- trans_cur_type@:
- ;----------------
- ; Entry: CX = CGA-compatible cursor type (ala VS_CUR_TYPE)
- ; BX = VS_
- ; Exit: CX = EGA equivalent as function of ECD presence
- ; Uses AX
-
- test video$,EGA+VGA
- jz trans_back1
-
- ; Here to trans cursor type
- push dx
- push di
- mov ah,ch
- and ah,60h
- cmp ah,20h ; no curs?
- jne ega_on
- mov cx,01E00h ; curs off for ega
- jmps trans_back
- ega_on:
- cmp VS_SCREEN_MODE,04
- jb test_ecd
- cmp VS_SCREEN_MODE,07
- jne no_ecd ; jump if graphics mode
- test_ecd:
- test video$,ECD ; ecd attached?
- jz no_ecd
-
- cmp ch,4
- jbe ye
- add ch,5
- ye:
- cmp cl,4
- jbe ye1
- add cl,5
- ye1:
- no_ecd:
- cmp ch,0
- jnz not_0
- inc cl
- jmps ne_1
- not_0:
- inc cl
- mov dx,ds ; save seg
- mov di,PC_SEGMENT
- mov ds,di
- cmp cl,.85h
- mov ds,dx
- jb ne_1
- sub cl,cl
- ne_1:
- push cx
- sub cl,ch
- cmp cl,10h
- pop cx
- jne ye2
- inc cl
- ye2:
- trans_back:
- pop di
- pop dx
- trans_back1:
- mov VS_CUR_TYPE_HW,cx ; save hardware cursor
- ret
- eject
-
- ;********************************************************
- ;* *
- ;* CONSOLE OUT VARIABLES *
- ;* *
- ;********************************************************
-
- w3dseg0 dseg word
-
- c_copy rb 1 ; character
- a_copy rb 1 ; attribute
- h_copy equ word ptr c_copy
-
- scroll_mode$ db 0 ; 0 => fast flicker, 1 => slow snake
- ; 2 => wide open
- ; Single / double line frame drawing data:
-
- HORIZ equ word ptr 0[si]
- VERT equ word ptr 2[si]
- TOP_CORNERS equ word ptr 4[si]
- BOT_CORNERS equ word ptr 6[si]
-
- s_lines$ dw 07C4h,07B3h
- dw 0BFDAh,0D9C0h
-
- d_lines$ dw 0FCDh,0FBAh
- dw 0BBC9h,0BCC8h
-
- ; Variable video params for the COMPAQ:
-
- var_cursor$ dw COLOR_CURSOR ; hi or low res
- var_sync$ db SYNC_BIT ; to sync or not
- db 0DBh ; pad
-
-
- CRT_FULL equ 100h * (CRT_ROWS_C - 1) + (CRT_COLS - 1)
-
- ; Virtual console data tables:
-
- table_vs$ dw first_vs$,second_vs,third_vs,fourth_vs
-
- first_vs$ dw 0,0,CRT_FULL
- dw 0,CRT_FULL,CRT_FULL
- dw 1850H,0
- dw CRT_ROWS_C,CRT_COLS,0
- dw 0,0,vc_list$
- db 07h,INIT_MODE,1,CRT_COLS,0,1
- dw 0,con_normal@,0
- db CRT_ROWS_C,0
- dw 0,0
- dw pfk_tbl0$,0,0FF00h
- dw 0,0,0,0,0
- db 1,0
- dw 0
- db 30h ; color sel 80 alpha
- dw 0 ; scratch
- db 0 ; graphics wait flag
- dw 0 ; cur_type_hw
- db 0 ; hercules mode
- db 01 ; default blink toggle
- db 0,1,2,3,4,5,14h,7,38h,39h ; default pallette
- db 3ah,3bh,3ch,3dh,3eh,3fh,0 ; settings + overscan
- dw 00 ; PC equipment word
- dw 0000h ; ansi options count
- rb VS_ANSI_SIZE ; ansi input buffer
- ;if BACKG
- db 0 ; virtual port 3?4h
- rb 0 ; virtual port 3?5h
- db 71h,50h,5ah,0ah,1fh,6,19h,1ch,2,7,6,7
- db 0,0,0,0,0,0,0,0
- db 0 ; virtual port 3?Ah
- ;endif
-
- second_vs dw 0,0,CRT_FULL
- dw 0,CRT_FULL,CRT_FULL
- dw 1850H,0
- dw CRT_ROWS_C,CRT_COLS,0
- dw 0,0,vc_list$
- db 07h,INIT_MODE,1,CRT_COLS,1,2
- dw 0,con_normal@,0
- db CRT_ROWS_C,0
- dw 0,0
- dw pfk_tbl1$,0,0FF00h
- dw 0,0,0,0,0
- db 1,0
- dw 0
- db 30h ; color sel 80 alpha
- dw 0 ; scratch
- db 0 ; graphics wait flag
- dw 0 ; cur_type_hw
- db 0 ; hercules mode
- db 01 ; default blink toggle
- db 0,1,2,3,4,5,14h,7,38h,39h ; default pallette
- db 3ah,3bh,3ch,3dh,3eh,3fh,0 ; settings + overscan
- dw 00 ; PC equipment word
- dw 0000h ; ansi options count
- rb VS_ANSI_SIZE ; ansi input buffer
- ;if BACKG
- db 0 ; virtual port 3?4h
- rb 0 ; virtual port 3?5h
- db 71h,50h,5ah,0ah,1fh,6,19h,1ch,2,7,6,7
- db 0,0,0,0,0,0,0,0
- db 0 ; virtual port 3?Ah
- ;endif
-
- third_vs dw 0,0,CRT_FULL
- dw 0,CRT_FULL,CRT_FULL
- dw 1850H,0
- dw CRT_ROWS_C,CRT_COLS,0
- dw 0,0,vc_list$
- db 07h,INIT_MODE,1,CRT_COLS,2,4
- dw 0,con_normal@,0
- db CRT_ROWS_C,0
- dw 0,0
- dw pfk_tbl2$,0,0FF00h
- dw 0,0,0,0,0
- db 1,0
- dw 0
- db 30h ; color sel 80 alpha
- dw 0 ; scratch
- db 0 ; graphics wait flag
- dw 0 ; cur_type_hw
- db 0 ; hercules mode
- db 01 ; default blink toggle
- db 0,1,2,3,4,5,14h,7,38h,39h ; default pallette
- db 3ah,3bh,3ch,3dh,3eh,3fh,0 ; settings + overscan
- dw 00 ; PC equipment word
- dw 0000h ; ansi options count
- rb VS_ANSI_SIZE ; ansi input buffer
- ;if BACKG
- db 0 ; virtual port 3?4h
- rb 0 ; virtual port 3?5h
- db 71h,50h,5ah,0ah,1fh,6,19h,1ch,2,7,6,7
- db 0,0,0,0,0,0,0,0
- db 0 ; virtual port 3?Ah
- ;endif
-
- fourth_vs dw 0,0,CRT_FULL
- dw 0,CRT_FULL,CRT_FULL
- dw 1850H,0
- dw CRT_ROWS_C,CRT_COLS,0
- dw 0,0,vc_list$
- db 07h,INIT_MODE,1,CRT_COLS,3,8
- dw 0,con_normal@,0
- db CRT_ROWS_C,0
- dw 0,0
- dw pfk_tbl3$,0,0FF00h
- dw 0,0,0,0,0
- db 1,0
- dw 0
- db 30h ; color sel 80 alpha
- dw 0 ; scratch
- db 0 ; graphics wait flag
- dw 0 ; cur_type_hw
- db 0 ; hercules mode
- db 01 ; default blink toggle
- db 0,1,2,3,4,5,14h,7,38h,39h ; default pallette
- db 3ah,3bh,3ch,3dh,3eh,3fh,0 ; settings + overscan
- dw 00 ; PC equipment word
- dw 0000h ; ansi options count
- rb VS_ANSI_SIZE ; ansi input buffer
- ;if BACKG
- db 0 ; virtual port 3?4h
- rb 0 ; virtual port 3?5h
- db 71h,50h,5ah,0ah,1fh,6,19h,1ch,2,7,6,7
- db 0,0,0,0,0,0,0,0
- db 0 ; virtual port 3?Ah
- ;endif
-
- mono_params$ db 61h,80,52h,0fh,25,6,25,25,2,0dh,0bh,0ch
- MONO_PARAMS_LEN$ equ offset $ - offset mono_params$
-
- ; We only have the space to save alpha consoles.
- fatal_gr_msg$ db 0dh,0ah,'Concurrent Error: This program suspended'
- db ' while other program in graphics.'
- FATAL_GR_MSG_LENGTH equ offset $ - offset fatal_gr_msg$
-
- fatal_ser_msg$ db 0dh,0ah,'Concurrent Error: This program '
- db 'can not run on a serial console.'
- FATAL_SER_MSG_LENGTH equ offset $ - offset fatal_ser_msg$
-
- end
-
- ; END OF WINDOWS3.A86
-