1.2.21.16 1.3.25.16 1.4.21.16 1.5.25.16 1.6.22.16 1.7.23.16 1.9.19.16 1.29.23.16 1.30.18.16 1.31.18.16 1.32.26.16 1.33.16.16 1.37.18.16 1.38.21.16 1.39.18.16 1.40.20.16 SERCOMx_USART_ReadIsBusy Function
C
/* x = SERCOM instance number */
/* Non-blocking mode */
bool SERCOMx_USART_ReadIsBusy( void )
Summary
Returns the read request status associated with the given USART peripheral instance
Description
This function returns the read request status associated with the given USART peripheral instance. It can be used to check the completion status of the SERCOMx_USART_Read() function when the library is configured for interrupt (non-blocking) mode. In that, the function can be used as an alternative to using a callback function to check for completion.
Precondition
SERCOMx_USART_Initialize must have been called for the associated USART instance.
Parameters
None.
Returns
true - USART is busy in processing the previous read request
false - USART is free and ready to accept the new read request
Example
if(SERCOM0_USART_ReadIsBusy() == true) { //USART is currently processing the previous read request. //Wait to submit new request. }
Remarks
None