diff Discovery/Src/tMenuEditHardware.c @ 930:25948e805406 Evo_2_23

DevBugfix Co2 sensor details: The CO2 sensor could not be selected to enter the details menu. This has been corrected and the enable / disable state is shown in the sensor overview.
author Ideenmodellierer
date Tue, 03 Dec 2024 20:24:06 +0100
parents 875933272056
children
line wrap: on
line diff
--- a/Discovery/Src/tMenuEditHardware.c	Mon Dec 02 11:16:10 2024 +0100
+++ b/Discovery/Src/tMenuEditHardware.c	Tue Dec 03 20:24:06 2024 +0100
@@ -589,6 +589,10 @@
 	if(((pSettings->ext_sensor_map[0] < SENSOR_OPTIC) || (pSettings->ext_sensor_map[0] >= SENSOR_TYPE_O2_END)))
 	{
 		pSettings->ppo2sensors_deactivated |= 1;
+		if(pSettings->ext_sensor_map[0] == SENSOR_CO2M)
+		{
+			write_field_on_off(StMHARD3_O2_Sensor1,	 30, 95, ME_Y_LINE1,  &FontT48, "", pSettings->co2_sensor_active);
+		}
 	}
 	else
 	{
@@ -601,6 +605,10 @@
 	if(((pSettings->ext_sensor_map[1] < SENSOR_OPTIC) || (pSettings->ext_sensor_map[1] >= SENSOR_TYPE_O2_END)))
 	{
 		pSettings->ppo2sensors_deactivated |= 2;
+		if(pSettings->ext_sensor_map[1] == SENSOR_CO2M)
+		{
+			write_field_on_off(StMHARD3_O2_Sensor2,	 30, 95, ME_Y_LINE2,  &FontT48, "", pSettings->co2_sensor_active);
+		}
 	}
 	else
 	{
@@ -613,6 +621,10 @@
 	if(((pSettings->ext_sensor_map[2] < SENSOR_OPTIC) || (pSettings->ext_sensor_map[2] >= SENSOR_TYPE_O2_END)))
 	{
 		pSettings->ppo2sensors_deactivated |= 4;
+		if(pSettings->ext_sensor_map[2] == SENSOR_CO2M)
+		{
+			write_field_on_off(StMHARD3_O2_Sensor3,	 30, 95, ME_Y_LINE3,  &FontT48, "", pSettings->co2_sensor_active);
+		}
 	}
 	else
 	{