10.

contents
Next: mode and default Up: A dip Reference Previous: The if and goto

send, wait and sleep

These commands help implement simple chat scripts in dip. send outputs its arguments to the serial line. It does not support variables, but understands all C-style backslash character sequences such as n and b. The tilde character () is used as an abbreviation for carriage return/newline.

wait takes a word as an argument, and scans all input on the serial line until it recognizes this word. The word itself may not contain any blanks. Optionally, you may give wait a timeout value as second argument; if the expected word is not received within that many seconds, the command will return with an $errlvl value of one.

The sleep statement may be used to wait for a certain amount of time, for instance to patiently wait for any login sequence to complete. Again, the interval is specified in seconds.



Andrew Anderson
Thu Mar 7 23:22:06 EST 1996



The Network Administrators' Guide
Linux Network Administrators Guide (2nd Edition)
ISBN: B00007FYJC
EAN: N/A
Year: 1992
Pages: 296

flylib.com © 2008-2017.
If you may any questions please contact us: flylib@qtcs.net