Shearwater Petrel import has wrong timestamp

Dirk Hohndel dirk at hohndel.org
Sun May 12 06:24:56 PDT 2013


On Sun, 2013-05-12 at 10:12 +0200, Henrik Brautaset Aronsen wrote:
> Dirk Hohndel wrote: 
> > On Sun, 2013-05-12 at 00:14 +0200, Henrik Brautaset Aronsen wrote:
> > > I tried importing a couple of dives from the Petrel today.  Observations:
> > > 
> > > - The imported dives are two hours wrong.  E.g. a dive is at 14:23 on 
> > > the Petrel, but is imported as 16:23 in Subsurface.  Norway is in CEST 
> > > (GMT+2) right now, that might have something to do with it.  There are 
> > > no time zone settings on the Petrel.
> > 
> > That is very odd. Need to try again with mine with the latest code in
> > master of both libdivecomputer and Subsurface. This worked perfectly the
> > last time I tried it (with PST - GMT-8).
> 
> I tried again with a clean Subsurface profile.  Same result.

Ok, I may not be able to try this today, but I'll add this to my todo
list.

> > > - I get a bluetooth timeout error on the Petrel when it tries to import 
> > > the two test dives that came with the computer.
> > 
> > Also odd. Which firmware is installed on your Petrel?
> 
> The latest, V12.  When I tried again today, the two test dives *did*
> import after all, so it's all good.  But I got the "Bluetooth error:
> Disconnect" regardless.

Jef, any ideas?

> > > - The Petrel doesn't show up in the device name editor.
> > Once the cu device is created it /should/ show up. Can you try that one
> > again, please?
> 
> Same thing.  Maybe it's got something to do with the BT disconnect?
> It doesn't show up in the device editor when I reload the XML file
> either, even though the divecomputer ID's are in there.

Oh, I think we are talking about different things. You are talking about
the divecomputer device editor (Command-E). That may be because of what
you do with merging below.

Nope, it's because the Petrel download has no DeviceId. I need to look
at the new libdivecomputer code if that is not sending us enough data to
build a DeviceId for some reason.

> > > - If I merge the dives from the HelO2 and the Petrel (after correcting 
> > > the Petrel's timestamp), it doesn't show up as a dive with two 
> > > divecomputers.  Only the Suunto profile is kept.
> > That is totally bogus. This has worked for a very long time (and I have
> > lots of dives with three or four divecomputers in my log).
> > 
> > Could you start from an empty file, download from the HelO2 and then
> > from the Petrel and verify this? And once you verified it, could you set
> > a breakpoint in merge_dives() and figure out what's going wrong?
> 
> So, since the Petrel timestamps aren't correct when I download the
> dives, the auto-merging doesn't happen.  What I tried to do was to set
> the correct timestamp for the Petrel, select the two matching dives
> and right-click -> merge.

That's not how I would do it. Edit the timestamps, then click
'autogroup' and if the two clocks are close enough, Subsurface should
merge the dives correctly all by itself.

Yep, tried that and it works perfectly.

/D



More information about the subsurface mailing list