CMOS Programmable Interval Timer: Features Description
CMOS Programmable Interval Timer: Features Description
CMOS Programmable Interval Timer: Features Description
82C54
March 1997 CMOS Programmable Interval Timer
Features Description
• 8MHz to 12MHz Clock Input Frequency The Harris 82C54 is a high performance CMOS Programma-
• Compatible with NMOS 8254 ble Interval Timer manufactured using an advanced 2 micron
CMOS process.
- Enhanced Version of NMOS 8253
• Three Independent 16-Bit Counters The 82C54 has three independently programmable and
functional 16-bit counters, each capable of handling clock
• Six Programmable Counter Modes input frequencies of up to 8MHz (82C54) or 10MHz
• Status Read Back Command (82C54-10) or 12MHz (82C54-12).
• Binary or BCD Counting The high speed and industry standard configuration of the
• Fully TTL Compatible 82C54 make it compatible with the Harris 80C86, 80C88,
and 80C286 CMOS microprocessors along with many other
• Single 5V Power Supply industry standard processors. Six programmable timer
• Low Power modes allow the 82C54 to be used as an event counter,
- ICCSB . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .10µA elapsed time indicator, programmable one-shot, and many
- ICCOP . . . . . . . . . . . . . . . . . . . . . . . . . . 10mA at 8MHz other applications. Static CMOS circuit design insures low
power operation.
• Operating Temperature Ranges
- C82C54 . . . . . . . . . . . . . . . . . . . . . . . . . .0oC to +70oC The Harris advanced CMOS process results in a significant
reduction in power with performance equal to or greater than
- I82C54 . . . . . . . . . . . . . . . . . . . . . . . . . -40oC to +85oC
existing equivalent products.
- M82C54 . . . . . . . . . . . . . . . . . . . . . . . -55oC to +125oC
Pinouts
82C54 (PDIP, CERDIP, SOIC) 82C54 (PLCC/CLCC)
TOP VIEW TOP VIEW
VCC
WR
NC
RD
D5
D6
D7
D7 1 24 VCC
4 3 2 1 28 27 26
D6 2 23 WR
D5 3 22 RD
D4 4 21 CS D4 5 25 NC
D3 5 20 A1 D3 6 24 CS
D2 6 19 A0 D2 7 23 A1
D1 7 18 CLK 2 D1 8 22 A0
D0 8 17 OUT 2
D0 9 21 CLK2
CLK 0 9 16 GATE 2
CLK 0 10 20 OUT 2
OUT 0 10 15 CLK 1
NC 11 19 GATE 2
GATE 0 11 14 GATE 1
GND 12 13 OUT 1
12 13 14 15 16 17 18
NC
GND
CLK 1
OUT 0
OUT 1
GATE 0
GATE 1
CAUTION: These devices are sensitive to electrostatic discharge. Users should follow proper IC Handling Procedures. File Number 2970.1
Copyright © Harris Corporation 1997
4-1
82C54
Ordering Information
PART NUMBERS TEMPERATURE
8MHz 10MHz 12MHz RANGE PACKAGE PKG. NO.
CP82C54 CP82C54-10 CP82C54-12 0oC to +70oC 24 Lead PDIP E24.6
IP82C54 IP82C54-10 IP82C54-12 -40oC to +85oC 24 Lead PDIP E24.6
CS82C54 CS82C54-10 CS82C54-12 0oC to +70oC 28 Lead PLCC N28.45
IS82C54 IS82C54-10 IS82C54-12 -40oC to +85oC 28 Lead PLCC N28.45
CD82C54 CD82C54-10 CD82C54-12 0oC to +70oC 24 Lead CERDIP F24.6
ID82C54 ID82C54-10 ID82C54-12 -40oC to +85oC 24 Lead CERDIP F24.6
MD82C54/B MD82C54-10/B MD82C54-12/B -55oC to +125oC 24 Lead CERDIP F24.6
MR82C54/B MR82C54-10/B MR82C54-12/B -55oC to +125oC 28 Lead CLCC J28.A
SMD # 8406501JA - 8406502JA -55oC to +125oC 24 Lead CERDIP F24.6
SMD# 84065013A - 84065023A -55oC to +125oC 28 Lead CLCC J28.A
CM82C54 CM82C54-10 CM82C54-12 0oC to +70oC 24 Lead SOIC M24.3
Functional Diagram
CLK 0
DATA/ COUNTER
D7 - D0 8 BUS GATE 0 INTERNAL BUS
0
BUFFER
OUT 0
CONTROL STATUS
WORD LATCH
REGISTER
CRM CRL
RD CLK 1 STATUS
REGISTER
INTERNAL BUS
CLK 2
CONTROL OLM OLL
COUNTER GATE 2
WORD 2
REGISTER
OUT 2
GATE n
CLK n OUT n
COUNTER INTERNAL BLOCK DIAGRAM
Pin Description
DIP PIN
SYMBOL NUMBER TYPE DEFINITION
D7 - D0 1-8 I/O DATA: Bi-directional three-state data bus lines, connected to system data bus.
CLK 0 9 I CLOCK 0: Clock input of Counter 0.
OUT 0 10 O OUT 0: Output of Counter 0.
GATE 0 11 I GATE 0: Gate input of Counter 0.
GND 12 GROUND: Power supply connection.
OUT 1 13 O OUT 1: Output of Counter 1.
GATE 1 14 I GATE 1: Gate input of Counter 1.
CLK 1 15 I CLOCK 1: Clock input of Counter 1.
GATE 2 16 I GATE 2: Gate input of Counter 2.
OUT 2 17 O OUT 2: Output of Counter 2.
4-2
82C54
DIP PIN
SYMBOL NUMBER TYPE DEFINITION
CLK 2 18 I CLOCK 2: Clock input of Counter 2.
A0, A1 19 - 20 I ADDRESS: Select inputs for one of the three counters or Control Word Register for read/write
operations. Normally connected to the system address bus.
A1 A0 SELECTS
0 0 Counter 0
0 1 Counter 1
1 0 Counter 2
1 1 Control Word Register
CS 21 I CHIP SELECT: A low on this input enables the 82C54 to respond to RD and WR signals. RD and
WR are ignored otherwise.
RD 22 I READ: This input is low during CPU read operations.
WR 23 I WRITE: This input is low during CPU write operations.
VCC 24 VCC: The +5V power supply pin. A 0.1µF capacitor between pins VCC and GND is recommended
for decoupling.
Functional Description
General
The 82C54 is a programmable interval timer/counter CLK 0
DATA/ COUNTER
designed for use with microcomputer systems. It is a general D7 - D0 8 BUS GATE 0
0
purpose, multi-timing element that can be treated as an BUFFER
OUT 0
array of I/O ports in the system software.
The 82C54 solves one of the most common problems in any
microcomputer system, the generation of accurate time
delays under software control. Instead of setting up timing RD CLK 1
loops in software, the programmer configures the 82C54 to WR READ/
INTERNAL BUS
COUNTER GATE 1
match his requirements and programs one of the counters WRITE 1
A0 LOGIC
for the desired delay. After the desired delay, the 82C54 will OUT 1
A1
interrupt the CPU. Software overhead is minimal and vari-
able length delays can easily be accommodated.
CS
Some of the other computer/timer functions common to micro-
computers which can be implemented with the 82C54 are: CLK 2
CONTROL COUNTER
• Real time clock WORD 2
GATE 2
REGISTER
• Event counter OUT 2
• Digital one-shot
• Programmable rate generator
• Square wave generator
• Binary rate multiplier FIGURE 1. DATA BUS BUFFER AND READ/WRITE LOGIC
FUNCTIONS
• Complex waveform generator
• Complex motor controller Read/Write Logic
Data Bus Buffer The Read/Write Logic accepts inputs from the system bus and
generates control signals for the other functional blocks of the
This three-state, bi-directional, 8-bit buffer is used to inter- 82C54. A1 and A0 select one of the three counters or the Con-
face the 82C54 to the system bus (see Figure 1). trol Word Register to be read from/written into. A “low” on the
RD input tells the 82C54 that the CPU is reading one of the
counters. A “low” on the WR input tells the 82C54 that the CPU
is writing either a Control Word or an initial count. Both RD and
WR are qualified by CS; RD and WR are ignored unless the
82C54 has been selected by holding CS low.
4-3
82C54
CE
CLK 0 CONTROL
DATA/ COUNTER LOGIC
D7 - D0 8 BUS GATE 0
0
BUFFER
OUT 0
OLM OLL
RD CLK 1 GATE n
INTERNAL BUS
4-4
82C54
All Control Words are written into the Control Word Register, 0 1 Read/Write least significant byte only.
which is selected when A1, A0 = 11. The Control Word spec- 1 0 Read/Write most significant byte only.
ifies which Counter is being programmed. 1 1 Read/Write least significant byte first, then most
By contrast, initial counts are written into the Counters, not significant byte.
the Control Word Register. The A1, A0 inputs are used to
M - Mode
select the Counter to be written into. The format of the initial
count is determined by the Control Word used. M2 M1 M0
0 0 0 Mode 0
ADDRESS BUS (16)
0 0 1 Mode 1
A1 A0
X 1 0 Mode 2
CONTROL BUS
I/OR I/OW X 1 1 Mode 3
DATA BUS (8) 1 0 0 Mode 4
1 0 1 Mode 5
8
4-5
82C54
Possible Programming Sequence (Continued) explained later. The second is a simple read operation of the
Counter, which is selected with the A1, A0 inputs. The only
A1 A0 requirement is that the CLK input of the selected Counter
LSB of Count - Counter 1 0 1 must be inhibited by using either the GATE input or external
LSB of Count - Counter 0 0 0 logic. Otherwise, the count may be in process of changing
when it is read, giving an undefined result.
MSB of Count - Counter 0 0 0
MSB of Count - Counter 1 0 1
Counter Latch Command
MSB of Count - Counter 2 1 0 The other method for reading the Counters involves a spe-
cial software command called the “Counter Latch Com-
Possible Programming Sequence mand”. Like a Control Word, this command is written to the
Control Word Register, which is selected when A1, A0 = 11.
A1 A0 Also, like a Control Word, the SC0, SC1 bits select one of
Control Word - Counter 2 1 1 the three Counters, but two other bits, D5 and D4, distin-
guish this command from a Control Word.
Control Word - Counter 1 1 1
.
4-6
82C54
1. Read least significant byte. The read-back command may also be used to latch status
2. Write new least significant byte. information of selected counter(s) by setting STATUS bit D4
= 0. Status must be latched to be read; status of a counter is
3. Read most significant byte.
accessed by a read from that counter.
4. Write new most significant byte.
The counter status format is shown in Figure 6. Bits D5
If a counter is programmed to read or write two-byte counts,
through D0 contain the counter’s programmed Mode exactly
the following precaution applies: A program MUST NOT
as written in the last Mode Control Word. OUTPUT bit D7
transfer control between reading the first and second byte to
contains the current state of the OUT pin. This allows the
another routine which also reads from that same Counter.
user to monitor the counter’s output via software, possibly
Otherwise, an incorrect count will be read.
eliminating some hardware from a system.
Read-Back Command
D7 D6 D5 D4 D3 D2 D1 D0
The read-back command allows the user to check the count OUTPUT NULL RW1 RW0 M2 M1 M0 BCD
value, programmed Mode, and current state of the OUT pin COUNT
and Null Count flag of the selected counter(s).
D7: 1 = Out pin is 1
The command is written into the Control Word Register and 0 = Out pin is 0
has the format shown in Figure 5. The command applies to D6: 1 = Null count
the counters selected by setting their corresponding bits D3, 0 = Count available for reading
D2, D1 = 1. D5 - D0 = Counter programmed mode (See Control Word Formats)
COMMANDS
D7 D6 D5 D4 D3 D2 D1 D0 DESCRIPTION RESULT
1 1 0 0 0 0 1 0 Read-Back Count and Status of Counter 0 Count and Status Latched for Counter 0
1 1 1 0 0 1 0 0 Read-Back Status of Counter 1 Status Latched for Counter 1
1 1 1 0 1 1 0 0 Read-Back Status of Counters 2, 1 Status Latched for Counter 2,
But Not Counter 1
1 1 0 1 1 0 0 0 Read-Back Count of Counter 2 Count Latched for Counter 2
1 1 0 0 0 1 0 0 Read-Back Count and Status of Counter 1 Count Latched for Counter 1,
But Not Status
1 1 1 0 0 0 1 0 Read-Back Status of Counter 1 Command Ignored, Status Already
Latched for Counter 1
FIGURE 7. READ-BACK COMMAND EXAMPLE
4-7
82C54
Both count and status of the selected counter(s) may be If a new count is written to the Counter it will be loaded on
latched simultaneously by setting both COUNT and STATUS the next CLK pulse and counting will continue from the new
bits D5, D4 = 0. This is functionally the same as issuing two count. If a two-byte count is written, the following happens:
separate read-back commands at once, and the above dis-
(1) Writing the first byte disables counting. Out is set low
cussions apply here also. Specifically, if multiple count
immediately (no clock pulse required).
and/or status read-back commands are issued to the same
counter(s) without any intervening reads, all but the first are (2) Writing the second byte allows the new count to be
ignored. This is illustrated in Figure 7. loaded on the next CLK pulse.
If both count and status of a counter are latched, the first This allows the counting sequence to be synchronized by
read operation of that counter will return latched status, software. Again OUT does not go high until N + 1 CLK
regardless of which was latched first. The next one or two pulses after the new count of N is written.
reads (depending on whether the counter is programmed for
one or two type counts) return latched count. Subsequent If an initial count is written while GATE = 0, it will still be
reads return unlatched count. loaded on the next CLK pulse. When GATE goes high, OUT
will go high N CLK pulses later; no CLK pulse is needed to
CS RD WR A1 A0 load the counter as this has already been done.
CW = 10 LSB = 4
0 1 0 0 0 Write into Counter 0
WR
0 1 0 0 1 Write into Counter 1
0 1 0 1 0 Write into Counter 2 CLK
0 1 0 1 1 Write Control Word
GATE
0 0 1 0 0 Read from Counter 0
OUT
0 0 1 0 1 Read from Counter 1
0 0 0 0 0 FF FF
0 0 1 1 0 Read from Counter 2 N N N N 4 3 2 1 0 FF FE
0 0 1 1 1 No-Operation (Three-State)
CW = 10 LSB = 3
1 X X X X No-Operation (Three-State)
WR
0 1 1 X X No-Operation (Three-State)
CLK
FIGURE 8. READ/WRITE OPERATIONS SUMMARY
Mode Definitions GATE
The following are defined for use in describing the operation
of the 82C54. OUT
CLK PULSE: 0 0 0 0 0 0 FF
N N N N 3 2 2 2 1 0 FF
A rising edge, then a falling edge, in that order, of a
Counter’s CLK input. CW = 10 LSB = 3 LSB = 2
WR
TRIGGER:
A rising edge of a Counter’s Gate input. CLK
COUNTER LOADING:
GATE
The transfer of a count from the CR to the CE (See “Func-
OUT
tional Description”)
0 0 0 0 0 0 FF
N N N N 3 2 1 2 1 0 FF
Mode 0: Interrupt on Terminal Count
Mode 0 is typically used for event counting. After the Control FIGURE 9. MODE 0
Word is written, OUT is initially low, and will remain low until NOTES: The following conventions apply to all mode timing diagrams.
the Counter reaches zero. OUT then goes high and remains 1. Counters are programmed for binary (not BCD) counting and for
high until a new count or a new Mode 0 Control Word is writ- reading/writing least significant byte (LSB) only.
ten to the Counter. 2. The counter is always selected (CS always low).
3. CW stands for “Control Word”; CW = 10 means a control word of
GATE = 1 enables counting; GATE = 0 disables counting. 10, Hex is written to the counter.
GATE has no effect on OUT.
4. LSB stands for Least significant “byte” of count.
After the Control Word and initial count are written to a 5. Numbers below diagrams are count values. The lower number is
Counter, the initial count will be loaded on the next CLK the least significant byte. The upper number is the most signifi-
pulse. This CLK pulse does not decrement the count, so for cant byte. Since the counter is programmed to read/write LSB
an initial count of N, OUT does not go high until N + 1 CLK only, the most significant byte cannot be read.
pulses after the initial count is written. 6. N stands for an undefined count.
7. Vertical lines show transitions between count values.
4-8
82C54
WR Writing a new count while counting does not affect the current
counting sequence. If a trigger is received after writing a new
count but before the end of the current period, the Counter will
CLK
be loaded with the new count on the next CLK pulse and count-
ing will continue from the end of the current counting cycle.
GATE
CW = 14 LSB = 3
OUT WR
0 0 0 0 FF 0 0
N N N N N 3 2 1 0 FF 3 2 CLK
CW = 12 LSB = 3 GATE
WR OUT
0 0 0 0 0 0 0
N N N N 3 2 1 3 2 1 3
CLK
CW = 14 LSB = 3
GATE WR
OUT CLK
0 0 0 0 0 0 0
N N N N N 3 2 1 3 2 1 0 GATE
WR 0 0 0 0 0 0 0
N N N N 3 2 2 3 2 1 3
WR
GATE
CLK
OUT
GATE
0 0 0 FF FF 0 0
N N N N N 2 1 0 FF FE 4 3 OUT
0 0 0 0 0 0 0
FIGURE 10. MODE 1 N N N N 4 3 2 1 5 4 3
4-9
82C54
GATE
OUT
0 0 0 0 0 0 0 0 0 0
N N N N 5 4 2 5 2 5 4 2 5 2
CW = 16 LSB = 4
WR
CLK
GATE
OUT
0 0 0 0 0 0 0 0 0 0
N N N N 4 2 4 2 2 2 4 2 4 2
4-10
82C54
CW = 18 LSB = 3 CW = 1A LSB = 3
WR WR
CLK CLK
GATE
GATE
OUT
0 0 0 0 FF FF FF OUT
N N N N 3 2 1 0 FF FE FD
0 0 0 0 FF 0
N N N N N 3 2 1 0 FF 3
CW = 18 LSB = 3
WR CW = 1A LSB = 3
WR
CLK
CLK
GATE
GATE
OUT
0 0 0 0 0 0 FF OUT
N N N N 3 3 3 2 1 0 FF
0 0 0 0 0 0 FF
N N N N N N 3 2 3 2 1 0 FF
CW = 18 LSB = 3 LSB = 2
WR CW = 1A LSB = 3 LSB = 5
WR
CLK
CLK
GATE
OUT GATE
0 0 0 0 0 0 FF
N N N N 3 2 1 2 1 0 FF OUT
4-11
82C54
Counter
New counts are loaded and Counters are decremented on
MODE MIN COUNT MAX COUNT
the falling edge of CLK.
0 1 0
The largest possible initial count is 0; this is equivalent to 216
for binary counting and 104 for BCD counting. 1 1 0
4-12
82C54
Die Characteristics
Gate Count . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 2250 Gates
CAUTION: Stresses above those listed in “Absolute Maximum Ratings” may cause permanent damage to the device. This is a stress only rating and operation
of the device at these or any other conditions above those indicated in the operational sections of this specification is not implied.
DC Electrical Specifications VCC = +5.0V ± 10%, TA = 0oC to +70oC (C82C54, C82C54-10, C82C54-12)
TA = -40oC to +85oC (I82C54, I82C54-10, I82C54-12)
TA = -55oC to +125oC (M82C54, M82C54-10, M82C54-12
2.2 - V M82C54
ICCSB Standby Power Supply Current - 10 µA VCC = 5.5V, VIN = GND or VCC,
Outputs Open, Counters
Programmed
NOTE:
1. Not tested, but characterized at initial design and at major process/design changes.
4-13
82C54
AC Electrical Specifications VCC = +5.0V ± 10%, TA = 0oC to +70oC (C82C54, C82C54-10, C82C54-12)
TA = -40oC to +85oC (I82C54, I82C54-10, I82C54-12)
TA = -55oC to +125oC (M82C54, M82C54-10, M82C54-12)
READ CYCLE
WRITE CYCLE
(27) TWO OUT Delay from Mode Write - 260 - 240 - 240 ns 1
(30) TCL CLK Setup for Count Latch -40 40 -40 40 -40 40 ns 1
NOTE:
1. Not tested, but characterized at initial design and at major process/design changes.
4-14
82C54
Timing Waveforms
A0 - A1
(9)
tWA (11)
tAW
CS
(10)
tSW
(13)
tDW tWD (14)
WR
(12)
tWW
A0 - A1
CS
(2)
tSR (4)
tRR
RD
(5) (7)
tRD tDF
(6)
DATA BUS tAD
VALID
(8) (15)
tRV
RD, WR
COUNT
MODE (SEE NOTE)
WR
tWC (28) (23)
(16)
tGS
(17) tCLK
tCL (30)
tPWH (18)
CLK tPWL
(19)
tGS tF (20)
tR tGH (24)
(23)
GATE (21)
(24) tGW
(22)
tGH tGL tOD (25)
OUT
(27) tODG (26)
tWO
NOTE: LAST BYTE OF COUNT BEING WRITTEN
4-15
82C54
Burn-In Circuits
MD 82C54 CERDIP
VCC
C1
R1
Q1 1 24
R1 R1
Q2 2 23 Q3
R1 R1
VCC 3 22 VCC
R1 R1
GND 4 21 GND
R1 R1
F9 5 20 Q5 VCC
R1 R1
F10 6 19 Q4
R1 R2
F11 7 18 F2
R1 R3
F12 8 17 A
R2 R1 A
F0 9 16 Q8
R2 R4
A 10 15 F1
R1 R1
Q6 11 14 Q7
GND 12 13 A
MR 82C54 CLCC
VCC
C1
R1 R1 R1 R1 R1
4 3 2 1 28 27 26
R1
GND 5 25 OPEN
R1 R1
F9 6 24 GND
R1 R1
F10 7 23 Q5
R1 R1
F11 8 22 Q4
R1 R2
F12 9 21 F2
R2 R5
F0 10 20 VCC/2
R1
OPEN 11 19 Q8
12 13 14 15 16 17 18
R5 R1 R5 R1 R2
NOTES:
1. VCC = 5.5V ± 0.5V 8. R4 = 1.8kΩ ±5%
2. GND = 0V 9. R5 = 1.2kΩ ±5%
3. VIH = 4.5V ±10% 10. C1 = 0.01µF Min
4. VIL = -0.2V to 0.4V 11. F0 = 100kHz ±10%
5. R1 = 47kΩ ±5% 12. F1 = F0/2, F2 = F1/2, ...F12 = F11/2
6. R2 = 1.0kΩ ±5%
7. R3 = 2.7kΩ ±5%
4-16
82C54
Die Characteristics
DIE DIMENSIONS: Thickness: Metal 1: 8kÅ ± 0.75kÅ
129mils x 155mils x 19mils Metal 2: 12kÅ ± 1.0kÅ
(3270µm x 3940µm x 483µm)
GLASSIVATION:
METALLIZATION: Type: Nitrox
Type: Si-Al-Cu Thickness: 10kÅ ± 3.0kÅ
D5 D6 D7 VCC WR RD
D4 CS
D3 A1
D2 A0
D1 CLK2
D0 OUT2
CLK0 GATE2
4-17