COMM-DRV/Lib: IsOverrunError() Returns true if the UART receive register was overrun

Description-

Returns true if an overrun error occurred since the last call to this function. There are two types of overrun. One is a hardware overrun which means that the UART got another character before COMM-DRV/LIB was able to process the previous character. The second type of overrun occurs if the COMM-DRV/LIB ring buffers (the buffer whose buffer size was given in the InitializePort() or OpenComPort() function). This function returns the hardware overrun condition. The function IsInputOverrun() returns the ring buffer overrun condition.

Syntax-

stat = IsOverrunError(port);

On Entry-

int port;

Port previously opened with OpenComPort().

On Exit-

int stat;

0 If overrun error did not occur.

1 If overrun error occurred.

See Also-

IsBreak()
IsCarrierDetect()
IsCts()
IsDsr()
IsFramingError()
IsInputOverrun()
IsOverrunError()
IsParityError()
IsRing()

Example-

#include “comm.h”

int port=0;
int stat;

if ((stat = IsOverrunError(port)) == 1)
{
printf(“Overrun Error occurred\n”);
}