
The data in the counter read register, and the action taken on the data in a counter
load register, is dependent upon the control code written to the control register.
The counters are 16-bit types, each with an 8-bit window (the read / load
register). Data is shifted into and out of the 16-bit counters through these 8-bit
windows according to the control byte. You will need an 8254 data sheet if you want
to program the 8254 directly at the register level. You can download a copy from our
WEB site at http://www.computerboards.com/PDFmanuals/82C54.pdf
3.6 COUNTER CONTROL REGISTER
BASE ADDRESS + 7
BCDM0M1M2RL0RL1SC0SC1
01234567
WRITE ONLY
SC1 to SC0 are the counter-select bits. They are binary coded between 0 and 2.
RL1 to RL0 are the read and load control bits:
RL1 RL0 OPERATION
0 0 Latch counter.
0 1 Read/load high byte.
1 0 Read/load low byte.
1 1 Read/load low the high byte (word transfer).
M2 to M0 are the counter control operation type bits:
M2 M1 M0 OPERATION TYPE
0 0 0 Change on terminal count.
0 0 1 Programmable one-shot.
0 1 0 Rate generator
0 1 1 Square wave generator
1 0 0 Software triggered strobe.
1 0 1 Hardware triggered strobe.
If BCD = 0, then counter data is 16-bit binary. (65,535 max)
If BCD = 1, then counter data is 4-decade Binary Coded Decimal. (9,999 max)
12
Kommentare zu diesen Handbüchern