18 UART
18-4
EPSON
S1C17704 TECHNICAL MANUAL
18.4 Setting Transfer Data Conditions
The following conditions are selectable to configure transfer data format:
• Character length: 7 or 8 bits
• Start bit:
1 bit, fixed
• Stop bit:
1 or 2 bits
• Parity bit:
Even, odd, or none
Note
: Make sure that the UART is disabled (RXEN/UART_CTL register = 0) when setting the transfer
data conditions.
∗
RXEN
: UART Enable Bit in the UART Control (UART_CTL) Register (D0/0x4104)
Character length
Use the CHLN bit (D4/UART_MOD register) to select the character length. When CHLN is set to 0 (default),
the character length is configured to seven bits; when CHLN is set to 1, the character length is configured to
eight bits.
∗
CHLN
: Character Length Select Bit in the UART Mode (UART_MOD) Register (D4/0x4103)
Stop bit
Use the STPB bit (D1/UART_MOD register) to select the stop bit length. When STPB is set to 0 (default), the
stop bit length is set to one bit; when STPB is set to 1, the stop bit length is set to two bits.
∗
STPB
: Stop Bit Select Bit in the UART Mode (UART_MOD) Register (D1/0x4103)
Parity bit
Use the PREN bit (D3/UART_MOD register) to select whether the parity function is enabled or not. When
PREN is set to 0 (default), parity function is disabled. In this case, a parity bit will not be added to transfer
data and the parity check will not be performed when data is received. When PREN is set to 1, parity function
is enabled. In this case, a parity bit will be added to transfer data and the parity check will be performed when
data is received.
When the parity function is enabled, select a parity mode using the PMD bit (D2/UART_MOD register). When
PMD is set to 0 (default), the parity bit is added/checked as even parity; when PMD is set to1, the parity bit is
added/checked as odd parity.
∗
PREN
: Parity Enable Bit in the UART Mode (UART_MOD) Register (D3/0x4103)
∗
PMD
: Parity Mode Select Bit in the UART Mode (UART_MOD) Register (D2/0x4103)
Sampling clock (sclk•1/16)
CHLN = 0, PREN = 0, STPB = 0
CHLN = 0, PREN = 1, STPB = 0
CHLN = 0, PREN = 0, STPB = 1
CHLN = 0, PREN = 1, STPB = 1
CHLN = 1, PREN = 0, STPB = 0
CHLN = 1, PREN = 1, STPB = 0
CHLN = 1, PREN = 0, STPB = 1
CHLN = 1, PREN = 1, STPB = 1
s1
D0
D1
D2
D3
D4
D5
D6
s2
s1
D0
D1
D2
D3
D4
D5
D6
p
s2
s1
D0
D1
D2
D3
D4
D5
D6
s2
s3
s1
D0
D1
D2
D3
D4
D5
D6
p
s2
s3
s1
D0
D1
D2
D3
D4
D5
D6
D7
s2
s1
D0
D1
D2
D3
D4
D5
D6
D7
p
s2
s1
D0
D1
D2
D3
D4
D5
D6
D7
s2
s3
s1
D0
D1
D2
D3
D4
D5
D6
D7
p
s2
s3
s1: start bit, s2 & s3: stop bit, p: parity bit
Figure 18.4.1 Transfer Data Format
Содержание S1C17704
Страница 1: ...TECHNICAL MANUAL S1C17704 CMOS 16 BIT SINGLE CHIP MICROCOMPUTER ...
Страница 22: ...1 OVERVIEW 1 10 EPSON S1C17704 TECHNICAL MANUAL THIS PAGE IS BLANK ...
Страница 42: ...3 MEMORY MAP BUS CONTROL 3 12 EPSON S1C17704 TECHNICAL MANUAL THIS PAGE IS BLANK ...
Страница 82: ...6 INTERRUPT CONTROLLER ITC 6 26 EPSON S1C17704 TECHNICAL MANUAL THIS PAGE IS BLANK ...
Страница 108: ...8 CLOCK GENERATOR CLG 8 8 EPSON S1C17704 TECHNICAL MANUAL THIS PAGE IS BLANK ...
Страница 112: ...9 PRESCALER PSC 9 4 EPSON S1C17704 TECHNICAL MANUAL THIS PAGE IS BLANK ...
Страница 138: ...10 I O PORTS P 10 26 EPSON S1C17704 TECHNICAL MANUAL THIS PAGE IS BLANK ...
Страница 156: ...11 16 BIT TIMERS T16 11 18 EPSON S1C17704 TECHNICAL MANUAL THIS PAGE IS BLANK ...
Страница 208: ...14 8 BIT OSC1 TIMER T8OSC1 14 16 EPSON S1C17704 TECHNICAL MANUAL THIS PAGE IS BLANK ...
Страница 234: ...16 STOPWATCH TIMER SWT 16 14 EPSON S1C17704 TECHNICAL MANUAL THIS PAGE IS BLANK ...
Страница 242: ...17 WATCHDOG TIMER WDT 17 8 EPSON S1C17704 TECHNICAL MANUAL THIS PAGE IS BLANK ...
Страница 264: ...18 UART 18 22 EPSON S1C17704 TECHNICAL MANUAL THIS PAGE IS BLANK ...
Страница 300: ...20 I2C 20 20 EPSON S1C17704 TECHNICAL MANUAL THIS PAGE IS BLANK ...
Страница 320: ...21 REMOTE CONTROLLER REMC 21 20 EPSON S1C17704 TECHNICAL MANUAL THIS PAGE IS BLANK ...
Страница 360: ...24 ON CHIP DEBUGGER DBG 24 6 EPSON S1C17704 TECHNICAL MANUAL THIS PAGE IS BLANK ...
Страница 362: ...25 BASIC EXTERNAL WIRING DIAGRAM 25 2 EPSON S1C17704 TECHNICAL MANUAL THIS PAGE IS BLANK ...