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