comparison Discovery/Src/tInfoSensor.c @ 845:17d9d6eddd8d Evo_2_23

Added new PreDiveCheck info page: In case a DiveO2 sensor is connected to the OSTC than the values of the DiveO2 internal pressure and temperature sensors may be used for predive checks. The pressure sensors is used for over / under pressure test and the values are visualized using a graph to make it easier to check if the pressure keeps stable. The temperature measurement gives an indication if the scrubber is getting active. This view is highly dependend on the surface temperature but may be useful e.g. for diving in european area. In addition the values ofthe connected sensors are shown.
author Ideenmodellierer
date Sun, 21 Jan 2024 22:24:36 +0100
parents ffb1036c27c2
children
comparison
equal deleted inserted replaced
844:e04d7dd199fb 845:17d9d6eddd8d
107 value /= 10; 107 value /= 10;
108 } 108 }
109 strcpy(pbuf,&tmpBuf[index+1]); 109 strcpy(pbuf,&tmpBuf[index+1]);
110 } 110 }
111 111
112 void tInfo_write_buttonTextline_simple(uint8_t left2ByteCode, char middle2ByteCode, char right2ByteCode)
113 {
114 char localtext[32];
115
116 if(left2ByteCode)
117 {
118 localtext[0] = TXT_2BYTE;
119 localtext[1] = left2ByteCode;
120 localtext[2] = 0;
121 tInfo_write_content_simple(0, 800, 480-24, &FontT24,localtext,CLUT_ButtonSurfaceScreen);
122 }
123
124 if(middle2ByteCode)
125 {
126 localtext[0] = '\001';
127 localtext[1] = TXT_2BYTE;
128 localtext[2] = middle2ByteCode;
129 localtext[3] = 0;
130 tInfo_write_content_simple(0, 800, 480-24, &FontT24,localtext,CLUT_ButtonSurfaceScreen);
131 }
132
133 if(right2ByteCode)
134 {
135 localtext[0] = '\002';
136 localtext[1] = TXT_2BYTE;
137 localtext[2] = right2ByteCode;
138 localtext[3] = 0;
139 tInfo_write_content_simple(0, 800, 480-24, &FontT24,localtext,CLUT_ButtonSurfaceScreen);
140 }
141 }
142 112
143 static void refreshInfo_SensorO2(GFX_DrawCfgScreen s) 113 static void refreshInfo_SensorO2(GFX_DrawCfgScreen s)
144 { 114 {
145 const SDiveState *pStateReal = stateRealGetPointer(); 115 const SDiveState *pStateReal = stateRealGetPointer();
146 SSensorDataDiveO2* pDiveO2Data; 116 SSensorDataDiveO2* pDiveO2Data;