##############################################################
#       Dialinfo - Dialer procedure definitions              #
#                                                            #
#    See dialer.1 dialprint.1 dial.2 dialinfo.7 for          #
#    more information.   And good luck.                      #
#                                                            #
#                                Gene H. Olson (author)      #
##############################################################

#	Hayes modem dialer.

hayes,
	star=*, pound=#, flash=H0\,H1,
	delay=\,, wait=\,, retry=20,
	s0=P1 M"AT Q0\r" [OK]1 [in:]4 [IN:]4 [rd:]4 [RD:]4 S10 T3,
	s1=E"dialing %1 %2 %3 %4 %{DIALDEBUG}" M"AT DT%N\r" [CONNECT]10 [NO CARRIER]2 S60 T3,
	s2=E"no answer ..." D1 R3 G0,
	s3=E"no modem response ..." D1 R10 G0,
	s4=E"hung up unix system ..." D1 R5 G0,
	s6=\$hello \${hello},
	s10=C1 G+,


#	Hayes entry to call another UNIX system.

uhayes,
	s10=E"looking for login ..." C1 [login:]40 [ssword:]11 H31 S2  T11,
	s11=R1 M"^M"  [login:]40 [ssword:]11 H31 S5  T12,
	s12=M"^M"     [login:]40 [ssword:]11 H31 S5  T13,
	s13=M"^D^D^D" [login:]40 [ssword:]11 H31 S10 T14,
	s14=B         [login:]40 [ssword:]11 H31 S10 T15,
	s15=M"^M"     [login:]40 [ssword:]11 H31 S5  T16,
	s16=B         [login:]40 [ssword:]11 H31 S10 T17,
	s17=M"^M"     [login:]40 [ssword:]11 H31 S5  T18,
	s18=B         [login:]40 [ssword:]11 H31 S10 T19,
	s19=M"^M"     [login:]40 [ssword:]11 H31 S5  T20,
	s20=B         [login:]40 [ssword:]11 H31 S10 T21,
	s21=M"^M"     [login:]40 [ssword:]11 H31 S5  T30,

	s30=E"No response from remote ..." R10 G0,
	s31=E"Remote system hung up ..." R3 G0,

	s40=M"^M"     G+,
	use=hayes,

#	Vadic 3451

vadic|va3451,
	delay=K, wait=KK, retry=5,
	s0=G1,
	s1=M"^E^M" [Y\n*] S4 T10,
	s2=M"D^M" [NUMBER]3 [ERROR]11 [*]11 T0,
	s3=M"%P^M" [%N]4 [ERROR]11 [*]11 T0,
	s4=M"^M" [ING:],
	s5=[CONNECT]+ [NO CARRIER]12 T30,
	s10=E"No response from dialer" R2 G0,
	s11=E"Comm error with dialer" R2 G0,
	s12=E"Connect failed" R1 G0,
	use=prometheus,
