# HG changeset patch # User Ideenmodellierer # Date 1763488401 -3600 # Node ID d91345e9c00945af561018e8bf6f52ff49c12068 # Parent 493a5903ec207250d9e651a31c9a6752d170ae41 Added GF for surface: The GF for the surface will now be shown in the lowerleft corner as well as in the customer summary view. diff -r 493a5903ec20 -r d91345e9c009 Common/Inc/data_central.h --- a/Common/Inc/data_central.h Sat Nov 15 19:29:44 2025 +0100 +++ b/Common/Inc/data_central.h Tue Nov 18 18:53:21 2025 +0100 @@ -105,6 +105,7 @@ int output_ndl_seconds; float output_ceiling_meter; float super_saturation; + float gf_surf; uint32_t tickstamp; } SDecoinfo; diff -r 493a5903ec20 -r d91345e9c009 Discovery/Src/buehlmann.c --- a/Discovery/Src/buehlmann.c Sat Nov 15 19:29:44 2025 +0100 +++ b/Discovery/Src/buehlmann.c Tue Nov 18 18:53:21 2025 +0100 @@ -320,11 +320,14 @@ float inertgas_a; float inertgas_b; float ceiling; + float M_surf,gf_surf; float super_saturation; float pres_respiration = pLifeData->pressure_ambient_bar; + float pres_surface = pLifeData->pressure_surface_bar; int ci; pDecoInfo->super_saturation = 0; + pDecoInfo->gf_surf = 0; for (ci = 0; ci < 16; ci++) { @@ -341,6 +344,16 @@ inertgas_b = ( ( buehlmann_N2_b[ci] * gTissue_nitrogen_bar[ci]) + ( buehlmann_He_b[ci] * gTissue_helium_bar[ci]) ) / tissue_inertgas_saturation; } + M_surf = inertgas_a + inertgas_b * pres_surface; + if (M_surf > pres_surface) + { + gf_surf = (tissue_inertgas_saturation - pres_surface) / (M_surf - pres_surface); + if(gf_surf > pDecoInfo->gf_surf) + { + pDecoInfo->gf_surf = gf_surf; + } + } + ceiling = pres_respiration / inertgas_b + inertgas_a; if(tissue_inertgas_saturation > pres_respiration) { diff -r 493a5903ec20 -r d91345e9c009 Discovery/Src/t7.c --- a/Discovery/Src/t7.c Sat Nov 15 19:29:44 2025 +0100 +++ b/Discovery/Src/t7.c Tue Nov 18 18:53:21 2025 +0100 @@ -3348,7 +3348,10 @@ /* actual GF */ case LLC_GF: headerText[2] = TXT_ActualGradient; - snprintf(text,TEXTSIZE,"\020%.0f\016\016%%\017",100 * pDecoinfoStandard->super_saturation); + snprintf(text,TEXTSIZE,"\020\002\016\016%3.0f%% @ C\017\n\r\002\016\016%3.0f%% @ 0\017",100 * pDecoinfoStandard->super_saturation + ,100 * pDecoinfoStandard->gf_surf); + tinyHeaderFont = 1; + line = 1; break; case LLC_ScrubberTime: @@ -4146,6 +4149,9 @@ text[textpointer++] = TXT_ActualGradient; text[textpointer++] = '\n'; text[textpointer++] = '\r'; + text[textpointer++] = TXT_ActualGradient; + text[textpointer++] = '\n'; + text[textpointer++] = '\r'; text[textpointer++] = TXT_CNS; text[textpointer++] = '\n'; text[textpointer++] = '\r'; @@ -4187,7 +4193,11 @@ text[textpointer++] = '\n'; text[textpointer++] = '\r'; text[textpointer++] = '\t'; - textpointer += snprintf(&text[textpointer],10,"\020%.0f\016\016%%\017", 100 * pDecoinfoStandard->super_saturation); + textpointer += snprintf(&text[textpointer],15,"\020%.0f\016\016%%\017 @ C", 100 * pDecoinfoStandard->super_saturation); + text[textpointer++] = '\n'; + text[textpointer++] = '\r'; + text[textpointer++] = '\t'; + textpointer += snprintf(&text[textpointer],15,"\020%.0f\016\016%%\017 @ 0", 100 * pDecoinfoStandard->gf_surf); text[textpointer++] = '\n'; text[textpointer++] = '\r'; text[textpointer++] = '\t'; diff -r 493a5903ec20 -r d91345e9c009 Discovery/Src/vpm.c --- a/Discovery/Src/vpm.c Sat Nov 15 19:29:44 2025 +0100 +++ b/Discovery/Src/vpm.c Tue Nov 18 18:53:21 2025 +0100 @@ -290,6 +290,7 @@ pDECOINFO->output_ndl_seconds = 0; pDECOINFO->output_ceiling_meter = 0; pDECOINFO->super_saturation = 0; + pDECOINFO->gf_surf = 0; uint8_t tmp_calc_status; for(int i=0;i