Data collector

Data collector IO The Data collector I/O is used when performing streaming measurements. During streaming measurements, data arrives in consecutive blocks with a size equal to the instrument's record length. To form a continuous stream of data, these blocks must be appended to each other. The data collector does this job. It will fill its data with the arriving blocks of data, see the picture below.

Data collector example

When a Data collector is used in combination with other I/O's which process the data, there are two ways to connect them to each other, each with its own advantage and disadvantage:

  • first process the data with the I/O's and then collect the data
    The I/O's only have (relative) small chunks of data to process, which can be done relatively fast. The Data collector only has to collect the already processed data. The disadvantage is that the original data is not collected this way; when later turns out that the data was wrongly processed, the measurement will have to be done again.
  • first collect the data and then process the data with the I/O's
    The I/O's will have to process the full data size of the Data collector, even if it's only partly filled yet. This can create a very heavy load on the computer, even causing the streaming measurement to be stopped because the computer cannot keep up anymore. The advantage is that the original data is kept, making it possible to change the data processing in a later stage.

The first method is preferred in most situations. When the original data is important, it is always possible to create a second Data collector to collect the original, unprocessed data.

When a graph contains a Data collector, it is possible, while the Data collector is being filled, to zoom in on the latest data and have the graph automatically keep the latest data visible. Choose the appropriate zoom factor in the graph and right-click the timebase axis and select Follow source from the popup menu. This will show a sub menu with the possible sources to follow and an option not to follow a source.

When streaming data needs to be stored on disk, use a Disk writer sink which can store streaming data directly. Do not store streaming data that is collected in a Data collector I/O using a Disk writer. Each time the Data collector receives new data, this will be signaled to the Disk writer, which will then add the complete Data collector content to the file, not just the new data.

Properties and actions

To control the behavior of the Data collector I/O, several properties are available. These can be accessed through a popup menu which is shown when the I/O is right clicked.

Data size

The Data size property sets the size of the output block (the "record length") of the Data collector. Several default values are available, as well as a user defined setting. The size of the collected data can be set to a maximum of 20 million samples.

Fill Mode

The Fill mode property sets how the data collector is filled with data.

  • From left to right: new data is appended starting from the left
  • From right to left: existing data is shifted to left, new data is appended at the right

When full

The When full property determines what action the Data collector performs when the output data block is full.

  • Continue: the oldest data is shifted out at the left, while new data is appended to the right
  • Stop: data collecting is stopped when full. (The measurement is NOT stopped.)
  • Clear: the output data is cleared and the filling starts over again
  • Overwrite: existing data in the output array is overwritten by the new data (roll mode)

Clear

The Data collector I/O can be manually cleared with the Clear action.

Common properties and actions

Alias

You can change the displayed name of an object by giving it an Alias. This can be handy when you are dealing with a lot of objects and have problems keeping them apart. You can for example give channel one of your instrument the alias "Battery", when it is measuring a battery voltage. To give an object an alias, use the item Alias ... in its menu. To remove an alias and revert to the original name of the object, set the alias to an empty string.

Color

When multiple sources or I/O's are displayed in a graph or a meter, they can be distinguished from each other by their Color. Three different color settings are available for a source or an I/O.

  • Automatic
    A color is selected from a group of colors. There are separate groups for channel colors and source colors. The groups can be configured in the program settings. Each new channel or source uses the next available color in the group. When the last color in the group is used and another channel or source is added, picking will start at the top of the group again.
  • As source
    This setting is only available for I/O's. The I/O will use the same color as its source. When multiple sources are connected to the I/O, the color of the first connected source is used.
  • User defined...
    The color of the source or I/O is user selected, using a color picker dialog. Any color can be used.

Disconnect all sources

To disconnect all sources from an I/O or Sink at once, use the Disconnect all sources action.

Disconnect sink(s)

To disconnect one or more sinks from an I/O or Source, use the Disconnect sink(s) action. This will show a dialog that lists all connected sinks. Individual sinks can then be selected and disconnected from the object.

Disconnect all sinks

To disconnect all sinks from an I/O or source at once, use the Disconnect all sinks action.

Clone

When a new object is to be created, similar to an already existing object, with the same properties, the Clone action can be used. This will create an identical copy of the original object, with the exact same properties. Source(s) and sink(s) of the new object are not yet connected.

Delete

The Delete action deletes a source, I/O or sink. All connections of the object will be disconnected and then the object will be removed from the object tree. The source property of the objects that used this object as source will be cleared. The sink property of the objects that used this object as sink will be cleared. An axis in a graph that was connected to this object will be also deleted.

Export data

The Export data action allows to export the data of an object to a file. This is detailed described on the page about Exporting data.

Load

The Load action allows to load the settings and data for an object from a TPS or TPO file. This is detailed described on the page about Loading into selected objects.

Save as

The Save as action allows to save the settings and data of one or more objects to a TPO file. When multiple objects are selected, the connections between the objects are saved as well. This is detailed described on the page about Saving objects to a TPO file.