MSC8144E Reference Manual, Rev. 3
20-8
Freescale
Semiconductor
UART
Begin a UART transmission as follows:
1.
Configure the UART:
a. Select a baud rate. Write the appropriate value to the SCIBR to start the baud-rate
generator. Note that the baud-rate generator is disabled when the baud rate is zero.
Writing to the 5 MSB (SBR[12–8]) bits of the SCIBR has no effect without also
writing to the 8 LSB of SCIBR (SBR[7–0]).
b. Configure
GPIO14
for UART
UTXD
(see
, GPIO):
•
Select the UART transmit signal for the GPIO14 external connection via the
GPIO14 configuration registers.
•
Set the direction bit for the GPIO14 port to select output.
c. Write to the SCICR to configure data length, parity, and other configuration bits (LOOPS,
RSRC, M, WAKE, ILT, PE, PT) and enable the transmit and receive interrupts as required
(TIE, TCIE, RIE, ILIE, TE, RE, RWU, and SBK). A preamble character is now shifted out of
the transmitter shift register.
2.
Perform the transmit procedure for each character:
d. Poll the TDRE flag by reading the SCISR or responding to the UART interrupt. Keep
in mind that the TDRE reset value is one.
e. If the TDRE flag is set, write the data to be transmitted to SCIDR, where the ninth bit is
written to the T8 bit in SCIDR if the UART is in 9-bit data format. Reading TDRE bit in the
SCISR and then writing new data to T[7–0] in the SCIDR clears the TDRE flag. Otherwise,
the last data transmitted and then
UTXD
goes to idle condition, that is, a logic 1 (high).
3.
Repeat step 2 for each subsequent transmission.
Note:
The TDRE flag is set when the shift register is loaded with the next data to be
transmitted from SCIDR, which occurs 9/16ths of a bit time after the start of the stop
bit of the previous frame.
Note:
When the shift register is empty (the TC and TDRE flags are set), transmission starts
until one bit time after the data register is written. If only the TC interrupt source is
enabled (SCICR[TCIE] = 1, SCICR[TIE] = 0), then you must ensure at least one bit
time interval between successive writes to the SCIDR to enable the transmitter
software to write twice to the SCIDR per interrupt.
Setting the Transmitter Enable (SCICR[TE]) bit to 1 automatically loads the transmit shift
register with a preamble of 10 logic 1s (if M = 0) or 11 logic 1s (if M = 1). After the preamble
shifts out, control logic transfers the data from the SCIDR into the transmit shift register. A logic
0 start bit automatically goes into the least significant bit position of the transmit shift register. A
logic 1 stop bit goes into the most significant bit position.
Hardware supports odd or even parity. When parity is enabled, the most significant bit (msb) of
the data character is the parity bit.
Summary of Contents for MSC8144E
Page 1: ...MSC8144E Reference Manual Quad Core Media Signal Processor MSC8144ERM Rev 3 July 2009 ...
Page 48: ...MSC8144E Reference Manual Rev 3 xlviii Freescale Semiconductor ...
Page 86: ...MSC8144E Reference Manual Rev 3 1 38 Freescale Semiconductor Overview ...
Page 168: ...MSC8144E Reference Manual Rev 3 3 60 Freescale Semiconductor External Signals ...
Page 242: ...MSC8144E Reference Manual Rev 3 5 26 Freescale Semiconductor Reset ...
Page 314: ...MSC8144E Reference Manual Rev 3 8 24 Freescale Semiconductor General Configuration Registers ...
Page 414: ...MSC8144E Reference Manual Rev 3 10 14 Freescale Semiconductor MSC8144E SC3400 DSP Subsystem ...
Page 452: ...MSC8144E Reference Manual Rev 3 11 38 Freescale Semiconductor Internal Memory Subsystem ...
Page 520: ...MSC8144E Reference Manual Rev 3 12 68 Freescale Semiconductor DDR SDRAM Memory Controller ...
Page 1070: ...MSC8144E Reference Manual Rev 3 21 28 Freescale Semiconductor Timers ...