home *** CD-ROM | disk | FTP | other *** search
/ Il CD di internet / CD.iso / SOURCE / N / DIP / _DIP.TAR / usr / doc / dip / samples / annex.dip next >
Encoding:
Text File  |  1995-01-13  |  1.1 KB  |  55 lines

  1. ###############################################################################
  2. # DIP script to connect to a Xylogics Micro Annex
  3. # Written by Kevin Layer (layer@franz.com) with help from John
  4. #   Foderaro (jkf@franz.com).
  5.  
  6.   # Fetch the IP address of our target host.
  7. main:
  8.  
  9.   # Set the desired serial port and speed.
  10.   port /dev/modem
  11.   speed 38400
  12.  
  13.   # Reset the modem and terminal line.
  14.   reset
  15.  
  16.   # Prepare for dialing.
  17.   send ATZ\r
  18.   wait OK 10
  19.   if $errlvl != 0 goto error
  20.   dial t5551212
  21.   if $errlvl != 1 goto error
  22.  
  23.   # We are connected.  Login to the system.
  24. login:
  25.   sleep 3
  26.   wait word: 10
  27.   if $errlvl != 0 goto error
  28.   send PUT_YOUR_PASSWORD_HERE\n
  29.   wait annex 10
  30.   if $errlvl != 0 goto error
  31.   send slip\n
  32.  
  33.   wait Annex 10
  34.   wait address 1
  35.   wait is 1
  36.   if $errlvl != 0 goto error
  37.   get $remote remote 1
  38.   if $errlvl != 0 goto error
  39.  
  40.   wait Your 1
  41.   wait address 1
  42.   wait is 1
  43.   if $errlvl != 0 goto error
  44.   get $local remote 1
  45.   if $errlvl != 0 goto error
  46. done:
  47.   print CONNECTED to $remote with address $local
  48.   default
  49.   mode CSLIP
  50.   goto exit
  51. error:
  52.   print error.
  53. exit:
  54.  
  55.