Include po2 on Shearwater import

Signed-off-by: Miika Turkia <miika.turkia@gmail.com>
Signed-off-by: Dirk Hohndel <dirk@hohndel.org>
Reset counters when importing new MK6 log

Naturally the pressure counters and cylinder index must be reset to zero when
reading in a new Poseidon dive log.

Signed-off-by: Miika Turkia <miika.turkia@gmail.com>
Signed-off-by: Dirk Hohndel <dirk@hohndel.org>
Add list of string pairs to dive structure

This extra_data is designed to hold unstructured data from the dive
computer. Things like battery voltage. Deco algorithm. Whatever the dive
computer wants to report to us.

Signed-off-by: Dirk Hohndel <dirk@hohndel.org>
Add helper function to add extra_data to dive computer

Signed-off-by: Dirk Hohndel <dirk@hohndel.org>
Load and save extra data in Subsurface XML format

Includes test dive to test missing attributes and the overall syntax.

Signed-off-by: Dirk Hohndel <dirk@hohndel.org>
Load and save extra data in git format

Signed-off-by: Dirk Hohndel <dirk@hohndel.org>
Show extra data in separate tab on MainTab

This way any extra data probided by the dive computer is visible to the
user (without other processing). This data cannot be edited by the user as
it reflects the information given by the dive computer.

Signed-off-by: Dirk Hohndel <dirk@hohndel.org>
Extract some useful extra data from Uemis SDA

This is just a proof of concept for this patch series, mainly designed to
show how the extra data would be used.

Signed-off-by: Dirk Hohndel <dirk@hohndel.org>
Remove leading spaces in buddy tags

The buddy list generated by the buddy tag logic gets separated by
,<space> so this trims away any leading spaces from the buddy name.

Signed-off-by: Anton Lundin <glance@acc.umu.se>
Signed-off-by: Dirk Hohndel <dirk@hohndel.org>
Convert volume calculations into floating point

The basic problem was that for gases containing more than 2147483648 ml
of nitrogen the calculations overflowed. This changes the code into
using floating point math for that calculation which will be more
accurate to.

Signed-off-by: Anton Lundin <glance@acc.umu.se>
Signed-off-by: Dirk Hohndel <dirk@hohndel.org>
Added import for Liquivision LVD log files

Support includes cylinder pressures and works for v3.0 log files.

Signed-off-by: Dirk Hohndel <dirk@hohndel.org>
Liquivision import fixes

Fixed rounding of temperatures
Fixed compile warnings

Signed-off-by: Dirk Hohndel <dirk@hohndel.org>
Cleaned up file list in open and import dialogs

Lists were getting a little jumbled. I sorted the extensions and added
suitable human readable names.

Signed-off-by: Dirk Hohndel <dirk@hohndel.org>
Don't overwrite zero setpoints

As we agreed, in memory we don't zero repeated setpoints and thus zero
setpoints don't have to be overwritten by the last setpoint value.

This corrects the deco ceiling with CCR dives that bailout to OC.

Signed-off-by: Robert C. Helling <helling@atdotde.de>
Signed-off-by: Dirk Hohndel <dirk@hohndel.org>
The po2 argument of addS_segment is the setpoint, not the pO2 at that time

Signed-off-by: Robert C. Helling <helling@atdotde.de>
Signed-off-by: Dirk Hohndel <dirk@hohndel.org>