
25
* This specification are subject to be changed without notice.
6.11.1998
EM73400
4-BIT MICRO-CONTROLLER FOR GENERAL PURPOSE PRODUCT
(1b) . To receive 4-bit data by internal clock with trailing edge shift mode .
LDIA
#0110b
OUTA P31 ; setting SIO in internal clock receive mode with leading edge shift type.
LDIA
#1110b
OUTA P31 ; start SIO transfer.
(2a) . To terminate receive 4-bit data by internal clock with leading edge shift mode .
LDIA #0100b;
OUTA P31 ; terminate SIO internal clock receive mode with leading edge shift type.
SIOEND: TTP P14,3
SBR SIOEND; Check SIO ending; SCSS=0.
(2b) . To terminate receive 4-bit data by internal clock with trailing edge shift mode .
LDIA #0110b;
OUTA P31 ; terminate SIO internal clock receive mode with trailing edge shift type .
SIOEND: TTP P14,3
SBR SIOEND; Check SIO ending; SCSS=0
b. External clock type:
Receive mode with external clock type is transfer 4-bit data from outside system to SIO data buffer of CPU by
external clock source. There are two types of external clock receive mode; one is data shift in leading edge,
the other in trailing edge, these different condition setting is decided by P31 .
The operation procedure of receive mode with external clock is as following.
1. Setting the receive mode and type by setting P31 = 0 1 X 1 .
2. Start SIO transfer by setting P31 = 11 X 1 .
3. By the external clock, SIO control start to transfer 4-bit data into shift register from LSB to MSB from P9.0/
SI pin until the shift register is full ,then shift register send data to SIO data buffer.
4. As SIO processing, user can get the SIO status by P14.
5. When SIO data buffer (P15) becomes full, the SIO control unit will send a SIOI interrupt request to the
interrupt service rountine to request read the transfer data from P15.
6. The SIOI interrupt request will be clear after CPU read the data from data buffer.
7. To stop current SIO receive mode is sending STC(P31.3) "0" in interrupt service rountine, then the current
SIO transfer will be stoped, user can detect the SIO ending by SCSS ( P14.3) be "0" .
NOTE: The leading edge shift mode is shift data in every leading edge of serial clock ( the falling edge of SCK
), for receive mode of leading edge type, user must put the data in P9.0/SI before the serial clock start.
STC
SIO external clock receive mode with leading edge shift type
SIOS
SIOSS
SCK
SO
SIOI
PORT 15
D
D'
D0
D1
D2
D3
D'
0
D'
1
D'
2
D'
3
Read SIO data buffer (P15)