
APPENDIX E SUMMARY OF PRECAUTIONS
AP-E-6
EPSON
S1C33E07 TECHNICAL MANUAL
Depending on the counter and comparison register values, an NMI or reset signal may be generated after
the NMI or reset function is enabled, or immediately after the watchdog timer starts. Always be sure to set
comparison data and reset the watchdog timer before writing 1 to NMIEN (D1/0x300662), RESEN (D0/
0x300662), or RUNSTP (D4/0x300662).
NMIEN: Watchdog Timer NMI Enable Bit in the Watchdog Timer Enable Register (D1/0x300662)
RESEN: Watchdog Timer RESET Enable Bit in the Watchdog Timer Enable Register (D0/0x300662)
RUNSTP: Watchdog Timer Run/Stop Control Bit in the Watchdog Timer Enable Register (D4/0x300662)
General-purpose Serial Interface (EFSIO)
Before setting various serial-interface parameters, make sure the transmit and receive operations are disabled
(TXENx = RXENx = 0).
TXENx: Serial I/F Ch.x Transmit Enable Bit in the Serial I/F Ch.x Control Register (D7/0x300Bx3)
RXENx: Serial I/F Ch.x Receive Enable Bit in the Serial I/F Ch.x Control Register (D6/0x300Bx3)
When the serial interface is transmitting or receiving data, do not set TXENx or RXENx to 0, and do not
execute the slp instruction.
In clock-synchronized transfers, the mode of communication is half-duplex, in which the clock line is shared
between the transmit and receive units. Therefore, RXENx and TXENx cannot be enabled simultaneously.
After an initial reset, the cause-of-interrupt flags become indeterminate. To prevent generation of an
unwanted interrupt or IDMA request, reset these flags in the program.
If a receive error occurs, the receive-error interrupt and receive-buffer full interrupt causes occur
simultaneously. However, since the receive-error interrupt has priority over the receive-buffer full interrupt,
the receive-error interrupt is processed first. Therefore, it is necessary to reset the receive-buffer full interrupt
cause flag through the use of the receive-error interrupt processing routine.
To prevent the regeneration of interrupts due to the same cause of interrupt following the occurrence of an
interrupt, always be sure to reset the cause-of-interrupt flag before setting the PSR again or executing the reti
instruction.
Follow the procedure described below to initialize the serial interface.
Set IRMDx[1:0]
Set SMDx[1:0]
Other settings
Enable transmitting/receiving
00(normal I/F) or 10(IrDA I/F)
Transfer mode setting
Data format and clock selection
Internal division ratio, IrDA I/O logic
and other settings
Enable transmitting, receiving or both
Figure E.1 Serial Interface Initialize Procedure
When transmitting data in clock-synchronized master mode, transmit data is written to the transmit data
register after the initial setting is performed following the flow above. However, the clock generated by the
baud-rate timer must be supplied to the serial interface (at least one underflow has had to have occurred in
the baud-rate timer) before this writing. Otherwise, 0xFF will be transmitted prior to the written data.
The maximum transfer rate of the serial interface is limited to 8 Mbps in clock-synchronized mode or 1 Mbps
in asynchronous mode. Do not set a transfer rate (baud rate) that exceeds the limit.
If the receive circuit is stopped during reception, set both transmission and reception to the disabled status.
When performing data transfer in the clock-synchronized mode, the division ratio of the reload data for the
baud-rate timer should be set so that the baud-rate is 1/4 of the system clock frequency or lower.