XR68C92/192
22
Rev. 1.33
INTERRUPT MASK REGISTER (IMR)
This register selects which bits in the interrupt status
register can cause an interrupt output. If a bit in the
interrupt status register is a “1” and the corresponding
bit in this register is also a “1”, the -INT output will be
asserted. If the corresponding bit in this register is a
zero, the state of the bit in the interrupt status register
has no effect on the -INT output. Note that the interrupt
mask register does not have any effect on the pro-
grammable interrupt outputs OP7 through OP3 or the
value read from the interrupt status register.
0 = Interrupt output (-INT) disabled (default)
1 = Enable interrupt output for the event controlled by
the corresponding bit in ISR.
COUNTER / TIMER REGISTERS
The Preload value Upper (CTPU) and Lower (CTPL)
registers hold the most-significant byte and the least-
significant byte, respectively, of the value to be used by
the C/T (in both counter and timer modes). The C/T
Upper (CUR) and Lower Registers (CLR) give the
current value of the C/T, at the time they are read. In the
counter mode, the CUR and CLR should only be read
when the counter is stopped. Upon receiving a start
command after a stop command, the counter starts a
fresh cycle and begins counting down from the original
(preload) value written to CTPU and CTPL. Also
changing the value of these registers does not take
effect till the current cycle is stopped and a subsequent
start command is issued.
In the timer mode, the CUR and CLR registers cannot
be read by the CPU. A stop command will not stop the
timer, but will only clear the counter ready status bit in
ISR (bit-3). Changing the value of the CTPU and CTPL
registers when the timer is running will change the
waveform after the current half-period of the square
wave. For more details, see the Counter/Timer sec-
tion.
GENERAL PURPOSE REGISTER (GPR)
This is a general purpose scratchpad register which
can be used to store and retrieve one byte of user
infomation.
INPUT PORT REGISTER - Read Only
The current state of the multi-purpose inputs (IP0-IP6)
can be read via this register.
IPR Bit 0-5:
0 = Inputs are in low state.
1 = Inputs are in high state.
IPR Bit 6-7:
Not used and set to “0”.
OUTPUT PORT CONFIGURATION REGISTER
(OPCR) - Write Only
This register selects following options for the multi-
purpose outputs OP2 to OP7.4Alternate functions of
OP1 and OP0 are controlled by the mode registers, not
the OPCR. MR1A Bit-7 and MR2A Bit-5 control OP0.
MR1B Bit-7 and MR2B Bit-5 control OP1. For more
details on these, see 'Multi-purpose Outputs' on page
8.
OP2 Output Select
Bit-1 Bit-0
0 0 Controlled by SOPR and ROPR
(default)
0 1 TxAClk16-Transmit A 16X clock
1 0 TxAClk1-Transmit A 1X clock
1 1 RxAClk1- Receive A 1X clock
OP3 Output Select
Bit-3 Bit-2
0 0 Controlled by SOPR and ROPR
(default)
0 1 C/T Output
1 0 TxBClk1-Transmit B 1X clock
1 1 RxBClk1- Receive B 1X clock
If OP3 is to be used for the timer output (a square wave
of the programmed frequency), program the counter/
timer for timer mode (ACR Bit-6 = 1), initialize the
counter/timer pre-load registers (CTPU and CTPL),
and read the 'Start C/T Command Register' (STCR)
before setting OPCR Bits 3-2 = 01. In the counter
mode, the output remains high until the terminal count
is reached, at which time it goes low. The output
becomes high again when the counter is stopped by a
stop counter command.
OP4 output select (Bit 4):
0 = Controlled by SOPR and ROPR (default)
1 = -RxARDY which is the complement of ISR bit-1
XR68C92/192
23
Rev. 1.33
OP5 output select (Bit 5):
0 = Controlled by SOPR and ROPR (default)
1 = -RxBRDY which is the complement of ISR bit-5
OP6 output select (Bit 6):
0 = Controlled by SOPR and ROPR (default)
1 = -TxARDY which is the complement of ISR bit-0
OP7 output select (Bit 7):
0 = Controlled by SOPR and ROPR (default)
1 = -TxBRDY which is the complement of ISR bit-4
START COUNTER/TIMER REGISTER (STCR) -
Read Only
Reading from this register will start the C/T. Data
values returned should be ignored.
STOP COUNTER/TIMER REGISTER (SPCR) -
Read Only
Reading from this register will stop the C/T. Data
values returned should be ignored.
SET OUTPUT PORT REGISTER (SOPR) -
Write Only
Output ports (OP0-OP7), when used as general pur-
pose outputs, can be asserted (set to low) by writing a
“1” to the corresponding bit in this register. Once an
output is asserted, it can be negated only by issuing a
command through the Reset Output Port Register (see
below).
However, note that SOPR and ROPR cannot be used
to assert and negate outputs that are programmed for
alternate functions (see description under OPCR). For
example, if OP0 is programmed to output -RTSA (see
'Configuring Multi-purpose Outputs), it cannot be con-
trolled by SOPR or ROPR. In that case, commands
from the Command Register should be issued to
assert (CRA bits 7:4 = 0x8) and negate (CRA bits 7:4
= 0x9) OP0.
SOPR Bit 0-7:
0 = No change (same state).
1 = Assert the corresponding output (Set it low).
RESET OUTPUT PORT REGISTER (ROPR) - Write
Only
Each output port bit can be changed to high state by
writing a “1” to each individual bit.
ROPR Bit 0-7:
0 = No change (same state).
1 = Negate the corresponding output (Set it high).
XR68C92/192
24
Rev. 1.33
PROGRAMMING EXAMPLES
The following examples show how to initialize the XR68C92/192 for various operating conditions:
A) The first example will initialize channel A of an XR68C92 device for regular RX/TX. The operating parameters
will be 9600 baud, 8 word length, no parity and 1 stop bit.
Operation Register Value Remarks
Write CRA 0x20 ; reset RX (receiver)
Write CRA 0x30 ; reset TX (transmitter)
Write CRA 0x40 ; reset error status
Write CRA 0xB0 ; reset MR pointer to MR0
Write MR0A 0x00 ; use normal baud rate table. Now MR pointer points to MR1
Write MR1A 0x13 ; select word length & parity. Now MR pointer points to MR2
Write MR2A 0x07 ; normal mode (not loopback) & 1 stop bit
Write CSRA 0xBB ; 9600 baud for RX & TX - clock source is XTAL1
Write CRA 0x05 ; enable RX & TX
Read SRA ; should get a value 0x0C
B) This example will show how to use hardware flow control for both RX (RTS via OP0) and TX (CTS via IP0):
Write CRA 0x10 ; reset MR pointer to MR1
Write MR1A 0x93 ; select auto RTS control. The -RTS signal is sent via output OP0
Write MR2A 0x17 ; select auto CTS control. The input IP0 serves as the -CTS signal
C) This example will configure clock sources for TX and RX of both channels and C/T. Specifically, XTAL1 will be used
as channel A's TX clock; IP4 as channel A's 16X RX clock; IP5 as channel B's 1X TX clock and XTAL1 as channel
B's RX clock. Also, the C/T will be initialized in the timer mode and IP2 will be used as its clock source. Some
of these will be programmed to appear at the multi-purpose output pins:
Write ACR 0x40 ; C/T initialized in timer mode & IP2 chosen as its clock source
; also, bit-7 = 0, therefore baud rate Set1 has been selected
Write CTPU 0x00 ; It is essential to program CTPU & CTPL before programming OP3
Write CTPL 0x05 ; as C/T output (see below)
Write CSRA 0xEB ; channel A RX clock source: IP4-16X, TX clock source: XTAL1 (if MR0A
; bits 2 and 0 = 0, the TX baud rate is 9600)
Write CSRB 0xBF ; channel B RX clock source: XTAL1 (9600 baud), TX clock source: IP5-1X
Read STCR ; Start the C/T
Write OPCR 0x06 ; C/T output appears at OP3 and channel A's TX 1X clock (this is XTAL1
; clock divided by 16) at OP2.
D) The next example will show how to configure and run channel B's transmitter in a multi-drop application. Note
that all other relevant parameters should be configured already, like baud rate etc.
Write CRB 0x10 ; reset MR pointer to MR1
Write MR1B 0x1B ; word length = 8 and use A/D tag in the place of parity
Write CRB 0x04 ; Enable transmitter of channel B
Write TXB address ; Send the address first (A/D tag = 1)
Write CRB 0x10 ; reset MR pointer to MR1
Write MR1B 0x13 ; change A/D tag = 0
Write TXB data ; You can load the data (A/D tag = 0) immediately after the address. There is no
; need to wait till the transmitter is empty. Load all the data. Check to see if the
Read SRB ; transmitter is empty & ready. You need to do this before you can load the next
; address. Repeat the last 5 steps to load different addresses and their data.

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