🚀 go-pugleaf

RetroBBS NetNews Server

Inspired by RockSolid Light RIP Retro Guy

Article View: comp.sys.ibm.pc.rt
Article #1907

How to set up a dial-in hayes modem for an IBM/4.3 system

#1907
From: Charlie Slater
Date: Tue, 13 Feb 1990 22:22
105 lines
5109 bytes
This posting describes how I set up ibmsupt's Hayes 2400 modems which
receive incoming calls from IBM/4.3 customers.   For outgoing calls,
the default settings are fine, so if your only modem application is to
call ibmsupt to download new compilers, you don't need to read this
posting.


Objective: Prevent unwanted chatter between the RT and the Modem

How logins work:  A program called "getty" prints out a banner (usually
the name of the machine and the version of the operating system) and
then prompts for a username with "login: ".  The username is passed to
/bin/login which prompts for a password.  If the port is marked "on" in
/etc/ttys, then getty will open and prompt for a username whenever the
port is free.

One does not want the modem to echo "login: " back to getty and
"password: " back to login.  You don't want it to say "OK" or "NO
CARRIER" either, indeed even "0" and "1" could be mistaken for
usernames and passwords.  Therefore, people configuring a modem to
accept incoming calls include the "E0Q1" in their Hayes commands.
"E0" means disable echo and "Q1" means suppress result codes.

The following is sufficient to configure many modems to accept
incomming calls:

AT&F&C1&D2S0=1E0Q1&W

&F means start with factory defaults and &W means write to NVM.
S0=1 means answer after one ring.

The new settings which have some data communications implications are
&C1 and &D2.  They mean do the "right" thing with Data Carrier Detect
(DCD) and Data Terminal Ready (DTR), respectively.  The "right" thing
for the modem to do when carrier is lost is to lower DCD.  This tells
the computer that the line is no longer in use and the driver sends a
HUP signal to the process attached to that port.  The "right" thing for
the modem to do with DTR is to insist that it be there.  If DTR is not
asserted by the computer, the modem will not answer the phone.  If the
computer lowers DTR, the modem will disconnect the phone.   The diagram
below illustrates the concepts presented so far.

 ________________
|getty  login sh |
|	         |	      _____
|      kernel    |-----------|modem|
|         DTR    |->       <-|DCD  |
 ----------------             -----

For most modems, this is enough.  For example, to configure the Telebit
Trailblazer modems attached to ibmsupt, I locked the baud rate at
19.2Kbps, turned off flow control and reversed the tone search sequence
so that PEP was last with this command:

AT&F&S51=5S58=0S66=1S92=1

I then did the Telebit equivalent of the previously mentions Hayes
command:

ATS53=2S52=1S0=1E0Q1&W

and I could dial this Telebit with a Hayes modem or another Telebit and
things worked fine.

Setting up the Hayes to accept incomming calls was not quite this
simple.  Even with echo and result codes disabled, the modem would
chatter with the computer between the time the phone rang and the time
the connection was established.  This chatter caused the modem to
connect at 1200 bps instead of 2400 bps.  I did not know why this was
happening, but I did know how to prevent it.

In the config file entry for each asy controller there is a "flags"
field.  If flags is 0xFF, the variable asysoftCAR is set for each port
on the controller and the driver will return from open right away.
This is the default as shipped.  If the flags is 0x00, the then
asysoftCAR is not set and the driver will not return from open until
carrier is present.

For the controller that serves inbound modems, I changed asysoftCAR
from 0xFF to 0x00.  This solved the dial-in problem.  (For those who
are short of controllers or slots and need to do this by port:  The
lower four bits are used.  0x01 <==> bit 0 <==> port 0.  In practice
the results of 0x0F are equivalent to 0xFF.)

The downside of clearing asysoftCAR is that when you want to talk to
the modem when carrier is not present (e.g. you want to configure the
modem or dial out), you cannot because the open call will not return.

Acucntrl attempts to set or clear asysoftCAR as appropriate.  I have
not always had success with acucntrl, so when I need to talk to the
modem, I turn getty off in /etc/ttys and turn asysoftCAR on with adb.

IBM/4.3 includes online documentation for adb, asy, getty, login, and tty.

Disclaimer: This posting does not imply an endorsement of either Hayes
or Telebit modems.  Other manufacturer's modems may work as well or
better or worse in this application.  I speak for myself not IBM and
any errors in this posting are my responsibility.

-- 
charlie slater
uunet!ibmsupt!cslater		(UUCP)
cslater%ibmsupt@uunet.uu.net	(Internet)
cslater@ibmpa.tcspa.ibm.com	(IBM internal internet)
Technical Details
Message-ID: <4017@ibmpa.UUCP>
Path: arc1-ca.pugleaf.net!utzoo!utgpu!jarvis.csri.toronto.edu!mailrus!umich!samsung!cs.utexas.edu!uunet!ibmpa!cslater

Show Full Headers
Complete Article Headers
Path: arc1-ca.pugleaf.net!utzoo!utgpu!jarvis.csri.toronto.edu!mailrus!umich!samsung!cs.utexas.edu!uunet!ibmpa!cslater
From: cslater@ibmpa.UUCP (Charlie Slater)
Newsgroups: comp.sys.ibm.pc.rt
Subject: How to set up a dial-in hayes modem for an IBM/4.3 system
Keywords: IBM/4.3 asy adb modem
Message-ID: <4017@ibmpa.UUCP>
Date: 13 Feb 90 22:22:44 GMT
Organization: IBM AWD Development, Palo Alto
Lines: 105