From 11a0c0cc701806ccec975c67d27dec97fbb13b1f Mon Sep 17 00:00:00 2001 From: Linus Torvalds Date: Thu, 20 Jul 2017 14:39:02 -0700 Subject: Unify sample pressure and o2pressure as pressure[2] array We currently carry two pressures around for all the samples and plot info, but the second pressure is reserved for CCR dives as the O2 cylinder pressure. That's kind of annoying when we *could* use it for regular sidemount dives as the secondary pressure. So start prepping for that instead: don't make it "pressure" and "o2pressure", make it just be an array of two pressure values. NOTE! This is purely mindless prepwork. It literally just does a search-and-replace, keeping the exact same semantics, so "pressure[1]" is still just O2 pressure. But at some future date, we can now start using it for a second sensor value for sidemount instead. Signed-off-by: Linus Torvalds Signed-off-by: Dirk Hohndel --- core/uemis.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to 'core/uemis.c') diff --git a/core/uemis.c b/core/uemis.c index e48ab0c92..92b7cdfe9 100644 --- a/core/uemis.c +++ b/core/uemis.c @@ -360,7 +360,7 @@ void uemis_parse_divelog_binary(char *base64, void *datap) sample->depth.mm = rel_mbar_to_depth(u_sample->water_pressure, dive); sample->temperature.mkelvin = C_to_mkelvin(u_sample->dive_temperature / 10.0); sample->sensor = active; - sample->cylinderpressure.mbar = + sample->pressure[0].mbar = (u_sample->tank_pressure_high * 256 + u_sample->tank_pressure_low) * 10; sample->cns = u_sample->cns; uemis_event(dive, dc, sample, u_sample); -- cgit v1.2.3-70-g09d2