AnDan Software Fossil Version 1.10 Users Manual Scandinavian Digital Systems AnDan Software Fossil Version 1.10 Users Manual ÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄ Table of contents 1 Overview ............................................... 3 1.1 Features of ADF ................................... 3 2 Shareware .............................................. 3 2.1 Use as shareware .................................. 3 2.2 How to register ................................... 4 3 Support and new versions ............................... 5 4 Included files ......................................... 5 5 Installation ........................................... 5 6 Command line arguments ................................. 5 7 Execution examples ..................................... 6 8 Baud rate calculation .................................. 7 9 Receiver FIFO trigger level ............................ 8 10 The Comcheck program ................................... 9 11 Version history ........................................ 9 Copyright (c) 1994-1995 Scandinavian Digital Systems AB This product, including the manual and the software, is provided as is. Scandinavian Digital Systems AB and Anders Danielsson disclaims all warranties of any kind, whether expressed or implied, and are not liable to you or anyone else for any damages or costs due to the use or inability to use this product. Acknowledgments: AnDan Software is a trademark of Scandinavian Digital Systems AB. FidoNet is a trademark of Tom Jennings. Windows is a trademark of Microsoft Corporation. TurboCom is a trademark of Bio-Engineering Research Laboratories. X00.SYS is a program made by Raymond L. Gwinn. ÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄ Scandinavian Digital Systems Page 2 AnDan Software Fossil Version 1.10 Users Manual ÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄ 1 Overview ADF is a FOSSIL version 5 driver, with some of the additional functions defined by Raymond L. Gwinn in X00.SYS v1.50. The author of ADF did experience some problems with other FOSSIL drivers, at least when running in an MS Windows v3.1 environment using TurboCom and 16550. Because of this, ADF was written. ADF is specially designed for users of high speed modems with or without the 16550 UART, running in a multitasking environment. Some communication parameters can not be set in ADF, they are hard coded for best optimization. These hard coded parameters will work fine for almost all users of high speed modems (users using a locked baud-rate). By doing this hard coding and by writing the complete ADF program in the assembly language, the FOSSIL driver will be faster and smaller. 1.1 Features of ADF * Always a locked baud-rate. * Locked baud-rate of any speed (2 bps - 115200 bps). * Always 8 databits, no parity, and 1 stopbit (8N1). * Always CTS/RTS handshake. Never DSR/DTR or XON/XOFF handhake. * One port per ADF (load ADF in different tasks for many ports). * COM-port address configurable (0H-FFFFH). * COM-port IRQ configurable (0-15). * Supports the 16550 UART. * Fills transmit 16550-FIFO buffer with 16 bytes. * Receiver 16550-FIFO configurable (1, 4, 8 or 14 bytes). * FOSSIL function 7EH and 7FH for "external application" not supported. 2 Shareware The files in this package may be copied and distributed if no fee is charged, if no changes are done and as no part of other products, in purpose to test and evaluate this product for a period of 30 days. 2.1 Use as shareware To use ADF.EXE as shareware, you must first execute the supplied REGISTER.EXE and register ADF.EXE as shareware to be able to use it for a test period of 30 days. Run REGISTER.EXE, specify ADF.EXE as file to register and do not enter any user name. ADF.EXE may then be used as shareware. ÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄ Scandinavian Digital Systems Page 3 AnDan Software Fossil Version 1.10 Users Manual ÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄ When ADF.EXE is executed it will display the number of days left of the test period. After 30 days, ADF.EXE will stop executing! 2.2 How to register To register the program and use it for more than 30 days, you must pay 60 SEK, DM 10 or an amount equal to the sum of USD 10 in a currency of your own choice. You can either send cash to: Scandinavian Digital Systems AB Billerudsgatan 20 S-661 30 Saffle Sweden or you can deposit the amount to the Swedish postal giro account 970159-0. After depositing the fee, send an electronic mail through FidoNet to Reg at 2:203/620 or through Internet to reg@andan.edv.se. The mail should contain the following lines: Prod=ADF User= You will recieve an automatic reply to the address you mailed your registration. The reply will contain the following information: Prod=ADF File=ADF.EXE User= Code= When you have received the reply, run REGISTER.EXE and enter the required information. When you specify your user registration name after the "User=", you should use your name together with some kind of address or location information. Examples: User=Anders Danielsson, AnDan BBS, 2:203/620 User=Charles Smith, cs@someplace.com User=Hans Schultz, Dernauer Str., Hamburg, Germany You may also phone AnDan BBS at +46-533-13700 and register on-line. The on-line registration is similar to the mail registration. ÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄ Scandinavian Digital Systems Page 4 AnDan Software Fossil Version 1.10 Users Manual ÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄ E-mail registration replys through FidoNet are routed. If you don't want routed mail, use the on-line registration. 3 Support and new versions If you have questions, comments or find bugs in the program, please send electronic mail to the author, Anders Danielsson at FidoNet 2:203/620 or ad@andan.edv.se. You may also phone AnDan BBS at +46-533-13700, where the newest versions and other shareware programs from AnDan Software always are downloadable for all users. 4 Included files You should have received the following files: File name: Description: ADF.TXT This file ADF.EXE The FOSSIL driver COMCHECK.EXE Checks COM-ports REGISTER.EXE Registration program 5 Installation Just copy ADF.EXE to a directory included in your PATH. If you are only running DOS, edit your AUTOEXEC.BAT and insert a line that loads ADF. If you are using a multitasking environment, sush as Windows, load one copy of ADF in each wanted DOS session. 6 Command line arguments When you run ADF without any arguments, it will display the following help text (use ADF|MORE for more prompt): adf port addr irq baud recbuf trabuf trig [/d] port Fossil port number (0-127). Example: 0 addr Address in hex of COM-port. Example: 3F8 irq IRQ number of COM-port. Example: 4 baud Locked baud-rate. Example: 38400 recbuf Size of receive buffer. Example: 1024 trabuf Size of transmit buffer. Example: 256 trig Receiver FIFO trigger level, 1, 4, 8 or 14. Example: 8 /d Optional debug mode, loads debug code into memory. ÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄ Scandinavian Digital Systems Page 5 AnDan Software Fossil Version 1.10 Users Manual ÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄ ADF will stay resident when using the above command line. adf unload ADF will remove itself from memory when using the above command line. adf watch on|off ADF will turn carrier watchdog on or off when using the above command line. adf debug none|screen|file If ADF is loaded in debug mode (/d), this command specify where to output debug information, none = no output, screen = screen, file = C:\ADF.DEB. 7 Execution examples Example of loading ADF using COM1: adf 0 3F8 4 38400 1024 256 8 Example of loading ADF using COM2: adf 1 2F8 3 38400 1024 256 8 Example of unloading ADF: adf unload Example of REMOTE.BAT, to execute on DOS-Shell in a BBS: @echo off rem %1 = Baud rate (used to detect local call) rem %2 = Port number (1 or 2) if %2@==1@ goto port if %2@==2@ goto port goto end :port if not %1@==0@ ctty COM%2 if not %1@==0@ adf watch on command adf watch off ctty CON :end exit ÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄ Scandinavian Digital Systems Page 6 AnDan Software Fossil Version 1.10 Users Manual ÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄ The carrier watchdog will try to reboot the computer after about 10 seconds from the carrier drops. This may be dangerous, especially in a multitasking environment (such as Windows). Example of debugging: adf 0 3F8 4 38400 1024 256 8 /d adf debug file The above commands will put debug information of all FOSSIL calls into the file C:\ADF.DEB. This should be used with care, the file C:\ADF.DEB may get very large, and ADF will work very slow. 8 Baud rate calculation A PC compatible serial port uses the following formula to calculate the baud rate: Baud = 115200 / Divisor The Divisor is an integer number, 1 to 65535, used to program the serial port (the UART chip). When you specify a baud rate on the command line to ADF, ADF calculates the reverse to get the Divisor: Divisor = 115200 / Baud The division is rounded down to the nearest integer. Even if ADF will accept any baud rate on the command line, this calculation will only allow certain baud rates, due to the Divisor is an integer: Divisor: Baud rate: 1 115200 bps 2 57600 bps 3 38400 bps 4 28800 bps 5 23040 bps 6 19200 bps 7 16457 bps 8 14400 bps 9 12800 bps 10 11520 bps 11 10473 bps 12 9600 bps . . . . . . ÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄ Scandinavian Digital Systems Page 7 AnDan Software Fossil Version 1.10 Users Manual ÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄ If you for example use 76800 bps as a baud rate to ADF, a Divisor of INT(115200/76800) = 1 will be calculated, and the baud rate is set to 115200 bps. 9 Receiver FIFO trigger level The last argument to ADF when loading it, is the receiver FIFO trigger level. This used by the 16550 UART, if you don't have a 16550 or compatible, it will have no effect, but must still be specified on the command line. The receiver FIFO trigger level can be set to 1, 4, 8 or 14. The value is the number of bytes in the receiver FIFO buffer that will generate an interrupt from the UART to the CPU. The receiver FIFO buffer and it's trigger level, is the main reason why many people replaces their old 8250 and 16450 UARTs with 16550. If you for example use a baud rate of 38400 bps, there will be a new byte received each 260 us (microseconds). With an ordinary UART, the CPU must answer to an interrupt from the UART each 260 us, and read the byte and store it in memory. If the CPU is unable to answer an interrupt at this rate, or if some program has disable interrupts longer than 260 us, received bytes will be lost. If you are downloading a file, you will get a lot of resends. The 16550 UART has a 16 byte receiver FIFO buffer (and also a 16 byte transmitter FIFO) so it can store up to 16 bytes until the CPU must read and empty the buffer. The receiver FIFO trigger level specifies when an interrupt should be generated by the UART to the CPU. If the trigger level is set to 4, the UART will generate an interrupt after 4 bytes have been received, but will still fill the buffer up to 16 bytes if the CPU doesn't answer the interrupt. The rate of interrupts at 38400 bps will be 4*260 = 1040 us, and the tolerance to no answer from the CPU will be (16- 4)*260 = 3120 us. The most common problem with high baud rates, is that programs turns of interrupts during too long time. A trigger level of 14 would in most cases not be a good solution, normally a trigger level of 8 is good enough, in some cases you may lower it to 4. You should not choose a lower trigger level then necessary, because it would load the CPU without giving any benefits. ÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄ Scandinavian Digital Systems Page 8 AnDan Software Fossil Version 1.10 Users Manual ÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄ 10 The Comcheck program When you run Comcheck without any arguments, it will display the following help text: comcheck addr addr Address in hex of COM-port. Example: 3F8 Comcheck checks if there is an UART at the specified port address. The most common port addresses are: COM1 3F8 COM2 2F8 COM3 3E8 COM4 2E8 If the UART is a 16550, Comcheck will enable the FIFO and change the trigger level. 11 Version history v1.10 November 22, 1995 This is the first non-BETA version. The setting of the receiver FIFO trigger level on the command line has been added since the v1.00 BETAs. ÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄ Scandinavian Digital Systems Page 9