User`s manual

PK2100
D-6 s Appendix D: I/O Map and Interrupt Vectors
Interrupt Vectors
Most interrupt vectors can be altered under program control. The ad-
dresses are relative to the start of the interrupt vector page, which is
determined by the contents of the I-register. Table D-4 lists the default
interrupt vectors set by the boot code in the Dynamic C EPROM.
A directive such as the following is used to vector an interrupt to a user
function in Dynamic C.
#INT_VEC 0x10 myfunction
This causes the interrupt at offset 10H (serial port 1 of the Z180) to invoke
the function myfunction(). The function must be declared with the
interrupt keyword:
interrupt myfunction() {
...
}
Table D-3. Read Registers
Address Bits Symbol Function
0x80 0-D7 UINP
Bits 0-6 are universal inputs 0–5 and
the sensitive input (bit 6). Bit 7 is a
user-programmable jumper (J8 pins
11-12) and is low when the jumper is
installed. Bit 7 represents signal PR.
DREG1
0x81 0-D7
SDA_R
Bit 0 is EEPROM data bit. Bit 1 is
NMI interrupt line (power fail line).
Bits 2, 3, 4, 5, 6, and 7 are keypad
columns 0, 1, 2, 3, 4, and 5.
0x88 0-D7 DREG2
Bits 0-6 are digital inputs 0-6. Bit 7
is the universal input channel fed
through AD+ (or universal input
channel 8).
0x98 WDOG
Reading this location “hits” the
watchdog timer.
0xC0 0-D7 BUSR0 First read, data port expansion bus.
0xC2 0-D7 BUSRD1
Second read, data port expansion
bus.
0xC4 0-D7 BUSSPARE Unused bus read address.
0xC6 BUSRESET
Read location to reset all devices on
expansion bus.