Datasheet
237
7593L–AVR–09/12
AT90USB64/128
Table 21-6. Status codes for Slave Transmitter mode.
Status code
(TWSR) pr-
escaler bits
are 0
Status of the 2-wire serial bus and
2-wire serial interface hardware
Application software response
Next action taken by TWI hardware
To/from TWDR
To TWCR
STA STO TWINT TWEA
0xA8 Own SLA+R has been received;
ACK has been returned
Load data byte
or
Load data byte
X
X
0
0
1
1
0
1
Last data byte will be transmitted and NOT ACK should
be received
Data byte will be transmitted and ACK should be re-
ceived
0xB0 Arbitration lost in SLA+R/W as
Master; own SLA+R has been re-
ceived; ACK has been returned
Load data byte
or
Load data byte
X
X
0
0
1
1
0
1
Last data byte will be transmitted and NOT ACK should
be received
Data byte will be transmitted and ACK should be re-
ceived
0xB8 Data byte in TWDR has been
transmitted; ACK has been re-
ceived
Load data byte
or
Load data byte
X
X
0
0
1
1
0
1
Last data byte will be transmitted and NOT ACK should
be received
Data byte will be transmitted and ACK should be re-
ceived
0xC0 Data byte in TWDR has been
transmitted; NOT ACK has been
received
No TWDR action
or
No TWDR action
or
No TWDR action
or
No TWDR action
0
0
1
1
0
0
0
0
1
1
1
1
0
1
0
1
Switched to the not addressed Slave mode;
no recognition of own SLA or GCA
Switched to the not addressed Slave mode;
own SLA will be recognized;
GCA will be recognized if TWGCE = “1”
Switched to the not addressed Slave mode;
no recognition of own SLA or GCA;
a START condition will be transmitted when the bus be-
comes free
Switched to the not addressed Slave mode;
own SLA will be recognized;
GCA will be recognized if TWGCE = “1”;
a START condition will be transmitted when the bus be-
comes free
0xC8 Last data byte in TWDR has been
transmitted (TWEA = “0”); ACK
has been received
No TWDR action
or
No TWDR action
or
No TWDR action
or
No TWDR action
0
0
1
1
0
0
0
0
1
1
1
1
0
1
0
1
Switched to the not addressed Slave mode;
no recognition of own SLA or GCA
Switched to the not addressed Slave mode;
own SLA will be recognized;
GCA will be recognized if TWGCE = “1”
Switched to the not addressed Slave mode;
no recognition of own SLA or GCA;
a START condition will be transmitted when the bus be-
comes free
Switched to the not addressed Slave mode;
own SLA will be recognized;
GCA will be recognized if TWGCE = “1”;
a START condition will be transmitted when the bus be-
comes free