Dealing with Poseidon MkVI dive logs.

Miika Turkia miika.turkia at gmail.com
Tue Apr 22 09:23:00 PDT 2014


Hi Willem,

I'll include the mailing list, as this should really be discussed there,
especially since we are talking about functionality me and Tomaz are not
familiar with.

On Sun, Apr 20, 2014 at 10:08 PM, Willem Ferguson <
willemferguson at zoology.up.ac.za> wrote:

> Tomaz, Miika,
>
> The good news after the last email is that I discovered that Linus had
> already built in a facility to use po2-values directly from the dive log
> file. For demo purposes I add four source code files that I changed over
> the weekend. I clearly marked all places where I did editing.
>

It is actually easier to see the changes if you send a normally formatted
patch. Just commit it to git and user "git format-patch origin" to produce
a patch file that shows quickly what has changed and can be easily included
in our own git clones with "git am".


> 1) Profile.c was changed to accept the first tank which in the dive log
> file has EAN100 and then to use the po2 data from the log file. I attach a
> screen shot to show that this is done correctly.
> The other three files were changed as follows:
> 2) Three attributes (o2sensor1,o2sensor2,ccrsetpoint) were added to the
> sample structure (defined in dive.h).
> 3) An attribute of "isrebreather" was added to the divecomputer structure.
> (see dive.h as well as parse-xml). At the moment this is an integer. It is
> an internal number that indicates whether a particular dive computer is a
> rebreather or not.
> The three sample attributes above as well as the isrebreather attribute
> are read in correctly. I added printf statements at places in divelist.c to
> show that these items are stored correctly from the dive log file.
> So, now we have the o2sensor1, o2sensor2 and ccrsetpoint data stored
> correctly (I hope!) and we have an attribute that indicates whether the
> dive computer is a rebreather or not.
> 4) There is already a po2 attribute of sample that Linus created when
> writing the code. Remember po2 is the mean of o2sensor1 and o2sensor2.
>
> I hope this provides sufficient infrastructure to be able to add the
> additional graphs in Qt.
>
> There is one unclarity. I defined the isrebreather attribute to the dc
> structure in line 112 of parse-xml.c. This is the one that is used, as far
> as I can see. There is another structure called "divecomputer" defined in
> dive.h. I added an "isrebreather" attribute to it, but as far as I can see
> it is not used in any of the four files that I worked with. Would you be
> prepared to check, please? Looks like a dubious duplication in variables
> and I probably do not read the C code correctly.
>

I think Dirk will be able to answer this one easily. I have not looked into
this part of the code before...

>
> An important part of this adaptation of the code is to deal with the
> cylinders in an appropriate way, since rebreathers use two cylinders
> simultaneously, the first of which is EAN100.
>
> I attach the xml dive log as an example. It has been improved from the
> previous xml that I sent you.
>

I wonder if there is a bug in the battery reading. Value seems to be
missing the first 15+ minutes. Or is it only reported when it drops below
certain value?

>
> Does this help at all?
>
> Miika: This week I will see what can be done about our xslt problem
>

Excellent, it would be great if we did not need the extension.

miika
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.hohndel.org/pipermail/subsurface/attachments/20140422/007f74d1/attachment-0001.html>


More information about the subsurface mailing list