Mercurial > public > ostc4
comparison Discovery/Src/t7.c @ 1070:4499227a2db8 Icon_Integration
Added compile option for o2/diluent pressure display:
Some external devices (like the RedBare rebreather) provide pressure sensor information o2 and diluent bottles. A data channel from RTE to main CPU has been defined and a visualization has been added to the lower left corner (llc). Pressure will be displayed in the gas list as well => for o2 display the definition of a 100% o2 gas is needed. Diluent will be assigned to the first gas. The ADVANCED_GAS compile switch needs to be activated for this feature
| author | Ideenmodellierer |
|---|---|
| date | Thu, 19 Feb 2026 13:17:25 +0100 |
| parents | de56b8d75504 |
| children |
comparison
equal
deleted
inserted
replaced
| 1069:e0ba2b29dc1f | 1070:4499227a2db8 |
|---|---|
| 3253 _Bool tinyHeaderFont = 0; | 3253 _Bool tinyHeaderFont = 0; |
| 3254 uint8_t line = 0; | 3254 uint8_t line = 0; |
| 3255 #ifdef ENABLE_BOTTLE_SENSOR | 3255 #ifdef ENABLE_BOTTLE_SENSOR |
| 3256 uint16_t agedColor = 0; | 3256 uint16_t agedColor = 0; |
| 3257 #endif | 3257 #endif |
| 3258 | 3258 #ifdef ENABLE_ADVANCED_GAS |
| 3259 static uint8_t gasIdO2 = 0; | |
| 3260 static uint8_t gasIdDiluent = 0; | |
| 3261 #endif | |
| 3259 SDivetime Stopwatch = {0,0,0,0}; | 3262 SDivetime Stopwatch = {0,0,0,0}; |
| 3260 float fAverageDepth, fAverageDepthAbsolute; | 3263 float fAverageDepth, fAverageDepthAbsolute; |
| 3261 const SDecoinfo * pDecoinfoStandard; | 3264 const SDecoinfo * pDecoinfoStandard; |
| 3262 const SDecoinfo * pDecoinfoFuture; | 3265 const SDecoinfo * pDecoinfoFuture; |
| 3263 float fCNS; | 3266 float fCNS; |
| 3386 #ifdef ENABLE_BOTTLE_SENSOR | 3389 #ifdef ENABLE_BOTTLE_SENSOR |
| 3387 case LCC_BottleBar: | 3390 case LCC_BottleBar: |
| 3388 headerText[2] = TXT_AtemGasVorrat; | 3391 headerText[2] = TXT_AtemGasVorrat; |
| 3389 tinyHeaderFont = 1; | 3392 tinyHeaderFont = 1; |
| 3390 snprintf(text,TEXTSIZE,"%d\016\016\017", stateUsed->lifeData.bottle_bar[stateUsed->lifeData.actualGas.GasIdInSettings]); | 3393 snprintf(text,TEXTSIZE,"%d\016\016\017", stateUsed->lifeData.bottle_bar[stateUsed->lifeData.actualGas.GasIdInSettings]); |
| 3394 break; | |
| 3395 #endif | |
| 3396 | |
| 3397 #ifdef ENABLE_ADVANCED_GAS | |
| 3398 case LCC_BottleBar: | |
| 3399 headerText[2] = TXT_AtemGasVorrat; | |
| 3400 tinyHeaderFont = 1; | |
| 3401 if(isLoopMode(stateUsed->diveSettings.diveMode)) | |
| 3402 { | |
| 3403 if((gasIdO2 == 0) && (gasIdDiluent == 0)) | |
| 3404 { | |
| 3405 DataEX_helper_Get_ID_Of_O2_Diluent(&gasIdO2, &gasIdDiluent); | |
| 3406 } | |
| 3407 if(gasIdO2 != 0) | |
| 3408 { | |
| 3409 textpointer = snprintf(text,TEXTSIZE,"\020\016\016%u",stateUsed->lifeData.bottle_bar[gasIdO2]); | |
| 3410 } | |
| 3411 if(gasIdDiluent != 0) | |
| 3412 { | |
| 3413 textpointer = snprintf(&text[textpointer],TEXTSIZE,"\n\r%u",stateUsed->lifeData.bottle_bar[gasIdDiluent]); | |
| 3414 } | |
| 3415 } | |
| 3416 else | |
| 3417 { | |
| 3418 snprintf(text,TEXTSIZE,"%d\016\016\017", stateUsed->lifeData.bottle_bar[stateUsed->lifeData.actualGas.GasIdInSettings]); | |
| 3419 } | |
| 3391 break; | 3420 break; |
| 3392 #endif | 3421 #endif |
| 3393 #ifdef ENABLE_CO2_SUPPORT | 3422 #ifdef ENABLE_CO2_SUPPORT |
| 3394 case LCC_CO2: | 3423 case LCC_CO2: |
| 3395 headerText[2] = TXT_CO2Sensor; | 3424 headerText[2] = TXT_CO2Sensor; |
