EasyManua.ls Logo

Intel 8253 - Page 596

Intel 8253
773 pages
Print Icon
To Next Page IconTo Next Page
To Next Page IconTo Next Page
To Previous Page IconTo Previous Page
To Previous Page IconTo Previous Page
Loading...
XA User Guide 7-20 4/17/98
High Impedance Output
The final XA port output configuration is called high impedance mode. This mode simply turns
all output drivers on a port pin off. Thus, the pin will not source or sink current and may be used
effectively as an input-only pin with no internal drivers for an external device to overcome.
7.4.4 Reset State and Initialization
Upon chip reset, all of the port output configurations are set to quasi-bidirectional, and the port
latches are written with all ones. The quasi-bidirectional output type is a good default at power-
up or reset because it does not source a large amount of current if it is driven by an external
device, yet it does not allow the port pin to float. A floating input pin on a CMOS device can
cause excess current to flow in the pin’s input circuitry, and of course all port pins have input
circuits in addition to outputs.
7.4.5 Sharing of I/O Ports with On-Chip Peripherals
Since XA on-chip peripheral devices share device pins with port functions, some care must be
taken not to accidentally disable a desired pin function by inadvertently activating another
function on the same pin. A peripheral that has an output on a pin will use the I/O port output
configuration for that pin (quasi-bidirectional, open drain, push-pull, or high impedance).
The method of sharing multiple functions on a single pin involves a logic AND of all of the
functions on a pin. So, if a port latch contains a zero, it will drive that port pin low, and any
peripheral output function on that pin is overridden. Conversely, an on-chip peripheral outputting
a zero on a pin prevents the contents of the port latch from controlling the output level. It is
usually not an issue to avoid turning on an alternate peripheral function on a pin accidentally,
since most peripherals must be either explicitly turned on or activated by a write to one of their
SFRs. It is more likely that a user program could erroneously write a zero to a port latch bit
corresponding to a pin with a peripheral function that is being used and therefore disable that
function. The simple rule to follow is: never write a zero to a port bit that is associated with an
active on-chip peripheral, or that should only be used an input.
When an XA I/O port pin is used as an input for a peripheral function, it is sampled at the
oscillator rate divided by 2. For example, if an XA is running at a 20 MHz clock (giving a 50 ns
clock period), an external timer input would have to remain in the same state for at least 100 ns
in order to guarantee that it is sampled correctly. This gives a maximum frequency for such
inputs as the oscillator rate divided by 4. In this example, the maximum external timer input rate
would be 5 MHz.

Table of Contents