The CScript command te.wait() allows multiple-case wait strings; e.g.,
return_value = te.wait(“my name^S|^Syour name”,0);
which will return 0 if either “my name” or “your name” is received. The WAIT command in TERM Script Language allows a similar structure:
wait “my name|your name”
but the return value is position-dependent. In the above example “my name” would return 0 to the _retval variable, and “your name” would return 1.
This functionality was added to te.wait() in TinyTERM 4.30.
CR 392
This entry was posted
on Friday, April 20th, 2007 at 1:27 pm and is filed under CScript.
You can follow any responses to this entry through the RSS 2.0 feed.
Both comments and pings are currently closed.