home
***
CD-ROM
|
disk
|
FTP
|
other
***
search
/
Shareware Overload
/
ShartewareOverload.cdr
/
comm
/
comset.zip
/
COMSET.DOC
next >
Wrap
Text File
|
1989-05-07
|
13KB
|
325 lines
___________________________________________
C O M S E T
Modem / Uart Setup Program
Version 5.2..release date 5/7/89
from Hank Volpe Computers (c) 1989
___________________________________________
Introduction
Comset is a utility that is designed to setup a communications port
and a AT (Hayes) Compatible smartmodem. Many modems, especially
internals, do not have a method to reset the modem when it is
activated, nor does an adequate method exist to setup the serial port
for use.
Comset will setup your serial port to any speed from 300 to 19200 bps
and then check to see if your modem is on-line. If it isn't, Comset
will perform a hardware reset to "wake" it up. Next a software reset
is performed by sending the command ATZ. If the reply OK is received,
you are informed that the modem is fine. If OK is not received, Comset
will attempt 3 times to reset the modem before informing you of an
error. If you have an external modem and it is off, Comset will abort
after setting up the serial port to the desired baud rate.
Some of the features of Comset include the following ;
Level 1 options...Shareware Version
** User Selected baud rates from 300 to 19200 bps.
** User Selected Comm port assignments.
** Modem Status register testing.
** Redirectable output..can be sent to a file for logging.
or used over any serial link.
** RTS/CTS DTR/DSR Handshake testing.
Registered Users Have the following advanced features;
** User Selection of Comm ports 1 2 3 4.
** Log in of Comm ports 3 & 4 to DOS for use by other programs
such as high level languages or applications.
** Batch file parameter passing and error reporting.
è
1
Comset....Smart modem utility version 5.2
I. USING COMSET
----------------
The usage syntax for Comset is simple.
COMSET [speed] [port]
or
COMSET h
[speed] and [port] are user options
h invokes runtime help for the user
Comset is easy to use. Typing COMSET from the dos prompt will
automatically attempt to set up serial port COM1 to 2400 bps and
attempt to wake up its modem. Selecting a different speed involves
only adding the speed after the word Comset...ie COMSET 1200 sets
serial port COM1 to 1200 bps instead of the default 2400. Trailing
zeros are not necessary, so you could also type COMSET 12 to set up
serial port COM1 to 1200 bps. If you wish to use a different serial
port, add that after the speed...ie COMSET 24 2 will set serial port
COM2 to 2400 bps. If you accidentally enter an invalid baud rate, the
default of 2400 bps will be used. If you accidentally enter an invalid
range of comm ports, the default of COM1 will be used. Defaults are
always used if the user does not supply speed and port.
Typing COMSET h will bring up a runtime summary of features and other
helpful information.
Ideally, Comset should be run out of your autoexec.bat file when you
first turn on your computer. Internal modem users can appreciate the
fact that probably 2 or 3 times out of a 100 their internal modem does
not "wake-up" properly when the computer is first turned on, and this
can hang-up some communications programs. Also, BBS sysops sometimes
experience problems with modems when stopping the BBS and trying to
use the modem to call out. This is why Comset was written!
II. SERIAL PORT INFORMATION
---------------------------
Comset supports all the industry standard Serial Port address
assignments for modems. The shareware version supports COM1 and COM2,
while the registered version adds COM3 and COM4 support also. Almost
all PC-modems allow you to use COM1-4, however only specific software
can use COM3 or COM4 on most machines.
è
2
Comset....Smart modem utility version 5.2
The full featured version of Comset not only will use COM3 or COM4 for
itself, but it will log those ports into DOS for use by other programs
such as high-level languages and applications (something that under
normal conditions can't be done with an IBM-PC or most clones without
special software).
III ERROR REPORTING INFORMATION
-------------------------------
Comset checks your serial port in three distinct steps;
1) Set the Serial Port computer UART to the desired baud rate
and raise the DTR and RTS lines. If a serial port is not
detected, Comset aborts and displays the message that there
is no serial port with that COMM designation in your system.
2) Check that DSR and CTS are returning from the modem, if not
report an error and stop testing.
3a)If steps 1 & 2 are successful, wake up the modem by sending
the command string "ATZ". If OK is received, report all is
Normal and leave the RTS and DTR lines active.
b)If the modem did not wake up, issue a more advanced hardware
and software command string to reset and wake up the modem.
Three attempts are made..if it fails, the RTS and DTR lines
are turned off. This could happen if you tell Comset to
test a serial port that does not have a compatible modem
attached. In that case, a "failure" of this kind would be
"normal" for your system.
The Shareware version will report status to the screen. You can
redirect the output of Comset to a file if you wish to maintain a log
of each initialization. To do this, just use the command string
COMSET [speed] [port] >> comset.log
Speed and port are optional. The >> symbol tells dos to make a file
called comset.log and append it each time Comset is run.
è
3
Comset....Smart modem utility version 5.2
IV FULL FEATURE USE AND ERROR REPORTING
---------------------------------------
Registered Users of Comset receive some advanced features, some of
which were described above in previous sections. An additional feature
of the registered version is that of error-code reporting. Error code
reporting simply stated passes "result-codes" from Comset to its
calling program. This allows you to write some advanced batch-file
procedures or to take specific actions.
Running the registered copy, additional information is displayed
informing you of the Error code received. Also that error code can be
interpreted by Dos Batch files using the ERRORLEVEL function. Under
Normal conditions, a result code of 0 is returned to the calling
program. If something wrong is detected, an error code of 99 is
returned to the calling program.
A simple use of this can be to start a communications program if the
modem is ok, but if not, default to some other action...an example
batch-file program looks like this;
echo off
comset 24 1
áááááIF ERRORLEVEL 99 goto stop
echo passed
goto exit
áááá:stop
echo failed!
:exit
Other uses are left up to your imagination...you could flash up help
screens to the user like "HEY DUMMY...TURN ON THE MODEM!!!" or
something similar. Combined with redirecting the output to a logging
file, you could trace a history of failures or other actions.
è
4
Comset....Smart modem utility version 5.2
V. REGISTRATION INFORMATION
--------------------------
You can freely make copies and distribute Comset over BBS systems or
public domain libraries as long as no fee for Comset is charged
(except duplication costs) and as long as Comset.exe is distributed
along with this file Comset.doc. These may be archived together for
use on a bbs system.
Comset is copyrighted by Hank Volpe and is not public domain software.
Shareware version users are granted a limited license for its use. No
warranties for Comset are stated or implied.
Shareware authors continually provide computer users with low priced
software compared to the traditional retail approach. If you register
Comset, you will be able to use all the features ( COM 1-4 support,
auto-log in of COM3 and 4 for Dos applications, advanced Error
reporting and batch file support).
Registration is simple...and price is low. Comset is only $10, which
includes the latest version and free version updates. To register,
send $10 along with your name and address to;
Hank Volpe
108 Broadmoor Dr.
Tonawanda NY 14150
VI. ERROR MESSAGES
THERE IS NO COMx IN YOUR SYSTEM -
Comset was instructed by the user to test a non-existent comm port.
This could happen automatically if you don't have a COM1 in
your system. If this is the case, use the line
COMSET [speed] [port] to select your specific needs.
è
5
Comset....Smart modem utility version 5.2
MODEM NOT RESPONDING PROPERLY -
The modem under test did not set up even after 3 extensive hardware
and software attempts to do so. Either you have a non-compatible
or non-intelligent modem, or you are using the wrong opening
baud rate. Comset's defaults are 2400 bps and COM1. If you only
have a 1200 or 300 bps modem, use the line
COMSET [speed] [port] and use a lower speed. Valid speeds are
300 bps, 1200 bps , 2400 bps [default], 4800 bps, 9600 bps
and 19200 bps. Any other values default automatically to 2400 bps.
MODEM APPEARS TO BE OFF OR DISCONNECTED -
The hardware handshaking pairs RTS/CTS or DTR/DSR are not
communicating properly. This should NEVER happen on internal modems
unless the CTS signal is not enabled. Internal Modems usually keep
this signal at a logic 1, so if you see this error, check your
internal modem for proper strapping of the CTS and DSR signals.
If you have an external modem,and the power for the modem is on, you
will see this error message if you do not have the CTS signal at a
logic 1 or you have a defective or inadequate Serial Cable. Most
external modems have Dip-switches on the back for setting the CTS
signal. Normally the CTS follows the Serial Ports RTS and the modem
DSR (sometimes called MR) follows the Serial Ports DTR.
In the case of an external modem you will see this error message
everytime the modem has not been turned on. This is telling you
that your serial port hardware is fine, just that your modem is
off.
VII COMSET PROGRAM HISTORY
--------------------------
Version 1 - Simple Assy program fixed at 300 bps. Two versions
COM1 and COM2.
Version 2 - Baud rate raised to 1200 bps.
Version 3 - Baud rate raised to 2400 bps.
Version 4 - COM1 / COM2 support in one program.
Version 5 - Major rewrite, added interrupt support, hardware
and software testing, COM 1-4 support, Multiple
baud rate support, error checking and reporting,
and support for high speed modems to 19200 bps.
Current released version is 5.2...released May 7, 1989
è
6