summaryrefslogtreecommitdiffstats
path: root/Readme.ubuntu
diff options
context:
space:
mode:
authorGravatar Linus Torvalds <torvalds@linux-foundation.org>2017-07-21 13:37:34 -0700
committerGravatar Dirk Hohndel <dirk@hohndel.org>2017-07-21 16:34:33 -0700
commitf2a6a76b3e64858691dda623873b2d40c1e98add (patch)
tree10c0c14792c448c99cadb4aa9545f047175b198b /Readme.ubuntu
parentea31800f6194dbf45b530ab21049add076de52bd (diff)
downloadsubsurface-f2a6a76b3e64858691dda623873b2d40c1e98add.tar.gz
Fix up o2 pressure sensor handling at load time
Because of how we traditionally did things, the "o2pressure" parsing depends on implicitly setting the sensor index to the last cylinder that was marked as being used for oxygen. We also always defaulted the primary sensor (which is used for the diluent tank for CCR) to cylinder 0, but that doesn't work when the oxygen tank is cylinder 0. This gets that right at file loading time, and unifies the xml and git sample parsing to make them match. The new defaults are: - unless anything else is explicitly specified, the primary sensor is associated with the first tank, and the secondary sensor is associated with the second tank - if we're a CCR dive, and have an explicit oxygen tank, we associate the secondary sensor with that oxygen cylinder. The primary sensor will be switched over to the second cylinder if the oxygen cylinder is the first one. This may sound backwards, but matches our traditional behavior where the O2 pressure was the secondary pressure. This is definitely not pretty, but it gets our historical files working right, and is at least reasonably sensible. Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org> Signed-off-by: Dirk Hohndel <dirk@hohndel.org>
Diffstat (limited to 'Readme.ubuntu')
0 files changed, 0 insertions, 0 deletions