Black Box LRA001A-R2 Network Router User Manual


 
ASYNC ROUTER AR-P, AR-5, AND SYNC ROUTER REFERENCE MANUAL
257
Action initiated by each command is:
control down—turn off DTR in order to reset the modem
wait 100—give the system 100 milliseconds to respond
control up—turn DTR on
speed 38400—set DTE port speed
send “AT&FS=1&C1&D2&Q5&W\r” 100—set up modem parameters
wait 3000 “OK”—wait for modem to be ready
•send “ATDT 1-555-426-1888\r”—dial the number
wait 45000 “CONNECT 38400”—Wait for connection to be ready
send “\r\r\r” 100—send return to autobaud remote modem, if needed
wait 45000 “login:”—get login prompt
send “ppp\r”—send userid
wait 10000 “word:”—get password prompt
send “ppp\r”—send password
status up—start PPP on this line
B.4.3 S
AMPLE REMOTE LOGIN DIALER SCRIPT USING MACRO STRINGS
Macro strings enable the use of one dialer command file to access many systems with different logins,
phone numbers, and passwords. The initial effort to produce the script is reduced and modification is
easy. The sample script below causes the same result as the script on the previous page, but has the
advantage that it does not need modification if system parameters change.
control down
wait 100
control up
speed 38400
send “AT&FS=1&C1&D2&Q5&W\r” 100
wait 3000 “OK”
send $PHONE
wait 45000 “CONNECT 38400”
send “\r\r\r” 100
wait 45000 “login:”
send $LOGIN_NAME
wait 10000 “word:”
send $LOGIN_PWD
status up
The $PHONE macro sends the phone value previously specified by the command:
dialup iface demand phone
The $LOGIN_NAME macro sends the login_name value previously specified by the command:
dialup iface login_name login_name