# Dialup to a TIA server (static IP)
# Dials 1 out of 8 numbers if server is busy
login=******           
password=*****
$PORT = $entry x_tcp.cfg, "$PORT:"
$IRQ = $entry x_tcp.cfg, "$IRQ:"
$BAUD =$entry x_tcp.cfg,"$BAUD:"
$VEC = $entry wattcp.cfg, "pktint="
initstring = $entry x_tcp.cfg, "initstring:"
dialstring=  $entry x_tcp.cfg, "dialstring:"
packetdriver = $entry x_tcp.cfg, "packetdriver:"
my_ip = $entry wattcp.cfg, "my_ip="
gateway="192.0.2.1"
nameserver="129.206.100.127"
predial="atdp06221"
nr(1)=49071
nr(2)=49072
nr(3)=49073
nr(4)=49074
nr(5)=409008
nr(6)=49134
nr(7)=419661
nr(8)=49158
if $carrier=off
   send initstring+{13}
   wait 2 ok{13,10}
   if $0<>ok{13,10}
      print "Modem not responding!"
      exit
   else
      do
           add n,1
           if n>8 
              n=1
           endif
           send predial + nr(n) + {13}
           wait 120 $carrier=on BUSY NO
           if $CARRIER=OFF 
              wait 1  
              countdown=on
                 print
                 print "Redial Wait ...;"
                 wait 30
              countdown=off
           end if     
      while $carrier=off    
   end if 
   wait 60 relay!login:
   wait 2
   send "tia/"+login+{13}
   wait 10 "Password:"
   wait 2 
   send password+{13}
   wait 10 Slip
end if
modify "wattcp.cfg", "my_ip=", my_ip
modify "wattcp.cfg", "gateway=", gateway
modify "wattcp.cfg", "nameserver=", nameserver
openslip packetdriver
end                                        # THAT's IT
