English
Language : 

HD64F3048VTF8 Datasheet, PDF (558/903 Pages) Renesas Technology Corp – Hardware Manual Renesas 8-Bit Single-Chip
Section 14 Smart Card Interface
14.3.6 Transmitting and Receiving Data
Initialization
Before transmitting or receiving data, initialize the smart card interface by the procedure below.
Initialization is also necessary when switching from transmit mode to receive mode or from
receive mode to transmit mode.
1. Clear the TE and RE bits to 0 in the serial control register (SCR).
2. Clear the ERS, PER, and ORER error flags to 0 in the serial status register (SSR).
3. Set the parity mode bit (O/E) and baud rate generator clock source select bits (CKS1 and
CKS0) as required in the serial mode register (SMR). At the same time, clear the C/A, CHR,
and MP bits to 0, and set the STOP and PE bits to 1.
4. Set the SMIF, SDIR, and SINV bits as required in the smart card mode register (SCMR).
When the SMIF bit is set to 1, the TxD0 and RxD0 pins switch from their I/O port functions to
their serial communication interface functions, and are placed in the high-impedance state.
5. Set a value corresponding to the desired bit rate in the bit rate register (BRR).
6. Set clock enable bit 0 (CKE0) as required in the serial control register (SCR). Write 0 in the
TIE, RIE, TE, RE, MPIE, TEIE, and CKE1 bits. If bit CKE0 is set to 1, a serial clock will be
output from the SCK0 pin.
7. Wait for at least the interval required to transmit or receive one bit, then set the TIE, RIE, TE,
and RE bits as necessary in SCR. Do not set TE and RE both to 1, except when performing a
loop-back test.
Rev. 3.00 Sep 27, 2006 page 530 of 872
REJ09B0325-0300