2 output register – Measurement Computing PC104-PDISO8 User Manual
Page 10

Table 3-3. Control Byte Example
171
AB
1
1
1
1
1
1
0
2
1
2
2
1
2
1
0
0
4
0
0
4
2
8
1
8
8
1
8
3
0
0
16
0
0
10
4
32
1
32
20
1
20
5
0
0
64
0
0
40
6
128
1
128
80
1
80
7
WEIGHT
ON=1
DECIMAL
WEIGHT
ON=1
HEX
RELAY
If the relay status byte is read back, it is in the same format.
The isolated inputs are read in this format as well. To disassemble the byte and
determine the state of the isolated inputs or the relay read back register, perform the
following operation in software:
Table 3-4. Register Read-Back
1
1
INPUT 0/RELAY 0
2
2
INPUT 1/RELAY 1
4
4
INPUT 2/RELAY 2
8
8
INPUT 3/RELAY 3
16
10
INPUT 4/RELAY 4
32
20
INPUT 5/RELAY 5
64
40
INPUT 6/RELAY 6
128
80
INPUT 7/RELAY 7
DECIMAL
HEX
INPUT/RELAY
3.2 OUTPUT REGISTER
The output register is located at the base address (BASE + 0).
WRITE = CONTROL: Write a byte to the register to control the relays. A one in the
relay bit position turns the relay.
READ = STATUS: Read the status of the relay control register. A one in the relay
bit position indicates the relay is on.
6