ModularSensors > Files > src / VariableBase.h

VariableBase.h file

Contains the Variable class.

A variable is a result value taken by a sensor or calculated from the results of one or more sensors. It is characterized by a name (what it is a measurement of), a unit of measurement, and a resolution. The names and units of measurements for all variables come from the controlled vocabularies developed for the ODM2 data system. (http://vocabulary.odm2.org/) The resolution is determined by the method used to take the measurement by the sensor. A variable may also be assigned a universally unique identifier (UUID) and a unique variable code. Many sensors are capable of measuring multiple variables at a single time. For example, a Decagon CTD-10 is a sensor. It is able to measure 3 variables: specific conductance, temperature, and water depth. The variable named "specificConductance" has units of microsiemens per centimeter (µS/cm) and a resolution of 1 µS/cm. Each measured variable is explicitly tied to the "parent" sensor that "notifies" the variable when a new value has been measured. Each calculated variable has a parent function returning a float which is the value for that variable.

Variables are expected to be grouped together into VariableArrays.

Classes

class Variable
The variable class for a value and related metadata.