EVAL-ADP5520
Rev. 0 | Page 12 of 24
GPIO INPUTS WITH INTERRUPT
First press the reset button (S17) on the evaluation board to put
the device in a known state; then complete the following steps.
1.
On the motherboard, do the following:
a.
Move the jumpers on Block J1 through Block J8 to the
GPI position.
b.
Change all SW1 through SW8 switches to the low
position.
2.
On the
Aux LEDs Config
tab, set Bit 4 and Bit 5 in
Register 0x11 high; then program this setting by clicking
the
Program 0x11
button.
This reconfigures the R3 and C3 pins.
3.
On the GPIO Config tab, do the following:
a.
Set Bit 0 in Register 0x1D high; then program this
setting by clicking the
Program 0x1D
button.
This configures the GPI D0 (R0 pin) to trigger an
interrupt on a low to high input event.
b.
Set Bit 0 in Register 0x1B high; then program this
setting by clicking the
Program 0x1B
button.
This enables a GPI D0 (R0 pin) interrupt.
4.
On the motherboard, change the SW1 switch to the high
position.
LED D18 on the motherboard lights up, indicating that the
INT pin (nINT on the board) is active and that an
interrupt has triggered.
5.
On the
GPIO Config
tab, do the following:
a.
Read back Register 0x19 by clicking the
Read 0x19
button.
b.
The readback value should indicate that the LSB is set to
1 and, therefore, that GPI D0 (R0 pin) is currently high.
c.
Read back Register 0x1C by clicking the
Read 0x1C
button.
d.
The readback value should indicate that the LSB is set
to 1 and, therefore, that a GPI D0 (R0 pin) interrupt is
triggered.
6.
On the
BackLight Config
tab, read back Register 0x00 by
clicking the
Read 0x00
button.
The readback value should indicate that Bit 2 (the master
GPI interrupt bit) is set to 1 and, therefore, that a GPI
interrupt is triggered.
To clear an interrupt, do the following:
1.
On the motherboard, change the SW18 switch to the low
position.
2.
On the
GPIO Config
tab, read back Register 0x1C by
clicking the Read 0x1C button.
After the interrupt condition is removed, reading this
register clears the interrupt status bit in the register.
3.
On the
BackLight Config
tab, set Bit 2 in Register 0x00
high; then program this setting by clicking the
Program
0x00
button.
This clears the master GPI interrupt bit.
All interrupt status bits are now cleared, and LED D18 on the
motherboard goes out, indicating that the INT pin (nINT on
the board) is inactive.