Page 56
Aanderaa Data Instruments AS – TD302
Example 4: Set Comm TimeOut to 20 sec
//Press Enter to start communicating with the sensor, refer chapter 7.2.2.
↵
//press Enter
Stop
↵
// Stop current measurement.
Wait for ack #. Repeat if necessary.
Set Passkey(1000)
↵
//wait for ack #
Set Comm TimeOut(20 s)
↵
//wait for ack #
Save
↵
// wait for ack #
Reset
↵
// the sensor will restart with new settings
Example 5: Set Tidal Average Period to 1 min
//Press Enter to start communicating with the sensor, refer chapter 7.2.2.
↵
//press Enter
Stop
↵
// Stop current measurement.
Wait for ack #. Repeat if necessary.
Set Passkey(1)
↵
//wait for ack #
Set Tidal Average Period(1 min)
↵
//wait for ack #
Save
↵
// wait for ack #
Reset
↵
// the sensor will restart with new settings
7.4
Scripting -sending a string of commands
Often it may be usefully to include more than one command in a text file. For example the instructions below can be
written in an ordinary text editor and saved as a text file, which can be sent to the sensor.
Example of text file:
// Set sampling interval to 30 seconds
Stop
↵
// Stop current measurement.
Wait for ack #. Repeat if necessary.
Set Passkey(1)
↵
//wait for ack #
Set Interval(30)
↵
//wait for ack #
Save
↵
// wait for ack #
Reset
↵
// the sensor will restart with new settings
Get All
↵
Note! The last line,
Get All
, reads out available properties for the sensor.
The first line is a comment line that is disregarded by the sensor. Strings starting with either ‘//’ or ‘;’ are ignored by
the software, and do not produce errors or acknowledgements.
Always press Enter before sensing a script file, refer chapter 7.2.2.