CMT2380F17
Rev0.1 | 272/347
www.cmostek.com
22 Serial Interface Detection (STWI/SI2C)
The serial interface detection module (SID) is always monitoring the “Start” and “Stop” condition on
software two-wire-interface (STWI/SI2C). STWI_SCL is the serial clock signal and STWI_SDA is the serial
data signal. If any matched condition is detected, hardware set the flag on STAF and STOF. Software can poll
these two flags or set SIDFIE (SFIE.7) to share the interrupt vector on System Flag. And STWI_SCL is
located on nINT1 which helps MCU to strobe the serial data by nINT1 interrupt. Software can use these
resources to implement a variable TWI slave device.
22.1
SID Structure
Figure 22
–1 shows the configuration of STAF and STOF detection, interrupt architecture and event
detecting waveform.
Transition
Detection
STWI_SDA input
(S0MI)
STWI_SCL input
(nINT1)
enable
SYSCLK
STAF
STOF
AUXR2.7
SIDFIE
(SFIE.7)
SID Flags
Interrupt
ESF
(EIE1.3)
AUXR2.6
STWI_SDA
STWI_SCL
Set STAF
Set STOF
Figure 22-1. Serial Interface Detection structure
22.2
SID Register
AUXR2
:
Auxiliary Register 2
SFR Page
= 0~F
SFR Address = 0xA3
Bit
7
6
5
4
3
2
1
0
Name
STAF
STOF
--
--
T1X12
T0X12
T1CKOE
T0CKOE
R/W
R/W
R/W
W
W
W
W
W
W
Reset Value
0
0
X
X
0
0
0
0
Bit 7: STAF, Start Flag detection of STWI (SID).
0: Clear by
firmware by writing “0” on it. STAF might be held within MCU reset period, so needs to clear
STAF in firmware initial.
1: Set by hardware to indicate the START condition occurred on STWI bus.
Bit 6: STOF, Stop Flag detection of STWI (SID). 0: Clear by
firmware by writing “0” on it.
1: Set by hardware to indicate the STOP condition occurred on STWI bus. STOF might be held within
MCU reset period, so needs to clear STOF in firmware initial.
SFIE
:
System Flag Interrupt Enable Register
SFR Page
= 0~F
Summary of Contents for CMT2380F17
Page 27: ...CMT2380F17 Rev0 1 27 347 www cmostek com 1 25 Phase Noise...
Page 177: ...CMT2380F17 Rev0 1 177 347 www cmostek com Figure 17 3 PCA Interrupt System...
Page 246: ...CMT2380F17 Rev0 1 246 347 www cmostek com SnMIPS S0MI S1MI 1 P3 3 P4 7...