Intel 8XC196MH manual Programming the Baud Rate and Clock Source, Clksrc, BV7, BV9 BV8, BV1 BV0

Models: 8XC196MD 8XC196MH 8XC196MC

1 579
Download 579 pages 24.12 Kb
Page 181
Image 181

8XC196MC, MD, MH USER’S MANUAL

7.4.3Programming the Baud Rate and Clock Source

The SPx_BAUD register (Figure 7-7) selects the clock input for the baud-rate generator and de- fines the baud rate for all serial I/O modes. (For mode 4 with SCLKx# configured for input, the baud-rate generator is not used.) This register acts as a control register during write operations and as a down-counter monitor during read operations.

WARNING

Writing to the SPx_BAUD register during a reception or transmission can corrupt the received or transmitted data. Before writing to SPx_BAUD, check the SPx_STATUS register to ensure that the reception or transmission is complete.

SPx_BAUD

Address:

1F84H, 1F8CH

x = 0–1 (8XC196MH)

Reset State:

0000H

The serial port baud rate x (SPx_BAUD) register selects the serial port x baud rate and clock source. The most-significant bit selects the clock source. The lower 15 bits represent BAUD_VALUE, an unsigned integer that determines the baud rate.

The maximum BAUD_VALUE is 32,767 (7FFFH). In asynchronous modes 1, 2, and 3, the minimum BAUD_VALUE is 0000H when using XTAL1 and 0001H when using BCLKx. In synchronous mode 0, the minimum BAUD_VALUE is 0001H for transmissions and 0002H for receptions. In synchronous mode 4, the minimum BAUD_VALUE is 0001H for both transmissions and receptions.

8XC196MH

15

CLKSRC

BV14

BV13

BV12

7

 

 

 

 

 

 

 

BV7

BV6

BV5

BV4

 

 

 

 

8

BV11

BV10

BV9

BV8

 

 

 

0

 

 

 

 

BV3

BV2

BV1

BV0

 

 

 

 

Bit

Bit

Function

Number

Mnemonic

 

 

 

 

15

CLKSRC

Serial Port Clock Source

 

 

This bit determines whether the serial port is clocked from an internal or an

 

 

external source.

 

 

0 = signal on the BCLKx pin (external source)

 

 

1 = input frequency on the XTAL1 pin (internal source)

 

 

 

Figure 7-7. Serial Port x Baud Rate (SPx_BAUD) Register

7-12

Page 181
Image 181
Intel 8XC196MH, 8XC196MD, 8XC196MC manual Programming the Baud Rate and Clock Source, Clksrc, BV7, BV9 BV8, BV1 BV0