diff Discovery/Src/data_central.c @ 873:e373e90a48db Evo_2_23

merge new screen stuff
author heinrichsweikamp
date Wed, 14 Aug 2024 16:44:46 +0200
parents db92692c014f fa431d42b5fb
children a7f4451ba69e
line wrap: on
line diff
--- a/Discovery/Src/data_central.c	Wed Aug 14 14:41:04 2024 +0200
+++ b/Discovery/Src/data_central.c	Wed Aug 14 16:44:46 2024 +0200
@@ -563,12 +563,19 @@
 	nitrogen -= helium;
 
 
-	if((lifeData->actualGas.nitrogen_percentage != nitrogen) || (lifeData->actualGas.helium_percentage != helium) || (lifeData->actualGas.AppliedDiveMode != DIVEMODE_OC))
+	if ((lifeData->actualGas.nitrogen_percentage != nitrogen) || (lifeData->actualGas.helium_percentage != helium) || lifeData->actualGas.AppliedDiveMode != DIVEMODE_OC)
     {
-    	stateUsedWrite->events.manualGasSet = 1;
-    	stateUsedWrite->events.info_manualGasSetHe = helium;
-    	stateUsedWrite->events.info_manualGasSetO2 = oxygen;
+       if (stateUsed->diveSettings.ccrOption) {
+            stateUsedWrite->events.bailout = 1;
+            stateUsedWrite->events.info_bailoutHe = helium;
+            stateUsedWrite->events.info_bailoutO2 = oxygen;
+        } else {
+            stateUsedWrite->events.manualGasSet = 1;
+            stateUsedWrite->events.info_manualGasSetHe = helium;
+            stateUsedWrite->events.info_manualGasSetO2 = oxygen;
+        }
     }
+
     if(	lifeData->actualGas.setPoint_cbar != setpoint_cbar)
     {
     	stateUsedWrite->events.setpointChange = 1;