From 9d2c52f692018f13ce8ba87e751c7ad2e28d2f94 Mon Sep 17 00:00:00 2001 From: Jan Mulder Date: Wed, 13 Dec 2017 09:47:57 +0100 Subject: Add pSCR divemode detection In libdivecomputer, a new divemode is added (DC_DIVEMODE_SCR) useful for dive computers that have specfic functionality for semi-closed rebreathers. At this moment, only the HW computers seem to provide this. This commit takes care of proper recognition of this new divemode when importing data from a dive computer. Tested on an actual import from an OSTC3 that contained dives in this new mode. Signed-off-by: Jan Mulder --- core/libdivecomputer.c | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-) diff --git a/core/libdivecomputer.c b/core/libdivecomputer.c index b67b95581..14fe42a6e 100644 --- a/core/libdivecomputer.c +++ b/core/libdivecomputer.c @@ -735,9 +735,12 @@ static dc_status_t libdc_header_parser(dc_parser_t *parser, device_data_t *devda case DC_DIVEMODE_OC: /* Open circuit */ dive->dc.divemode = OC; break; - case DC_DIVEMODE_CCR: /* Closed circuit */ + case DC_DIVEMODE_CCR: /* Closed circuit rebreather*/ dive->dc.divemode = CCR; break; + case DC_DIVEMODE_SCR: /* Semi-closed circuit rebreather */ + dive->dc.divemode = PSCR; + break; } #endif -- cgit v1.2.3-70-g09d2