diff options
author | willem ferguson <willemferguson@zoology.up.ac.za> | 2014-11-17 21:04:36 +0200 |
---|---|---|
committer | Dirk Hohndel <dirk@hohndel.org> | 2014-11-18 08:57:21 +0000 |
commit | 514a0e582a7c7a0a1c3b576382c4c4f4ed3da0ec (patch) | |
tree | 536f7593511eb0e71a73d82ee4c1de1a296a5ca5 /profile.c | |
parent | 55763d3da1c0f154b209c8c8d1ddc97b6ee0c2d7 (diff) | |
download | subsurface-514a0e582a7c7a0a1c3b576382c4c4f4ed3da0ec.tar.gz |
Fix issues in CCR handling
In commit 0d7c192e6edc ("For CCR dives, the diluent cylinder is the
current cylinder") a few things got broken. This tries to undo those
changes and adds expanded XML output.
1) Calculate correct partial pressure of oxygen to be plotted on
dive profile, taking into account the oxygen sensor data.
Currently, erroneously, OC PO2 values are shown, due to an
erroneous calling parameter to fill_pressures().
2) Read start and end cylinder pressured correctly. some wrong
assignments were done in file.c. This is now corrected and the correct
cylinder pressures are shown in the equipment tab.
3) Write correct cylinder pressures to XML. Currently the data for
the two cylinders are written to XML the wrong way round
(diluent pressures = oxygen and vice versa).
4) Expand XML output:
a) Write oxygen sensor data to XML
b) Write no_of_02sensors to XML
Signed-off-by: willem ferguson <willemferguson@zoology.up.ac.za>
Signed-off-by: Dirk Hohndel <dirk@hohndel.org>
Diffstat (limited to 'profile.c')
-rw-r--r-- | profile.c | 2 |
1 files changed, 1 insertions, 1 deletions
@@ -905,7 +905,7 @@ static void calculate_gas_information_new(struct dive *dive, struct plot_info *p amb_pressure = depth_to_mbar(entry->depth, dive) / 1000.0; - fill_pressures(&entry->pressures, amb_pressure, &dive->cylinder[cylinderindex].gasmix, entry->pressures.o2, dive->dc.dctype, entry->sac); + fill_pressures(&entry->pressures, amb_pressure, &dive->cylinder[cylinderindex].gasmix, entry->o2pressure, dive->dc.dctype, entry->sac); fn2 = (int) (1000.0 * entry->pressures.n2 / amb_pressure); fhe = (int) (1000.0 * entry->pressures.he / amb_pressure); |