Rev. 1.10
92
November 26, 2019
Rev. 1.10
93
November 26, 2019
HT68FB240
USB Low Speed Flash MCU
I
2
C Time Out Operation
The time-out counter will start counting when the I
2
C interface received the START bit and address
match. After that the counter will be cleared on each falling edge of the SCL pin. If the time counter
is larger than the selected time-out time, then the anti-locked protection scheme will take place and
the time-out counter will be stopped by hardware automatically, the I2CTOF bit will be set high and
an I
2
C interrupt will also take place. Note that this scheme can also be stopped when the I
2
C received
the STOP bit. There are several time-out periods can be selected by the I2CTOS0~I2CTOS5 bits in
the I2CTOC register.
I2CTOC Register
Bit
7
6
5
4
3
2
1
0
Name
I2CTOEN I2CTOF I2CTOS5 I2CTOS4 I2CTOS3 I2CTOS2 I2CTOS1 I2CTOS0
R/W
R/W
R/W
R/W
R/W
R/W
R/W
R/W
R/W
POR
0
0
0
0
0
0
0
0
Bit 7
I2CTOEN:
I
2
C Time Out function control bit
0: Disable
1: Enable
Bit 6
I2CTOF:
I
2
C Time Out indication bit
0: Not occurred
1: Occurred
Bit 5~0
I2CTOS5~I2CTOS0:
I
2
C Time out time period select
The I
2
C Time out clock is provided by the f
L
/32. The time out time period can be
calculated from the accompanying equation.
([I2CTOS5:I2CTOS0]
+
1) × (32/f
L
)