Loading files
This file is pinned to the selected release. Download the original to open it in your design tool.
DS88 EQU 0330H ; digisector port
VSYNC EQU 01000000B ; vertival sync
HSYNC EQU 00100000B ; horizontal sync
HALFHS EQU 009 ; timing constant for half
; of the horizontal sync
HALFVS EQU 02500 ; timing constant for half
; of the vertical sync
FRAMEL: MOV DX,DS88 ; point only at the status port
CLI ; no interuppts allowed
L0: IN AX,DX ; get the status
TEST AH,VSYNC ; are we in VSYNC now
JE L0 ; yes, then loop untill were not
MOV CX,HALFVS ; wait this long
L1: LOOP L1 ; wait, wait, wait, ...
L2: IN AX,DX ; get the status again
TEST AH,HSYNC ; are we in HSYNC
JNE L2 ; no, look for an HSYNC
MOV CX,HALFHS ; now wait 1/2 of a HSYNC period
L3: LOOP L3 ; wait, wait, wait, ...
IN AX,DX ; get the status
TEST AH,VSYNC ; are we getting VSYNC
JNE L2 ; no, wrong frame, try again
31f96539fThis file is pinned to the selected release. Download the original to open it in your design tool.