Mercurial > public > ostc4
diff Discovery/Src/tCCR.c @ 782:9a1bb9e7cb61
Sensor status support for multiplexed DiveO2 sensors:
The sensor status is now provided for every DiveO2 sensor connected to the OSTC => The sensor error detection had to be extended to support the bigger data structure.
author | Ideenmodellierer |
---|---|
date | Mon, 29 May 2023 20:22:15 +0200 |
parents | b6d8a6fbf4fd |
children | acf6614dc396 |
line wrap: on
line diff
--- a/Discovery/Src/tCCR.c Mon May 29 18:26:55 2023 +0200 +++ b/Discovery/Src/tCCR.c Mon May 29 20:22:15 2023 +0200 @@ -180,7 +180,7 @@ if(sensorActive[index]) { - if(((stateUsed->lifeData.extIf_sensor_map[index] == SENSOR_DIGO2) && (((SSensorDataDiveO2*)(stateUsed->lifeData.extIf_sensor_data))->status & DVO2_FATAL_ERROR)) + if(((stateUsed->lifeData.extIf_sensor_map[index] == SENSOR_DIGO2) && (((SSensorDataDiveO2*)(stateUsed->lifeData.extIf_sensor_data[index]))->status & DVO2_FATAL_ERROR)) || ((stateUsed->lifeData.extIf_sensor_map[index] != SENSOR_DIGO2) && (((stateUsed->lifeData.sensorVoltage_mV[index] < MIN_SENSOR_VOLTAGE_MV) || (stateUsed->lifeData.sensorVoltage_mV[index] > MAX_SENSOR_VOLTAGE_MV))))) {