Re: Script to check whether modem telephone line in use --- how?
Isn't this what the line:
ABORT "NO CARRIER"
should do in the chat script?
On Thu, Apr 01, 1999 at 10:43:45AM +0930, Mark Phillips wrote:
>
> This morning I typed "pon" to dial up a ppp connection, only to hear
> noise on my modem to idicate that the line was already in use. I
> quickly typed "poff", but it was too late --- I had already killed my
> father's connection to the internet. He was not pleased as I had
> killed his connection near the end of an 8M download.
>
> Anyway, I don't want this to happen again, so I would like, if
> possible, to write a script which does nothing except listen to the
> modem line for a few seconds so that I can hear whether someone else
> is using it. I have some idea about how such a script would go, but
> would appreciate some input. Here is what I propose:
>
> #!/bin/bash
>
> echo atm2 > /dev/ttyS1
> echo ato0 > /dev/ttyS1
> pause 2
> echo +++ > /dev/ttyS1
> pause 2
> echo atm1 > /dev/ttyS1
>
>
> I'd appreciate any comments about whether this is the best way to go
> about this problem.
>
> Thanks,
>
> Mark.
>
>
>
> _/~~~~~~~~\___/~~~~~~\____________________________________________________
> ____/~~\_____/~~\__/~~\__________________________Mark_Phillips____________
> ____/~~\_____/~~\________________________________mark@ist.flinders.edu.au_
> ____/~~\HE___/~~\__/~~\APTAIN_____________________________________________
> ____/~~\______/~~~~~~\____________________________________________________
> __________________________________________________________________________
> "They told me I was gullible ... and I believed them!"
>
>
>
>
> --
> Unsubscribe? mail -s unsubscribe debian-user-request@lists.debian.org < /dev/null
>
>
--
Jim Foltz <aa204@acorn.net> <jfoltz@raex.com>
ACORN techie <http://www.acorn.net>
AOL/IM Jim Foltz
Reply to: