Technical information
Using NewBIOS Serial Solutions
inregs.h.al = 0x9A; /* Parameters as above. */
inregs.x.dx = 0x0; /* COM1. */
int86(0x14, &inregs, &outregs); /* Async services. */
/* Note:- that the return value
and the value assigned to outregs are not used. */
/* Note:- also the address operator ’&’ used with inregs
and outregs. */
The file BIOS.H includes a set of manifest constants for use
with the standard asynchronous services. Using them makes the
use of int86() slightly easier, so the above code would be:
inregs.h.ah = _COM_INIT; /* Service 0, initialise. */
inregs.h.al = _COM_1200 +_COM_EVENPARITY +_COM_CHR7+_COM_STOP1;
/* Parameters */
inregs.x.dx = 0x0; /* COM1. */
int86(0x14, &inregs, &outregs); /* Asynchronous services. */
Chapter 4 Page 51