home *** CD-ROM | disk | FTP | other *** search
/ Programmer 7500 / MAX_PROGRAMMERS.iso / PROGRAMS / UTILS / MODEMS / NOISECHK.ZIP / NOISE.DOC < prev    next >
Encoding:
Text File  |  1989-01-29  |  8.3 KB  |  193 lines

  1.  
  2.  
  3.  
  4.  
  5.                              Serial Communications
  6.                                Diagnostic Program
  7.                                    NOISE.COM
  8.                               Created 11-DEC-1988
  9.                                Richard B. Johnson
  10.                         PROGRAM EXCHANGE (303) 440-0786
  11.  
  12.           General.
  13.           This program is meant to be executed as a "live program"
  14.           from a BBS system and as an "external protocol" from a
  15.           remote-user's communications program. It will display in-
  16.           formation concerning the quality of the transmission channel
  17.           existing between the remote user and the BBS system. It may
  18.           be helpful in obtaining better quality service from the
  19.           telephone company.
  20.  
  21.           Now to install this program.
  22.           If you are a BBS system operator, you create a batch file
  23.           containing the following information:
  24.  
  25.           REM * Noise Program Batch file *
  26.           D:\PATH\NOISE/PORT=2/MODE=MIRROR/SPEED=19200
  27.           |     |     |      |           |     |__ optional
  28.           |     |     |      |           |________ Execute mirror mode
  29.           |     |     |      |____________________ COM port (1-4)
  30.           |     |     |___________________________ Program name
  31.           |     |_________________________________ Path to program
  32.           |_______________________________________ Drive name
  33.  
  34.           You then define this as a "live program" (DOOR) in your BBS
  35.           system software configuration.
  36.  
  37.           If you are a remote-user, using a communications program
  38.           like TELIX or PCPLUS, you create a batch file containing the
  39.           following information:
  40.  
  41.           REM * Noise Program Batch file *
  42.           D:\PATH\NOISE/PORT=2/SPEED=19200
  43.           |     |     |      |     |
  44.           |     |     |      |     |__________ Optional
  45.           |     |     |      |________________ COM port (1-4)
  46.           |     |     |_______________________ Program name
  47.           |     |_____________________________ Path to program
  48.           |___________________________________ Drive name
  49.  
  50.           You then define this batch file as an "external protocol"
  51.           DOWNLOAD utility. In TELIX, you use ALT-O to get to the cor-
  52.           rect menu. You can use "NOISE" as the protocol name. Tell
  53.           TELIX that you do NOT wish to be prompted for a file name.
  54.  
  55.           How to use this program.
  56.  
  57.  
  58.  
  59.  
  60.  
  61.  
  62.  
  63.                                      - 1 -
  64.           
  65.  
  66.  
  67.  
  68.           Find a BBS system that has this line-noise live program
  69.           "door" installed. Execute the live program from your com-
  70.           munications program just as though you were going to execute
  71.           any other live-program. When the BBS system advises that you
  72.           execute your local NOISE.COM program, just hit the "down-
  73.           load" key (PgDn for TELIX) and select "NOISE". The program
  74.           should begin execution and keep a running tabulation of the
  75.           amount of data sent and received, the number of bad bytes
  76.           and the percentage error-rate.
  77.  
  78.           When you wish to exit the program, just hit control-break,
  79.           escape, or control-C. Control-break and escape are "cleaner"
  80.           because they don't mess up your screen with a "^C" echo and
  81.           cause the screen to be overwritten.
  82.  
  83.           You can also execute this program from the DOS command line.
  84.           If you were executing a communications program, you could
  85.           "shell" to DOS and execute the same command-line that you
  86.           used within the batch file. If your program exists within
  87.           the current path, you need not type the path and drive on
  88.           the command line. If the communications adapter port in use
  89.           in COM1, you need not enter anything on the command line. In
  90.           this case, "NOISE", entered at the DOS prompt or from the
  91.           batch file, is sufficient. In most cases, you will never
  92.           have to set the baud-rate with the "SPEED" command. When the
  93.           "SPEED" command is not found, NOISE just leaves the baud-
  94.           rate alone. It remains set to whatever it was when the com-
  95.           munications program was executing, which certainly should be
  96.           the correct baud-rate.
  97.  
  98.           Other usage:
  99.           NOISE has two modes of operation. The default mode is to
  100.           send a string of bytes to a remote location and record any
  101.           errors in the string being echoed back. The other mode, the
  102.           "mirror" mode, simply echoes any characters received. It
  103.           functions as though you put a connection between pins 2 and
  104.           3 of a RS-232C connector to immediately echo any bytes re-
  105.           ceived on the RX line back to the TX line. The only differ-
  106.           ence between NOISE in the "mirror" mode and a piece of wire
  107.           is that if NOISE receives a ^C, it aborts. You can see from
  108.           this that NOISE can be very useful in debugging local RS-
  109.           232C connections as well as monitoring line-noise.
  110.  
  111.           NOISE.ARC contains the complete source-code and documenta-
  112.           tion. The source code shows how to operate the UARTs used in
  113.           IBM-compatible computers in interrupt-mode. Interrupt-mode
  114.           operation is necessary if you intend to use these UARTs at
  115.           speeds much in excess of 2400 baud for communications. In
  116.           particular, the code shows how to:
  117.  
  118.           (1)   Set up the required interrupt vectors.
  119.           (2)   Set up the UART
  120.  
  121.  
  122.  
  123.  
  124.  
  125.  
  126.  
  127.                                      - 2 -
  128.           
  129.  
  130.  
  131.  
  132.           (3)   Set up the interrupt controller.
  133.           (4)   Operate both transmit and receive in interrupt-mode.
  134.           (5)   Trap ^C and control-break so vectors may be restored.
  135.           (6)   Restore interrupt vectors before program exit.
  136.           (7)   Restore interrupt-controller mask program before exit.
  137.           (8)   Restore saved UART parameters before program exit.
  138.  
  139.           Restoring the machine-state before the program exits is very
  140.           important. The major failing of many, otherwise excellent,
  141.           home-made communications programs has been that the program
  142.           may exit without restoring the machine state. The next time
  143.           a program is executed, the system will crash if the machine
  144.           state has not been correctly restored.
  145.  
  146.           If you use these routines for a tutorial, remember that it
  147.           is seldom necessary to operate the UART in interrupt-mode
  148.           for transmit, only for receive. Operation of the UART in
  149.           interrupt-mode during transmit will accomplish nothing use-
  150.           ful in a communications program since the program must wait
  151.           until the host receives the characters, processes them, and
  152.           sends back a response, before the interactive user sends
  153.           more characters. Operation in interrupt-mode for receive is
  154.           important so that no incoming characters are ever lost even
  155.           if the user is typing at the keyboard, reading from a file,
  156.           etc.
  157.  
  158.           How the program works.
  159.           The program sends a string of all the ANSI characters (with
  160.           ^C missing) to the remote computer. The remote computer
  161.           simply echoes these characters back.
  162.  
  163.           The program then compares the characters sent with those
  164.           received. If they are the same, the block-number and byte-
  165.           count is updated on the screen and the cycle continues. If a
  166.           byte is missing or garbled, the program records this fact,
  167.           calculates a running error-rate, and then continues. The
  168.           process continues until aborted by the user or until the
  169.           modem carrier fails.
  170.  
  171.           If the user aborts, a string of ^C characters are sent to
  172.           the remote computer to cause the remote program to abort
  173.           also. In case of an abort for any reason, the machine-state
  174.           is restored before the program terminates.
  175.  
  176.           Warranty.
  177.           This program is supplied "as-is" with no warranty whatso-
  178.           ever. The complete source-code is provided so the users may
  179.           determine for themselves if the program may serve a useful
  180.           purpose.
  181.  
  182.           - finis -
  183.  
  184.  
  185.  
  186.  
  187.  
  188.  
  189.  
  190.  
  191.                                      - 3 -
  192.           
  193.