XR68C92/192
13
Rev. 1.33
dress 0x7) can be from 0x0001 through 0xFFFF and can
be changed at any time. At power-up and after reset, the
C/T operates in counter mode.
COUNTER MODE
In counter mode, the CPU can start and stop the C/T.
This mode allows the C/T to function as a system
stopwatch or a real-time single interrupt generator. In
this mode, the C/T counts down from the pre-load
value using the programmed counter clock source.
When a read at the start counter command register
(address 0xE) is performed, the counter is initialized to
the pre-load value and begins a countdown sequence.
When the counter counts from 0x0001 to 0x0000
(terminal count), the C/T-ready bit in the interrupt
status register (ISR Bit-3) is set.
3
Users can program the counter to generate an inter-
rupt request for this condition on the -INT output by
unmasking the bit-3 in the Interrupt Mask Register
(IMR, address 0x5). After 0x0000 the count becomes
0xFFFF, and the counter continues counting down
from there. If the CPU changes the pre-load value, the
counter will not recognize the new value until it receives
the next start counter command (and is reinitialized).
When a read at the stop counter command register
(address 0xF) is performed, the counter stops the
countdown sequence and clears ISR Bit-3. The count
value should only be read while the counter is stopped
because only one of the count registers (either CUR, at
address 0x6 or CLR, at address 0x7) can be read at a
time. If the counter is running, a decrement of CLR that
requires a borrow from the CUR could take place
between the two register reads. Figure 2 shows the
C/T output in the counter mode. OP3 can be pro-
grammed to show the C/T output.
In addition to the watch dog timer described above, the
C/T can be used for receive timeout function (see
description under CRA, CRB in the registers section
also). The C/T is more accurate and the timeout period
is programmable unlike the watchdog timer. However,
only one channel can use the C/T for receive timeout
at any given time. The C/T timeout mode uses the
received data stream to start the counter. Each time a
character is shifted from the receive shift register to the
receive FIFO, the C/T is reloaded with the pro-
grammed value in CTPU and CTPL and it restarts on
the next C/T clock. If a new character is not received
before the C/T reaches terminal count (= 0x0000), a
counter ready interrupt (ISR bit-3) is generated. The
user can appropriately program the CTPU and CTPL
for the desired timeout period. Typically this is slightly
more than one character time. Note that if C/T is used
for receiver timeout, a counter ready interrupt is gener-
ated whereas if the watchdog timer is used, a receiver
ready interrupt is generated.
TIMER MODE
In the timer mode, the C/T runs continuously once the
start command is issued (by reading the start C/T
PRELOAD
VALUE
TERMINAL
COUNT
C/T OUTPUT IN
COUNTER MODE
C/T OUTPUT IN
TIMER MODE
PRELOAD
VALUE
TERMINAL
COUNT
PRELOAD
VALUE
TERMINAL
COUNT
PRELOAD
VALUE
PRELOAD
VALUE
TERMINAL
COUNT
TERMINAL
COUNT
TERMINAL
COUNT
PRELOAD
VALUE
PRELOAD
VALUE
START C/T COMMAND
ISSUED
PRELOAD
VALUE
TERMINAL
COUNT
Figure 2: C/T output in Timer and Counter modes.
XR68C92/192
14
Rev. 1.33
command register) and the CPU cannot stop it. When
the stop command is issued (by reading the stop C/T
command register), the CPU only resets the C/T inter-
rupt. This mode allows the C/T to be used as a
programmable clock source for channels A and B (see
CSRA, CSRB register), and/or a periodic interrupt
generator. In this mode, the C/T generates a square-
wave output (see Figure 2) derived from the pro-
grammed timer input clock source. The square wave
generated by the timer has a period of 2 X (pre-load
value) X (period of clock source) and is available as a
clock source for both channels A and B. Since the timer
cannot be stopped, the values in the registers
(CUR:CLR) should not be read. See description of
ACR register to see how to choose clock source for the
C/T.
When the start counter command register (STCR,
address 0xE) is read, the C/T terminates the current
countdown sequence and sets its output to a '1' (OP3
can be programmed to show this output). The C/T is
then initialized to the pre-load value, and begins a new
countdown sequence. When the terminal count is
reached (0x0000), the C/T sets its output to a '0'. Then,
it gets re-initialized to the pre-load value and repeats
the countdown sequence. See Figure 2 for the result-
ing waveform.
The timer sets the C/T-ready bit in the interrupt status
register (ISR Bit-3) every other time it reaches the
terminal count (at every rising edge of the output).
Users can program the timer to generate an interrupt
request for this condition (every second countdown
cycle) on the -INT output. If the CPU changes the pre-
load value, the timer will not recognize the new value
until either
(a) it reaches the next terminal count and is reinitialized
automatically, or
(b) it is forced to re-initialize by a start command.
When a read at the stop counter command address is
performed, the timer clears ISR Bit-3 but does not stop.
Because in timer mode the C/T runs continuously, it
should be completely configured (pre-load value
loaded and start counter command issued) before
programming the timer output to appear on OP3.
OTHER PROGRAMMING REMARKS
The contents of internal registers should not be
changed during receiver/transmitter operation as cer-
tain changes can produce undesired results. For ex-
ample, changing the number of bits per character while
the transmitter is active will result in transmitting an
incorrect character. The contents of the clock-select
register (CSR) and ACR Bit-7 should only be changed
after the receiver(s) and transmitter(s) have been
issued software RX and TX reset commands. Simi-
larly, changes to the auxiliary control register (ACR Bits
4-6) should only be made while the counter/timer (C/T)
is not used.
The mode registers of each channel MR0, MR1 and
MR2 are accessed via an auxiliary pointer. The pointer
is set to mode register one (MR1) by RESET. It can be
set to MR0 or MR1 by issuing a “reset pointer”
command (0xB0 or 0x10 respectively) via the
channel's command register. Any read or write of the
mode register switches the pointer to next mode reg-
ister. All accesses subsequent to reading/writing MR1
will address MR2 unless the pointer is reset to MR0 or
MR1 as described above. The mode, command,
clock-select, and status registers are duplicated for
each channel to allow independent operation and
control (except that both channels are restricted to
baud rates that are in the same set).
XR68C92/192
15
Rev. 1.33
INTERNAL REGISTER DESCRIPTIONS
A3 A2 A1 A0 READ Operation WRITE Operation
0000 Mode Register A (MR0A, MR1A, MR2A) Mode Register A (MR0A, MR1A, MR2A)
0001 Status Register A (SRA) Clock-Select Register A (CSRA)
0010 Reserved Command Register A (CRA)
0011 Receiver Buffer A (RXA) Transmitter Buffer A (TXA)
0100 Input Port Change Register (IPCR) Auxiliary Control Register (ACR)
0101 Interrupt Status Register (ISR) Interrupt Mask Register (IMR)
0110 Counter/Timer Upper Register (CUR) C/T Preload value Upper Register (CTPU)
0111 Counter/Timer Lower Register (CLR) C/T Preload value Lower Register (CTPL)
1000 Mode Register B (MR0B, MR1B, MR2B) Mode Register B (MR0B, MR1B, MR2B)
1001 Status Register B (SRB) Clock-Select Register B (CSRB)
1010 Reserved Command Register B (CRB)
1011 Receiver Buffer B (RXB) Transmitter Buffer B (TXB)
1100 Interrupt Vector Register (IVR) Interrupt Vector Register (IVR)
1101 Input Port Register (IPR) Output Port Configuration Register (OPCR)
1110 Start C/T Command (STCR) Set Output Port Register (SOPR)
1111 Stop C/T Command (SPCR) Reset Output Port Register (ROPR)

XR68C92IVTR-F

Mfr. #:
Manufacturer:
MaxLinear
Description:
UART Interface IC XR68C92IVTR-F
Lifecycle:
New from this manufacturer.
Delivery:
DHL FedEx Ups TNT EMS
Payment:
T/T Paypal Visa MoneyGram Western Union