Application Examples
;
LED_STROBE
PROC
;
; THIS PROCEDURE STROBES THE LED ON THE ZT 8809A,
;
THEREBY INDICATING TO THE USER THE INTERRUPT EXPECTED WAS RECEIVED.
;
FIRST THE PRINTER PORT BIT
;
THAT CONTROLS THE LED IS READ AND EXTRACTED, THEN
;
INVERTED AND OR’D BACK INTO THE BYTE READ. THE
;
BYTE IS THEN REWRITTEN TO THE PRINTER PORT. THIS TAKES
;
PLACE TWICE, SO THE LED IS PULSED EITHER ON OR OFF.
;
; INPUTS:
NONE
; OUTPUTS:
NONE
; CALLS:
NONE
; DESTROYS:
NONE
;
PUSH
AX
; SAVE REGISTERS USED
PUSH
BX
PUSH
CX
PUSH
DX
MOV
BL,2
; GO THRU TWICE
DO_TWICE:
GET
PRTR_CTRL
; READ THE CONTROL BYTE
MOV
AH,AL
; SAVE IT INTO AH
AND
AH,2
; EXTRACT THE BIT
NOT
AH
; INVERT IT
AND
AH,2
; ZERO ALL OTHERS
AND
AL,0FDH
; ZERO THE BIT IN CTRL BYTE
OR
AL,AH
; OR NEW ONE BACK INTO THE AL
PUT
PRTR_CTRL
; REPLACE INTO CONTROL BYTE
XOR
CX,CX
; ZERO CX
WAITLP:
LOOP
WAITLP
; WAIT A PERIOD OF TIME
DEC
BL
; CHECK TO SEE IF GONE THRU
; TWICE
JNZ
DO_TWICE
POP
DX
POP
CX
POP
BX
POP
AX
RET
LED_STROBE
ENDP
;
4-24
Содержание ZT 8809A
Страница 15: ...Tables Table B 9 J5 Pin Assignments B 17 Table B 10 J6 Pin Assignments B 18 Table B 11 J7 Pin Assignments B 19...
Страница 334: ...Jumper Configurations W49 W48 A W47 B A B W37 W66 A W50 B C J7 W67 Figure A 11 W37 W47 50 W66 W67 Jumper Blocks A 34...
Страница 346: ...Jumper Configurations W61 W60 W62 W63 W64 A B A B W65 Figure A 13 W60 W65 Jumper Block A 46...