1 of 1 people found this helpful
You may read the I2C slave status to poll for a complete transfer and any errors occured. Then by querying the buffer size API you can see how many bytes have been received or need transmission.
Thank you very much Bob, I have found a workaround though not finding, I think, how that software object (I2C Slave) is meant to be used.
I alredy performed a poll checking the status flags but there was the problem I specified in my previous post.
The workaround is to add a futher check to detect the incoming write command using the buffer size API you mentioned (thank you!).
There are two functions, one for the read buffer and one for the write buffer. Currently I check that SlaveGetReadBufSize returns zero because if it receives something but the read buffer is empty it must have been a write command.