Intel 386 User Manual

Page 330

Advertising
background image

11-43

ASYNCHRONOUS SERIAL I/O UNIT

/*****************************************************************************

Service_RBF:

Description:

Service routine for interrupts generated by RBF signal. This

routine is used for Interrupt-Driven Serial Reads. It echoes

the typed character to the screen, stopping when it receives

an ESC character.

Parameters:

None

Returns:

None

Assumptions:

None

Syntax:

Not called by user

Real/Protected Mode:

No changes required.

*****************************************************************************/

void Service_RBF (void)

{

/* Read in contents of RBR0 */

rec_buffer = _GetEXRegByte(RBR0);

SerialWriteChar(SIO_0, rec_buffer); // Echo to screen

if ( rec_buffer == 0x1b ) {

/* ESC character received, disable RBF interrupts*/

_SetEXRegByte(IER0,

0x00);

}

}/* Service_RBF */

/*****************************************************************************

SerialWriteStr_Int:

Advertising