blocking vs nonblocking RFAL apis
Hi,
I am trying to understand the difference between blocking/non-blocking rfal apis.
ReturnCode rfalNfcvPollerReadMultipleBlocks( uint8_t flags, const uint8_t* uid, uint8_t firstBlockNum, uint8_t numOfBlocks, uint8_t* rxBuf, uint16_t rxBufLen, uint16_t *rcvLen );
It seems to me that the above api is a blocking one. How can I achieve the same functionality in a non-blocking way ?
The reason I am asking this is because it seems that this api is taking too much time to execute (Without the time required to perform I2C read). Is my understanding correct on the RFAL library sequence for the above api ?
- RFAL library request ST25R3916 for the requested amount of data.
- RFAL waits in a busy wait loop until interrupt pin changes
- Once the interrupt pin changes, RFAL library performs read from ST25R3916.
I am concerned about step 2 as it is a busy wait loop and other threads seem to be starving.
