Simple Example Using _bios_serialcom() (39501)
The information in this article applies to:
- The C Run-Time (CRT), when used with:
- Microsoft C for MS-DOS 5.1
- Microsoft C for MS-DOS 6.0
- Microsoft C for MS-DOS 6.0a
- Microsoft C for MS-DOS 6.0ax
- Microsoft C/C++ for MS-DOS 7.0
This article was previously published under Q39501 SUMMARY
Below is an example of using the C run-time library function
_bios_serialcom() to transmit and receive a single character over the
serial-communications port COM1.
The _bios_serialcom() routine simply calls the PC's ROM BIOS interrupt
14h. On most PCs, these routines are not interrupt-driven or buffered.
As a result, characters may be lost if a significant amount of
processing occurs between status checks and reads and/or when
receiving very high-speed transmissions, 1200 baud is the recommended
maximum. Although Microsoft does not provide interrupt-driven serial
I/O routines with our C compilers, there are several third-parties
that do. A partial listing is available in the Language Support
Directory that comes with the compiler.
For additional information about ROM BIOS calls, please refer to "IBM
ROM BIOS" by Ray Duncan, published by Microsoft Press.
If ROM BIOS routines are not operating as expected, you may need to
contact the company that supplied the BIOS for your particular
machine.
Modification Type: | Major | Last Reviewed: | 12/11/2003 |
---|
Keywords: | kb16bitonly KB39501 |
---|
|