A script file is required only if your ISP does NOT use a standard PPP connection. The following section describes script files.
Three commands can be used to automate a proprietary negotiation process. The commands are as follows, where items in [ ] are optional, and the [ ] themselves are not used:
Send[msec] <string> | Send a data string, with a. [msec] (milliseconds) delay between the sending of each character. |
Wait [msec] | Wait for the specified time (milliseconds) to elapse before executing the next script line. |
Wait [msec] <string> | Wait for the specified time (milliseconds) to receive the string. If the string is not received within the specified time, the connection is reset. An error conditions arises if [msec] is not specified and the string is not received immediately. |
Eleven special string variables can be used in conjunction with the command strings discussed above. These following string variables are used to insert special characters in the string.
The supported variables are:
Variable |
Description |
\a | alert |
\b | backspace |
\f | form feed |
\n | new line |
\r | carriage return |
\t | horizontal tab |
\v | vertical tab |
\? | Literal question mark |
\ | literal single quotation mark |
\" | literal double quotation mark |
\\ | literal back slash |
Note: The strings and special control variables need
to be enclosed in double quotes. Literal variables are
used when ?, , ", or \ are part of the string.
For example, to send the string "User Name",
(including the quotes) the script file entry should be as
follows: "\"User Name\"" Also, each script entry command, time and string, must be separated by a space. |
The following is a sample script file with the proper syntax conventions. This script file could be used to log on to Compuserve.
wait 3000
send 100 "\r"
wait 3000
send 100 "CIS\r"
wait 3000 ":"
send 100 "user id\r"
wait 3000
send 100 "password\r"
wait 60000 "!"
send 100 "GO PPPCONNECT\r"
Command |
Explanation |
wait 3000 | Pause for 3 seconds |
send 100 "\r" | Send the carriage return character, pausing for 100 ms between characters. |
wait 3000 | Pause for 3 seconds |
send 100 "CIS\r" | Send the string "CIS", followed by a carriage return character. Pause for 100 ms between each character. |
wait 3000 ":" | Wait for 3 seconds to receive the character
":". If the character is not received in this time, the connection will be dropped. |
send 100 "user id\r" | Send the string user id, where user id is your log-in name, followed by a carriage return. Pause for 100 ms between each character. |
wait 3000 | Pause for 3 seconds |
send 100 "password\r" | Send the string password, where password is your password, followed by a carriage return. Pause for 100 ms between each character. |
wait 60000 "!" | Wait for 60 seconds to receive the character
"!". If not received in this time, the connection will be dropped. |
Send 100 "GO PPPCONNECT\r" | Send the string "GO PPPCONNECT", followed by a carriage return character. Pause for 100 ms between each character. |