NEC 78K0/KD1 Series User Manual page 265

8-bit single-chip microcontrollers
Table of Contents

Advertisement

(3) Example of setting baud rate
Baud Rate
f
= 10.0 MHz
X
[bps]
TPS01,
k
TPS00
2400
4800
9600
3
16
10400
3
15
19200
3
8
31250
2
20
38400
2
16
76800
2
8
115200
1
22
153600
1
16
230400
1
11
Remark TPS01, TPS00:
k:
f
:
X
ERR:
CHAPTER 13 SERIAL INTERFACE UART0
Table 13-3. Set Data of Baud Rate Generator
Calculated
ERR[%]
TPS01,
Value
TPS00
3
9766
1.73
3
10417
0.16
3
19531
1.73
2
31250
0
2
39063
1.73
2
78125
1.73
1
−1.36
113636
1
156250
1.73
1
−1.36
227273
1
Bits 7 and 6 of baud rate generator control register 0 (BRGC0) (setting of base clock
(f
))
XCLK
Value set by the MDL04 to MDL00 bits of BRGC0 (k = 8, 9, 10, ..., 31)
X1 input clock oscillation frequency
Baud rate error
Preliminary User's Manual U16315EJ1V0UD
f
= 8.38 MHz
X
k
Calculated
ERR[%]
TPS01,
Value
TPS00
27
4850
1.03
−2.58
14
9353
−3.15
13
10072
27
19398
1.03
−1.41
17
30809
−2.58
14
38796
27
77593
1.03
18
116389
1.03
−2.58
14
149643
9
232778
1.03
f
= 4.19 MHz
X
k
Calculated
ERR[%]
Value
3
27
2425
1.03
−2.58
3
14
4676
2
27
9699
1.03
2
25
10475
0.72
−2.58
2
14
18705
2
27
38796
1.03
−2.58
1
14
74821
1
9
116389
1.03
265

Hide quick links:

Advertisement

Table of Contents
loading

Table of Contents