Shearwater: add support for remaining gas time

Signed-off-by: Dirk Hohndel <dirk@hohndel.org>
This commit is contained in:
Dirk Hohndel 2017-07-07 07:40:29 -07:00
parent 8736a6dca1
commit 41417fbe59

View File

@ -605,6 +605,11 @@ shearwater_predator_parser_samples_foreach (dc_parser_t *abstract, dc_sample_cal
sample.pressure.value = pressure * 2 * PSI / BAR;
if (callback) callback (DC_SAMPLE_PRESSURE, sample, userdata);
}
// Gas time remaining in minutes
if (data[offset + 21] < 0xFBu) {
sample.rbt = data[offset + 21];
if (callback) callback (DC_SAMPLE_RBT, sample, userdata);
}
}
offset += parser->samplesize;