A96G150 User's manual
15. Combination of USART, SPI, and I2C (USI)
203
To operate as a slave when the MLOSTn bit in USInST2 is set, the ACKnEN bit in USInCR4
must be set and the received 7-bit address must equal to the USInSLA[6:0] bits in USInSAR.
In this case I2C operates as a slave transmitter or a slave receiver (go to appropriate section).
In this stage, I2C holds the SCLn LOW. This is because to decide whether I2C continues serial
transfer or stops communication. The following steps continue assuming that I2C does not
lose mastership during first data transfer.
I2C (Master) can choose one of the following cases according to the reception of ACK signal
from slave:
Case 1: Master receives ACK signal from slave, so continues data transfer because slave can
prepare and transmit more data to master. Configure ACKnEN bit in USInCR4 to decide
whether I2C ACKnowledges the next data to be received or not.
Case 2: Master stops data transfer because it receives no ACK signal from slave. In this case,
set the STOPCn bit in USInCR4.
Case 3: Master transmits repeated START condition due to no ACK signal from slave. In this
case, load SLAn+R/W into the USInDR and set STARTCn bit in USInCR4.
After doing one of the actions above, write arbitrary value to USInST2 to release SCLn line.
For the case 1, move to step 7. For the case 2, move to step 9 to handle STOP interrupt. For
the case 3, move to step 6 after transmitting the data in USInDR and if transfer direction bit is
‘0’ go to master transmitter section.
7.
1-Byte of data is being received.
8.
This is ACK signal processing stage for data packet transmitted by slave. I2C holds the SCLn
LOW. When 1-Byte of data is received completely, I2C generates TENDn interrupt.
I2C can choose one of the following cases according to the RXACKn flag in USInST2:
Case 1: Master continues receiving data from slave. To do this, set ACKnEN bit in USInCR4
to ACKnowledge the next data to be received.
Case 2: Master wants to terminate data transfer when it receives next data by not generating
ACK signal. This can be done by clearing ACKnEN bit in USInCR4.
Case 3: Because no ACK signal is detected, master terminates data transfer. In this case, set
the STOPCn bit in USInCR4.
Case 4: No ACK signal is detected, and master transmits repeated START condition. In this
case, load SLAn+R/W into the USInDR and set the STARTCn bit in USInCR4.
Содержание A96G150
Страница 126: ...12 Timer 0 1 2 3 4 5 A96G150 User s manual 126 Figure 43 16 bit Timer Counter Mode Operation Example...
Страница 136: ...12 Timer 0 1 2 3 4 5 A96G150 User s manual 136 Figure 51 16 bit Timer Counter Mode Operation Example...
Страница 147: ...A96G150 User s manual 12 Timer 0 1 2 3 4 5 147 Figure 59 16 bit Timer Counter Mode Operation Example...
Страница 157: ...A96G150 User s manual 12 Timer 0 1 2 3 4 5 157 Figure 67 16 bit Timer Counter Mode Operation Example...
Страница 171: ...A96G150 User s manual 14 12 bit ADC 171 Figure 79 ADC Operation Flow Sequence...
Страница 333: ...A96G150 User s manual Revision history 333 Revision history Revision Date Notes 1 00 2022 06 22 First creation...