mirror of
https://github.com/subsurface/subsurface.git
synced 2025-02-19 22:16:15 +00:00
These pO2 samples exist in both the Predator and the Petrel
Signed-off-by: Dirk Hohndel <dirk@hohndel.org>
This commit is contained in:
parent
8fa205a59d
commit
6374d9cc03
1 changed files with 4 additions and 2 deletions
6
dive.c
6
dive.c
|
@ -883,11 +883,13 @@ void update_setpoint_events(struct divecomputer *dc)
|
||||||
if (dc->divemode == CCR)
|
if (dc->divemode == CCR)
|
||||||
new_setpoint = prefs.defaultsetpoint;
|
new_setpoint = prefs.defaultsetpoint;
|
||||||
|
|
||||||
if (dc->divemode == OC && same_string(dc->model, "Shearwater Predator")) {
|
if (dc->divemode == OC &&
|
||||||
|
(same_string(dc->model, "Shearwater Predator") ||
|
||||||
|
same_string(dc->model, "Shearwater Petrel"))) {
|
||||||
// make sure there's no setpoint in the samples
|
// make sure there's no setpoint in the samples
|
||||||
// this is an irreversible change - so switching a dive to OC
|
// this is an irreversible change - so switching a dive to OC
|
||||||
// by mistake when it's actually CCR is _bad_
|
// by mistake when it's actually CCR is _bad_
|
||||||
// So we make sure, this comes from a Predator and we only remove
|
// So we make sure, this comes from a Predator or Petrel and we only remove
|
||||||
// pO2 values we would have computed anyway.
|
// pO2 values we would have computed anyway.
|
||||||
struct event *ev = get_next_event(dc->events, "gaschange");
|
struct event *ev = get_next_event(dc->events, "gaschange");
|
||||||
struct gasmix *gasmix = get_gasmix_from_event(ev);
|
struct gasmix *gasmix = get_gasmix_from_event(ev);
|
||||||
|
|
Loading…
Add table
Reference in a new issue