Relay-Version: version B 2.10 5/3/83; site utzoo.UUCP Path: utzoo!mnetor!uunet!husc6!mit-eddie!ll-xn!ames!ptsfa!hoptoad!dasys1!eravin From: eravin@dasys1.UUCP (Ed Ravin) Newsgroups: comp.sys.att,comp.unix.questions Subject: Re: UUCP dialout, uugetty fighting... Message-ID: <1187@dasys1.UUCP> Date: Thu, 3-Sep-87 11:15:27 EDT Article-I.D.: dasys1.1187 Posted: Thu Sep 3 11:15:27 1987 Date-Received: Sat, 5-Sep-87 17:49:32 EDT References: <2896@psuvax1.psu.edu> <1463@chinet.UUCP> <18171@amdcad.AMD.COM> Reply-To: eravin@dasys1.UUCP (Ed Ravin) Organization: Ministry of Information Retrieval, DZ-103 Lines: 80 Summary: set hayes clone to dumb for dialin, smart for dialout Xref: mnetor comp.sys.att:1140 comp.unix.questions:3880 I see people are trying to set up 2400 baud modems with uugetty and the like. Here's a quick summary of my experiences with a few Unix systems and a few modems: First things first: when you get your Hayes-clone modem from the factory, it is configured so a PC user will be able to use it with the least amount of pain. This means that the modem is set to echo input when in command mode (so the PC user can see what they're typing), to give you messages like OK or RING when the phone rings (so the PC user will know what is happening), and to ignore DTR as an enable command (in case the PC cable isn't wired properly). All three of these features MUST BE DISABLED if a Hayes modem is to work properly as a DIAL-IN modem. On the original Hayes SmartModem 1200, you must adjust the DIP switches behind the front panel. On the 2400 baud modems, you must turn off these parameters via commands over the serial port and then send the command to "burn in" the configuration settings (save them in the non-volatile RAM of the modem so that they will be the default power-up parameters). (Why must these features be disabled? You'll get the "getty-war" if you leave local echo on, as the modem echoes the getty message and the getty tries to log itself in. The "RING" message when the phone rings will also fool getty and this will interfere with the login procedure. Telling the modem to be enabled/disabled by DTR is optional, but hangup commands (stty 0) won't work without it, and the connection is much less reliable if the computer is unable to hang up and reset it.) The above covers setting up a modem for INCOMING CALLS only. If you want to set up a Hayes-beastie for OUTGOING CALLS ONLY, this is also possible. The only thing you really have to do is to turn off auto-answer in the modem. This is done by the DIP switch on the original Hayes 1200 modems, or by ATA0 and the burn-in command on the smarter, faster modems. Now you can set up your "chat script" or "acucap" or "modemcap" or whatever dial-out language your system uses. You might want to disable the "+++" feature that lets the modem be commanded out of on-line mode and into command mode, to prevent accidents. Other than that, there should be no problems. You should leave the status messages like "OK" and "NO CARRIER" and (especially) "CONNECT" ENABLED so that your chat script can tell if the modem is alive and if the phone call succeeded. If you've been patient enough to read this far, then you're probably also patient enough to be able to set up a Hayes-critter for INCOMING AND OUTGOING calls. First problem: support for bidirectional modems in many Unix systems is non-existent. You must either have a version of "uugetty" that understands the lock files used by UUCP and can create them when a person logs in on the modem, or a version of "uucp" and "cu" that is smart enough to disable the getty on a port that it wishes to dial out on. The Unix PC uses the latter method, and the 3b2/3b5 Unix comes with the former. For a Hayes-thingie modem, use the "uugetty -r -t 60" options. The "-r" tells uugetty not to consider the port open until a character is received. This is because a port is usually considered open when DCD is sensed. But for an outgoing modem, you must configure the modem so that DCD is always on, otherwise you wouldn't be able to connect to it to tell it to dial. So uugetty with the "-r" option will wait until someone types something (and it can't be the modem typing in the word "RING"!) before it will create the lock file, effectively locking out uucp or cu from using the port. Second problem: we can't dial out effectively if the status messages like "CONNECT" are turned off. We had to turn them off so that we wouldn't get fouled up by the "RING" message when the modem was used for incoming calls, but now we need them back. My solution was to use the "DTR reset causes modem to switch to power-up default" option of my Hayes 2400 clone. I programmed the modem to be an INCOMING modem, with status messages turned off. Then I created a chat script that would turn the status messages back on before the phone number was dialed when an outgoing call was made. If the call connected, the dialer would receive the "CONNECT" message from the modem. When the call was hung up, the modem would reset to its power-up defaults, which would turn the status messages back off again. --