home *** CD-ROM | disk | FTP | other *** search
/ Power-Programmierung / CD1.mdf / lan / driver6s / drivers.doc < prev    next >
Text File  |  1990-03-15  |  19KB  |  575 lines

  1.  
  2.  
  3.  
  4.  
  5.  
  6.  
  7.                  User documentation for the packet driver collection
  8.                                    Russell Nelson
  9.                                  Clarkson University
  10.                                   Potsdam, NY 13676
  11.                               nelson@clutx.clarkson.edu
  12.  
  13.  
  14.           The purpose of the packet drivers
  15.  
  16.                Every PC Ethernet board is different.  The 3c501 was, for
  17.           some time, the most popular board, and would have become the
  18.           defacto standard but for its poor performance.  By the time 3Com
  19.           created a board with acceptable performance, so had many others,
  20.           and 3Com lost its lead.  FTP Software, in order to support each
  21.           of these boards without losing its collective mind, created the
  22.           Packet Driver Spec (PDS).
  23.  
  24.                Some boards use DMA, programmed I/O, shared memory, and/or
  25.           bus mastering.  The PDS masks the differences between these
  26.           boards by defining a software interface to the boards.  This
  27.           software interface is a software interrupt in the range between
  28.           0x60 (hex) and 0x80.
  29.  
  30.  
  31.           Document conventions
  32.  
  33.                All numbers in this document are given in C-style
  34.           representation.  Decimal is expressed as 11, hexadecimal is
  35.           expressed as 0x0B, octal is expressed as 013.  All reference to
  36.           network hardware addresses (source, destination and multicast)
  37.           and demultiplexing information for the packet headers assumes
  38.           they are represented as they would be in a MAC-level packet
  39.           header being passed to the send_pkt() function.
  40.  
  41.  
  42.           Using the packet drivers
  43.  
  44.                The packet driver must be installed prior to use.  Since
  45.           each packet driver takes only approximately 1800 bytes, this is
  46.           best done in your autoexec.bat.  Since the Ethernet boards typi-
  47.           cally have jumpers on board, the packet driver must be informed
  48.           of the values of these jumpers (auto-configure is possible, but
  49.           can disturb other boards).  The first parameter is the software
  50.           interrupt used to communicate with the packet driver.  And again,
  51.           because each board is different, the rest of the parameters will
  52.           be different.
  53.  
  54.           All parameters must be specified in C-style representation.
  55.           Decimal is expressed as 11, hexadecimal is expressed as 0x0B,
  56.           octal is expressed as 013.  Any numbers that the packet driver
  57.           prints will be in the same notation.
  58.  
  59.           Before installing the packet driver, you must choose a software
  60.           interrupt number in the range between 0x60 and 0x80.  Some of
  61.           these interrupts are used for other purposes, so your first
  62.  
  63.  
  64.  
  65.  
  66.  
  67.  
  68.           choice may not work.  See Appendix A for the section of Ralf
  69.           Brown's interrupt list between 0x60 and 0x80.
  70.  
  71.           Running a packet driver with no specifications will give a usage
  72.           message.  The parameters for each packet driver are documented
  73.           below.
  74.  
  75.  
  76.           3Com 3C501
  77.  
  78.                usage: 3C501 packet_int_no [int_no [io_addr]]
  79.  
  80.                The 3c501 driver requires two additional parameters -- the
  81.           hardware interrupt number and the I/O address.  The defaults are
  82.           3 and 0x300.
  83.  
  84.  
  85.           3Com 3C503
  86.  
  87.                usage: 3C503 packet_int_no [int_level(2-5) [io_addr
  88.           [cable_type]]]
  89.  
  90.                The 3c503 driver requires three additional parameters --
  91.           the hardware interrupt number, the I/O address, and the cable
  92.           type.  The 3c503 can be attached to thick or thin Ethernet
  93.           cables, and the selection is made in software.  The cable type
  94.           parameter should be zero for thin, and one for thick.  The
  95.           defaults are 2, 0x300, and 0 (thin).  The 3c503 uses shared
  96.           memory whose address is set by jumpers, but the software can ask
  97.           the board what the address is.
  98.  
  99.  
  100.           3Com 3c505
  101.  
  102.                usage: 3c505 packet_int_no [int_no [io_addr [base_addr]]]
  103.  
  104.                The 3c505 driver requires three additional parameters --
  105.           the hardware interrupt number, the I/O address, and the memory
  106.           base address.  The defaults are 2 and 0x300 and 0xd000.
  107.  
  108.  
  109.           3Com 3c523
  110.  
  111.                usage: 3c523 packet_int_no [int_no [io_addr [base_addr]]]
  112.  
  113.                The 3c523 driver requires three additional parameters --
  114.           the hardware interrupt number, the I/O address, and the memory
  115.           base address.  The defaults are 3 and 0x300 and 0xc000.
  116.  
  117.  
  118.  
  119.  
  120.  
  121.  
  122.           ARCNET
  123.  
  124.                usage: arcnet packet_int_no [int_no [io_addr [base_addr]]]
  125.  
  126.                The ARCNET driver requires three additional parameters --
  127.           the hardware interrupt number, the I/O address, and the memory
  128.           base address.  The defaults are 5 and 0x2e0 and 0xd800.  Note
  129.           that a packet driver client must specifically support ARCNET.
  130.           The only known client is Phil Karn's (KA9Q) networking package,
  131.           NOS.
  132.  
  133.  
  134.           AT&T
  135.  
  136.                usage: at&t packet_int_no [int_no [io_addr [base_addr]]]
  137.  
  138.                The AT&T driver requires three additional parameters -- the
  139.           hardware interrupt number, the I/O address, and the memory base
  140.           address.  The defaults are 2 and 0x360 and 0xd000.  This driver
  141.           supports the StarLAN 1, StarLAN 10 NAU, EN100 and StarLAN Fiber
  142.           NAU.
  143.  
  144.  
  145.           IBM Token Ring
  146.  
  147.                usage: ibmtoken packet_int_no [adapter_no]
  148.  
  149.                The IBM Token Ring packet driver requires one additional
  150.           parameters -- the adapter number.  The default is zero.  See
  151.           IBMTOKEN.DOC for more information.
  152.  
  153.  
  154.           Novell IPX
  155.  
  156.                usage: ipxpkt packet_int_no
  157.  
  158.                The ipxpkt packet driver simulates Ethernet on Novell IPX
  159.           protocol.
  160.  
  161.  
  162.           BICC Data Networks' ISOLAN 4110 ethernet
  163.  
  164.                usage: isolan packet_int_no [int_no [base_addr]]
  165.  
  166.                The BICC Isolan requires three additional parameters -- the
  167.           hardware interrupt number and the memory base address.  The
  168.           defaults are 2 and 0xb800h.
  169.  
  170.  
  171.  
  172.  
  173.  
  174.  
  175.           Netbios
  176.  
  177.                usage: nb <packet_int_no> <ip.ad.dr.ess> [receive queue
  178.           size]
  179.  
  180.                The netbios packet driver transports IP packets over
  181.           NetBIOS.
  182.  
  183.  
  184.           Novell ne1000
  185.  
  186.                usage: ne1000 packet_int_no [int_no [io_addr]]
  187.  
  188.                The ne1000 driver requires two additional parameters -- the
  189.           hardware interrupt number and the I/O address.  The defaults are
  190.           3 and 0x300.
  191.  
  192.  
  193.           Novell ne2000
  194.  
  195.                usage: ne2000 packet_int_no [int_no [io_addr]]
  196.  
  197.                The ne2000 driver requires two additional parameters -- the
  198.           hardware interrupt number and the I/O address.  The defaults are
  199.           2 and 0x300.
  200.  
  201.  
  202.           Racal/Interlan (Formerly Interlan) NI5010
  203.  
  204.                usage: NI5010 packet_int_no [int_no [io_addr]]
  205.  
  206.                The NI5010 driver requires two additional parameters -- the
  207.           hardware interrupt number and the I/O address.  The defaults are
  208.           3 and 0x300.
  209.  
  210.  
  211.           Racal/Interlan (Formerly Micom-Interlan) NI5210
  212.  
  213.                usage: ni5210 packet_int_no [int_no [io_addr [base_addr]]]
  214.  
  215.                The NI5210 driver requires three additional parameters --
  216.           the hardware interrupt number, the I/O address, and the memory
  217.           base address.  The defaults are 2 and 0x360 and 0xd000.  Note
  218.           that Interlan sets the default memory base to 0xa000, which is
  219.           brain-damaged, because that area of memory is specifically
  220.           reserved for video adapters, and in fact the EGA and VGA use it.
  221.  
  222.  
  223.           Racal/Interlan NI6510
  224.  
  225.                usage: ni6510 packet_int_no [int_no [io_addr]]
  226.  
  227.                The ni6510 driver has two additional parameters -- the
  228.           hardware interrupt number and the I/O address.  The defaults are
  229.           2 and auto-sense.  These parameters do not need to be set unless
  230.  
  231.  
  232.  
  233.  
  234.  
  235.  
  236.           the auto-sense routine fails, or otherwise disrupts operation of
  237.           your PC.
  238.  
  239.  
  240.           Racal-Interlan (Formerly Micom-Interlan) NI9210
  241.  
  242.                usage: ni9210 packet_int_no [int_no [io_addr [base_addr]]]
  243.  
  244.                The ni9210 driver requires three additional parameters --
  245.           the hardware interrupt number, the I/O address, and the memory
  246.           base address.  The defaults are 2 and 0x360 and 0xd000.
  247.  
  248.  
  249.           SLIP8250
  250.  
  251.                usage: SLIP8250 packet_int_no [-h] [driver_class] [int_no]
  252.                   [io_addr] [baud_rate] [send_buf_size] [recv_buf_size]
  253.                   The driver_class should be SLIP, KISS, AX.25, or a
  254.                   number.
  255.  
  256.                The SLIP8250 driver is not strictly an Ethernet adapter,
  257.           however some software packages (such as KA9Q's NET and NCSA
  258.           Telnet) support Serial Line IP (SLIP).  SLIP must be specially
  259.           supported because it doesn't use ARP and has no hardware
  260.           addresses prepended to its packets.  The PDS is not clear on
  261.           this, but the packet driver does the SLIP encoding.  The
  262.           parameters are as follows.  The -h flag is included if you wish
  263.           to use hardware handshaking (the packet driver will then suspend
  264.           the transmission of characters while CTS is low).  The
  265.           driver_class is the class that is returned to a client of the
  266.           packet driver spec in the driver_info call.  The int_no is the
  267.           hardware interrupt number, defaults to 4 (COM1).  The io_addr is
  268.           the hardware I/O address, defaults to 0x3f8 (COM1).  The
  269.           baud_rate defaults to 4800 baud.  The send_buf_size and
  270.           recv_buf_size default to 3000 each.
  271.  
  272.  
  273.           Western Digital WD8003 E EBT EB ET/A and E/A
  274.  
  275.                usage: WD8003E packet_int_no [-o] [int_level [io_addr
  276.           [mem_base]]]
  277.  
  278.                The WD8003E driver runs the Western Digital E, EBT, EB,
  279.           ET/A, and E/A Ethernet cards.  The WD8003E requires three addi-
  280.           tional parameters -- the hardware interrupt number, the I/O
  281.           address, and the memory base address.  The defaults are 2 and
  282.           0x280 and 0xd000.  The wd8003 cards do not enable their memory
  283.           until configuration time.  Some 386 memory mappers will map
  284.           memory into the area that the card intends to use.  You should be
  285.           able to configure your software to leave this area of memory
  286.           alone.  Also driver will refuse to map memory into occupied
  287.           memory.  The occupied memory test fails on some machines, so the
  288.           optional switch -o allows you to disable the check for occupied
  289.           memory.
  290.  
  291.  
  292.  
  293.  
  294.  
  295.  
  296.           Errorlevels
  297.  
  298.                Some of the packet drivers return error codes.  Some of
  299.           these error codes indicate fatal errors, and some are merely
  300.           warnings.  For the moment, you must consult the source to see
  301.           what the errorcodes mean.  For example, pktchk returns 0 if a
  302.           packet driver exists at a given address, and 1 if not.  You might
  303.           use it in a batch file that only installs a packet driver if one
  304.           is not found.
  305.  
  306.                   rem only install the packet driver if there isn't one
  307.                   rem already.
  308.                   pktchk 0x7e
  309.                   if errorlevel 0 goto gotit
  310.                   ni5210 0x7e
  311.           :gotit
  312.  
  313.                The "errorlevel" test is true if the errorlevel is less
  314.           than or equal to the parameter.
  315.  
  316.  
  317.           Utility Programs
  318.  
  319.                There are also several utility programs for packet drivers:
  320.  
  321.  
  322.           PKTADDR
  323.  
  324.                usage: pktaddr packet_int_no [ethernet_addr]
  325.  
  326.                If the second argument is given, the Ethernet address of
  327.           the given packet driver is set.  The Ethernet address is printed
  328.           out.
  329.  
  330.  
  331.           PKTALL
  332.  
  333.                usage: pktall packet_int_no
  334.  
  335.                All packets are received and discarded from the given
  336.           packet driver.  This program is of most use with PKTMODE and
  337.           TRACE.
  338.  
  339.  
  340.           PKTCHK
  341.  
  342.                usage: pktchk packet_int_no [packet_int_no]
  343.  
  344.                Test for existance of a packet driver.  Returns with
  345.           errorlevel 0 if the specified interrupt has a packet driver.  If
  346.           the second argument is given, all interrupts in the range are
  347.           checked for a packet driver.  If no packet driver is found at
  348.           all, errorlevel 1 is returned.
  349.  
  350.  
  351.  
  352.  
  353.  
  354.  
  355.           PKTMODE
  356.  
  357.                usage: pktmode packet_int_no [receive_mode]
  358.  
  359.                If the second argument is given, the receive mode of the
  360.           given packet driver is set.  A decimal number from the list of
  361.           modes should be used.  All the possible modes are printed out.
  362.           Unimplemented modes are marked with "xx", and the current mode is
  363.           marked with "->".
  364.  
  365.  
  366.           PKTMULTI
  367.  
  368.                usage: pktmulti <packet_int_no> [-f <filename> | <address>
  369.           ...]
  370.  
  371.                The specified addresses are set as allowed multicast
  372.           addresses.  If no list of addresses is given, then the current
  373.           list of addresses is printed.  The addresses may either be
  374.           specified on the command line, or in a file using the -f option.
  375.           When a file is used, any whitespace in the file is ignored.
  376.  
  377.  
  378.           PKTSTAT
  379.  
  380.                usage: pktstat <first_int_no> [<last_int_no>]
  381.  
  382.                The statistics for all packet drivers in the given range
  383.           are printed.  The default range is 0x60 through 0x80.  The mean-
  384.           ings of the columns are given below.
  385.  
  386.  
  387.           pkt_in  is the number of packets ever received by this driver.
  388.           pkt_out is the number of packets ever transmitted by this
  389.                   driver.
  390.           byt_in  is the number of bytes ever received by this driver.
  391.           byt_out is the number of bytes ever transmitted by this driver.
  392.           pk_drop Packets dropped because there was no handler for that
  393.                   Ethernet packet type.
  394.           err_in  Dependent upon the packet driver.
  395.           err_out Dependent upon the packet driver.
  396.  
  397.  
  398.           PKTSEND
  399.  
  400.                usage: pktsend <packet_int_no> [-r] [-f filename | packet]
  401.  
  402.                The specified packet is sent using the specified packet
  403.           driver.  The -r option says to repeat sending as fast as
  404.           possible.  You shouldn't use this option very often.  The packet
  405.           may either be specified on the command line, or in a file using
  406.           the -f option.  When a file is used, any whitespace in the file
  407.           is ignored.
  408.  
  409.  
  410.  
  411.  
  412.  
  413.  
  414.           TERMIN
  415.  
  416.                usage: termin packet_int_no
  417.  
  418.                The specified packet driver is terminated, and its memory
  419.           recovered.
  420.  
  421.  
  422.           TRACE
  423.  
  424.                usage: trace packet_int_no [buffer_size]
  425.  
  426.                Trace is very useful for debugging packet driver troubles.
  427.           Trace lets you trace all transactions between a user program and
  428.           the packet driver.  The transactions are stored in a memory
  429.           buffer whose size is set with buffer_size.  The default size is
  430.           10,000 bytes.
  431.  
  432.                When you run trace, it sets itself up and then spawns
  433.           COMMAND.COM so that you can run a network program that uses the
  434.           packet driver.  After you quit your network session, you issue an
  435.           "EXIT" command.  This returns you to trace, which writes the
  436.           transaction log to "TRACE.OUT".  The following program, DUMP,
  437.           interprets TRACE.OUT.
  438.  
  439.  
  440.           DUMP
  441.  
  442.                usage: dump
  443.  
  444.                Interprets the contents of TRACE.OUT as written by TRACE.
  445.  
  446.  
  447.           Who?
  448.  
  449.           See the file support.txt for a listing of all the people who
  450.           contributed packet drivers.
  451.  
  452.  
  453.  
  454.  
  455.  
  456.  
  457.                                      Appendix A
  458.                    Interrupt usage in the range 0x60 through 0x80
  459.  
  460.  
  461.  
  462.           60 -- -- reserved for user interrupt
  463.           60 -- -- FTP Driver - PC/TCP Packet Driver Specification
  464.           60 01 FF FTP Driver - DRIVER INFO
  465.           60 02 -- FTP Driver - ACCESS TYPE
  466.           60 03 -- FTP Driver - RELEASE TYPE
  467.           60 04 -- FTP Driver - SEND PACKET
  468.           60 05 -- FTP Driver - TERMINATE DRIVER FOR HANDLE
  469.           60 06 -- FTP Driver - GET ADDRESS
  470.           60 07 -- FTP Driver - RESET INTERFACE
  471.           60 11 -- 10-NET - LOCK AND WAIT
  472.           60 12 -- 10-NET - LOCK
  473.           60 13 -- 10-NET - UNLOCK
  474.           60 20 -- FTP Driver - SET RECEIVE MODE
  475.           60 21 -- FTP Driver - GET RECEIVE MODE
  476.           60 24 -- FTP Driver - GET STATISTICS
  477.           61 -- -- reserved for user interrupt
  478.           62 -- -- reserved for user interrupt
  479.           63 -- -- reserved for user interrupt
  480.           64 -- -- reserved for user interrupt
  481.           65 -- -- reserved for user interrupt
  482.           66 -- -- reserved for user interrupt
  483.           67 -- -- LIM EMS
  484.                    ...
  485.           67 DE 00 Virtual Control Program Interface - INSTALLATION CHECK
  486.                    ...
  487.           68 01 -- APPC/PC
  488.                    ...
  489.           69 -- -- unused
  490.           6A -- -- unused
  491.           6B -- -- unused
  492.           6C -- -- system resume vector (CONVERTIBLE)
  493.           6C -- -- DOS 3.2 Realtime Clock update
  494.           6D -- -- VGA - internal
  495.           6E -- -- unused
  496.           6F -- -- Novell NetWare - PCOX API (3270 PC terminal interface)
  497.           6F 00 -- 10-NET - LOGIN
  498.                    ...
  499.           70 -- -- IRQ8 - AT/XT286/PS50+ - REAL-TIME CLOCK
  500.           71 -- -- IRQ9 - AT/XT286/PS50+ - LAN ADAPTER 1
  501.           72 -- -- IRQ10 - AT/XT286/PS50+ - RESERVED
  502.           73 -- -- IRQ11 - AT/XT286/PS50+ - RESERVED
  503.           74 -- -- IRQ12 - PS50+ - MOUSE INTERRUPT
  504.           75 -- -- IRQ13 - AT/XT286/PS50+ - 80287 ERROR
  505.           76 -- -- IRQ14 - AT/XT286/PS50+ - FIXED DISK
  506.           77 -- -- IRQ15 - AT/XT286/PS50+ - RESERVED
  507.           78 -- -- not used
  508.           79 -- -- not used
  509.           7A -- -- Novell NetWare - LOW-LEVEL API
  510.           7A -- -- AutoCAD Device Interface
  511.           7B -- -- not used
  512.  
  513.  
  514.  
  515.  
  516.  
  517.  
  518.           7C -- -- not used
  519.           7D -- -- not used
  520.           7E -- -- not used
  521.           7F -- -- HDILOAD.EXE - 8514/A VIDEO CONTROLLER INTERFACE
  522.           7F -- -- HLLAPI (High-Level Language API)
  523.           80 -- -- reserved for BASIC
  524.  
  525.  
  526.  
  527.  
  528.  
  529.  
  530.  
  531.  
  532.  
  533.  
  534.  
  535.  
  536.  
  537.  
  538.  
  539.  
  540.  
  541.  
  542.  
  543.  
  544.  
  545.  
  546.  
  547.  
  548.  
  549.  
  550.  
  551.  
  552.  
  553.  
  554.  
  555.  
  556.  
  557.  
  558.  
  559.  
  560.  
  561.  
  562.  
  563.  
  564.  
  565.  
  566.  
  567.  
  568.  
  569.  
  570.  
  571.  
  572.  
  573.  
  574.  
  575.