Feature request for vgetty

Tony Scholl (A.J.Scholl@durham.ac.uk)
Tue, 13 Oct 1998 14:33:52 +0200


Marc Eberhard wrote:
[...]
>> I have only one line, but would like to get faxes into my home oon
>> my voice line.  It would be nice if vgetty -always- answered the
>> line, even after the phone is picked up.  Most modems cannot detect
>> when another phone has been picked up, but they all know when the
>> line stops ringing.
>> 
>> So, if the phone rings, but doesn't ring enough for vgetty to
>> answer normally, then as soon as it detects the ringing has stopped
>> (say, 5 or 10 seconds after the last ring) have it pick up the line
>> and just listen.  If it hears a CNG tone, then it can go into fax
>> mode right away.  If it doesn't hear a CNG tone, then it can hang
>> up after 10 seconds and reset.
>
>The problem is, that this is at least in Germany not allowed by law.
>The modem mustn't pick up the line without a ring signal coming in
>from the telco line. Only exception is a dialout by the modem itself.

Without doing any patching, how about simply listening to the log
file and sending SIGUSR1 to mgetty/vgetty? Something like

tail -f /var/spool/mgetty/log.ttyS1 | \
  gawk '/phone stopped/ { system("sleep 10; killall -USR1 vgetty") }'

might work, as "phone stopped ringing" is written to the log file
if the log level is not too low.

Actually I have thought for some time about a slightly different
feature - that vgetty would pick up the phone if it hears a
certain DTMF sequence. This is what my traditional fax machine
does - if I answer a call and hear the fax tone, I can key in the
code and the machine picks up the line, instead of having to run
downstairs... can vgetty detect DTMF at that stage of things?

Tony

------------------------------------------
Tony Scholl <a.j.scholl@durham.ac.uk>
WWW: http://fourier.dur.ac.uk:8000/~dma0ajs