-
Notifications
You must be signed in to change notification settings - Fork 3
Description
@Jean-Michel raised the following question
the argo variables dimension on N_SENSOR, eg
SENSOR
SENSOR_MAKER
are grouped into a structure SENSORS, eg
"SENSORS": [
{
"SENSOR": "SDN:R25::CTD_PRES",
"SENSOR_MAKER": "SDN:R26::RBR",
"SENSOR_MODEL": "SDN:R27::RBR_PRES_A",
"SENSOR_SERIAL_NO": "205908",
"SENSOR_FIRMWARE_VERSION": " ",
"sensor_vendorinfo": {
"vendor_schema" : "RBR",
"version": "1.0",
"RBR_foo1" : 1,
"RBR_foo2" : "twotwo"
}
},
{
"SENSOR": "SDN:R25::CTD_TEMP",
"SENSOR_MAKER": "SDN:R26::RBR",
"SENSOR_MODEL": "SDN:R27::RBR_ARGO3",
"SENSOR_SERIAL_NO": "205908",
"SENSOR_FIRMWARE_VERSION": " ",
"sensor_vendorinfo": {
"vendor_schema" : "None",
"example": "Vendors can add their own sensor info here; they can add any field they like as a fieldname below sensor_vendorinfo"
}
},
So when this is loaded into matlab, we end up with
js.SENSORS{1}.SENSOR
js.SENSORS{1}.SENSOR_MAKER
and so on.
And similar for
js.PARAMETERS{1}.PARAMETER
js.PARAMETERS{1}.PARAMETER_UNITS
@Jean-Michel question arises when one instrument, eg a CTD has multiple sensors (CTD_PRES, CTD_TEMP, CTD_CNDC, CTD_PSAL). His suggestion was to call the upper level structure 'INSTRUMENT' instead of 'SENSORS'.
So
js.INSTRUMENT
would have fields for SENSOR, SENSOR_MAKER and so on
This idea has some appeal in a file for a single instrument
But I think it breaks down when multiple instruments/sensors are aggregated for a full float.
The SENSOR array then grows to size 10, 15 or more for a BGC float.
The separate SENSOR entries are no longer so closely tied to their parent instrument.
There is just a collection of SENSORs, eg
CTD_PRES
CTD_TEMP
CTD_CNDC
TRANSISTOR_PH
OPTODE_DOXY
and so on.
All the sensors have the same status in the array, so grouping them under "SENSORS" seems like a good choice to me.
Comments welcome