Thread View: comp.os.linux.setup
2 messages
2 total messages
Started by Glenn Powell
Mon, 30 Sep 1996 00:00
ppp and chat permanent connection
Author: Glenn Powell
Date: Mon, 30 Sep 1996 00:00
Date: Mon, 30 Sep 1996 00:00
29 lines
1781 bytes
1781 bytes
Can someone help me with this script that I am writing to keep my modem connected to my ISP. Please note that 200.200.200.200 is the number that my ISP gives me apon connection. Here it is ( sleep 20 ; while : ; do /usr/sbin/pppd connect ' /usr/sbin/chat -f ./login.txt ' -detatch lcp-echo-interval 30 lcp-echo-failure 4 :200.200.200.200 /dev/cua0 38400 ; sleep 30 ; done ) & my chat script login.txt is as follows " " +++ " " ATH0 " ATZ OK ATDT 1234567 ogin: username word: pword " I am runnig Linux 2.0.18 with a 486-DX4-120 with 32mb ram with the slip and ppp modules compiled into the kernel. I usually use DIP to connect but it is not too good at reconnecting the modem. When this script is run the modem ON HOOK light flashes temporarly and the script keeps running without actually doing anything. If anyone can help me with this could a it be mailed to me at ma.eng@mailbox.uq.oz.au Thankyou in advance Glenn Powell
Re: ppp and chat permanent connection
Author: Al Longyear
Date: Wed, 02 Oct 1996 00:00
Date: Wed, 02 Oct 1996 00:00
55 lines
2506 bytes
2506 bytes
Glenn Powell <ma.eng@mailbox.uq.oz.au> writes:
>Can someone help me with this script that I am writing to keep my modem
>connected to my ISP.
>Please note that 200.200.200.200 is the number that my ISP gives me apon
>connection.
>Here it is
>( sleep 20 ; while : ; do /usr/sbin/pppd connect ' /usr/sbin/chat -f
>./login.txt ' -detatch lcp-echo-interval 30 lcp-echo-failure 4
>:200.200.200.200 /dev/cua0 38400 ; sleep 30 ; done ) &
^^^^
You have this reversed. It should read as follows: 200.200.200.200:
(The colon _follows_ your IP address and preceeds the IP address of the ISP)
>my chat script login.txt is as follows
>" " +++ " " ATH0 " ATZ OK ATDT 1234567 ogin: username word: pword "
NO. That won't work. Use:
TIMEOUT 4 "" AT OK-+++\c-OK ATH0 TIMEOUT 60
OK ATZ OK AT&C1&D2DT1234567 CONNECT \c ogin: username word: pword
1. Do not put spaces where you don't expect to receive spaces. They
are not there for just being pretty formatting.
2. The attention sequence does not work if the modem is already at
the command level. Just sending "AT" should return OK in this case.
3. You need the \c after the plus characters to prevent the additional
CR character which would invalidate the attention sequence.
4. Don't trust that "Z" will set the modem flow control options. Always
set them yourself and you will have fewer problems.
5. D is the command to dial, 'T' is to switch to tone dialing. If you
put a space after the 'T' then this becomes a reply string and that is
not what you want.
And finally, Add the options:
modem
defaultroute
crtscts
asyncmap 0
to the above list of options on pppd.
--
Al Longyear longyear@netcom.com
Thread Navigation
This is a paginated view of messages in the thread with full content displayed inline.
Messages are displayed in chronological order, with the original post highlighted in green.
Use pagination controls to navigate through all messages in large threads.
Back to All Threads