Intel C2530 FH8065401488915 Hoja De Datos
Los códigos de productos
FH8065401488915
Intel
®
Atom™ Processor C2000 Product Family for Microserver
September 2014
Datasheet, Vol. 2 of 3
Order Number: 330061-002US
533
Volume 2—8254 Programmable Interval Timer (PIT)—C2000 Product Family
Programming the 8254 Counters
27.4
Programming the 8254 Counters
The counter/timers are programmed in the following fashion:
1. Write a control word to select a counter.
2. Write an initial count for that counter.
3. Load the least and/or most significant bytes (as required by control word bits 5, 4)
2. Write an initial count for that counter.
3. Load the least and/or most significant bytes (as required by control word bits 5, 4)
of the 16-bit counter.
4. Repeat with the other counters.
Only two conventions need to be observed when programming the counters. First, for
each counter, the control word must be written before the initial count is written.
Second, the initial count must follow the count format specified in the control word
(least significant byte only, most significant byte only, or least significant byte and then
most significant byte).
A new initial count is written to a counter at any time without affecting the counter
programmed mode. Counting is affected as described in the mode definitions. The new
count must follow the programmed count format.
If a counter is programmed to read/write 2-byte counts, the precaution applies as
follows: a program must not transfer control between writing the first and second byte
to another routine which also writes into that same counter. Otherwise, the counter is
loaded with an incorrect count.
The Control Word Register at port 43h controls the operation of all three counters.
Several commands are available as follows:
• Control Word command - Specifies which counter to read or write, the operating
mode, and the count format (binary or binary-coded decimal).
• Counter Latch command - Latches the current count so the system reads it. The
countdown process continues.
• Read Back command - Reads the count value, programmed mode, the current state
of the OUT pins, and the state of the null count flag of the selected counter.
lists the six operating modes for the interval counters.
Table 27-3. Counter Operating Modes
Mode
Function
Description
0
Out signal on end of count (=0)
Output is 0. When the count goes to 0, the output goes to 1
and stays at 1 until the counter is reprogrammed.
1
Hardware-retriggerable one-shot
Output is 0. When the count goes to 0, the output goes to 1
for one clock time.
2
Rate generator (divide by n counter) Output is 1. The output goes to 0 for one clock time, then
back to 1 and the counter is reloaded.
3
Square wave output
Output is 1. The output goes to 0 when the counter rolls over,
and the counter is reloaded. The output goes to 1 when the
counter rolls over, and the counter is reloaded, etc.
4
Software triggered strobe
Output is 1. The output goes to 0 when the count expires for
one clock time.
5
Hardware triggered strobe
Output is 1. The output goes to 0 when the count expires for
one clock time.