An adventure in diving log software
dirk at hohndel.org
Wed Feb 20 09:20:17 PST 2013
Henrik Brautaset Aronsen <subsurface at henrik.synth.no> writes:
> So... I'm going for a two week dive trip tomorrow, and went looking for
> some dive log software for my tablet.
> Dive Log  looked promising, and it could export the log files. But
> the CSV export format was lacking, and the "backup" format didn't have
> any specification. So I contacted Rob (the Dive Log author), and he
> kindly supplied the backup format specification, in addition to
> promising to fix a formatting bug. What a guy!
> But it doesn't stop there. When I asked about whether he could add an
> XML export feature, he asked my advice on how to use and export to the
> Subsurface format natively. Such a good idea! So that's in Rob's
> pipeline now.
> At the same time, I contacted Rainer Mohr (the author of the
> en.divelogs.de online dive log) about supporting the Dive Log backup
> format. And after a couple of emails and hours, the import  was in
> production! So cool!
Indeed. Very cool
> While I was talking to Rainer, I asked if he was able to provide XML
> export from divelogs, since the current UDCF export doesn't provide all
> the stored data. And sure, after some more emails and hours, he even
> provided an official XML export . Fantastic!
Wow. You have been a busy guy, Henrik!
> So, this would only need an XLST transform in Subsurface to be
> supported. Miika to the rescue: He provided a patch and a transform in
> an extremely short time. It lacks a couple of small things (longitude
> and empty pressures needs some care), but it's almost perfect. I'm
> attaching the beta version of the patch for those interested.
> All in all, this has been a great day for dive software, and for me.
> Three guys have impressed me a lot.
> And Dirk, we can postpone this feature until 3.1 :)
Well, I looked at Miika's patch and it seems rather harmless. It's
another xslt transformation and the support to call that from the
This all seems rather harmless.
Two questions (mostly to Miika, I guess):
a) can this format be positively identified? i.e. what's the risk of
false positives (like we had recently when we suddenly couldn't read our
own files anymore as they were misidentified)...
As you know, I don't speak xslt, but this seems like I shouldn't have to
be too nervous:
+ <xsl:template match="/">
+ <divelog program='subsurface' version='2'>
+ <xsl:apply-templates select="DIVELOGSDATA"/>
b) can you send a paragraph for the user-manual that adds a brief
explanation how this would work?
With positive answers to both of those I'll be happy to pull this for
More information about the subsurface