home *** CD-ROM | disk | FTP | other *** search
- # Login.cmd for ID-Net, Innovative Data Services
- #
- #trace on
-
- if ![load $username]
- if [username "Enter your WinCONNECT login-id"]
- save $username
- end
- end
-
- if ![load $password]
- if [password "Enter your WinCONNECT password"]
- save $password
- end
- end
-
- $number = "1-810-718-7575"
- $dialstring = "DT"
- $modemsetup = "&C1&D2"
- $userprompt = "GATEWAY>"
- $passprompt = "assword:"
- $addrtarg = ") to "
- %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 "AT" $dialstring $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
- #
- # now prod the terminal server
- #
- output \13
- #
- # wait for the username prompt
- #
- input 30 $userprompt
- output $username\13
- #
- # and the password
- #
- input 30 $passprompt
- output $password\13
- #
- # we are now logged in,
- # wait for the address string
- #
- input 30 $addrtarg
- #
- # parse address
- #
- address 30
- #
- # we are now connected, logged in and in slip mode.
- #
- display \n
- display Connected. Your IP address is \i.\n
- #
- # now we are finished.
- #
-