Jump to main content

##

# 2.131.6 USARTx_ReadIsBusy Function

## C

    /* x = FLEXCOM instance number */

    /* Non-blocking mode */
    bool USARTx_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 a read operation 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

USARTx_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(USART1_ReadIsBusy() == true)
    {
        //USART is currently processing the previous read request.
        //Wait to submit new request.
    }

## Remarks

None.