home
***
CD-ROM
|
disk
|
FTP
|
other
***
search
/
DOS/V Power Report 1997 December
/
VPR9712A.ISO
/
OLS
/
WIN16
/
TTERMV13
/
DIALUP.TTL
< prev
next >
Wrap
Text File
|
1995-12-18
|
1KB
|
68 lines
; Sample macro for Tera Term
; Dial-up login
; open Tera Term
; command line = 'TERATERM /C=1' (COM1 port)
connect '/C=1'
DialPrefix = 'ATD'
; set phone number, username, and password
PhoneNumber = '0000000000'
UsernamePrompt = 'Username:'
Username = 'MYNAME'
PasswordPrompt = 'Password:'
Password = 'MYPASSWORD'
; initialize modem (see the manual for your modem)
sendln 'ATZ'
wait 'OK'
; dial up
:dial
send DialPrefix
sendln PhoneNumber
; set timeout (30 sec)
timeout = 30
; wait for strings from modem
wait 'CONNECT' 'BUSY' 'NO CARRIER'
; pause 2 sec
pause 2
; timeout?
if result=0 goto error
; 'CONNECT'?
if result=1 goto conn
; 'BUSY'?
if result=2 goto redial
; 'NO CARRIER'
if result=3 goto error
; error. stop macro
:error
messagebox 'Dialing error!' 'Tera Term'
end
:redial
yesnobox 'Busy! Try again?' 'Tera Term'
if result goto dial
end
; connect!
:conn
; login
wait UsernamePrompt
sendln Username
wait PasswordPrompt
sendln Password
; OK, auto login complete.