Hercules-EBX CPU User Manual V1.02
Page 111
20.2 DAQ Board DIO interface
The Data Acquisition Test Board provides a complete loopback capability for each DIO bit: each
DIO signal can potentially be driven and read back by at least one other DIO channel. The details
of this loopback are user-configurable for many DIO bits – see details below.
20.2.1 DIO A – DIO B LOOPBACK
DIO channel A (bits 7-0) are looped back to DIO channel B (bits 7-0). There is one special case
for this loopback: bit 0 also goes to “EXTTRIG”.
In general, this loopback requires that one port be set up as an output and the other port should
be set as an input (on the Hercules-EBX, via software). While there is some protection for the
case of both set as outputs, this should not be done and serves no useful purpose in testing.
This loopback is connected to a bank of 8 LED’s on the test board. A given LED will be active
when the associated data bit is low. For example, if DIO channel A is set as an output and DIO
channel B is set as an input then a value of “0xFE” written to the DIO Channel A output register
would result in “0xFE” in the channel B input register and would result in one LED (bit 0) being
“ON” while the rest of the DIO loopback LED’s would be off.
To perform DIO loopback tests, ensure that one of the channels is set as an output and the other
channel is set as an input. Any data written to the output channel should be read back on the
input channel.
20.2.2 DIO C – DIO D – DIOE LOOPBACK
DIO channel C (bits 7-0) is looped back to DIO channel D (bits 7-0) and DIO channel E (bits 7-0)
(through some switches for bits 7-4). For basic loopback testing, switch bank SW1 would be set
such that:
•
Switch 1 is ON (E bit 4 connected to C bit 4 and D bit 4)
•
Switch 2 is ON (E bit 5 connected to C bit 5 and D bit 5)
•
Switch 3 is ON (E bit 6 connected to C bit 6 and D bit 6)
•
Switch 4 is OFF (E bit 6 NOT connected to ACK output)
•
Switch 5 is ON (E bit 7 connected to C bit 7 and D bit 7)
(NOTE: Switch 6 does not affect DIO loopback – it is for watchdog timer functions)
To perform DIO loopback tests, ensure that one of the three channels is set as an output and the
other two channels are set as inputs. Any data written to the output channel should be read back
on the two input channels.
There are several special cases for Channel E testing:
•
Channel E, bits 3-0 can also be used for the Pulse-Width Modulation output function.
In this case, channels C and D would both need to be configured as inputs to avoid
out-output contention. These PWM waveforms can be readily sampled via DIO
Channel C 3-0 or DIO Channel D 3-0, or they can be manually measured at pins 1-4
on testpoint connector TP1.
•
Channel E, bit 4 can also be used for the “GATE1” function. It can be connected to
DIO Channel C and D bit 4 by selecting SW1 – switch 1 to the “ON” position. In this
configuration, it is directly wired for DIO loop back to Channel C bit 4 and Channel D
bit 4.
To test “GATE1” functionality, one of the other sources must be set as an output to
assert the required signal or SW1 – switch 1 can be set to the “OFF” position and an