Retro video games delivered to your door every month!
Click above to get retro games delivered to your door ever month!
X-Hacker.org- Peter Norton Programmer's Guide - Norton Guide http://www.X-Hacker.org [<<Previous Entry] [^^Up^^] [Next Entry>>] [Menu] [About The Guide]

  Service 03H (decimal 3) returns the complete serial port status in the AX
  register. The 16 status bits in AX are divided into two groups: AH reports
  the line status (which is also reported when errors occur with services
  01H and 02H), and AL reports the modem status, when applicable. Figure
  12-4 contains the bit codings of the status bits. Some codes report
  errors, and others simply report a condition.

  --------------------------------------------------------------------------
  NOTE:
    One special bit of information about the time-out error (AH, bit 7) is
    worth noting: The earliest version of the ROM BIOS for the original PC
    had a programming error that caused a serial-port time-out to be
    reported as a transfer-shift-register-empty/break-detect-error
    combination (bits 01010000 rather than 10000000). This has been
    corrected on all subsequent versions of the ROM BIOS, but it has caused
    many communications programs to treat these error codes skeptically. You
    may want to keep this in mind. See page 63 for details on identifying
    the ROM BIOS version dates and machine ID codes.
  --------------------------------------------------------------------------

        Bit
  7 6 5 4 3 2 1 0          Meaning (when set to 1)
  --------------------------------------------------------------------------
  AH Register (line status)
  1 . . . . . . .          Time-out error
  . 1 . . . . . .          Transfer shift register empty
  . . 1 . . . . .          Transfer holding register empty
  . . . 1 . . . .          Break-detect error
  . . . . 1 . . .          Framing error
  . . . . . 1 . .          Parity error
  . . . . . . 1 .          Overrun error
  . . . . . . . 1          Data ready

  AL Register (modem status)
  1 . . . . . . .          Received line signal detect
  . 1 . . . . . .          Ring indicator
  . . 1 . . . . .          Data-set-ready
  . . . 1 . . . .          Clear-to-send
  . . . . 1 . . .          Delta receive line signal detect
  . . . . . 1 . .          Trailing-edge ring detector
  . . . . . . 1 .          Delta data-set-ready
  . . . . . . . 1          Delta clear-to-send
  --------------------------------------------------------------------------

  Figure 12-4.  The bit coding for the status bytes returned in register AX
  by service 03H.

Online resources provided by: http://www.X-Hacker.org --- NG 2 HTML conversion by Dave Pearson