Product specifications
RL (IY+0)
RL (IY+1)
RL (IY+2)
RL (IY+3)
RL (IY+4)
DJNZ RAN0 ;Decrement loop counter and if
;loop counter < > 0 goto RAN0
LD A,(IY+0) ;else drop through to next
LD (RND),A ;statement and update value of RND
PDP IY ;Retrieve saved IY register pair
PDP BC ;Retrieve saved BC register pair
PDP AF ;Retrieve saved Acc and flags
(End of routine)
As mentioned in section 3.1, VDP interrupt routines can be used to create glitch free
screen updates.
Listed below is a routine which will fill a text mode display screen with a selected byte
(It could be a blanking byte or any other), simply by selecting the appropriate byte and
loading it into a variable called FILTEX.
If FILTEX contains 255 no action is taken and therefore this is the only byte which
cannot be sent to the screen using this routine.
The assumptions made when using the routine listed below are :
1. That the VDP is in text mode
2. The start address of the screen (pattern name table), is £1800 (Hex) or 6K
3. That we are using the VDP I/O routines described in section 1.1
;
;TEXMOD-FILL A TEXT MODE SCREEN (960 BYTES LONG) WITH A
; SELECTED BYTE HELD IN VARIABLE FILTEXR
; IF FILTER = 255 THEN NO ACTION TAKEN
;
; NO REGISTER SET P REQUIRED ON ENTRY
; AF, BC, DE REGISTERS AFFECTD ON EXIT
;
; THE TWO BYTE VARIABLE SATMSC
; (START ADDRESS TEXT MODE SCREEN) MUST BE SET TO START
OF TEXT PRIOR TO ENTRY TO THIS ROUTINE
;
SATMSC: DW £1800 ;See description above
FILTEX: DB 0 ;See description above
;
TEXMOD: LD A,(FILTEX) ;If variable FILTEX = 255
CP 255 ;then no action taken – goto TEXMO4
JR Z,TEXMO4 ;and exit routine
;else drop through to TEXM01 and
;perform screen update
;
TEXMO1: LD DE,(SATMSC) ;Set write to VRAM pointer to start
CALL VSETOT ;of text display screen
LD C,A ;Load contents of variable FILTEX