UARTs

Figure 10-3. IR Transmit and Receive Example

UART TRANSMIT

 

 

START

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

BIT

 

1

 

0

 

 

0

 

 

0

 

 

 

1

 

 

0

 

 

 

1

 

0

 

 

STOP

 

SHIFT VALUE

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

BIT

 

IR ENCODER OUTPUT

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

(TXD PIN VALUE)

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

RXD PIN VALUE

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

IR DECODER OUTPUT

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

START

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

UART RECEIVE

 

 

 

 

BIT

 

1

 

 

0

0

0

 

1

 

 

0

 

1

 

0

 

STOP

 

SHIFT VALUE

 

 

 

 

 

 

 

 

 

 

 

BIT

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

The top line in Figure 10-3shows an asynchronous transmission as it is sent from the UART. The second line shows the pulses generated by the IR encoder at the TXD pin. A pulse is generated in the middle of the START bit and any data bit that is a zero. The third line shows the values received at the RXD input pin. The fourth line shows the receive decoder’s output. The receive decoder drives the receiver data line low when it detects a pulse. The bottom line shows how the UART’s receiver interprets the decoder’s action. This last line is the same as the first, but it is shifted half a bit period.

When XMODE is cleared, each zero bit has a pulse width of 3/16 of a bit time. When XMODE is set, a pulse of 1.6 ∝s is generated in the middle of each zero bit. The shorter infrared pulse generated when XMODE is set reduces the LEDs’ power consumption. At 2400 bps, the LED is normally on for 78 ∝s for each zero bit that is transmitted. When XMODE is set, the LED is on only 1.6 ∝s. XMode changes the behavior of the receiver. The receiver expects pulses of the correct pulse width. If the transceiver crops the incoming pulse, then Xmode must be set.

Note:

Figure 10-4. XMODE Example

1

7

11

16

16X Baud Clock

 

 

 

(14.7456 MHz)

 

 

 

Transmit Start bit

 

 

 

followed by 1

 

 

 

IR_TXD Pin value

 

 

 

XMODE = 0

 

 

 

IR_TXD Pin value

 

3 16X BAUD Clock periods

 

 

 

XMODE = 1

 

 

 

 

 

1.6 s

 

Note: Note: The SIR TXD output pin is automatically held deasserted when the RCVEIR bit is set. Before setting the RCVEIR bit, check that the TEMT bit is 1. While receiving, any data placed in

Intel® PXA255 Processor Developer’s Manual

10-25

Page 383
Image 383
Intel PXA255 manual IR Transmit and Receive Example