home *** CD-ROM | disk | FTP | other *** search
/ High Voltage Shareware / high1.zip / high1 / DIR2 / DIGIPROG.ZIP / INT14.TXT < prev    next >
Text File  |  1993-09-01  |  49KB  |  2,341 lines

  1.  
  2.                 
  3.                 
  4.                 
  5.                 
  6.                 
  7.                BIOS Interrupt 14h
  8.                 Functions
  9.  
  10.  
  11.  
  12.  
  13.  
  14.             Supplement to the
  15.                Installation Guide
  16.                    for
  17.              DigiCHANNEL Intelligent
  18.            Asynchronous Communications Boards
  19.            Universal DOS Device Driver
  20.               DOS 2.0 - 5.0
  21.                 
  22. Copyright (C) Digi International, Inc. 1991-1993
  23. All Rights Reserved
  24.  
  25.  
  26.  
  27.  
  28. Information in this document is subject to change without notice
  29. and does not represent a commitment on the part of DigiBoard.
  30.  
  31. DigiBoard provides this document "as is", without warranty of any
  32. kind, either expressed or implied, including, but not limited to, the
  33. particular purpose.  DigiBoard may make improvements and/or changes
  34. in this document or in the product(s) and/or the program(s) described 
  35. in this document at any time.
  36.  
  37. This document could include technical inaccuracies or typographical
  38. errors.  Changes are periodically made to the information herein;
  39. these changes may be incorporated in new editions of the publication.
  40. Table of Contents
  41.  
  42. Introduction                                                   4
  43. Interrupt 14h Function Descriptions                            5
  44.   Initialize a Port  -  Function 00h                           5
  45.   Output a Single Character  -  Function 01h                   7
  46.   Input a Single Character  -  Function 02h                    8
  47.   Get Status  -  Function 03h                                  9
  48.   Extended Port Initialization - Function 04h                 11
  49.   Extended Communications Port Control - Function 05h         13
  50.   Get Driver/Board Information - Function 06h                 14
  51.   Send Break - Function 07h                                   16
  52.   Alternate Status Check - Function 08h                       17
  53.   Clear Buffers - Function 09h                                18
  54.   Input Queue Check - Function 0Ah                            19
  55.   Drop Handshake Lines - Function 0Bh                         20
  56.   Get Channel Parameters - Function 0Ch                       21
  57.   Get Pointer to Character Ready Flag - Function 0Dh          23
  58.   Write String - Function 0Eh                                 24
  59.   Read String - Function 0Fh                                  25
  60.   Clear Receive Buffer - Function 10h                         26
  61.   Clear Transmit Buffer - Function 11h                        27
  62.   Get Transmit Buffer Free Space - Function 12h               28
  63.   Set Handshake Lines - Function 13h                          29
  64.   Non-Destructive Character Read - Function 14h               30
  65.   Input Byte Count - Function 15h                             31
  66.   Pause/Resume Transmit - Function 17h                        32
  67.   Pause/Resume Receive - Function 18h                         33
  68.   Get Water Marks and Buffer Size - Function 1Bh              34
  69.   Set Water Marks - Function 1Ch                              35
  70.   Set Flow Control - Function 1Eh                             36
  71.   Enable/Disable Read/Write Timeouts - Function 20h           38
  72.   Presence Test - EBIOS Function F4h                          39
  73.   Specify Modem Leads - EBIOS Function FBh                    40
  74.   Receive with No Wait - EBIOS Function FCh                   41
  75.   Retrieve Buffer Count - EBIOS Function FDh                  42
  76.   Set Pacing Mode - EBIOS Function FEh                        43
  77.   Set Buffered Mode - EBIOS Function FFh                      44
  78.  
  79.  
  80.  
  81.  
  82.  
  83.  
  84.  
  85.  
  86.  
  87.  
  88.  
  89.  
  90.  
  91.  
  92.  
  93.  
  94.  
  95.  
  96.  
  97.  
  98.                                   3
  99. Introduction
  100.  
  101. The  DOS device driver for DigiCHANNEL intelligent communications
  102. boards  provides an interface for programmers via BIOS  interrupt
  103. 14h.  This software interface provides over 30 functions to allow
  104. programmers  to read and write single characters  or  strings  of
  105. characters, get status information, set communication parameters,
  106. control handshake lines, check interrupt status, etc.
  107.  
  108. Interrupt 14h functions are invoked by placing a function  number
  109. in  the  CPU's  AH  register, the number of  the  channel  to  be
  110. affected  in  the DX register and the parameters associated  with
  111. that  function in one or more of the remaining CPU registers  (as
  112. specified  by the particular function).  After the registers  are
  113. loaded,  a  software Interrupt 14h is generated by  a  issuing  a
  114. special  interrupt  command. In C, this  command  is  int86(0x14,
  115. ®s, ®s), where regs is a union of the CPU registers.  Other
  116. languages  may  use different conventions, and  some  don't  have
  117. software   interrupt  capability - see  your  programming  language
  118. reference manual for the correct command syntax.  Upon completion
  119. of the command, status will be returned in one or more of the CPU
  120. registers.
  121.  
  122. When the DOS device driver is loaded, it takes over the interrupt
  123. 14h  vector,  but  saves  the address of any  handler  previously
  124. assigned to that interrupt.  Thus, if an interrupt 14h request is
  125. generated  for  a  non-DigiCHANNEL device (i.e. the  DX  register
  126. contains a channel number not assigned to the DigiBoard), control
  127. is  transferred to the previously defined vector.   This  enables
  128. the  DigiBoard  device driver to co-exist with the  standard  DOS
  129. COM1/COM2  driver, as well as EBIOS drivers and others which  may
  130. also use interrupt 14h.
  131.  
  132.  
  133.  
  134.  
  135.  
  136.  
  137.  
  138.  
  139.  
  140.  
  141.  
  142.  
  143.  
  144.  
  145.  
  146.  
  147.  
  148.  
  149.  
  150.  
  151.  
  152.  
  153.  
  154.  
  155.  
  156.  
  157.                                   4
  158. Interrupt 14h Function Descriptions
  159.  
  160.  
  161. Initialize a Port - Function 00h
  162.  
  163. This function initializes a port with the specified parameters.
  164. NOTES - See Function 04h - Extended Port Initialization, for  more
  165. options.
  166.  
  167. If EBIOS support was included in the DOS device driver configuration 
  168. (via the set-up program), 110 baud is replaced by 19200 baud in this 
  169. function.  In this case, 110 baud can still be obtained by executing 
  170. Function 04h - Extended Port Initialization.
  171.  
  172. Preparation
  173.  
  174. Before  requesting  Interrupt 14h,  load  the  CPU  registers  as
  175. follows:
  176.  
  177.   DX  xxxx Channel number.
  178.   AH  00h  Function number.
  179.   AL  xx   Channel parameters:
  180.            Bits 0, 1 = Data bits per character:
  181.          00 = 5 bits
  182.          01 = 6 bits
  183.          10 = 7 bits
  184.          11 = 8 bits
  185.            Bit 2 = Stop bits:
  186.          0  =  1  stop  bit    NOTE- 1.5  stop bits can only be
  187.          1  =  2  stop  bits   set  by  the  configuration utility.
  188.            Bits 3, 4 = Parity:
  189.          00 = No parity
  190.          01 = Odd parity
  191.          10 = No parity
  192.          11 = Even parity
  193.            Bits 5, 6, 7 = Baud rate:
  194.          000 = 110 baud    (or  19200, if EBIOS is supported)
  195.          001 = 150 baud       (or  19200, if EBIOS is supported)
  196.          010 = 300 baud    (or  38400, if EBIOS is supported)
  197.          011 = 600 baud    (or  57600, if EBIOS is supported)
  198.          100 = 1200 baud   (or 115200, if EBIOS is supported)
  199.                    (No 115200 substitution on C/X driver.)
  200.          101 = 2400 baud
  201.          110 = 4800 baud
  202.          111 = 9600 baud
  203.  
  204. Return
  205.  
  206. After  executing  the  function,  the  following  information  is
  207. available in the CPU registers:
  208.  
  209.   AH  FFh  Error indication.  Otherwise:
  210.   AH  xx   Line status (See function 03h - Get Status).
  211.   AL  xx   Modem status (See function 03h - Get Status).
  212.  
  213.  
  214.  
  215.  
  216.  
  217.                                   5
  218. Output a Single Character  -  Function 01h
  219.  
  220. This  function places the character in the AL register  into  the
  221. transmit buffer of the designated channel.
  222.  
  223. Preparation
  224.  
  225. Before  requesting  Interrupt 14h,  load  the  CPU  registers  as
  226. follows:
  227.   DX  xxxx Channel number.
  228.   AH  01h  Function number.
  229.   AL  xx   Character to be transmitted.
  230.  
  231. Return
  232.  
  233. After  executing  the  function,  the  following  information  is
  234. returned in the CPU registers:
  235.   AL  xx   Character transmitted.
  236.   AH  xx   Line status:
  237.            Bit  0  =  Data Ready - If set to 1, there  is  data
  238.          available  in the receive buffer; if set  to  0,
  239.          the receive buffer is empty.
  240.            Bit  5 = Transmitter Holding Register Empty - If set
  241.          to  1,  there  is  room for at  least  one  more
  242.          character in the transmit buffer; if set  to  0,
  243.          the transmit buffer is full (same as bit 6).
  244.            Bit 6 = Transmitter Shift Register Empty - If set to
  245.          1,   there  is  room  for  at  least  one   more
  246.          character in the transmit buffer; if set  to  0,
  247.          the transmit buffer is full (same as bit 5).
  248.            Bit  7 = Timeout Error - If transmit buffer is full,
  249.          the  driver  will try for 2 seconds to  write  a
  250.          character  before  timing out.   If  timeout  is
  251.          disabled through Function 20h, only one  attempt
  252.          will be made before generating a timeout error.
  253.  
  254.  
  255.  
  256.  
  257.  
  258.  
  259.  
  260.  
  261.  
  262.  
  263.  
  264.  
  265.  
  266.  
  267.  
  268.  
  269.  
  270.  
  271.  
  272.  
  273.  
  274.  
  275.  
  276.                                   6
  277. Input a Single Character - Function 02h
  278.  
  279. This  function reads a character from the receive buffer  of  the
  280. selected  channel.  If no character is found, the  function  will
  281. keep trying for approximately two seconds, then return a time-out
  282. error.
  283.  
  284. Preparation
  285.  
  286. Before  requesting  Interrupt 14h,  load  the  CPU  registers  as
  287. follows:
  288.   DX  xxxx Channel number.
  289.   AH  02h  Function number.
  290.  
  291. Return
  292.  
  293. After  executing  the  function,  the  following  information  is
  294. returned in the CPU registers:
  295.  
  296.   AL  xx   Character received.
  297.   AH  xx   Line status:
  298.            Bit  0  =  Data Ready - If set to 1, there  is  data
  299.          available  in the receive buffer; if set  to  0,
  300.          the receive buffer is empty.
  301.            Bit 1 = Overrun Error - If set to 1, indicates that
  302.          an  overrun  error occurred while attempting  to
  303.          read  the character.  This would normally  occur
  304.          when  incoming data is received while the  input
  305.          buffer is full.
  306.            Bit  2  = Parity Error - If set to 1, indicates that
  307.          the character received has a parity error.
  308.            Bit  3 = Framing Error - If set to 1, indicates that
  309.          the character received has a framing error.
  310.            Bit  4  =  Break Interrupt - Indicates that a  Break
  311.          occurred  at  this  point  in  the  input   data
  312.          stream.   The AL register should contain  a  NUL
  313.          (00h) character.
  314.            Bit  5 = Transmitter Holding Register Empty - If set
  315.          to  1,  there  is  room for at  least  one  more
  316.          character in the transmit buffer; if set  to  0,
  317.          the transmit buffer is full (same as bit 6).
  318.            Bit 6 = Transmitter Shift Register Empty - If set to
  319.          1,   there  is  room  for  at  least  one   more
  320.          character in the transmit buffer; if set  to  0,
  321.          the transmit buffer is full (same as bit 5).
  322.            Bit  7 = Timeout Error - If set to 1, indicates that
  323.          there was no character in the input buffer.
  324.  
  325.  
  326.  
  327.  
  328.  
  329.  
  330.  
  331.  
  332.  
  333.  
  334.  
  335.                                   7
  336. Get Status - Function 03h
  337.  
  338. This  function  returns the Line Status and Modem Status  of  the
  339. specified  channel.   The  status  bytes  are  in  the  form   of
  340. 8250/16450   UART   Line  Status  and  Modem   Status   registers
  341. (regardless of whether the board has 16450 UARTs or 8530 SCCs).
  342. NOTE - This function returns the status of the channel, and not the
  343. physical  communications chip (16450 or  8530).   Thus,  in  this
  344. context, "Transmitter Holding Register Empty" means that there is
  345. room  in  the  board's  transmit buffer for  at  least  one  more
  346. character.
  347.  
  348. Preparation
  349.  
  350. Before  requesting  Interrupt 14h,  load  the  CPU  registers  as
  351. follows:
  352.  
  353.   DX  xxxx Channel number.
  354.   AH  03h  Function number.
  355.  
  356. Return
  357.  
  358. After  executing  the  function,  the  following  information  is
  359. returned in the CPU registers:
  360.  
  361.   AH  FFh  Error.  Otherwise:
  362.   AH  xx   Line status:
  363.            Bit  0  =  Data Ready - If set to 1, there  is  data
  364.          available  in the receive buffer; if set  to  0,
  365.          the receive buffer is empty.
  366.            Bit  5 = Transmitter Holding Register Empty - If set
  367.          to  1,  there  is  room for at  least  one  more
  368.          character in the transmit buffer; if set  to  0,
  369.          the transmit buffer is full (same as bit 6).
  370.            Bit 6 = Transmitter Shift Register Empty - If set to
  371.          1,   there  is  room  for  at  least  one   more
  372.          character in the transmit buffer; if set  to  0,
  373.          the transmit buffer is full (same as bit 5).
  374.            Bits 1, 2, 3, 4 & 7 - Not applicable.
  375.   
  376.   AL  xx   Modem Status:
  377.            Bit 0 = Delta Clear To Send - If set to 1, indicates
  378.          that  CTS has changed state since the last  time
  379.          Modem  Status was checked (by any function  that
  380.          provides a Modem Status byte).
  381.            Bit  1  =  Delta Data Set Ready - If set to 1,  indi
  382.          cates that DSR has changed state since the  last
  383.          time  Modem Status was checked (by any  function
  384.          that provides a Modem Status byte).
  385.            Bit  2 = Trailing Edge Ring Indicator - If set to 1,
  386.          indicates  that RI (Ring Indicator  has  changed
  387.          from  an active state to an inactive state since
  388.          the  last time Modem Status was checked (by  any
  389.          function that provides a Modem Status byte).
  390.  
  391.  
  392.  
  393.  
  394.                                   8
  395.            Bit 3 =  Delta Data Carrier Detect - If set to  1,
  396.          indicates  that DCD has changed state since  the
  397.          last  time  Modem  Status was  checked  (by  any
  398.          function that provides a Modem Status byte).
  399.            Bit 4 = Clear To Send (CTS) - If set to 1, indicates
  400.          that  CTS  is  active.  If set to  0,  indicates
  401.          that CTS is inactive.
  402.            Bit  5  =  Data  Set  Ready  (DSR) - If  set  to  1,
  403.          indicates  that DSR is active.   If  set  to  0,
  404.          indicates that DSR is inactive.
  405.            Bit 6 = Ring Indicator (RI) - If set to 1, indicates
  406.          that  RI is active.  If set to 0, indicates that
  407.          RI is inactive.
  408.            Bit  7  =  Data Carrier Detect (DCD) - If set to  1,
  409.          indicates  that DCD is active.   If  set  to  0,
  410.          indicates that DCD is inactive.
  411.  
  412.  
  413.  
  414.  
  415.  
  416.  
  417.  
  418.  
  419.  
  420.  
  421.  
  422.  
  423.  
  424.  
  425.  
  426.  
  427.  
  428.  
  429.  
  430.  
  431.  
  432.  
  433.  
  434.  
  435.  
  436.  
  437.  
  438.  
  439.  
  440.  
  441.  
  442.  
  443.  
  444.  
  445.  
  446.  
  447.  
  448.  
  449.  
  450.  
  451.  
  452.  
  453.                                   9
  454. Extended Port Initialization - Function 04h
  455.  
  456. This function provides more initialization options than the basic
  457. initialization  function (Function 00h).  Baud  rates  of  up  to
  458. 115,200  are supported, and the function can be used to  force  a
  459. BREAK condition which can be held indefinitely.
  460.  
  461. NOTE - The  maximum  baud rate which can be set on  the  COM/Xi  is
  462. 57,600.   However,  baud rates in excess of 38,400  may  not  run
  463. reliably on that board.
  464.  
  465. Preparation
  466.  
  467. Before  requesting  Interrupt 14h,  load  the  CPU  registers  as
  468. follows:
  469.  
  470.   DX  xxxx Channel number.
  471.   AH  04h  Function number.
  472.   AL  xx   Break setting:
  473.            0 = No break
  474.            1 = Break  (held until reset by  executing  this
  475.                command with AL = 0)
  476.   BH  xx   Parity:
  477.            0 = No parity
  478.            1 = Odd parity
  479.            2 = Even parity
  480.            3 = Stick parity odd (not supported)
  481.            4 = Stick parity even (not supported)
  482.   BL  xx   Stop bits:
  483.            0 = 1 stop bit NOTE - 1.5 stop bits can only be
  484.            1 = 2 stop bitsset by the configuration utility.
  485.   CH  xx   Character length:
  486.            0 = 5 bits
  487.            1 = 6 bits
  488.            2 = 7 bits
  489.            3 = 8 bits
  490.   CL  xx   Baud rate:
  491.            00h   110 baud      09h   38400 baud
  492.            01h   150 baud      0Ah   57600 baud
  493.            02h   300 baud      0Bh   76800 baud
  494.            03h   600 baud      0Ch   115200 baud
  495.            04h   1200 baud     0Dh   50 baud
  496.            05h   2400 baud     0Eh   75 baud
  497.            06h   4800 baud     0Fh   134 baud
  498.            07h   9600 baud     10h   200 baud
  499.            08h   19200 baud    11h   1800 baud
  500.  
  501. Return
  502.  
  503. After  executing  the  function,  the  following  information  is
  504. returned in the CPU registers:
  505.  
  506.   AH  FFh  Error.  Otherwise:
  507.   AH  xx   Line status (see function 03h).
  508.   AL  xx   Modem status (see function 03h).
  509.  
  510.  
  511.  
  512.                                   10
  513. Extended Communications Port Control - Function 05h
  514.  
  515. This  function enables software to directly monitor  and  control
  516. the  handshaking lines DTR (Data Terminal Ready) and RTS (Request
  517. to Send).
  518.  
  519. Note - access to the LOOP bit is not supported.  Access to the OUT1
  520. and OUT2 bits is limited to the COM/Xi board. Also, RTS and DTR will 
  521. not be affected if these lines are being used for hardware handshaking.
  522.  
  523. Preparation
  524.  
  525. Before requesting Interrupt 14h, load the CPU registers as follows:
  526.  
  527.   DX  xxxx Channel number.
  528.   AH  05h  Function number.
  529.   AL  xx   00h = Read Modem Control Register.
  530.        01h = Write Modem Control Register.
  531.   BL  xx   If AL = 01h, and hardware handshaking is disabled:
  532.            setting bit 0 of BL to 1 will raise DTR;
  533.            setting bit 0 of BL to 0 will drop DTR;
  534.            setting bit 1 of BL to 1 will raise RTS;
  535.            setting bit 1 of BL to 0 will drop RTS;
  536.                setting bit 2 of BL to 1 will raise OUT1 (COM/Xi only);
  537.                setting bit 2 of BL to 0 will drop OUT1 (COM/Xi only);
  538.                setting bit 3 of BL to 1 will raise OUT2 (COM/Xi only);
  539.                setting bit 3 of BL to 0 will drop OUT2 (COM/Xi only).
  540.  
  541. Return
  542.  
  543. After  executing  the  function,  the  following  information  is
  544. returned in the CPU registers:
  545.   AH  xx   Line status (see function 03h).
  546.   AL  xx   Modem status (see function 03h).
  547.   BL  xx   Modem Control Register:
  548.            Bit 0 = DTR (active if set to 1).
  549.            Bit 1 = RTS (active if set to 1).
  550.                Bit 2 = OUT1 (COM/Xi only - active if set to 1).
  551.                Bit 3 = OUT2 (COM/Xi only - active if set to 1).
  552.  
  553.  
  554.  
  555.  
  556.  
  557.  
  558.  
  559.  
  560.  
  561.  
  562.  
  563.  
  564.  
  565.  
  566.  
  567.  
  568.  
  569.  
  570.  
  571.                                   11
  572. Get Driver/Board Information - Function 06h
  573.  
  574. This  function provides information about the board and  the  DOS
  575. device driver.
  576.  
  577. Preparation
  578.  
  579. Before  requesting  Interrupt 14h,  load  the  CPU  registers  as
  580. follows:
  581.  
  582.   DX  xxxx Channel number.
  583.   AH  06h  Function number.
  584.  
  585. Sub-function 00h: Get port name
  586.   AL  00h  Sub-function number.
  587.  
  588. Sub-function 01h: Get driver information
  589.   AL  01h  Sub-function number.
  590.  
  591. Sub-function 02h: Get board information
  592.   AL  02h  Sub-function number.
  593.   BX  xxxx Board number (0-3).
  594.  
  595. Sub-function FFh: Get driver name
  596.   AL  FFh  Sub-function number.
  597.  
  598. Returns
  599.  
  600. After  executing  the  function,  the  following  information  is
  601. returned in the CPU registers:
  602.  
  603. Sub-function 00h: Port name:
  604.   AH  FFh  Error indication - otherwise:
  605.   AL  xx   Number of highest Interrupt 14h function supported.
  606.   ES:BX    Pointer to 8 byte ASCII string which contains  the
  607.            name of the port (e.g. "COM5    ") if DOS support  is
  608.            enabled  (done through the "Options" menu  in  driver
  609.            set-up  program).   If DOS support is  disabled  (Int
  610.            14h   support   only),   the  string   will   contain
  611.            "NoDriver".
  612.  
  613. Sub-function 01h: Driver information:
  614.   AH  FFh  Error indication - otherwise:
  615.   AX  xxxx Total number of channels supported.
  616.   BX  xxxx Driver version number (e.g. V 2.0.1: BX = 0201h).
  617.   CX  xxxx Total number of boards supported.
  618.   DX  xxxx Lowest channel number supported by this driver - to  get
  619.            highest  supported channel number,  use  the  formula
  620.            AX+DX-1.
  621.  
  622.  
  623.  
  624.  
  625.  
  626.  
  627.  
  628.  
  629.  
  630.                                   12
  631. Sub-function 02h: Board information:
  632.   AH  FFH  Error indication.  Otherwise:
  633.   AH  xx   IRQ number.
  634.   AL  xx   Board type:
  635.                01h  COM/Xi
  636.                02h  MC/Xi
  637.                03h  PC/Xe
  638.                04h  PC/Xi
  639.                05h  PC/Xm
  640.   BX  xxxx Board's dual-ported memory segment.
  641.   CX  xxxx Number of channels on the board.
  642.   DX  xxxx Board's I/O port address.
  643.   SI  xxxx Channel number of first channel on the board.
  644.  
  645. Sub-function FFh: Driver name:
  646.   AX  xxxx Driver version number.
  647.   CX  xxxx Number of channels supported.
  648.   ES:BX    Pointer  to 8-byte string containing the  driver's
  649.            name (e.g. "DIGIFEP5").
  650.  
  651.  
  652.  
  653.  
  654.  
  655.  
  656.  
  657.  
  658.  
  659.  
  660.  
  661.  
  662.  
  663.  
  664.  
  665.  
  666.  
  667.  
  668.  
  669.  
  670.  
  671.  
  672.  
  673.  
  674.  
  675.  
  676.  
  677.  
  678.  
  679.  
  680.  
  681.  
  682.  
  683.  
  684.  
  685.  
  686.  
  687.  
  688.  
  689.                                   13
  690. Send Break - Function 07h
  691.  
  692. This  function forces a BREAK condition for a specified interval.
  693. If   no  interval  is  specified,  the  default  (initially   250
  694. milliseconds)  is used. If an interval is specified,  it  becomes
  695. the new default BREAK time.
  696.  
  697. Preparation
  698.  
  699. Before  requesting  Interrupt 14h,  load  the  CPU  registers  as
  700. follows:
  701.   DX  xxxx Channel number.
  702.   AH  07h  Function number.
  703.   AL  00h  Use default BREAK time.  Otherwise:
  704.   AL  01h  BREAK time is value in BX times 10 milliseconds.
  705.   BX  xxxx Factor for determining length of BREAK
  706.            (BX times 10 milliseconds).
  707.  
  708. Return
  709.  
  710. After  executing  the  function,  the  following  information  is
  711. returned in the CPU registers:
  712.  
  713.   AH  FFh  Error indication.  Otherwise:
  714.   AH  00h  No errors.
  715.  
  716.  
  717.  
  718.  
  719.  
  720.  
  721.  
  722.  
  723.  
  724.  
  725.  
  726.  
  727.  
  728.  
  729.  
  730.  
  731.  
  732.  
  733.  
  734.  
  735.  
  736.  
  737.  
  738.  
  739.  
  740.  
  741.  
  742.  
  743.  
  744.  
  745.  
  746.  
  747.  
  748.                                   14
  749. Alternate Status Check - Function 08h
  750.  
  751. This  function performs a non-destructive read from  the  receive
  752. buffer.
  753.  
  754. Preparation
  755.  
  756. Before  requesting  Interrupt 14h,  load  the  CPU  registers  as
  757. follows:
  758.  
  759.   DX  xxxx Channel number.
  760.   AH  08h  Function number.
  761.  
  762. Return
  763.  
  764. After  executing  the  function,  the  following  information  is
  765. returned in the CPU registers:
  766.  
  767.   ZF  0    Next character in input buffer will appear in AL.
  768.   AL  xx   Next character to be read by a Read Single Character
  769.            or Read String function.
  770.   AH  xx   Line status associated with next character to be read
  771.            (see function 02h).
  772.   ZF  1    No character in buffer.
  773.   AH  FFh  No character in buffer.
  774.  
  775.  
  776.  
  777.  
  778.  
  779.  
  780.  
  781.  
  782.  
  783.  
  784.  
  785.  
  786.  
  787.  
  788.  
  789.  
  790.  
  791.  
  792.  
  793.  
  794.  
  795.  
  796.  
  797.  
  798.  
  799.  
  800.  
  801.  
  802.  
  803.  
  804.  
  805.  
  806.  
  807.                                   15
  808. Clear Buffers - Function 09h
  809.  
  810. This function clears (flushes) both the transmit and receive buffers
  811. for the designated channel.
  812.  
  813. Preparation
  814.  
  815. Before requesting Interrupt 14h, load the CPU registers as follows:
  816.  
  817.   DX  xxxx Channel number.
  818.   AH  09h  Function number.
  819.  
  820. Return
  821.  
  822. After executing the function, the following information is returned
  823. in the CPU registers:
  824.  
  825.   AH  FFh  Error indication.  Otherwise:
  826.   AH  00h  No errors.
  827.  
  828.  
  829.  
  830.  
  831.  
  832.  
  833.  
  834.  
  835.  
  836.  
  837.  
  838.  
  839.  
  840.  
  841.  
  842.  
  843.  
  844.  
  845.  
  846.  
  847.  
  848.  
  849.  
  850.  
  851.  
  852.  
  853.  
  854.  
  855.  
  856.  
  857.  
  858.  
  859.  
  860.  
  861.  
  862.  
  863.  
  864.  
  865.  
  866.                                   16
  867. Input Queue Check - Function 0Ah
  868.  
  869. This function returns the number of characters currently in the
  870. receive buffer.
  871.  
  872. NOTE - This function differs from function 15h (Input byte count),
  873. because there can be more bytes in the buffer than there are characters.  
  874. The character FFh requires two bytes, and characters with errors 
  875. (parity, framing, etc.) require three bytes.  Use this function to 
  876. determine how many characters are available to be read using the Read 
  877. Single Character or Read String functions, and use function 15h to 
  878. determine how much physical buffer space has been filled.
  879.  
  880. Preparation
  881.  
  882. Before requesting Interrupt 14h, load the CPU registers as follows:
  883.  
  884.   DX  xxxx Channel number.
  885.   AH  0Ah  Function number.
  886.  
  887.  
  888. Return
  889.  
  890. After executing the function, the following information is returned in the CPU registers:
  891.  
  892.   AX  xxxx Number of characters in input buffer.
  893.   DH  FFh  Error indication.  
  894.   ZF  1    Error indication.
  895.  
  896.  
  897.  
  898.  
  899.  
  900.  
  901.  
  902.  
  903.  
  904.  
  905.  
  906.  
  907.  
  908.  
  909.  
  910.  
  911.  
  912.  
  913.  
  914.  
  915.  
  916.  
  917.  
  918.  
  919.  
  920.  
  921.  
  922.  
  923.  
  924.  
  925.                                   17
  926. Drop Handshake Lines - Function 0Bh
  927.  
  928. This function causes DTR and RTS to drop (become inactive).  If hardware 
  929. handshaking is not enabled, these control lines will remain inactive 
  930. either until they are raised by executing Interrupt 14 function 13h 
  931. (Set Handshake Lines), or until hardware handshaking is enabled by 
  932. executing Interrupt 14h function 1Eh (Set Flow Control).
  933.  
  934. If hardware handshaking is enabled when this function is executed, 
  935. it is temporarily suspended and the DTR and RTS control lines are 
  936. dropped.  Then hardware handshaking is automatically reactivated, 
  937. and the control lines return to their previous state.  This has the 
  938. effect of "pulsing" the lines to the inactive state, and might be 
  939. used to hang up a modem.
  940.  
  941. Preparation
  942.  
  943. Before requesting Interrupt 14h, load the CPU registers as follows:
  944.  
  945.   DX  xxxx Channel number.
  946.   AH  0Bh Function number.
  947.  
  948. Return
  949.  
  950. After executing the function, the following information is available 
  951. in the CPU registers:
  952.  
  953.   AH  FFh  Error indication.  Otherwise:
  954.   AH  00h  No errors.
  955.  
  956.  
  957.  
  958.  
  959.  
  960.  
  961.  
  962.  
  963.  
  964.  
  965.  
  966.  
  967.  
  968.  
  969.  
  970.  
  971.  
  972.  
  973.  
  974.  
  975.  
  976.  
  977.  
  978.  
  979.  
  980.  
  981.  
  982.  
  983.  
  984.                                   18
  985. Get Channel Parameters - Function 0Ch
  986.  
  987. This function returns the current settings of flow control, baud rate, 
  988. parity and framing parameters for the designated channel.
  989.  
  990. Preparation
  991.  
  992. Before requesting Interrupt 14h, load the CPU registers as follows:
  993.  
  994.   DX  xxxx Channel number.
  995.   AH  0Ch  Function number.
  996.  
  997. Return
  998.  
  999. After executing the function, the following information is available in 
  1000. the CPU registers:
  1001.  
  1002.   AH  FFh  Error indication.  Otherwise:
  1003.   AH  xx   Software flow control (XON/XOFF):
  1004.          Bit 0 = Transmit flow control-If set to 1, XON/XOFF flow 
  1005.            control is enabled for transmitted data.  Inactive if 
  1006.            set to 0.
  1007.          Bit 1 = Receive flow control-If set to 1, XON/XOFF flow 
  1008.            control is enabled for received data. Inactive if set to 0.
  1009.   AL  xx   Hardware flow control:
  1010.          Bit 0 = DTR receive flow control-If set to 1, DTR is used 
  1011.            to control incoming data.
  1012.          Bit 1 = RTS receive flow control-If set to 1, RTS is used 
  1013.            to control incoming data.
  1014.          Bit 4 = CTS transmit flow control-If set to 1, data 
  1015.            transmission will be paused any time CTS (Clear To Send) 
  1016.            is dropped by the receiving device.  If set to 0, CTS 
  1017.            has no effect.
  1018.          Bit 5 = DSR transmit flow control-If set to 1, data 
  1019.            transmission will be paused any time DSR (Data Set Ready) 
  1020.            is dropped by the receiving device.  If set to 0, DSR has 
  1021.            no effect.
  1022.          Bit 7 = DCD transmit flow control-If set to 1, data 
  1023.            transmission will be paused any time DCD (Data Carrier 
  1024.            Detect) is dropped by the receiving device.  If set to 0, 
  1025.            DCD has no effect.
  1026.   BH  xx   Parity
  1027.          0 = No parity              
  1028.          1 = Odd parity     
  1029.          2 = Even parity
  1030.   BL  xx   Stop bits
  1031.          0 = 1 stop bit
  1032.          1 = 2 stop bits (or 1.5, as set with configuration utility)
  1033.   CH  xx   Character length
  1034.          0 = 5 bits
  1035.          1 = 6 bits
  1036.          2 = 7 bits
  1037.          3 = 8 bits
  1038.  
  1039.  
  1040.  
  1041.  
  1042.  
  1043.                                   19
  1044.   CL  xx   Baud rate
  1045.          00h   110 baud      09h   38400 baud
  1046.          01h   150 baud      0Ah   57600 baud
  1047.          02h   300 baud      0Bh   76800 baud
  1048.          03h   600 baud      0Ch   115200 baud
  1049.          04h   1200 baud     0Dh   50 baud
  1050.          05h   2400 baud     0Eh   75 baud
  1051.          06h   4800 baud     0Fh   134 baud
  1052.          07h   9600 baud     10h   200 baud
  1053.          08h   19200 baud    11h   1800 baud
  1054.  
  1055.  
  1056.  
  1057.  
  1058.  
  1059.  
  1060.  
  1061.  
  1062.  
  1063.  
  1064.  
  1065.  
  1066.  
  1067.  
  1068.  
  1069.  
  1070.  
  1071.  
  1072.  
  1073.  
  1074.  
  1075.  
  1076.  
  1077.  
  1078.  
  1079.  
  1080.  
  1081.  
  1082.  
  1083.  
  1084.  
  1085.  
  1086.  
  1087.  
  1088.  
  1089.  
  1090.  
  1091.  
  1092.  
  1093.  
  1094.  
  1095.  
  1096.  
  1097.  
  1098.  
  1099.  
  1100.  
  1101.  
  1102.                                   20
  1103. Get Pointer to Character Ready Flag - Function 0Dh
  1104.  
  1105. This function returns the pointer to a byte in host memory which can be 
  1106. used as a flag to indicate the presence or absence of input data 
  1107. characters in the receive buffer for the designated channel.  This 
  1108. permits a quick test for received data without necessitating an 
  1109. Interrupt 14h call.
  1110.  
  1111. This function must be executed for each channel for which a character 
  1112. ready flag is desired, and should be run as part of the initialization 
  1113. sequence of any application program using the flags.
  1114.  
  1115. NOTE - A hardware interrupt is required to set the character ready flag.  
  1116. Therefore, the board must have an IRQ line selected and the driver must 
  1117. be configured for that IRQ line.  It is also necessary to configure the 
  1118. driver to support the character ready flag for each applicable port.  
  1119. This is done through the "C)har Ready Flags" item in the Options menu 
  1120. of the set-up program.
  1121.  
  1122. Preparation
  1123.  
  1124. Before requesting Interrupt 14h, load the CPU registers as follows:
  1125.   DX  xxxx Channel number.
  1126.   AH  0Dh  Function number.
  1127.  
  1128. Return
  1129.  
  1130. After executing the function, the following information is available 
  1131. in the CPU registers:
  1132.  
  1133.   ES:BX    Pointer to the flag.  If the byte pointed to by ES:BX is 00h, 
  1134.        the receive buffer is empty.  If the byte contains FFh, the 
  1135.        buffer is not empty.
  1136.  
  1137.  
  1138.  
  1139.  
  1140.  
  1141.  
  1142.  
  1143.  
  1144.  
  1145.  
  1146.  
  1147.  
  1148.  
  1149.  
  1150.  
  1151.  
  1152.  
  1153.  
  1154.  
  1155.  
  1156.  
  1157.  
  1158.  
  1159.  
  1160.  
  1161.                                   21
  1162. Write String - Function 0Eh
  1163.  
  1164. This function copies a string of characters from a buffer in the host's 
  1165. memory to the transmit buffer for the designated channel.
  1166.  
  1167. NOTE -Before executing the Write String function, you should first find 
  1168. the amount of free space in the transmit buffer by executing Interrupt 
  1169. 14h Function 12h (Get Transmit Buffer Free Space). Attempting to write 
  1170. more characters than the buffer can hold may result in a time-out error.
  1171.  
  1172. Preparation
  1173.  
  1174. Before requesting Interrupt 14h, load the CPU registers as follows:
  1175.   DX  xxxx Channel number.
  1176.   AH  0Eh  Function number.
  1177.   CX  xxxx Number of characters in string.
  1178.   ES:BX    Pointer to the string.  Load ES and BX with the segment 
  1179.        and offset, respectively, of the first character of the 
  1180.        string you wish to send.
  1181.  
  1182. Return
  1183.  
  1184. After executing the function, the following information is available 
  1185. in the CPU registers:
  1186.  
  1187.   AX  xxxx Number of characters transmitted.
  1188.   DH  FFh  Error indication.
  1189.   ZF  1    Error indication.
  1190.  
  1191. (A time-out error will occur if there is insufficient space in the 
  1192. transmit buffer for the entire string after approximately 2 seconds.)
  1193.  
  1194.  
  1195.  
  1196.  
  1197.  
  1198.  
  1199.  
  1200.  
  1201.  
  1202.  
  1203.  
  1204.  
  1205.  
  1206.  
  1207.  
  1208.  
  1209.  
  1210.  
  1211.  
  1212.  
  1213.  
  1214.  
  1215.  
  1216.  
  1217.  
  1218.  
  1219.  
  1220.                                   22
  1221. Read String - Function 0Fh
  1222.  
  1223. This function moves a string of characters from the designated channel's 
  1224. receive buffer to an area in the hosts memory pointed to by the ES:BX 
  1225. registers.
  1226.  
  1227. Preparation
  1228.  
  1229. Before requesting Interrupt 14h, load the CPU registers as follows:
  1230.   DX  xxxx Channel number.
  1231.   AH  0Fh  Function number.
  1232.   CX  xxxx Number of characters to read.
  1233.   ES:BX    Pointer to callers buffer.  Load ES and BX with the segment 
  1234.        and offset, respectively, of a character array large enough 
  1235.        to hold the number of characters specified in CX.
  1236.  
  1237. Return
  1238.  
  1239. After executing the function, the following information is available in 
  1240. the CPU registers:
  1241.  
  1242.   AX  xxxx Number of characters read.
  1243.   DH  FFh  Error indication.
  1244.   ZF  1    Error indication.
  1245.  
  1246. An error will be flagged for data errors (parity, framing, etc.), or if 
  1247. the value in CX was larger than the number of characters available in 
  1248. the receive buffer.
  1249.  
  1250.  
  1251.  
  1252.  
  1253.  
  1254.  
  1255.  
  1256.  
  1257.  
  1258.  
  1259.  
  1260.  
  1261.  
  1262.  
  1263.  
  1264.  
  1265.  
  1266.  
  1267.  
  1268.  
  1269.  
  1270.  
  1271.  
  1272.  
  1273.  
  1274.  
  1275.  
  1276.  
  1277.  
  1278.  
  1279.                                   23
  1280. Clear Receive Buffer - Function 10h
  1281.  
  1282. This  function  clears  (flushes)  the  receive  buffer  for  the
  1283. designated channel.
  1284.  
  1285. Preparation
  1286.  
  1287. Before  requesting  Interrupt 14h,  load  the  CPU  registers  as
  1288. follows:
  1289.  
  1290.   DX  xxxx Channel number.
  1291.   AH  10h  Function number.
  1292.  
  1293. Return
  1294.  
  1295. After  executing  the  function,  the  following  information  is
  1296. available in the CPU registers:
  1297.  
  1298.   AH  FFh  Error indication.  Otherwise:
  1299.   AH  00h  No errors.
  1300.  
  1301.  
  1302.  
  1303.  
  1304.  
  1305.  
  1306.  
  1307.  
  1308.  
  1309.  
  1310.  
  1311.  
  1312.  
  1313.  
  1314.  
  1315.  
  1316.  
  1317.  
  1318.  
  1319.  
  1320.  
  1321.  
  1322.  
  1323.  
  1324.  
  1325.  
  1326.  
  1327.  
  1328.  
  1329.  
  1330.  
  1331.  
  1332.  
  1333.  
  1334.  
  1335.  
  1336.  
  1337.  
  1338.                                   24
  1339. Clear Transmit Buffer - Function 11h
  1340.  
  1341. This  function  clears  (flushes) the  transmit  buffer  for  the
  1342. designated channel.
  1343.  
  1344. Preparation
  1345.  
  1346. Before  requesting  Interrupt 14h,  load  the  CPU  registers  as
  1347. follows:
  1348.  
  1349.   DX  xxxx Channel number.
  1350.   AH  11h  Function number.
  1351.  
  1352. Return
  1353.  
  1354. After  executing  the  function,  the  following  information  is
  1355. available in the CPU registers:
  1356.  
  1357.   AH  FFh  Error indication.  Otherwise:
  1358.   AH  00h  No errors.
  1359.  
  1360.  
  1361.  
  1362.  
  1363.  
  1364.  
  1365.  
  1366.  
  1367.  
  1368.  
  1369.  
  1370.  
  1371.  
  1372.  
  1373.  
  1374.  
  1375.  
  1376.  
  1377.  
  1378.  
  1379.  
  1380.  
  1381.  
  1382.  
  1383.  
  1384.  
  1385.  
  1386.  
  1387.  
  1388.  
  1389.  
  1390.  
  1391.  
  1392.  
  1393.  
  1394.  
  1395.  
  1396.  
  1397.                                   25
  1398. Get Transmit Buffer Free Space - Function 12h
  1399.  
  1400. This  function returns the amount of free space in  the  transmit
  1401. buffer for the designated channel.
  1402.  
  1403. Preparation
  1404.  
  1405. Before  requesting  Interrupt 14h,  load  the  CPU  registers  as
  1406. follows:
  1407.  
  1408.   DX  xxxx Channel number.
  1409.   AH  12h  Function number.
  1410.  
  1411. Return
  1412.  
  1413. After  executing  the  function,  the  following  information  is
  1414. available in the CPU registers:
  1415.  
  1416.   AX  xxxx Number of free bytes in transmit buffer.
  1417.  
  1418.  
  1419.  
  1420.  
  1421.  
  1422.  
  1423.  
  1424.  
  1425.  
  1426.  
  1427.  
  1428.  
  1429.  
  1430.  
  1431.  
  1432.  
  1433.  
  1434.  
  1435.  
  1436.  
  1437.  
  1438.  
  1439.  
  1440.  
  1441.  
  1442.  
  1443.  
  1444.  
  1445.  
  1446.  
  1447.  
  1448.  
  1449.  
  1450.  
  1451.  
  1452.  
  1453.  
  1454.  
  1455.  
  1456.                                   26
  1457. Set Handshake Lines - Function 13h
  1458.  
  1459. This  function raises the RTS and DTR control lines (causes  them
  1460. to  become  active).  If hardware handshaking is enabled,  it  is
  1461. temporarily  suspended,  the  control  lines  are  raised,   then
  1462. hardware handshaking is re-activated and the control lines return
  1463. to their previous state.
  1464.  
  1465. Preparation
  1466.  
  1467. Before  requesting  Interrupt 14h,  load  the  CPU  registers  as
  1468. follows:
  1469.  
  1470.   DX  xxxx Channel number.
  1471.   AH  13h  Function number.
  1472.  
  1473. Return
  1474.  
  1475. After  executing  the  function,  the  following  information  is
  1476. available in the CPU registers:
  1477.  
  1478.   AH  FFh  Error indication.  Otherwise:
  1479.   AH  00h  No errors.
  1480.  
  1481.  
  1482.  
  1483.  
  1484.  
  1485.  
  1486.  
  1487.  
  1488.  
  1489.  
  1490.  
  1491.  
  1492.  
  1493.  
  1494.  
  1495.  
  1496.  
  1497.  
  1498.  
  1499.  
  1500.  
  1501.  
  1502.  
  1503.  
  1504.  
  1505.  
  1506.  
  1507.  
  1508.  
  1509.  
  1510.  
  1511.  
  1512.  
  1513.  
  1514.  
  1515.                                   27
  1516. Non-Destructive Character Read - Function 14h
  1517.  
  1518. This function is similar to Function 08h, Alternate Status Check,
  1519. except the ZF flag is not set.
  1520.  
  1521. Preparation
  1522.  
  1523. Before  requesting  Interrupt 14h,  load  the  CPU  registers  as
  1524. follows:
  1525.  
  1526.   DX  xxxx Channel number.
  1527.   AH  14h  Function number.
  1528.  
  1529. Return
  1530.  
  1531. After  executing  the  function,  the  following  information  is
  1532. available in the CPU registers:
  1533.  
  1534.   AH  xx   Line status.
  1535.   AL  xx   Next  character to be read by a Read Single  Character
  1536.        or Read String command.
  1537.  
  1538.  
  1539.  
  1540.  
  1541.  
  1542.  
  1543.  
  1544.  
  1545.  
  1546.  
  1547.  
  1548.  
  1549.  
  1550.  
  1551.  
  1552.  
  1553.  
  1554.  
  1555.  
  1556.  
  1557.  
  1558.  
  1559.  
  1560.  
  1561.  
  1562.  
  1563.  
  1564.  
  1565.  
  1566.  
  1567.  
  1568.  
  1569.  
  1570.  
  1571.  
  1572.  
  1573.  
  1574.                                   28
  1575. Input Byte Count - Function 15h
  1576.  
  1577. This  function returns the number of bytes waiting in the receive
  1578. buffer.  This is different from the number of characters, because
  1579. under  certain conditions, there can be more bytes in the  buffer
  1580. than there are characters (see Function 0Ah - Input Queue Check).
  1581. Use this function to determine how full the input buffer is.
  1582.  
  1583. Preparation
  1584.  
  1585. Before  requesting  Interrupt 14h,  load  the  CPU  registers  as
  1586. follows:
  1587.  
  1588.   DX  xxxx Channel number.
  1589.   AH  15h  Function number.
  1590.  
  1591. Return
  1592.  
  1593. After  executing  the  function,  the  following  information  is
  1594. available in the CPU registers:
  1595.  
  1596.   AX  xxxx Number of bytes in the receive buffer.
  1597.  
  1598.  
  1599.  
  1600.  
  1601.  
  1602.  
  1603.  
  1604.  
  1605.  
  1606.  
  1607.  
  1608.  
  1609.  
  1610.  
  1611.  
  1612.  
  1613.  
  1614.  
  1615.  
  1616.  
  1617.  
  1618.  
  1619.  
  1620.  
  1621.  
  1622.  
  1623.  
  1624.  
  1625.  
  1626.  
  1627.  
  1628.  
  1629.  
  1630.  
  1631.  
  1632.  
  1633.                                   29
  1634. Pause/Resume Transmit - Function 17h
  1635.  
  1636. This function overrides XON/XOFF output flow control.  It can  be
  1637. used   to   immediately  pause  transmission,   or   to   restart
  1638. transmission  which has previously been paused  (either  by  this
  1639. command, or by a received XOFF character).
  1640.  
  1641. NOTE - This  function will not override hardware flow control.   If
  1642. hardware handshaking is enabled, and the applicable control  line
  1643. (CTS,  DSR  and/or  DCD)  is inactive,  any  attempts  to  resume
  1644. transmission with this function will fail.
  1645.  
  1646. Preparation
  1647.  
  1648. Before  requesting  Interrupt 14h,  load  the  CPU  registers  as
  1649. follows:
  1650.  
  1651.   DX  xxxx Channel number.
  1652.   AH  17h  Function number.
  1653.   AL  xx   If AL = 0, pause transmission. If software (XON/XOFF)  
  1654.            flow  control is active,  transmission will resume if 
  1655.            an XON character is received.
  1656.        If AL = 1, resume previously paused transmission.
  1657.  
  1658. Return
  1659.  
  1660. After  executing  the  function,  the  following  information  is
  1661. available in the CPU registers:
  1662.  
  1663.   AH  FFh  Error indication.  Otherwise:
  1664.   AH  00h  No errors.
  1665.  
  1666.  
  1667.  
  1668.  
  1669.  
  1670.  
  1671.  
  1672.  
  1673.  
  1674.  
  1675.  
  1676.  
  1677.  
  1678.  
  1679.  
  1680.  
  1681.  
  1682.  
  1683.  
  1684.  
  1685.  
  1686.  
  1687.  
  1688.  
  1689.  
  1690.  
  1691.  
  1692.                                   30
  1693. Pause/Resume Receive - Function 18h
  1694.  
  1695. This  function  immediately activates or  releases  receive  flow
  1696. control.
  1697.  
  1698. NOTE - If the number of characters in the input buffer is less than
  1699. the  Receive  Low Water Mark (see Function 1Bh - Get Water  Marks
  1700. and  Buffer  Size),  any  attempts to  pause  reception  will  be
  1701. ignored.  Similarly,  if the number of characters  in  the  input
  1702. buffer  is greater than the Receive High Water Mark, any attempts
  1703. to resume reception will be ignored.
  1704.  
  1705. Preparation
  1706.  
  1707. Before  requesting  Interrupt 14h,  load  the  CPU  registers  as
  1708. follows:
  1709.  
  1710.   DX  xxxx Channel number.
  1711.   AH  18h  Function number.
  1712.   AL  xx   If AL  =  0,  pause  reception as  if  the  number  of
  1713.            characters  in  the  input  buffer  exceeded   the
  1714.            Receive  High Water Mark.  If software  (XON/XOFF)
  1715.            flow  control is active, send XOFF.   If  hardware
  1716.            flow  control  is  enabled,  drop  the  applicable
  1717.            handshaking lines (RTS and/or DTR).
  1718.         If AL  =  1,  resume reception as if  the  number  of
  1719.            characters  in  the input buffer  fell  below  the
  1720.            Receive  Low  Water Mark.  If software  (XON/XOFF)
  1721.            flow  control  is active, send XON.   If  hardware
  1722.            flow  control  is  enabled, raise  the  applicable
  1723.            handshaking lines (RTS and/or DTR).
  1724.         
  1725. Return
  1726.  
  1727. After  executing  the  function,  the  following  information  is
  1728. available in the CPU registers:
  1729.  
  1730.   AH  FFh  Error indication.  Otherwise:
  1731.   AH  00h  No errors.
  1732.  
  1733.  
  1734.  
  1735.  
  1736.  
  1737.  
  1738.  
  1739.  
  1740.  
  1741.  
  1742.  
  1743.  
  1744.  
  1745.  
  1746.  
  1747.  
  1748.  
  1749.  
  1750.  
  1751.                                   31
  1752. Get Water Marks and Buffer Size - Function 1Bh
  1753.  
  1754. This function returns the size of the selected buffer (receive or
  1755. transmit),  and the "water marks" for that buffer  (see  Function
  1756. 1Ch -Set Water Marks).
  1757.  
  1758. Preparation
  1759.  
  1760. Before  requesting  Interrupt 14h,  load  the  CPU  registers  as
  1761. follows:
  1762.  
  1763.   DX  xxxx Channel number.
  1764.   AH  1Bh  Function number.
  1765.   AL  xx   0 = Get Transmit Low Water Mark.
  1766.        1 = Get Receive Low Water Mark.
  1767.        2 = Get Receive High Water Mark.
  1768.  
  1769. Return
  1770.  
  1771. After  executing  the  function,  the  following  information  is
  1772. available in the CPU registers:
  1773.  
  1774.   AX  xxxx The requested water mark.
  1775.   BX  xxxx Size  of  the  buffer  for which the  water  mark  was
  1776.         requested (Transmit if AL was 0; Receive if AL was  1
  1777.         or 2).
  1778.   DH  FFh  Error indication.
  1779.   ZF  1    Error indication.
  1780.  
  1781.  
  1782.  
  1783.  
  1784.  
  1785.  
  1786.  
  1787.  
  1788.  
  1789.  
  1790.  
  1791.  
  1792.  
  1793.  
  1794.  
  1795.  
  1796.  
  1797.  
  1798.  
  1799.  
  1800.  
  1801.  
  1802.  
  1803.  
  1804.  
  1805.  
  1806.  
  1807.  
  1808.  
  1809.  
  1810.                                   32
  1811. Set Water Marks - Function 1Ch
  1812.  
  1813. This  function  provides control over the points  at  which  flow
  1814. control  actions take place during read operations, and at  which
  1815. an interrupt may be requested during write operations.
  1816.  
  1817. Receive High Water Mark:
  1818.   When  the  number  of bytes in the receive buffer  reaches  the
  1819.   Receive High Water Mark, the buffer is considered to be  nearly
  1820.   full,  and  appropriate handshaking is invoked  (XOFF  is  sent
  1821.   and/or  any  active hardware handshake lines  are  dropped)  to
  1822.   tell the sender to pause transmission.
  1823.  
  1824. Receive Low Water Mark:
  1825.   Once  handshaking has been invoked to pause remote transmission
  1826.   (see  Receive  High  Water Mark, above), it remains  in  effect
  1827.   while  characters  are  read from the  buffer  (with  the  Read
  1828.   Single Character or Read String functions) until the number  of
  1829.   bytes  in the buffer has been reduced to the Receive Low  Water
  1830.   Mark.   Then  appropriate action is taken (XON is  sent  and/or
  1831.   the  active  hardware handshake lines are raised) to  tell  the
  1832.   sender that it may resume transmission.  The two receive  water
  1833.   marks  set  up  a  hysteresis loop so that handshaking  is  not
  1834.   invoked every time a character enters the buffer.
  1835.  
  1836. Transmit Low Water Mark:
  1837.   Boards may be configured to generate an IRQ when the number  of
  1838.   characters  in  the transmit buffer drops to the  Transmit  Low
  1839.   Water Mark.
  1840.  
  1841. Preparation
  1842.  
  1843. Before  requesting  Interrupt 14h,  load  the  CPU  registers  as
  1844. follows:
  1845.  
  1846.   DX  xxxx Channel number.
  1847.   AH  1Ch  Function number.
  1848.   AL  xx   0 = Set Transmit Low Water Mark.
  1849.        1 = Set Receive Low Water Mark.
  1850.        2 = Set Receive High Water Mark.
  1851.   BX  xxxx Water mark value.
  1852.  
  1853. Return
  1854.  
  1855. After  executing  the  function,  the  following  information  is
  1856. available in the CPU registers:
  1857.  
  1858.   AH  FFh  Error indication.  Otherwise:
  1859.   AH  00h  No errors.
  1860.  
  1861.  
  1862.  
  1863.  
  1864.  
  1865.  
  1866.  
  1867.  
  1868.  
  1869.                                   33
  1870. Set Flow Control - Function 1Eh
  1871.  
  1872. This  function defines the method to be used for input and output
  1873. flow  control.  Any combination of the available methods  may  be
  1874. implemented.
  1875.  
  1876. Preparation
  1877.  
  1878. Before  requesting  Interrupt 14h,  load  the  CPU  registers  as
  1879. follows:
  1880.  
  1881.   DX  xxxx Channel number.
  1882.   AH  1Eh  Function number.
  1883.   BH  xx   Software flow control (XON/XOFF):
  1884.            Bit  0  =  Transmit  flow  control - If  set  to  1,
  1885.          XON/XOFF  flow  control will be used  for  trans
  1886.          mitted data.  Inactive if set to 0.
  1887.            Bit 1 = Receive flow control - If set to 1, XON/XOFF
  1888.          flow  control  will be used for  received  data.
  1889.          Inactive if set to 0.
  1890.            Bit  2 = Set new XON/XOFF characters - If set to  1,
  1891.          CH  contains  the  new  XOFF  character  and  CL
  1892.          contains the new XON character.
  1893.   BL  xx   Hardware flow control:
  1894.            Bit  0 = DTR receive flow control - If set to 1, DTR
  1895.          will be used to control incoming data.
  1896.            Bit  1 = RTS receive flow control - If set to 1, RTS
  1897.          will be used to control incoming data.
  1898.            Bit  4  =  CTS transmit flow control - If set to  1,
  1899.          data  transmission will be paused any  time  CTS
  1900.          (Clear  To  Send)  is dropped by  the  receiving
  1901.          device.   If set to 0, CTS will have  no  effect
  1902.          on transmission.
  1903.            Bit  5  =  DSR transmit flow control - If set to  1,
  1904.          data  transmission will be paused any  time  DSR
  1905.          (Data  Set  Ready) is dropped by  the  receiving
  1906.          device.   If set to 0, DSR will have  no  effect
  1907.          on transmission.
  1908.            Bit  7  =  DCD transmit flow control - If set to  1,
  1909.          data  transmission will be paused any  time  DCD
  1910.          (Data   Carrier  Detect)  is  dropped   by   the
  1911.          receiving  device.  If set to 0, DCD  will  have
  1912.          no effect on transmission.
  1913.   CH  xx   New XOFF character, if bit 2 of BH is set to 1.
  1914.   CL  xx   New XON character, if bit 2 of BH is set to 1.
  1915.  
  1916. Return
  1917.  
  1918. After  executing  the  function,  the  following  information  is
  1919. available in the CPU registers:
  1920.  
  1921.   AH  FFh  Error indication.  Otherwise:
  1922.   AH  00h  No errors.
  1923.  
  1924.  
  1925.  
  1926.  
  1927.  
  1928.                                   34
  1929. Enable/Disable Read/Write Timeouts - Function 20h
  1930.  
  1931. Normally the DOS device driver will try for 2 seconds to  execute
  1932. a read or write operation.  If no data is read, or if there is no
  1933. room  in the transmit buffer for a write operation after  this  2
  1934. second  period, a "timeout" occurs and the read or write function
  1935. will  return an error condition.  If read/write timeouts are  dis
  1936. abled,  the driver will try a read or write operation only  once,
  1937. and  if  unsuccessful,  will immediately  return  with  an  error
  1938. condition.
  1939.  
  1940. Preparation
  1941.  
  1942. Before  requesting Interrupt 14h, load the CPU registers  as  follows:
  1943.  
  1944.   DX  xxxx Channel number.
  1945.   AH  20h  Function number.
  1946.   AL  xx   0 = Disable read/write timeout.
  1947.        1 = Enable read/write timeout.
  1948.  
  1949. Return
  1950.  
  1951. After  executing the function, the following information is available 
  1952. in the CPU registers:
  1953.  
  1954.   AH  FFh  Error indication (invalid byte in AL).  Otherwise:
  1955.   AH  00h  No errors.
  1956.  
  1957.  
  1958.  
  1959.  
  1960.  
  1961.  
  1962.  
  1963.  
  1964.  
  1965.  
  1966.  
  1967.  
  1968.  
  1969.  
  1970.  
  1971.  
  1972.  
  1973.  
  1974.  
  1975.  
  1976.  
  1977.  
  1978.  
  1979.  
  1980.  
  1981.  
  1982.  
  1983.  
  1984.  
  1985.  
  1986.  
  1987.                                   35
  1988. Presence Test - EBIOS Function F4h
  1989.  
  1990. This function is used to determine whether the device driver  has
  1991. been  configured  for EBIOS support.  This is  done  through  the
  1992. D)evice Driver Support menu of the set-up program.
  1993.  
  1994. Preparation
  1995.  
  1996. Before  requesting  Interrupt 14h,  load  the  CPU  registers  as
  1997. follows:
  1998.  
  1999.   DX  xxxx Channel number.
  2000.   AH  F4h  Function number.
  2001.  
  2002. Return
  2003.  
  2004. After  executing  the  function,  the  following  information  is
  2005. available in the CPU registers:
  2006.  
  2007.   AX  0000 EBIOS functions present.  Otherwise:
  2008.   AH  FFh  EBIOS functions not present.
  2009.  
  2010.  
  2011.  
  2012.  
  2013.  
  2014.  
  2015.  
  2016.  
  2017.  
  2018.  
  2019.  
  2020.  
  2021.  
  2022.  
  2023.  
  2024.  
  2025.  
  2026.  
  2027.  
  2028.  
  2029.  
  2030.  
  2031.  
  2032.  
  2033.  
  2034.  
  2035.  
  2036.  
  2037.  
  2038.  
  2039.  
  2040.  
  2041.  
  2042.  
  2043.  
  2044.  
  2045.  
  2046.                                   36
  2047. Specify Modem Leads - EBIOS Function FBh
  2048.  
  2049. This  function allows you to raise or lower DTR and RTS,  and  to
  2050. specify  which  modem control signals (CTS, DSR  and/or  DCD)  to
  2051. honor for output flow control.
  2052.  
  2053. NOTES -  To execute this function, EBIOS support must be  included
  2054. in the DOS device driver during set-up.  This is done through the
  2055. D)evice Driver Support menu of the set-up program.
  2056.  
  2057. RTS  and  DTR will not be affected if these lines are being  used
  2058. for hardware handshaking.
  2059.  
  2060. Preparation
  2061.  
  2062. Before  requesting  Interrupt 14h,  load  the  CPU  registers  as
  2063. follows:
  2064.  
  2065.   DX  xxxx Channel number.
  2066.   AH  FBh  Function number.
  2067.   AL  xx   Modem leads:
  2068.            Bit 0 = 1: Raise DTR (drop if 0).
  2069.            Bit 1 = 1: Raise RTS (drop if 0).
  2070.            Bit 4 = 1: Use CTS for output flow control.
  2071.            Bit 5 = 1: Use DSR for output flow control.
  2072.            Bit 6 = 1: Use RI for output flow control  (not
  2073.               supported).
  2074.            Bit 7 = 1: Use DCD for output flow control.
  2075.  
  2076.  
  2077.  
  2078.  
  2079.  
  2080.  
  2081.  
  2082.  
  2083.  
  2084.  
  2085.  
  2086.  
  2087.  
  2088.  
  2089.  
  2090.  
  2091.  
  2092.  
  2093.  
  2094.  
  2095.  
  2096.  
  2097.  
  2098.  
  2099.  
  2100.  
  2101.  
  2102.  
  2103.  
  2104.  
  2105.                                   37
  2106. Receive with No Wait - EBIOS Function FCh
  2107.  
  2108. This  function  works like Function 02 - Read  Single  Character,
  2109. except  only  one  attempt to read the buffer is  made.   If  the
  2110. buffer  is empty, the function immediately returns 80h in the  AH
  2111. register, indicating a time-out error.
  2112.  
  2113. NOTE - To execute this function, EBIOS support must be included  in
  2114. the  DOS  device driver during set-up.  This is done through  the
  2115. D)evice Driver Support menu of the set-up program.
  2116.  
  2117. Preparation
  2118.  
  2119. Before  requesting  Interrupt 14h,  load  the  CPU  registers  as
  2120. follows:
  2121.  
  2122.   DX  xxxx Channel number.
  2123.   AH  FCh  Function number.
  2124.  
  2125. Return
  2126.  
  2127. After  executing  the  function,  the  following  information  is
  2128. available in the CPU registers:
  2129.  
  2130.   AL  xx   Character read.
  2131.   AH  xx   Line  status (see Function 02h - Read  Single  Character).
  2132.  
  2133.  
  2134.  
  2135.  
  2136.  
  2137.  
  2138.  
  2139.  
  2140.  
  2141.  
  2142.  
  2143.  
  2144.  
  2145.  
  2146.  
  2147.  
  2148.  
  2149.  
  2150.  
  2151.  
  2152.  
  2153.  
  2154.  
  2155.  
  2156.  
  2157.  
  2158.  
  2159.  
  2160.  
  2161.  
  2162.  
  2163.  
  2164.                                   38
  2165. Retrieve Buffer Count - EBIOS Function FDh
  2166.  
  2167. This function returns the number of characters currently residing
  2168. in the specified buffer.
  2169.  
  2170. NOTE - To execute this function, EBIOS support must be included  in
  2171. the  DOS  device driver during set-up.  This is done through  the
  2172. D)evice Driver Support menu of the set-up program.
  2173.  
  2174. Preparation
  2175.  
  2176. Before  requesting  Interrupt 14h,  load  the  CPU  registers  as
  2177. follows:
  2178.  
  2179.   DX  xxxx Channel number.
  2180.   AH  FDh  Function number.
  2181.   AL  xx   Buffer to check:
  2182.            1 = Get transmit buffer count.
  2183.            2 = Get receive buffer count.
  2184.  
  2185. Return
  2186.  
  2187. After  executing  the  function,  the  following  information  is
  2188. available in the CPU registers:
  2189.  
  2190.   CX  xxxx Character count.
  2191.  
  2192.  
  2193.  
  2194.  
  2195.  
  2196.  
  2197.  
  2198.  
  2199.  
  2200.  
  2201.  
  2202.  
  2203.  
  2204.  
  2205.  
  2206.  
  2207.  
  2208.  
  2209.  
  2210.  
  2211.  
  2212.  
  2213.  
  2214.  
  2215.  
  2216.  
  2217.  
  2218.  
  2219.  
  2220.  
  2221.  
  2222.  
  2223.                                   39
  2224. Set Pacing Mode - EBIOS Function FEh
  2225.  
  2226. This  function enables or disables XON/XOFF handshaking  for  the
  2227. specified  channel.  Executing this function (regardless  of  the
  2228. mode selected) also turns on CTS and DSR output flow control.
  2229.  
  2230. NOTE - To execute this function, EBIOS support must be included  in
  2231. the  DOS  device driver during set-up.  This is done through  the
  2232. D)evice Driver Support menu of the set-up program.
  2233.  
  2234. Preparation
  2235.  
  2236. Before  requesting  Interrupt 14h,  load  the  CPU  registers  as
  2237. follows:
  2238.  
  2239.   DX  xxxx Channel number.
  2240.   AH  FEh  Function number.
  2241.   AL  xx   Pacing mode:
  2242.            00h = No pacing.
  2243.            40h = XON/XOFF  for  receive;  no  pacing   for
  2244.              transmit.
  2245.            80h = XON/XOFF  for  transmit;  no  pacing  for
  2246.              receive.
  2247.            C0h = XON/XOFF for both transmit and receive.
  2248.  
  2249.  
  2250.  
  2251.  
  2252.  
  2253.  
  2254.  
  2255.  
  2256.  
  2257.  
  2258.  
  2259.  
  2260.  
  2261.  
  2262.  
  2263.  
  2264.  
  2265.  
  2266.  
  2267.  
  2268.  
  2269.  
  2270.  
  2271.  
  2272.  
  2273.  
  2274.  
  2275.  
  2276.  
  2277.  
  2278.  
  2279.  
  2280.  
  2281.  
  2282.                                   40
  2283. Set Buffered Mode - EBIOS Function FFh
  2284.  
  2285. This  function  is  included to maintain compatibility  with  the
  2286. EBIOS  specification.  Since DigiCHANNEL intelligent  boards  are
  2287. fully  buffered,  executing this function has no  effect  on  the
  2288. host.
  2289.  
  2290. NOTE - To execute this function, EBIOS support must be included  in
  2291. the  DOS  device driver during set-up.  This is done through  the
  2292. D)evice Driver Support menu of the set-up program.
  2293.  
  2294. Preparation
  2295.  
  2296. Before  requesting  Interrupt 14h,  load  the  CPU  registers  as
  2297. follows:
  2298.  
  2299.   DX  xxxx Channel number.
  2300.   AH  FFh  Function number.
  2301.   AL  xx   Buffer to affect:
  2302.            1 = Transmit buffer.
  2303.            2 = Receive buffer.
  2304.   CX  xxxx Buffer size; to terminate buffered mode, set CX to 0.
  2305.   ES:BX    Pointer to buffer.
  2306.  
  2307.  
  2308.  
  2309.  
  2310.  
  2311.  
  2312.  
  2313.  
  2314.  
  2315.  
  2316.  
  2317.  
  2318.  
  2319.  
  2320.  
  2321.  
  2322.  
  2323.  
  2324.  
  2325.  
  2326.  
  2327.  
  2328.  
  2329.  
  2330.  
  2331.  
  2332.  
  2333.  
  2334.  
  2335.  
  2336.  
  2337.  
  2338.  
  2339.  
  2340.  
  2341.                    41