comparison Discovery/Src/settings.c @ 758:b6d8a6fbf4fd

- Colours for scrubber display when time remaining falls below a threshold value - Display negative values when time is up and diving continues; - count down remaining scrubber time only when the dive computer is not set to bailout - after all, there is not much point in counting down time if the diver is not breathing through the scrubber.
author heinrichsweikamp
date Wed, 15 Mar 2023 09:18:07 +0100
parents 5078da3845c0
children 31883eacf1fa
comparison
equal deleted inserted replaced
757:39ff186b6f98 758:b6d8a6fbf4fd
1495 if(Settings.scubberActiveId > 1) 1495 if(Settings.scubberActiveId > 1)
1496 { 1496 {
1497 Settings.scubberActiveId = 0; 1497 Settings.scubberActiveId = 0;
1498 corrections++; 1498 corrections++;
1499 } 1499 }
1500 if((Settings.scrubberData[0].TimerMax > MAX_SCRUBBER_TIME) || (Settings.scrubberData[0].TimerCur > MAX_SCRUBBER_TIME)) 1500 if((Settings.scrubberData[0].TimerMax > MAX_SCRUBBER_TIME) || Settings.scrubberData[0].TimerCur < MIN_SCRUBBER_TIME || (Settings.scrubberData[0].TimerCur > MAX_SCRUBBER_TIME))
1501 { 1501 {
1502 Settings.scrubberData[0].TimerMax = 0; 1502 Settings.scrubberData[0].TimerMax = 0;
1503 Settings.scrubberData[0].TimerCur = 0; 1503 Settings.scrubberData[0].TimerCur = 0;
1504 corrections++; 1504 corrections++;
1505 } 1505 }
1506 if((Settings.scrubberData[1].TimerMax > MAX_SCRUBBER_TIME) || (Settings.scrubberData[1].TimerCur > MAX_SCRUBBER_TIME)) 1506 if((Settings.scrubberData[1].TimerMax > MAX_SCRUBBER_TIME) || Settings.scrubberData[1].TimerCur < MIN_SCRUBBER_TIME || (Settings.scrubberData[1].TimerCur > MAX_SCRUBBER_TIME))
1507 { 1507 {
1508 Settings.scrubberData[1].TimerMax = 0; 1508 Settings.scrubberData[1].TimerMax = 0;
1509 Settings.scrubberData[1].TimerCur = 0; 1509 Settings.scrubberData[1].TimerCur = 0;
1510 corrections++; 1510 corrections++;
1511 } 1511 }