
Creating a login script for TRUMPET Internet access on ExecNet

This file was last updated on 10-18-1995.


The information listed here has been used by a number of ExecNet callers
using Winsock/Trumpet.  Please note that ExecNet does _not_ have Trumpet
thus cannot actually try this setup.  The information has been supplied
and confirmed by our callers and is furnished as is, with no warranties
of any kind.  Current backups of your software and settings are always
a good idea and highly recommended!

Please note that in order to use this setup you must:

    a) Have a member account on ExecNet, including the SLIP/PPP option
    b) Have used the "Gateway" on EecNet to create your mailbox

If either of these two items is not true the script will not work.  Call us
for help or additional information at 914.667.2150 (voice) or mail
support@execnet.com with questions.


Changes YOU MUST make:

    The variable $prompt1a   should be set to a 4 if using SLIP or
                                                5 if using PPP.

    The variable $prompt3a   should be changed to reflect YOUR account
                             name (first and last name) and password as
                             established on ExecNet.

    The script file should be saved as LOGIN.CMD inyour Trumpet directory.


Changes you MAY WANT to make:

    The variable $modemsetup can be modified to initialize your modem
                             to your preferences (i.e. add M0 to it to
                             keep the speaker off at all times).

    The variable $number     may need to be changed if you are dialing from
                             an area code other than 914.
  Once you've made those changes, if necessary, save it as


CUT HERE
#                   Ŀ
#                    String declarations for the script 
#                   

#       How many dial attempts should be made before the script aborts
#
%attempts = 10

#                        Modem initialization string
#
$modemsetup = "atz"

#                  Phone number for ExecNet you wish to use
#
$number = "667-4567"

#                   Look for the "Language to use" prompt
#
$prompt1q = "age # to use (Enter)=no change?"

#                       Answer for the above question
#                  NOTE - use "4" for SLIP and "5" for PPP
#
$prompt1a = "4"

#                Look for the ""Do you want graphics" prompt
#
$prompt2q = "Do you want graphics"

#                       Answer for the above question
#              "nq" neams - no graphics and no welcome screens
#
$prompt2a = "nq"

#              Looks for the "What is your first name?" prompt
#
$prompt3q = "What is your first name?"

#                       Answer for the above question
#                     Answer with <first last password>
#
$prompt3a = "John Doe password"

#              Ŀ
#               Timeouts for various sections of the script 
#              

# timeout for busy tone... adjust this until the BUSY string is detected.
#
%busytimeout = 10

# time between successive busy attempts - in seconds
#
%busywait = 1

# time to wait for a CONNECT string to be received
#
%connecttimeout = 60

# time to wait until DCD is detected
#
%onlinetimeout = 60

# time to wait for username & password prompts
#
%logintimeout = 60

# time to wait for prompt to appear
#

%prompttimeout = 60

# time to wait for a SLIP address to be parsed
#
%addresstimeout = 60

#    Ŀ
#     Below is the actual script for logging in and getting connected 
#    

# initialize modem
#
status "Initializing modem..."
output "atz"\13
if ! [input 5 OK\n]
  message "Modem is not responding"
  abort
end

# send modem commands
#
output $modemsetup\13
if ! [input 10 OK\n]
  message "Modem is not responding"
  abort
end

# send phone number to modem
#
%n = 0
repeat
  %n = %n + 1
  if %n > %attempts
    message "Too many dial attempts"
    abort
  end
  status Dialing $number   (attempt %n)
  output "atdt"$number\13
  %busy = [input %busytimeout BUSY]
  if %busy
    status "The line is busy...pausing for a while"
    sleep %busywait
    %ok = 0
  else
    %ok = [input %connecttimeout CONNECT]
  end
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 %onlinetimeout dcd
status Connected.  Now logging in - please wait...

#  wait for the "Language to use" prompt and send the proper answer
#
input %logintimeout $prompt1q
output $prompt1a\13

#  wait for the "Do you want graphics" prompt and send the proper answer
#
input %logintimeout $prompt2q
output $prompt2a\13

#  wait for the "What is your first name?" prompt and send the proper answer
#
input %prompttimeout $prompt3q
output $prompt3a\13

# we are now logged in
#
status Now switching to Internet - this can take 5 - 20 seconds.
sleep 3
if %ppp
  input %prompttimeout "Preparing PPP session"
  status PPP session established. You will now be transfered to your browser.
  sleep 3
else
  address 30
  input %addresstimeout \n
  display \n
  display Connected.  Your IP address is \i.\n
  status Connected.  Your IP address is \i.
  sleep 3
end
#
# now we are finished.
CUT HERE



Getting information


To get further information on setting up for the internet Gateway send email
to "maiser@earth.execnet.com" (without the quotes!).  You can use the
following commands in the body of your message, one command per line.  Make
sure you leave a blank line after the last command.

        help                To get general informationon available commands
        index               To get a list of available files (by mail)
        send <filename>     To get an available file (by mail)
        list                To get a list of available list services
        subscribe gateway   To put yourself on the Gateway mailing list
                            and keep up with what is going on




