UPD78F0138 NEC, UPD78F0138 Datasheet - Page 326

no-image

UPD78F0138

Manufacturer Part Number
UPD78F0138
Description
(UPD78xxxx) 8-Bit Single-Chip Microcontrollers
Manufacturer
NEC
Datasheet

Available stocks

Company
Part Number
Manufacturer
Quantity
Price
Part Number:
UPD78F0138M1GK-9ET
Manufacturer:
NEC
Quantity:
115
Part Number:
UPD78F0138M5GB
Manufacturer:
NEC
Quantity:
20 000
(2) Generation of serial clock
326
A serial clock can be generated by using clock selection register 6 (CKSR6) and baud rate generator control
register 6 (BRGC6).
Select the clock to be input to the 8-bit counter by using bits 3 to 0 (TPS63 to TPS60) of CKSR6.
Bits 7 to 0 (MDL67 to MDL60) of BRGC6 can be used to select the division value of the 8-bit counter.
(a) Baud rate
(b) Error of baud rate
The baud rate can be calculated by the following expression.
• Baud rate =
f
k:
The baud rate error can be calculated by the following expression.
• Error (%) =
Cautions 1. Keep the baud rate error during transmission to within the permissible error range at
XCLK6
Example: Frequency of base clock = 10 MHz = 10,000,000 Hz
: Frequency of base clock selected by TPS63 to TPS60 bits of CKSR6 register
Value set by MDL67 to MDL60 bits of BRGC6 register (k = 8, 9, 10, ..., 255)
2. Make sure that the baud rate error during reception satisfies the range shown in (4)
f
the reception destination.
Permissible baud rate range during reception.
2 × k
XCLK6
Set value of MDL67 to MDL60 bits of BRGC6 register = 00100001B (k = 33)
Target baud rate = 153600 bps
Baud rate = 10 M/(2 × 33)
Error = (151515/153600 − 1) × 100
Actual baud rate (baud rate with error)
Desired baud rate (correct baud rate)
= −1.357 [%]
[bps]
= 10000000/(2 × 33) = 151,515 [bps]
CHAPTER 14 SERIAL INTERFACE UART6
User’s Manual U16228EJ2V0UD
− 1 × 100 [%]

Related parts for UPD78F0138