home
***
CD-ROM
|
disk
|
FTP
|
other
***
search
/
DP Tool Club 31
/
CDASC_31_1996_juillet_aout.iso
/
internet
/
4asrv280.zip
/
LOGIN.CMD
< prev
next >
Wrap
OS/2 REXX Batch file
|
1995-08-25
|
952b
|
58 lines
#
# Foray PPP Server example dialing script.
#
#trace on
#
# set up some strings for dialling up
#
if ![load $number]
if [query $number "Enter your dial up phone number"]
save $number
end
end
$modemsetup = "&c1&k3"
%attempts = 10
#
#
#----------------------------------------------------------
#
# initialize modem
#
output "atz"\13
if ! [input 10 OK\n]
display "Modem is not responding"\n
abort
end
#
# setup our modem commands
#
output "at"$modemsetup\13
input 10 OK\n
#
# send phone number
#
%n = 0
repeat
if %n = %attempts
display "Too many dial attempts"\n
abort
end
output "atdt"$number\13
%ok = [input 60 CONNECT]
%n = %n + 1
until %ok
input 10 \n
#
# wait till it's safe to send because some modem's hang up
# if you transmit during the connection phase
#
wait 30 dcd
#
# We are finished.
# PPP negotiation with Foray PPP Server begins immediately.
#