DLPU057A March 2018 – April 2022
A read failure can occur because of two reasons:
A read command will try to execute first before sending the response. Hence the slave may take more time to send the response for a read command. The response byte will indicate the failure status on encountering any error. In case of failure, only the response byte is transmitted by the slave. There is no read checksum or read bytes in such cases.
If the master tries to read additional bytes, the slave will respond with dummy bytes (0xFF). The slave will ignore all such bytes transmitted by master (bytes 119 to 121 in below figure) till it receives the next start of a command character (0xA5). If the slave ignores any bytes, it will be flagged in the system status bit “SPI Bytes Ignored”.
This example shows a case where the read command fails because of Length Mismatch in the transmitted data. The data length should be “00”. The slave response byte will indicate 0x05 (Length Mismatch).
111 | 112 | 113 | 114 | 115 | 116 | 117 | |
Host (Master) | A5 | 01 | 02 | FF | FF | 00 | 00 |
Piccolo (Slave) | FF | FF | FF | FF | FF | FF | FF |
118 | 119 | 120 | 121 | |
Host (Master) | 00 | 00 | 00 | 00 |
Piccolo (Slave) | 05 | FF | FF | FF |