I'm having trouble enabling >9600 baud on my modem for dial-in. Based on
feedback from a previous post, and other research, I'd like to send the
AT&B1 command to my modem.
However, in my previous post I asked how to send AT commands to the serial
port. Two suggestions came in. Both failed for my setup:
=>1: Simply use the echo command, redirecting output to /dev/ttyS1 (my modem
is on COM2). Unfortunately, the command hangs and I have to Ctrl-C to get
out of it:
echo "AT&B1" > /dev/ttyS1
When I do this, nothing happens. I let it run for at least 60 seconds, then
hit Ctrl-C. The following appears, but only after I pressed Ctrl-C:
bash: /dev/ttyS1: Interrupted system call
I also tried - and it also hung - the command:
echo "ATS0=1" > /dev/ttyS1
I thought echo might be* because getty already has the port in use.
So I removed ttyS1 from /etc/inittab, ran 'kill -1 1' and confirmed that the
getty process that ran for ttyS1 was no longer running - it wasn't.
Nevertheless, echo still hangs.
=>2. Second suggestion was to use minicom. Unfortunately, I'm working on a
stripped-down red hat 6.1 system, and RPM isn't included. Argh.
In reading about getty, I find there are many variants (eg, mgetty,
uugetty, getty_em, and agetty). My stripped down system only has
/sbin/getty, /sbin/mingetty and /sbin/uugetty. I'm calling /sbin/getty in
/etc/inittab. Should I use uugetty instead?
I tried uugetty in inittab, as follows:
S1:1345:respawn:/sbin/uugetty ttyS1 F9600
S1:1345:respawn:/sbin/uugetty ttyS1 F115200
but now after the modems connect, they IMMEDIATELY drop the line. In
Hyperterminal on the calling system I see only the CONNECT message, then the
line drops immidiately. At that moment, I see this syslog message:
uugetty: exiting on HANGUP signal
This is worse that when I used plain /sbin/getty .. at least it stayed
connected, albeit all data in and out are garbled due to the apparent baud