ÛZIATECH
74
14. PROGRAMMABLE LED
The ZT 8907 includes a Light-Emitting Diode (LED) located immediately below the
board extractor. The LED is software programmable through bit 7 of the Digital I/O
ASIC's System Register 3 (E5h) (refer to Chapter 11, "
"). Writing a
logical 0 to the LED bit turns the LED off and writing a logical 1 to the LED bit turns the
LED on. The LED is turned off after a power cycle or a reset.
The following code shows how to turn the LED on and off.
;--------------------------------------
; The multiple master interrupt is
; a bi-directional bit. The current
; software state of multiple master
; interrupt is maintained in the
; multiple master state bit. Input_e5
; updates the multiple master bit with
; the current software state maintained
; in the multiple master state bit.
;--------------------------------------
input_e5 macro
local multiple_on
in al,0e5h
test al,8
jnz multiple_on
and al,not 10h
multiple_on:
endm
;--------------------------------------
; led_on turns on the led. Bit 7 controls the
; LED. The state of bit 1 must be maintained
; (write the same value as was read). Bits 3
; and 4 must be handled as shown in the
; input_e5 macro.
;--------------------------------------
led_on: pushf
cli
input_e5
or al,80h