home *** CD-ROM | disk | FTP | other *** search
/ PC Online 1996 October / PCO_10.ISO / filesbbs / ntg_201b.arj / NTG.DOC next >
Encoding:
Text File  |  1992-04-27  |  54.8 KB  |  1,377 lines

  1.     ┌───────────────────────────────────────────────────────────┐
  2.     │     NTG Rev 5 FOSSIL Compatible Communications Driver     │
  3.     │                        Release 2.00                       │
  4.     └───────────────────────────────────────────────────────────┘
  5.  
  6.                           26th October, 1991
  7.                           
  8.                           Copyright (C) 1991
  9.  
  10.             Nikos Karasawidis and Nik The Greek's Drama BBS
  11.  
  12.                      +30-521-37156 (USR/HST V.42Bis)
  13.                      +30-521-37278 (MICROCOM MNP-10)
  14.  
  15.  
  16.     NTG is 'freely'  available copyrighted software, and supplied
  17.     no charge to system operators  of  (tm) and 'Othernet'
  18.     public access amateur network systems.  It is  NOT  available
  19.     in this form  for  commercial  use  or use outside of amateur
  20.     EMail systems.
  21.  
  22.     Please read the License details  at  the end of this document
  23.     on contacting the author regarding commercial  application of
  24.     NTG and associated products.
  25.  
  26.  
  27.  
  28.  
  29.  
  30.  
  31.                       NTG Revision 5 FOSSIL Communications Driver
  32.                                                      Version 2.00
  33.  
  34.  
  35.  
  36.     NTG is a  FOSSIL  compatible  Communications driver, suitable
  37.     for use with the following (among  others) bulletin board and
  38.     FidoNet(tm) mailer software:
  39.  
  40.  
  41.                      Fido v11,12
  42.                      BinkleyTerm
  43.                      Opus-CBCS
  44.                      RemoteAccess
  45.                      Maximus CBCS
  46.                      QuickBBS
  47.                      TPBoard
  48.                      SEAdog
  49.                      D'Bridge
  50.                      FrontDoor
  51.  
  52.  
  53.     It handles hardware  specific  aspects  of communications, to
  54.     enable the above applications to run in multiple environments
  55.     which are supported by a FOSSIL  compatible  driver.   NTG is
  56.     designed for the IBM PC, XT, AT, AT/386 and PS/2  range under
  57.     the MS-DOS operating  system  version 2.10 and above, OS/2 in
  58.     'DOS compatibility' mode and under  PC-MOS/386.   It may also
  59.     be compatible with other environments which emulate MS-DOS.
  60.  
  61.     The term 'FOSSIL'  is  short  for "Fido Opus SEAdog  Standard
  62.     Interface Layer".  It  is  a  generic hardware interface used
  63.     mainly by bulletin board systems  and  compatible mail
  64.     software which evolved from the efforts of Wynn  Wagner,  Bob
  65.     Hartman and Vince   Perriello.    The  current  "Revision  5"
  66.     standard makes it possible for  a lot of software to run on a
  67.     wide variety of hardware platforms capable of  running MS-DOS
  68.     but with distinct and incompatible hardware.
  69.  
  70.     NTG's main task  is  communications  handling.  It is a fully
  71.     interrupt driven communications   driver   which  effectively
  72.     handles communications "in  background",  and   continues  to
  73.     receive and transmit   characters   asynchronously  with  any
  74.     program or application running.   The application itself need
  75.     not be concerned   about   the  time  critical   aspects   of
  76.     communications, nor the capabilities, limitations or features
  77.     of the hardware itself.  These are all handled by NTG itself.
  78.  
  79.     NTG is one  of many FOSSIL drivers available.  NTG implements
  80.     many features found in other(tm) FOSSIL drivers, sometimes in
  81.     a slightly different  way.    Known   differences   will   be
  82.     highlighted.
  83.  
  84.     This package contains NTG.COM, with the driver itself being a
  85.     TSR program (Terminate and Stay Resident) which may be loaded
  86.     and unloaded, activated  or  made  dormant "on-the-fly";  and
  87.     also NTG.SYS, a  device  driver  implementation  loaded  from
  88.     CONFIG.SYS.  This is not as 'flexible'  as using NTG.COM, but
  89.     in general conserves some memory and allows loading  in  some
  90.     environments where the TSR implementation cannot be used.
  91.  
  92.  
  93.  
  94.  
  95.                                 - 1 -
  96.  
  97.  
  98.                       NTG Revision 5 FOSSIL Communications Driver
  99.                                                      Version 2.00
  100.  
  101.     Some of NTG's unique and more interesting features are:
  102.  
  103.          o    NTG  has  been  built  to  handle up to 4 COM ports
  104.               concurrently in up to 16 different configurations,
  105.  
  106.          o    It has an "open architecture"  which  will allow is
  107.               adaptation later  in  its  development  to  support
  108.               multiport shared    interrupt    and    intelligent
  109.               asynchronous IO boards,
  110.  
  111.          o    It supports the 16550 USART in fully buffered mode,
  112.               providing the capability of much higher baud rates,
  113.               performance and  significantly  less  CPU  overhead
  114.               especially in multitasking environments,
  115.  
  116.          o    The driver is extremely FAST, optimised  for speed,
  117.               and takes up very little memory,
  118.  
  119.          o    Incorporates  an optional "diagnostic" mode, so you
  120.               (the user) can inspect  the  state  of  the  FOSSIL
  121.               driver itself;    assisting   in   debugging    and
  122.               optimisation of   software  being  written  to  use
  123.               FOSSIL calls,  and   in   attempting  to  determine
  124.               problems in  software  using a FOSSIL,  such  as  a
  125.               mailer, BBS or BBS 'door',
  126.  
  127.          o    Has  'hooks'  for  an installable driver to support
  128.               network and  multitasking  software,  forcing  ill-
  129.               behaved processor intensive programs  to  give more
  130.               of their  time-slice to the system when inactive or
  131.               when simply "polling"  communications  or  keyboard
  132.               functions for activity or status reports,
  133.  
  134.          o    Allows 'fast' routing of screen output directly via
  135.               the ANSI  driver,  making  "FOSSIL"  screen  output
  136.               calls significantly   faster  than  going  via  DOS
  137.               itself,
  138.  
  139.          o    Allows for problems  in  some  XT  &  AT BIOS' when
  140.               16550AN's are installed:  very often  a  BIOS  will
  141.               not 'see'  the  communications  chip during startup
  142.               diagnostics -  so   NTG  will  force  the  BIOS  to
  143.               recognise it automatically,
  144.  
  145.          o    Provides a full range of utility functions  in  the
  146.               same .COM  file,  including built-in carrier watch,
  147.               system reboot, lock baud rate and/or communications
  148.               parameters and allowing  some  PC  BIOS  compatible
  149.               non-FOSSIL aware  software to take advantage  of  a
  150.               interrupt driven communications,
  151.  
  152.          o    Allows   resizing  of  communications  buffers  and
  153.               locking/unlocking   of   baud   rates   and   other
  154.               communications parameters "on-the-fly",
  155.  
  156.          o    Provides a means of displaying the currently loaded
  157.               driver's "status" and active parameters.
  158.  
  159.  
  160.  
  161.                                 - 2 -
  162.  
  163.  
  164.                       NTG Revision 5 FOSSIL Communications Driver
  165.                                                      Version 2.00
  166.  
  167.     NTG.COM is both a FOSSIL driver (TSR) and a utility which can
  168.     manipulate the resident   version   of   itself.    On  first
  169.     successful loading, it will terminate  and  leave  the driver
  170.     portion of itself   (only   about  5K  or  so   plus   buffer
  171.     requirements) resident, and  allocate  communication  buffers
  172.     for each of the enabled ports (typically  using 14K for a one
  173.     port install when  'diagnostics' mode is enabled).   It  then
  174.     captures and utilises  the  system's  INT 14H (communications
  175.     services) vector and services  requests  for  all  FOSSIL and
  176.     non-FOSSIL aware programs using the INT 14H interface.
  177.  
  178.     NTG will NEVER  load  itself  more than once,  unless  within
  179.     different tasks when    using    a   multitasker,   such   as
  180.     PC-MOS/386(tm), DESQview(tm), DoubleDOS(tm) or VM/386(tm).
  181.  
  182.     This documentation assumes a working knowledge of MS-DOS, and
  183.     no effort is made to explain MS-DOS  functions,  commands  or
  184.     setup.  Some familiarity  with  BBS or mail capable  software
  185.     and other FOSSIL drivers will definitely be an advantage, but
  186.     not required.
  187.  
  188.  
  189.  
  190.  
  191.                               USING NTG
  192.  
  193.  
  194.  
  195.     When running NTG,   avoid  using  any  other  software  which
  196.     purports to enhance   communications    products   (such   as
  197.     16550.EXE).  These WILL NOT work, and could cause your system
  198.     to crash or work unreliably.  NTG already uses  the 16550 and
  199.     16550AN to full advantage.
  200.  
  201.     Avoid loading DOS's   MODE   command   with   NTG.    NTG  is
  202.     incompatible with it's communications  handling  -  if loaded
  203.     after NTG, then  both may fail to operate reliably.   Printer
  204.     redirection is usually  ok,  provided  MODE  is loaded before
  205.     NTG.
  206.  
  207.     If you need to set a COM port's  baud rate (which is why MODE
  208.     is most often  used),  then you can get NTG  to  do  that  by
  209.     "locking" the baud  rate  (using  NTG /L as documented below)
  210.     which sets the COM port immediately  to  that rate.  Remember
  211.     to "unlock" the  baud  rate  if  not  using a constant  speed
  212.     between computer and modem.
  213.  
  214.     NTG.COM would normally  be  loaded  in your AUTOEXEC.BAT, and
  215.     installed as part of your normal  system  startup.  A typical
  216.     command line might be:
  217.  
  218.          NTG /F
  219.          [Loads NTG.COM with default settings and fast ANSI]
  220.  
  221.     NTG will respond  with  a  short  copyright   notice  and  an
  222.     indication that it  has been successfully loaded.  The number
  223.     of ports installed for will also be shown.
  224.  
  225.  
  226.  
  227.                                 - 3 -
  228.  
  229.  
  230.                       NTG Revision 5 FOSSIL Communications Driver
  231.                                                      Version 2.00
  232.  
  233.     NTG.SYS must be  loaded  from CONFIG.SYS (and probably can be
  234.     using QuarterDeck's DEVICE.COM under DESQview but I have only
  235.     run it this way for short periods)  using  a  "device"  line,
  236.     such as:
  237.  
  238.          device = C:\NTG.SYS /P2 /L0:19200,8N1 /F
  239.          [Loads NTG.SYS  for  2  ports, port 0 (COM1)  locked  at
  240.          19200 baud  8  data  bits 1 stop bit normal parity, fast
  241.          ANSI]
  242.  
  243.     A similar copyright message is  displayed  as  an  indication
  244.     that the driver has been installed.
  245.  
  246.     If NTG encounters  an error in the command line,  the  driver
  247.     will NOT be  installed.   The  device driver version displays
  248.     the command line parameter in error.
  249.  
  250.     NTG has been successfully run  loaded  "high"  above the 640K
  251.     mark using both   QuarterDeck's   QEMM(tm)   and    Qualitas'
  252.     386^MAX(tm) 386 memory  management  products.   It  should be
  253.     noted that there may be performance  differences  as a result
  254.     of either 386i  virtual  mode  switching  or  differences  in
  255.     hardware RAM access  speeds between mother-board RAM and that
  256.     used on an extended RAM card.  You should test the results on
  257.     your own hardware before deciding  which  method  is  better,
  258.     since generalisations without  considering  all  the  factors
  259.     involved can be misleading.
  260.  
  261.     Other enhanced memory  products may or may not work, but I am
  262.     either not familiar with them  or  do  not  know enough about
  263.     them to comment.
  264.  
  265.     Since NTG.COM can  be  unloaded  at  any  time   (unless  NTG
  266.     considers it unsafe to do so for various reasons), you should
  267.     be aware that  doing  so sometimes creates "holes" in memory.
  268.     This is not  a  problem  so   far   as   MS-DOS   or  various
  269.     applications running in it are concerned, but  the  effect of
  270.     releasing more memory  for  DOS  to use may be lost.  This is
  271.     almost always the  case when unloaded  from  within  a  batch
  272.     file: the memory freed will not be available until  after the
  273.     batch file terminates.
  274.  
  275.     If the desired  effect  is to "disable" NTG completely, refer
  276.     to the /Q and /C command line  switches  below.   This leaves
  277.     NTG loaded, but  provides  a  means of disabling  the  driver
  278.     completely and forces  use of the BIOS INT 14H functions or a
  279.     previously installed driver.
  280.  
  281.     One note regarding PS/2 hardware  and  applications which use
  282.     its specific INT  14H  functions  (though I haven't  actually
  283.     seen any).  A PS/2's extended BIOS contains a superset of INT
  284.     14H services, which  were designed after FOSSILs first become
  285.     available for PC's.    The  additional   services   are   NOT
  286.     compatible with the extended functions supported  by  FOSSIL,
  287.     and you should  therefore  either  unload  (/U) or deactivate
  288.     (/Q) NTG prior running such software.
  289.  
  290.  
  291.  
  292.  
  293.                                 - 4 -
  294.  
  295.  
  296.                       NTG Revision 5 FOSSIL Communications Driver
  297.                                                      Version 2.00
  298.  
  299.                            DEFAULT SETTINGS
  300.  
  301.  
  302.     By default, NTG  uses  1K  (1024 byte) communications buffers
  303.     for both transmit and receive.  This should be sufficient, if
  304.     not excessive, for most applications.   This  may  need to be
  305.     varied for systems  running  at slow (less than  6MHZ)  clock
  306.     speeds, use modems  with  higher  baud  rates,  make  use  of
  307.     special modem technology, run under  multitasking software or
  308.     run on a  network.   Some applications (for example  terminal
  309.     emulation systems and bulletin boards) require more buffering
  310.     because of the nature of how they communicate.
  311.  
  312.     The fast 'ANSI' output is DISabled by default.  The option to
  313.     use the faster  output  method  will normally work well under
  314.     standard MS-DOS, DESQview  or  most  DOS-based  environments.
  315.     This will NOT  work under PC-MOS/386 as it makes  use  of  an
  316.     undocumented MS-DOS feature  not  supported by that operating
  317.     system.
  318.  
  319.     After installation (only the first  successful  invocation of
  320.     NTG.COM actually loads the TSR portion), the FOSSIL  driver's
  321.     extended interrupt driven  functions  are  inactive, and only
  322.     the basic BIOS   services  are   provided   (by   NTG).    An
  323.     application must specifically   "initialise"   a   port   for
  324.     communications to make it become active and use the interrupt
  325.     driven functions.
  326.  
  327.     When NTG is  installed,  it  does a brief and simple hardware
  328.     diagnostic to detect what communications ports are valid.  If
  329.     errors are found  (most  PC BIOS'  miss  detection  of  16550
  330.     USARTS, cannot detect  non-standard  communications  hardware
  331.     and do not  look  for  anything  above COM2), the appropriate
  332.     BIOS tables and hardware bits  are  patched.  This means that
  333.     if you install and use non-standard port and IRQ settings for
  334.     a communications card,  and  tell  NTG about these  (via  the
  335.     NTGPORT utility) your  BIOS  will be changed to reflect this,
  336.     allowing other BIOS-compatible    programs    to    use   the
  337.     communications port (COM1 through COM4 only since the PC BIOS
  338.     can only support up to 4 ports).
  339.  
  340.  
  341.  
  342.  
  343.                          COMMAND LINE OPTIONS
  344.  
  345.  
  346.     Following is a  list  of  command line options  available  in
  347.     either or both   NTG.COM  and  NTG.SYS.   These  allow  "fine
  348.     tuning", setup and utility functions.
  349.  
  350.     Command line switches can be given  with a preceding dash (-)
  351.     or forward slash   (/).   Some  parameters   show   a   colon
  352.     separating the switch itself and a numeric parameter: this is
  353.     optional, and is  included  only  for readability.  An equals
  354.     (=) or comma (,) are NOT optional  and must be included since
  355.     these separate different parts of a command line switch.
  356.  
  357.  
  358.  
  359.                                 - 5 -
  360.  
  361.  
  362.                       NTG Revision 5 FOSSIL Communications Driver
  363.                                                      Version 2.00
  364.  
  365.     There are basically  two  "groups"  of command line switches.
  366.     The first are  configuration   switches,   which  affect  the
  367.     tuning, performance   and  behaviour  of  the  communications
  368.     driver.  These can  generally be combined on the same command
  369.     line (and invocation) without problems.   Exceptions (if any)
  370.     are noted where relevant.
  371.  
  372.     The second group are "utility" functions.  These switches are
  373.     normally used EXCLUSIVELY of all other switches.  That is, if
  374.     you use them, they must appear SEPARATELY on a  command line.
  375.     The switches in this group are:
  376.  
  377.          /C        Recapture INT 14H vector
  378.          /B        Reboot system unconditionally
  379.          /S        Display driver status
  380.          /H        Display help for command line switches
  381.          /U        Unload driver from memory
  382.          /W        Enable/disable carrier watch
  383.  
  384.     Remember that you  can  invoke NTG.COM multiple times with no
  385.     risk in loading the communications  driver  portion more than
  386.     once in any  logical  "task".   All  utilities   relating  to
  387.     NTG.COM are contained within the same .COM file.
  388.  
  389.     The device driver  version  works  a little differently.  Its
  390.     command line (specified  in  CONFIG.SYS)  must  contain  only
  391.     configuration items, since the utilities are  not  supported.
  392.     These are contained   within  a  separate  executable  called
  393.     NTGHELP.COM, and have a similar  -  if not identical - syntax
  394.     to the utility   functions   in   the   .COM  version.    Any
  395.     differences are noted below.
  396.  
  397.  
  398.  
  399.                                  ~~~
  400.  
  401.  
  402.  
  403.  
  404.     /T        Set Transmit buffer size
  405.               Available in .SYS and .COM versions
  406.  
  407.          eg.  /T:512
  408.               Sets 512 byte transmit buffers
  409.  
  410.          The default  transmit  buffer size is 1024 bytes.  Since
  411.          file transfers are "transmitter  driven" so far as speed
  412.          is concerned, this should be large enough to service the
  413.          interrupt driven transmitter without it "waiting"  to be
  414.          filled by the application.  These should be increased in
  415.          size where  multitaskers,  networks or faster baud rates
  416.          are being used.
  417.  
  418.  
  419.  
  420.  
  421.  
  422.  
  423.  
  424.  
  425.                                 - 6 -
  426.  
  427.  
  428.                       NTG Revision 5 FOSSIL Communications Driver
  429.                                                      Version 2.00
  430.  
  431.     /R        Set Receive buffer size
  432.               Available in .SYS and .COM versions
  433.  
  434.          eg.  /R:2048
  435.               Sets RX buffer size of 2048 (2K) bytes
  436.  
  437.          The default  RX  (receive)  buffer  size  is 1K, or 1024
  438.          bytes.  In practice, only  a portion of this is actually
  439.          used on a constant basis, but this will be  dependant on
  440.          how fast an application can service the buffer (and keep
  441.          it empty).
  442.  
  443.          Buffer sizes  CAN  be  changed  "on-the-fly".  But at no
  444.          time can  both  the  receive  and  transmit  buffers  be
  445.          increased in size beyond the combined amount  when first
  446.          installed.  For  example,  if  NTG was installed with 2K
  447.          transmit and 4K receive buffers, only 6K is available to
  448.          each port in total.  Combined  buffer size cannot exceed
  449.          that 6K.  An attempt to exceed this amount  will  result
  450.          in an error.
  451.  
  452.          Changing buffer  sizes  whilst  communications tasks are
  453.          active will be disallowed.
  454.  
  455.          When modifying the buffer  sizes,  it  is  advisable  to
  456.          first specify  the  one  which is to "shrink"  in  size,
  457.          before the  one  which  will "grow".  For example, if 1K
  458.          buffers were active (with  a total of 2K available), and
  459.          you wished  to  change  these  to .5K receive  and  1.5K
  460.          transmit:
  461.  
  462.               NTG /T1536 /R512
  463.  
  464.          would result in an error (Maximum buffer size exceeded).
  465.          The result  could  be  achieved by changing the order of
  466.          the command line arguments to:
  467.  
  468.               NTG /R512 /T1536
  469.  
  470.  
  471.  
  472.     /P        Enable concurrent ports
  473.               Available in .SYS and .COM versions
  474.  
  475.          eg.  /P:2
  476.               Enables two ports for use concurrently
  477.  
  478.          This sets the number of ports which can be active at the
  479.          same time.  Up to 4 ports  can  be used (in this current
  480.          release), in up to 16 different configurations.
  481.  
  482.          By default, NTG enables one port for 'interrupt  driven'
  483.          use.  This  is the most memory conservative approach and
  484.          fits the requirements of the majority of installations.
  485.  
  486.          The current  version  does   not   support  shared  port
  487.          arrangements or  multi-port  'intelligent'   serial   IO
  488.          controllers.
  489.  
  490.  
  491.                                 - 7 -
  492.  
  493.  
  494.                       NTG Revision 5 FOSSIL Communications Driver
  495.                                                      Version 2.00
  496.  
  497.  
  498.          This switch  does  not  determine  WHICH  ports  will be
  499.          valid, only HOW MANY can run  FOSSIL driven at one time.
  500.          The driver  will  support  whichever  port   (0-15)  the
  501.          application selects.
  502.  
  503.  
  504.  
  505.  
  506.     /L        Lock ports baud rate and/or settings
  507.               Available in .SYS and .COM versions
  508.  
  509.          eg.  /L:0=19200
  510.               Locks baud rate on port 0 (COM1) to 19200
  511.               /L:1=38400,8N1
  512.               Locks port 1 (COM2) to 38400, and forces 8
  513.               data bits, no parity and 1 stop bit.
  514.               /L:0=0,7E1
  515.               Unlocks port 0 (COM1) if previously locked,
  516.               or leaves it 'floating' if not, then forces
  517.               7 data bits, even parity and 1 stop bit.
  518.  
  519.          The baud  rate given must be valid for a standard FOSSIL
  520.          driver, and can be one of  0  (unlock)  300,  600, 1200,
  521.          2400, 4800,  9600,  19200 or 38400.  High  speed  modems
  522.          locked at a baud rate of 9600 or above also have CTS/RTS
  523.          hand-shaking forced since these use the modem's internal
  524.          buffering which make use of CTS/RTS flow control.
  525.  
  526.          A baud  rate  specification  of  zero "unlocks" the baud
  527.          rate and resets handshaking  to  default  (whatever  the
  528.          application sets).
  529.  
  530.          When using  this  switch,  your  modem  MUST  support  a
  531.          constant modem  to  computer  speed,  otherwise any baud
  532.          rate change requested by an application will be ignored,
  533.          resulting in an incorrect  setting  between  your system
  534.          and remote.  The result will normally be  garbled  input
  535.          and output.
  536.  
  537.          When the  baud  rate  is locked, the port's baud rate is
  538.          set IMMEDIATELY.  The baud  rate  is  maintained  at the
  539.          locked rate  even  though  FOSSIL  is   not   active   -
  540.          applications making  use  of  BIOS  calls to change baud
  541.          rate will not succeed.   This  allows  non-FOSSIL  aware
  542.          applications to  be run without fear of  the  baud  rate
  543.          being changed   even  though  these  do  not  explicitly
  544.          support higher baud rates.
  545.  
  546.  
  547.  
  548.  
  549.     /F        Enables/disable 'fast' screen writes
  550.               Available in .SYS and .COM versions
  551.  
  552.          eg.  /F+       Enables 'fast' screen writes
  553.               /F-       Disables 'fast' screen writes
  554.  
  555.  
  556.  
  557.                                 - 8 -
  558.  
  559.  
  560.                       NTG Revision 5 FOSSIL Communications Driver
  561.                                                      Version 2.00
  562.  
  563.  
  564.          This switch  is  used  for versions of DOS which support
  565.          faster character output  via  the  undocumented  INT 29H
  566.          method (used to call the ANSI driver directly).   To  my
  567.          knowledge, this  will  work  on  all  DOS  versions 2.00
  568.          through 4.01, but since it  is  "undocumented", there is
  569.          no guarantee that it will work.
  570.  
  571.          This should NOT be enabled under PC-MOS/386  version 4.0
  572.          or below.
  573.  
  574.  
  575.  
  576.  
  577.     /O        Enable function 0x1c compatibility
  578.               Available in .SYS and .COM versions
  579.  
  580.          eg.  /O
  581.  
  582.          This switch  is used to enable "compatible" operation of
  583.          NTG in situations where either  X00  or Opus!Com worked,
  584.          but NTG  doesn't.   Due  to  a misunderstanding  of  the
  585.          FOSSIL specification,  X00 and Opus!Com return 0x1c (28)
  586.          whenever the highest function  number is requested by an
  587.          application instead  of  0x1b  (27)  as   required   the
  588.          Revision 5 specification (FSC-0015).
  589.  
  590.          Several applications  rely  on  the  'feature'  of these
  591.          drivers and require a 0x1c  return  to  verify  that the
  592.          functions used by the application are present.   At this
  593.          time, a  function  0x1c  is  not actually implemented by
  594.          X00.SYS, Opus!Com or NTG.
  595.  
  596.          When given, this switch tells NTG to return 0x1c, and so
  597.          allows applications relying  on  0x1c  to  work with it.
  598.          Typically, such  programs will return with  "FOSSIL  not
  599.          present" or  "FOSSIL  version too old" (or words to that
  600.          effect) when NTG is loaded without using '/O'.
  601.  
  602.  
  603.  
  604.     /Z        Sets 16550 FIFO size/trigger levels
  605.               Available in .SYS and .COM versions
  606.  
  607.          eg.  NTG /Z0
  608.               Enables full 16550 FIFO buffering (16/14)
  609.               NTG /Z5
  610.               Disables 16550 FIFO buffers
  611.  
  612.          This switch provides the ability to 'fine tune' a system
  613.          equipped with  a National  Semiconductor  16550AN  UART.
  614.          The UART  is  the  device used in PC's for  asynchronous
  615.          communications handling,  and  the 16550AN is a superior
  616.          form of these (as compared  to  an  8250  or  16450 with
  617.          which it is pin-compatible), since it provides  on-board
  618.          FIFO (first-in   first-out)   buffers   or   queues  for
  619.          receiving and transmitting.
  620.  
  621.  
  622.  
  623.                                 - 9 -
  624.  
  625.  
  626.                       NTG Revision 5 FOSSIL Communications Driver
  627.                                                      Version 2.00
  628.  
  629.          Software must be built to specifically take advantage of
  630.          this UART's  features in order to gain any real benefit.
  631.          Normally, the  16550's  FIFO  buffers  are  disabled  on
  632.          power-up, and   remain  that  way  unless   specifically
  633.          enabled.  The software itself must service interrupts by
  634.          emptying and  filling  "queues"  rather  than the normal
  635.          single character receive and transmit holding registers.
  636.          Having this  ability  to   service   multiple  character
  637.          requests in  one  hardware  interrupt   call   makes  it
  638.          possible to   SIGNIFICANTLY   reduce  interrupt  service
  639.          overhead and thus CPU usage  on  any  machine.  This has
  640.          very obvious   advantages   when   operating   under   a
  641.          multitasker, on   a  network,  concurrently  with  other
  642.          heavily interrupt-driven devices or with modems or other
  643.          communications devices running at high baud rates.
  644.  
  645.          The /Z switch takes a single  digit parameter - a number
  646.          between 0  and  5.   This  number affects  the  internal
  647.          settings of both the UART itself (its internal 'trigger'
  648.          levels, which  define  how  "full"  the  FIFO's  will be
  649.          allowed to get before triggering an interrupt to the CPU
  650.          for service) and how full NTG will let the transmit FIFO
  651.          be queue on each transmit 'request'.
  652.  
  653.          Valid numeric parameters to the /Z switch are:
  654.  
  655.               /Z0            16 bytes       14 bytes (max)
  656.               /Z1            14 bytes       14 bytes (max)
  657.               /Z2            08 bytes       08 bytes
  658.               /Z3            04 bytes       04 bytes
  659.               /Z4            01 byte        01 byte
  660.               /Z5                - FIFOs disabled -
  661.  
  662.          Where 16550AN's  are  not   present,  NTG  automatically
  663.          ignores this switch completely.   The default  value  is
  664.          '/Z0', which activates the full 16550AN capability.
  665.  
  666.  
  667.  
  668.     /M        Enable/disable initialisation message
  669.               Available in .SYS and .COM versions
  670.  
  671.          eg.  /M+  Enable init message
  672.               /M-  Disables init message
  673.  
  674.          Normally the   driver   outputs   a   message   when  an
  675.          applications initialises  the  driver for its use.  This
  676.          may be suppressed or reenabled by using this switch.
  677.  
  678.  
  679.  
  680.  
  681.     /U        Unload driver from memory
  682.               Available in .COM version only
  683.  
  684.          eg.  NTG /U
  685.               Attempts unloading resident driver from memory
  686.  
  687.  
  688.  
  689.                                 - 10 -
  690.  
  691.  
  692.                       NTG Revision 5 FOSSIL Communications Driver
  693.                                                      Version 2.00
  694.  
  695.          This switch  tells NTG.COM to unload itself from memory.
  696.          This forces all ports to  be  deactivated  (if  any  are
  697.          active).  This  will fail if programs loaded  after  NTG
  698.          have "captured"  interrupt vectors which are used by NTG
  699.          (and which NTG cannot restore  as  a  result).   In this
  700.          case, NTG will not load, but will indicate  this  in  an
  701.          error message.    You  will  have to either unload these
  702.          later programs (such as FOSSIL  appendages),  or  reboot
  703.          your system.
  704.  
  705.          Since NTG.SYS is a device driver, it cannot  be disabled
  706.          or unloaded from memory.
  707.  
  708.  
  709.  
  710.     /Q        Disable communications driver interface
  711.               Available in .SYS and .COM versions
  712.  
  713.          eg.  NTG /Q
  714.               Disables resident driver
  715.  
  716.          This switch  is normally given when NTG installs itself,
  717.          and the effect is to "delay"  capturing  of  the INT 14H
  718.          vector until  a  '/C' command is issued.   This  may  be
  719.          useful if  loading  with  a  multitasker and using other
  720.          incompatible communications drivers in other tasks.
  721.  
  722.          If issued while NTG is already  loaded,  the  previously
  723.          active INT   14H  communications  services   vector   is
  724.          restored.  NTG's    extended    FOSSIL    services   are
  725.          effectively "dropped" out of the chain.
  726.  
  727.  
  728.  
  729.     /B        System reboot
  730.  
  731.          eg.  NTG /B0
  732.               Select default reboot method
  733.               NTG /B
  734.               Reboot (warm)
  735.  
  736.          This switch has two uses.   When  a digit is given after
  737.          the 'B', the reboot method is selected.  Only two values
  738.          are valid 0 or 1.
  739.  
  740.          Method 0 selects a standard BIOS method  of  jumping  to
  741.          the system's  reset  vector.  This should work with most
  742.          DOS environments on a wide  range of hardware, including
  743.          PC/XT/AT and 386 compatibles.
  744.  
  745.          Method 1 makes use of the AT's keyboard  reset  line  to
  746.          cause a  system  reboot.   It  will  work only on AT and
  747.          386AT systems.  However,  this  method  will  work under
  748.          some 386 specific software where the first  method  does
  749.          not.  (for  example,  PC-MOS/386).   In short, it "plays
  750.          rough".  Some 386 machines  and almost all PC/XT systems
  751.          cannot and should not use this method.
  752.  
  753.  
  754.  
  755.                                 - 11 -
  756.  
  757.  
  758.                       NTG Revision 5 FOSSIL Communications Driver
  759.                                                      Version 2.00
  760.  
  761.          If no  digit  is  given  after  the 'B', NTG proceeds to
  762.          reboot the machine - unconditionally.
  763.  
  764.  
  765.  
  766.     /H or /?  Display help information
  767.               Available in .COM version only
  768.  
  769.          This switch  displays  information  about  command  line
  770.          switches and  usage  for  those who don't  believe  that
  771.          reading manuals is a very useful exercise.  Pity they'll
  772.          probably never discover or know about this switch unless
  773.          told....
  774.  
  775.          This switch  much  be  used  alone,  and  will  not load
  776.          NTG.COM into memory.  The  help  screen  displayed  will
  777.          look like:
  778.  
  779.   ■  Usage: NTG [options]     · accepts / or - as switch character
  780.      /U          ∙ Uninstall (if already resident)
  781.      /T=nnnn     ∙ Set TX buffer size to <nnnn> (decimal)
  782.      /R=nnnn     ∙ Set RX buffer size to <nnnn> (decimal)
  783.      /P=nn       ∙ Enable nn concurrent ports (1-16 decimal)
  784.      /D[=n+|-]   ∙ Enable or install diagnostics panel
  785.      /N          ∙ Disable diagnostics panel (may be reenabled)
  786.      /A=nn       ∙ Set screen attribute for diagnostics window
  787.      /Lp=n[,lps] ∙ Lock port <p> (0=COM1) baud rate to <n> (0=Unlock)
  788.                    Optional: l=Character length, p=Parity, s=Stop Bits
  789.      /W=n+|-     ∙ Enable(+)/disable(-) carrier watch on port <n> (0=COM1)
  790.      /Q          ∙ Prevent INT 14H capture (install) or release INT 14H
  791.      /M+|-       ∙ Enable(+)/disable(-) FOSSIL "init" message
  792.      /I=n+|-     ∙ Initialise(+)/deinitialise(-) FOSSIL on port <n>
  793.      /F+|-       ∙ Enable/dssable faster screen writes via ANSI driver
  794.      /B[0|1]     ∙ Select reboot method, or perform system reboot
  795.      /Z[0-5]     ∙ Sets 16550 FIFOs [0=Max(16) 4=Min(1) 5=Disabled]
  796.      /O          ∙ Enable function 0x1c "compatibility"
  797.      /C          ∙ Recapture INT 14H vector
  798.      /S          ∙ Display driver status
  799.      /H or /?    ∙ Display this help screen
  800.  
  801.  
  802.  
  803.     /C        Recapture INT 14H vector
  804.               Available in .COM version only
  805.  
  806.          eg.  NTG /C
  807.               Recapture INT 14H
  808.               (must not be used with any other switches!)
  809.  
  810.          This forces NTG to takes a look at the current  location
  811.          of INT  14H  and  makes  sure  that  it  points into the
  812.          resident portion of NTG.   If not, it resets the INT 14H
  813.          address to the correct location.
  814.  
  815.          This is most often necessary when using a  multitasker -
  816.          such as  DESQview(tm) - which revectors the interrupt on
  817.  
  818.  
  819.                                 - 12 -
  820.  
  821.  
  822.                       NTG Revision 5 FOSSIL Communications Driver
  823.                                                      Version 2.00
  824.  
  825.          loading.  Since  one  standard  method  of detecting the
  826.          presence of a FOSSIL driver is to examine memory shortly
  827.          after the location pointed  to  by the INT 14H interrupt
  828.          vector, the  'stealing'  of the interrupt  in  this  way
  829.          causes many  applications  to  fail to locate the FOSSIL
  830.          driver.  Applications which  use  the  'init  signature'
  831.          method of detecting a FOSSIL driver will not normally be
  832.          affected by this behaviour, but there  is  a  risk  that
  833.          whatever 'stole'  the vector will unintentionally change
  834.          CPU registers used by the  application  for  the  FOSSIL
  835.          call, causing any number of complications  (and probably
  836.          a system crash!).
  837.  
  838.          Another use  of  this switch might be to enable toggling
  839.          between two or more communications  drivers  which  make
  840.          use  of  INT  14H  (such  as packet radio communications
  841.          drivers).  '/Q'  can  be  used  to  switch NTG "off" and
  842.          restore a previous vector, and '/C' used to recapture it
  843.          again for FOSSIL use.  The  following  sequence  is  the
  844.          suggested method of doing this:
  845.  
  846.            NTG /Q [other switches]
  847.                  (Install but don't vector INT 14H)
  848.            <install other communications driver>
  849.            NTG /C
  850.                  (Capture INT 14H saving previous vector)
  851.  
  852.          To use the secondary driver (which could even be another
  853.          FOSSIL driver,  but cannot be NTG), use  "NTG  /Q",  and
  854.          "NTG /C" to use NTG again.
  855.  
  856.  
  857.          NOTE: This  switch  MUST NOT be combined with any others
  858.          (since they will be ignored)!
  859.  
  860.  
  861.  
  862.     /W        Enable/disable carrier watchdog
  863.  
  864.          eg.  NTG /W0+
  865.               Enables carrier watchdog on port 0 (COM1)
  866.               NTG /W1-
  867.               Disables carrier watch on port 1 (COM2)
  868.  
  869.          This switch  enables or disables  carrier  watch  for  a
  870.          particular communications port.  If carrier detect drops
  871.          (the caller  hangs  up) while the watchdog  function  is
  872.          active, the system will be rebooted.
  873.  
  874.          This feature  is most often used with programs which are
  875.          not "carrier smart" and do  not monitor carrier detect -
  876.          some of these were probably never intended  to  run with
  877.          output directed  to  a communications port.  If a caller
  878.          hangs up while such a program  requests input, it may be
  879.          effectively "stuck", unable to continue until  its input
  880.          is satisfied.    It is possible that this situation also
  881.          presents a security risk.
  882.  
  883.  
  884.  
  885.                                 - 13 -
  886.  
  887.  
  888.  
  889.  
  890.  
  891.  
  892.     /S        Display NTG status
  893.               Available in .COM version only
  894.  
  895.          eg.  NTG /S
  896.               Displays NTG's current status
  897.  
  898.          The resulting  display  will depend on the current state
  899.          of the resident version of  the driver in memory, but if
  900.          loaded will normally look similar to:
  901.  
  902.          Driver Version: 2.00    Installed
  903.         Ports Available: 1
  904.            Ports Active: 0
  905.         FOSSIL Revision: 5
  906.          TX Buffer Size: 2048
  907.          RX Buffer Size: 2048
  908.         Max Buffer Size: 4096
  909.            Diags Module: Inactive
  910.            Init Message: Enabled
  911.             ANSI Output: Fast
  912.             Port Locked: 1 @ 19200
  913.  
  914.          If the driver is not yet installed, only  the first line
  915.          will be  shown,  with  the  text  "Not  Installed".  The
  916.          diagnostics module (explained below) is one of "Active",
  917.          "Inactive" (present but disabled)  or "Not loaded".  Any
  918.          ports whose  baud  rate  has  been "locked"  are  listed
  919.          sequentially.
  920.  
  921.          Note that  port  numbers are ZERO-BASED.  Port 0 is what
  922.          DOS refers to COM port 1  (ie.  the device COM1), port 1
  923.          is COM2  etc.    DOS does not define devices  for  ports
  924.          above port 3, though NTG can utilise them.
  925.  
  926.  
  927.  
  928.  
  929.  
  930.  
  931.                                 - 14 -
  932.  
  933.  
  934.                       NTG Revision 5 FOSSIL Communications Driver
  935.                                                      Version 2.00
  936.  
  937.     /D        Enable/disable or install diagnostics module
  938.  
  939.          eg.  NTG /D2+
  940.               On NTG install: Installs the diagnostics panel with
  941.                               a default 'refresh' rate of 2, and
  942.                               enabled (the '+' here is optional)
  943.               Otherwise:      Provided the diagnostics module has
  944.                               been installed, enables it and sets
  945.                               the 'refresh' rate to 2
  946.               NTG /D-
  947.               Disables diagnostics screen updating (but does not
  948.               deactivate them)
  949.  
  950.          This is   an   advanced   option,  useful  for  software
  951.          development using FOSSIL  calls  as  a  means of viewing
  952.          what the current state of the FOSSIL driver  is in 'real
  953.          time'.  When  enabled  and  a  port is active for FOSSIL
  954.          extended calls, a panel is  continually refreshed on the
  955.          screen during each timer tick which displays  a  summary
  956.          of various FOSSIL driver states.
  957.  
  958.          Information for   up   to   4  ports  can  be  displayed
  959.          concurrently on the screen (thought this might get a bit
  960.          messy!), overlaying anything currently displayed.
  961.  
  962.          By default, the "refresh rate" of the panel(s) is set to
  963.          0, which means it is refreshed EVERY timer tick, or at a
  964.          rate of about 18.2 times per second.  Refresh rates of 1
  965.          means every second tick, 2  every third, 3 every fourth,
  966.          and so  on.   Since video memory is slower  than  normal
  967.          RAM, slowing  down  the  refresh  rate will decrease the
  968.          overall detrimental  effect   that  diagnostics  has  on
  969.          system performance.
  970.  
  971.          It should  be  noted  that  running  diagnostics   quite
  972.          significantly impedes  system  performance  and  adds  a
  973.          great deal  of  CPU  overhead   in   servicing  what  is
  974.          effectively a "background" task.  You can therefore only
  975.          run diagnostics  on a system equipped with  a  fast  CPU
  976.          (286 or  above), running at lower baud rates and/or with
  977.          a 16550AN UART.  Some general 'minimal' guide-lines are:
  978.  
  979.            ■ 2400 baud or below
  980.               ∙ 6-8MHZ 286 class
  981.               ∙ 16450 UART or better
  982.  
  983.            ■ 9600 baud
  984.               ∙ 10-16MHZ 286 class  -or-   ∙ 20MHZ 386 class
  985.               ∙ 16550 UART                  ∙ 16450 UART
  986.  
  987.            ■ 19200 baud
  988.               ∙ 16-20MHZ 286/386 class
  989.               ∙ 16550AN UART
  990.  
  991.          It takes quite a bit of  processing  power  to  drive  a
  992.          'background' routine  to  refresh video  RAM  (which  is
  993.          relatively slow)    without    impacting    on    system
  994.          performance.
  995.  
  996.  
  997.                                 - 15 -
  998.  
  999.  
  1000.                       NTG Revision 5 FOSSIL Communications Driver
  1001.                                                      Version 2.00
  1002.  
  1003.  
  1004.          If you  are  having  any  difficulties  at all using the
  1005.          driver and have enabled the  diagnostics  panel, disable
  1006.          them immediately and try again.  I have found this to be
  1007.          a major cause of problems in the past.  This  feature is
  1008.          officially 'not  supported'  under any conditions, and I
  1009.          certainly don't need to hear that it "does" or "doesn't"
  1010.          work on your system.  Before  ANY problem report is made
  1011.          for any reason whatsoever, please try whatever  you  are
  1012.          trying to achieve WITHOUT DIAGNOSTICS LOADED!
  1013.  
  1014.          Usual symptoms  of  the diagnostics panel impacting in a
  1015.          detrimental way on a system's ability to communicate are
  1016.          failed handshaking   between      mailers,   poor
  1017.          resilience in file transfers when "task" switching under
  1018.          multitasking software, some spurious character loss from
  1019.          remote during terminal sessions, failure to initialise a
  1020.          modem and  inability  to detect incoming  calls  from  a
  1021.          modem returning    verbose   response   codes   (amongst
  1022.          others...).
  1023.  
  1024.          When loaded (which must be  done  via the /D switch when
  1025.          NTG is initially installed), you can selectively  enable
  1026.          or disable  the diagnostics display from a keyboard "hot
  1027.          key".  The window is in an  initial  "on" state, but can
  1028.          be toggled  on or off by pressing LeftShift-Ctrl-5  (the
  1029.          '5' located  on the numeric keypad).  The 'refresh rate'
  1030.          can also  be adjusted on-the-fly  using  LeftShift-Ctrl-
  1031.          Grey+ and LeftShift-Ctrl-Grey-.  The panel itself can be
  1032.          shifted on the screen by holding down the LeftShift-Ctrl
  1033.          combination and pressing Up, Down, Left and  Right arrow
  1034.          keys.  Note  that  the background screen is NOT restored
  1035.          (since it is never saved).
  1036.  
  1037.          In summary:
  1038.  
  1039.            Left-Shift     Action
  1040.  
  1041.            Numeric 5      Toggle panel "off" and "on"
  1042.            Grey+/Grey-    Speed up/slow down panel refresh rate
  1043.            Arrow keys     Move diagnostics panel on screen
  1044.  
  1045.          Note that these 'hot-keys'  work, no matter if the panel
  1046.          is visible  or  not, but not if disabled  using  the  /N
  1047.          switch.
  1048.  
  1049.          Toggling the  panel  "off"  using LS-5 does not entirely
  1050.          defeat the CPU overhead required  to  service the panel.
  1051.          In that case, the background task is still  active,  and
  1052.          only the  panel  is  not displayed.  To entirely disable
  1053.          the diagnostics  panel, either  unload  and  reload  NTG
  1054.          without the  /D  switch, or use "NTG /N" to  effectively
  1055.          turn it off.
  1056.  
  1057.          The following  diagram shows a typical diagnostics panel
  1058.          display, and explains the  fields  shown.    All numeric
  1059.          values are hexadecimal (base 16).
  1060.  
  1061.  
  1062.  
  1063.                                 - 16 -
  1064.  
  1065.  
  1066.                       NTG Revision 5 FOSSIL Communications Driver
  1067.                                                      Version 2.00
  1068.  
  1069.  
  1070.  
  1071.       ┌── Port 0001 ┐ ─────── Port number, zero based (0=COM1)
  1072.       │ TX Cnt 0001 │ ─────── Chrs currently in transmit buffer
  1073.       │ TX Max 003F │ ─────── Maximum chrs found in transmit
  1074.       │ TX Bse 141E │ ]       buffer (this is cleared whenever
  1075.       │ TX Top 241D │ ] ──┐   the port is initialised)
  1076.       │ TX Nxt 144A │ ]   └── Transmit buffer pointers/limits
  1077.       │ TX End 1449 │ ]
  1078.       │ RX Cnt 0002 │ ─────── Chrs currently in receive buffer
  1079.       │ RX Max 0019 │ ─────── Maximum chrs found in receive
  1080.       │ RX Bse 241E │ ]       buffered (cleared on init)
  1081.       │ RX Top 341D │ ] ───── Receive buffer pointers/limits
  1082.       │ RX Nxt 249A │ ]  ┌─── Current flow control state
  1083.       │ RX End 249A │ ]  │    highbyte=remote, lowbyte=local
  1084.       │ FlwFlg 0080 │ ───┘┌── Active flow control settings
  1085.       │ FlwCtl 0002 │ ────┘   highbyte=remote, lowbyte=local
  1086.       │ Status 6238 │ ─────── Current line/modem status
  1087.       │ FifoSz 0010 │ ─────── 16550AN FIFO buffer (TX) size
  1088.       │ Errors 0000 │ ─────── Number of FOSSIL errors registered
  1089.       │ ErrFun 0000 │ ─────── Function (AX value) of error call
  1090.       │ LastAX 0300 │ ─────── Last Int 14H function call (AX)
  1091.       │ Int14H 5F73 │ ─────── Accumulated Int 14H calls
  1092.       │ ISRInt 0D4F │ ─────── Accumulated hardware interrupts
  1093.       └──NTG─vX.XX──┘
  1094.  
  1095.  
  1096.  
  1097.          If you want to load diagnostics but have them completely
  1098.          inactive by   default,  use  the  following  batch  file
  1099.          sequence:
  1100.  
  1101.               REM Load diagnostics module when installing NTG
  1102.               NTG -D <other switches ...>
  1103.               REM Immediately disable them
  1104.               NTG -N
  1105.  
  1106.          The option to load without  screen  refresh "/Dn-" still
  1107.          uses clock cycles: only the screen update is inhibited.
  1108.  
  1109.          The "/N"   switch   actually  disables  the   background
  1110.          processing and   will   not  cause  any  degradation  in
  1111.          performance.  "/D" can be  used  to  reenable the module
  1112.          again.
  1113.  
  1114.  
  1115.  
  1116.  
  1117.     /N        Disable diagnostics panel
  1118.  
  1119.          eg.  NTG /N
  1120.  
  1121.          This switch disables output of diagnostic information to
  1122.          the screen, and also the background processing  required
  1123.          to update it.
  1124.  
  1125.  
  1126.  
  1127.  
  1128.  
  1129.                                 - 17 -
  1130.  
  1131.  
  1132.                       NTG Revision 5 FOSSIL Communications Driver
  1133.                                                      Version 2.00
  1134.  
  1135.  
  1136.     /A        Set diagnostics panel attribute
  1137.  
  1138.          eg.  NTG /A=79
  1139.               Causes the  diagnostics  panel  to  become  intense
  1140.               white on red
  1141.  
  1142.          This allows the physical screen attribute to be set.  By
  1143.          default, a colour screen uses  dark blue on white, and a
  1144.          monochrome screen reverse video.
  1145.  
  1146.  
  1147.  
  1148.     /I        Init/deinit FOSSIL enhanced functions
  1149.  
  1150.          eg.  NTG /I0+
  1151.               Initialise port 0 (COM1) for FOSSIL processing
  1152.               NTG /I1-
  1153.               Deinitialise port 1 (COM2)
  1154.  
  1155.          This provides the facility to force normally  non-FOSSIL
  1156.          aware BIOS  compatible  programs to use the basic FOSSIL
  1157.          character input/output functions.
  1158.  
  1159.          This has  specific  advantages   when  running  under  a
  1160.          multitasker, since  all  input/output is from  interrupt
  1161.          serviced buffers,   and   not   directly   polling   the
  1162.          communications port for activity.
  1163.  
  1164.          Not all non-FOSSIL aware  programs  will  be  compatible
  1165.          with use  of this option.  Only strictly  BIOS-compliant
  1166.          programs will benefit.  Some program will have their own
  1167.          interrupt driven  communications  functions,  and others
  1168.          will poll the port directly.  Initialising the FOSSIL in
  1169.          this way MAY interfere with  correct  operation of these
  1170.          programs.
  1171.  
  1172.  
  1173.  
  1174.  
  1175.                          GENERAL INFORMATION
  1176.  
  1177.  
  1178.     The following sections outline how best to utilise the driver
  1179.     and get the best performance from it on your hardware setup.
  1180.  
  1181.  
  1182.     INSTALLATION
  1183.  
  1184.     NTG.COM is usually installed in your AUTOEXEC.BAT  or at some
  1185.     time before you    load    your    communications   software.
  1186.     Alternatively, MS-DOS 4.xx has  an option to allow loading of
  1187.     some 'compatible' TSRs using an "install=" statement  in your
  1188.     CONFIG.SYS.  A major  benefit  of  this  is  that  NTG can be
  1189.     loaded before any environment variables are set, and so takes
  1190.     up the absolute minimum of RAM.   However, as with the device
  1191.     driver when loaded   from  CONFIG.SYS,  NTG.COM   cannot   be
  1192.     unloaded from memory using the "/U" option.
  1193.  
  1194.  
  1195.                                 - 18 -
  1196.  
  1197.  
  1198.                       NTG Revision 5 FOSSIL Communications Driver
  1199.                                                      Version 2.00
  1200.  
  1201.  
  1202.     ERRORLEVELS
  1203.  
  1204.     The following errorlevels are returned by NTG (this also
  1205.     documents some of the possible errors which can be returned):
  1206.  
  1207.  
  1208.          0    No error - operation(s) successful
  1209.          1    Status was requested and displayed
  1210.          2    A FOSSIL driver other than NTG is present
  1211.          3    Incompatible version of NTG is already loaded
  1212.          4    Can't modify parameters with ports active
  1213.          5    NTG is not yet resident or loaded
  1214.          6    Not used
  1215.          7    DOS memory allocation error - fatal abort
  1216.          8    Invalid command line option
  1217.          9    Can't unload - FOSSIL appendages are loaded
  1218.          10   System reboot failure
  1219.          11   Error enabling or disabling carrier watch
  1220.          12   Unable to recapture INT 14H vector
  1221.          13   Can't unload if installed from CONFIG.SYS
  1222.          14   Maximum combined TX/RX buffer size exceeded
  1223.          15   Can't disable/enable diags panel - not loaded
  1224.          16   Unable to unload due to interrupt chaining
  1225.          17   Problem initialising FOSSIL (with /I)
  1226.  
  1227.  
  1228.  
  1229.  
  1230.     MULTITASKERS
  1231.  
  1232.     Prior versions of NTG directly supported various multitaskers
  1233.     by allowing for  "poll" detection on status and character I/O
  1234.     calls made to the FOSSIL.  When NTG sensed a task was "idle",
  1235.     it automatically gave  time slices  up  during  "polling"  to
  1236.     other tasks in the system.
  1237.  
  1238.     This internal multitasker  support  has  been   removed  from
  1239.     NTG.COM and NTG.SYS,   and   the   /X  switch  is  no  longer
  1240.     implemented.  However, the current  version  of NTG does have
  1241.     'hooks' for an installable driver to link into  NTG and carry
  1242.     out this task.   This  eliminates  much  of  the  unnecessary
  1243.     "baggage" suffered by users  of  NTG  who  do  not  need this
  1244.     feature.  It also  eliminates  code  made  redundant  by  not
  1245.     having all multitasker   time   slice   resident   at   once,
  1246.     irrespective of which specific  multitasker  is in use.  Only
  1247.     that code which is actually used and plays a part  in support
  1248.     of the multitasker itself is loaded.
  1249.  
  1250.     While this current release (2.00) is not accompanied by these
  1251.     drivers (which are   now   [October,  1991]  in  beta  test),
  1252.     multitasking appendages for DESQview/TopView  and  PC-MOS/386
  1253.     will soon be available.
  1254.  
  1255.  
  1256.  
  1257.  
  1258.  
  1259.  
  1260.  
  1261.                                 - 19 -
  1262.  
  1263.  
  1264.                       NTG Revision 5 FOSSIL Communications Driver
  1265.                                                      Version 2.00
  1266.  
  1267.  
  1268.     MEMORY
  1269.  
  1270.  
  1271.     NTG.COM is approximately  11K  in size.  It is made up of the
  1272.     following main parts:
  1273.  
  1274.  
  1275.     Description           Size  Used by
  1276.     Resident
  1277.     -------------------------------------------------------------
  1278.     ISR Device Driver     0.5K  Common 4 ports   Yes
  1279.     INT 14H Despatcher    4.5K  Common 4 ports   Yes
  1280.     Diagnostics Model     1.0K  Common 4 ports   Optional
  1281.     Initialisation/Setup  1.0K  Run time only    Discarded
  1282.     Command line utility  4.0K  Run time only    Discarded
  1283.     -------------------------------------------------------------
  1284.  
  1285.     What eventually remains resident  depends  upon  what command
  1286.     line options are used.  Initial overhead is about  5K for the
  1287.     ISR and despatcher.   If  diagnostics are used (rarely), then
  1288.     add 1K. Add to this, the sum  of  the  transmit  and  receive
  1289.     buffers times the number of communications ports selected.
  1290.  
  1291.  
  1292.  
  1293.     THE DIAGNOSTICS PANEL
  1294.  
  1295.     The ability to  view the state of the FOSSIL driver  is  very
  1296.     useful when developing  software  utilising FOSSIL calls.  It
  1297.     can also be an invaluable aid in  "tuning" the driver to your
  1298.     machine.  Memory is precious - especially in  a  multitasking
  1299.     environment, and most  of  the time, the standard 1K transmit
  1300.     and receive buffers are far too  much  to allocate.  This can
  1301.     only be empirically tested.
  1302.  
  1303.     Instead of "guessing" and using trial and error  to  see  how
  1304.     well the driver  performs,  it  is  much better to enable the
  1305.     diagnostics window.  This provides a 'snapshot' of the driver
  1306.     18.2 times per second (each clock  tick).   Particular fields
  1307.     to look at are:
  1308.  
  1309.  
  1310.          "TX Cnt"  Indicates how full the transmit  buffer  is in
  1311.                    bytes.
  1312.  
  1313.          "TX Max"    This  is  the  current  'maximum'  count  if
  1314.                    characters in the  transmit buffer detected by
  1315.                    the diagnostics routine (it views  the  driver
  1316.                    in 'snapshots'   so   cannot   be   completely
  1317.                    accurate.
  1318.  
  1319.          "RX Cnt"  Indicates how full  the  receive  buffer is in
  1320.                    bytes.
  1321.  
  1322.          "RX Max"   Maximum count of characters  in  the  receive
  1323.                    buffer (see TX Max).
  1324.  
  1325.  
  1326.  
  1327.                                 - 20 -
  1328.  
  1329.  
  1330.                       NTG Revision 5 FOSSIL Communications Driver
  1331.                                                      Version 2.00
  1332.  
  1333.          "Int14h"  Particularly  useful  for  monitoring  program
  1334.                    activity.  This  counter ticks over every time
  1335.                    the running  application  requests   a  FOSSIL
  1336.                    service.
  1337.  
  1338.          "Errors"  Locates  possible  problems in the program you
  1339.                    are running.  Any  time  the  program makes an
  1340.                    "illegal" call  (usually  incorrect   register
  1341.                    values).  The   last   FOSSIL   function  code
  1342.                    invoked which  triggered  the  error  will  be
  1343.                    displayed next to "ErrFun".
  1344.  
  1345.  
  1346.     By observation, it is possible to calculate the  optimum size
  1347.     for both receive and transmit buffers.
  1348.  
  1349.  
  1350.  
  1351.     16550 USART SUPPORT
  1352.  
  1353.     NTG fully supports  the  16550 USART in buffered mode.  Using
  1354.     the /Z command line switch, you  can  decrease  the amount of
  1355.     FIFO buffering used, or disable the FIFO's completely.
  1356.  
  1357.     This option has  been  included for "compatibility"  reasons.
  1358.     Previous releases of   NTG   used  the  equivalent  of  "/Z2"
  1359.     buffering, whereas this release  defaults  to full use of the
  1360.     FIFO queues.  If you have problems using the default "/Z0"
  1361.     setting, try reducing  first to "/Z1", then "/Z2"  or  lower,
  1362.     and once you've found a setting that works, please contact me
  1363.     (I'm interested in  know what sort of setup this DOESN'T work
  1364.     on).
  1365.  
  1366.  
  1367.  
  1368.                                - End -
  1369.  
  1370.  
  1371.  
  1372.  
  1373.  
  1374.  
  1375.                                - 25 -
  1376.  
  1377.