2 configuration, 1 uart mode, Configuration -49 – Freescale Semiconductor MCF5480 User Manual

Page 811: Uart mode -49

Advertising
background image

Software Environment

MCF548x Reference Manual, Rev. 3

Freescale Semiconductor

26-49

26.7.2

Configuration

26.7.2.1

UART Mode

The following is a sample initialization sequence for UART mode.

Table 26-41. Sample Initialization Sequence for UART Mode

Step

No.

Register

Value

Details

Meaning

1

PSCSICR

08

RxDCD=1

DCD input effects receiver

SIM[2:0]=000

UART mode

2

PSCCSR

DD

RCS[3:0]=1101

Receiver baud rate is made from PSC timer

TCS[3:0]=1101

Transmitter baud rate is made from PSC timer

3

PSCCTUR

00

CT[15:0]=108 (dec)

Divide sys_clk by 108. If f(sys_clk) = 33.3333 MHz,

baud rate is 9600 bps.

PSCCTLR

6C

4

PSCCR

20

MISC=010

Reset receiver and RxFIFO

30

MISC=011

Reset transmitter and TxFIFO

40

MISC=100

Reset all error status

50

MISC=101

Reset break change interrupt

10

MISC=001

Reset MR pointer

5

PSCIMR

8700

IPC=1

Enable input port change interrupt

DB=1

Enable delta break interrupt

RxRDY or FU=1

Enable receiver interrupt/request

TxRDY=1

Enable transmitter interrupt/request

6

PSCACR

03

IEC1=1

Enable state change of DCD

IEC0=1

Enable state change of PSCnCTS

7

PSCMR1

23

RxRTS=0

Receiver has no effect on PSCnRTS

RxIRQ=0

RX interrupt is from RxRDY (one byte)

ERR=1 (fixed)

Block error mode

PM[1:0]=00, PMT=0

even parity

BC[1:0]=11

8 bit

8

PSCMR2

37

CM[1:0]=00

Normal mode (not test mode)

TxRTS=1

PSCnRTS is controlled by transmitter

TxCTS=1

PSCnCTS controls transmitter

SB[3:0]=0111

1 stop bit

Advertising
This manual is related to the following products: