
Table 4-1. Bit Weights
801287
40646
20325
10164
883
442
221
110
HEX VALUEDECIMAL VALUEBIT POSITION
To write a control word or data to a register, the individual bits must be set to 0 or 1
then combined to form a byte.
The method of programming required to set/read bits from bytes is beyond the scope
of this manual. It is covered in most Introduction To Programming books.
In summary form, the registers and their function are listed on the following table.
Each register has eight bits which can constitute a byte of data or can be eight
individual bit set/read functions.
Table 4-2. Register Functions
ConfigureNone. No read back.3
Port C OutputsPort C Inputs2
Port B OutputsPort B Inputs1
Port A OutputsPort A Inputs 0
WRITE FUNCTIONREAD FUNCTIONADDRESS
4.4 DIGITAL I/O REGISTERS
PORT A DATA
A0A1A2A3A4A5A6A7
01234567
PORT B DATA
B0B2B2B3B4B5B6B7
01234567
Ports A & B can be programmed as input or output. Each is written to and read from
in bytes. For control and monitoring purposes, individual bits are usually used. Mask
unwanted bits out of reads and writes.
7
Comentarios a estos manuales