Skip to main content
Skip table of contents

fetch

Usage

>> fetch [ channels | sleepafter ]

Security

Open.

Description

Requests an 'on-demand' sample set from the logger. If a recent scheduled sample set is available, those values may be returned to satisfy the fetch request. 'Recent' in this context currently means less than 500ms old. Otherwise, a sample set is explicitly acquired for the benefit of the fetch. A sample set acquired only for fetch is never stored in memory.

The logger simply responds with the <sample-data>; depending on the configured settling time (or power-on settling delay) for the attached sensors, there may be a noticeable delay before the <sample-data> appears. Refer to the channels command for further discussion of settling time.

  • channels [= <listofchannels>], is the list of channels to be acquired, using either indices or labels of channels (see channel). The output format of the <sample-data> is the channels samples in the same order. If this parameter is not provided, the output format of the <sample-data> is determined by the outputformat command.

If a channel or one of its supporting channel has its status set to off, requesting that channel will return an Error-14 as sample data for this channel. See channel for details.

  • sleepafter [= <sleepafter>], controls power strategy after the fetch is issued. <sleepafter> is either:

    1. false (default behavior), subsequent fetch commands may return data more quickly; after an initial fetch command, the sensors usually remain powered up in anticipation of another request. This behaviour is protected by an 8-second (default) timeout, after which the sensors are turned off again. Refer to the settings command for information on changing the default sensor power-off timeout.

    2. true causes the logger to power down when it has finished reporting the <sample-data>. This is equivalent to issuing two separate commands, fetch then sleep, except that after completing the fetch the logger goes to sleep silently; there is no "Ready" prompt following the <sample-data>, just as there is no "Ready" prompt following a sleep command. Note that the entire logger powers down if possible, not just the sensors; however if any normally scheduled samples are required immediately after the fetch, the power down action will be delayed until after those samples are complete.

Examples

CODE
>> outputformat labelslist
<< outputformat labelslist= temperature_00|pressure_00
>> fetch
<< 2017-10-21 11:50:49.000, 18.1745 C, 12.7052 dbar

Fetch a sample from all channels.

CODE
>> channel 1 type
<< channel 1 type = cond07
>> channel 2 type

<< channel 2 type = temp14

>> channel 3 type

<< channel 3 type = pres24
>> outputformat type, labelslist
<< outputformat type = caltext02, labelslist= conductivity_00|temperature_00|pressure_00

>> fetch
<< 2017-10-21 11:50:49.000, 40.0120 mS/cm, 18.1745 C, 12.7052 dbar
>> fetch channels = 3|2
<< 2017-10-21 11:50:49.000, 12.7052 dbar, 18.1745 C
>> fetch channels = pressure_00|temperature_00, sleepafter=true
<< 2017-10-21 11:50:49.000, 12.7052 dbar, 18.1745 C

Fetch a sample from some specific channels.

CODE
>> fetch
<< 2020-11-25 15:31:55.000, Error-07, ###, Error-14

Fetch command reporting error for channel 1 (timeout) and channel 3 (unable to compute value).  Channel 2 is not calibrated.  List of error code can be found in within Sample data standard format.  

Errors

Error E0108 invalid argument to command: '<invalid-argument>' 
An unrecognized argument was given with the command.

Error E0107 expected argument missing 
If the sleepafter option is used, a value of either true or false must also be supplied.

Error E0410 no sampling channels active 
Indicates that the logger has no channels activated for sampling.

Error E0111 command failed 
Indicates a serious fault with the logger; please contact RBR Ltd for help. 

JavaScript errors detected

Please note, these errors can depend on your browser setup.

If this problem persists, please contact our support.