vgetty / vm shell programming Q
Al Borchers (alborchers@steinerpoint.com)
Fri, 09 Apr 1999 09:06:53 -0500
Bjoern --
To control when DIAL returns READY some modems support the AT+VRA and
AT+VRN commands. These commands are not in vgetty now, but I sent a
patch to Marc Schaefer that adds support for these for the US Robotics
and ZyXEL 1496 modems. What modem are you using? I can send you the
patch if you want.
The US Robotics and ZyXEL modems try to detect when the phone was
answered by waiting for the ringback to stop. The VRA and VRN commands
set the timeout--if no ringback is heard in this time the modem assumes
the phone has been answered. This does not work very well; there is
always a delay of several seconds before the modem realizes there has
been no ringback. What I did was set these timeouts to 0 so the DIAL
returns immediately; then I played a short looping message "Hi, this is
X, press a key to continue" and waited for a keypress that told me
someone had answered (kludgy).
There are some race conditions when sending a STOP command. It is quite
possible to send a STOP after the action (PLAY, WAIT, ...) has stopped
but before you got the READY, and then you will get two READYs--one from
the action (PLAY, WAIT, ...) and one more from the STOP. Normally if
you
send a STOP while the action is in progress you only get one READY back.
I added a flush command to my top level script and called this after
stopping an action to flush the possible extra READY (set an alarm, read
and discard input until the alarm comes in). Not sure this is your
problem with getting an extra READY, though.
-- Al