James O'Neill's Blog

March 16, 2009

A day out with Divers

Filed under: Events,Photography,Windows 7,Windows Vista — jamesone111 @ 11:38 am

I spent yesterday at the DIVERSE – the South Eastern area conference for BSAC (the British Sub Aqua Club) : officially I was there to speak about why Windows Vista (and 7) are so good at handling pictures. Unofficially as a diver (though not a BSAC member) any valid excuse to hang out with diving folk is welcome. “Club” suggests “amateur”, but I’ve been to plenty of IT industry events which were less professionally run. It was well attended too, and it’s quite some time since I’ve seen an audience so obviously enjoying what was being presented to them (even a potentially dull session on accident statistics was lightened with the some of the funny things people right when reporting accidents).

I’ve uploaded the slides I used. The main thrust of my session was that

  1. Putting data about your pictures in the pictures themselves (using EXIF data) is much more valuable than putting them in a separate database
    (One gentleman asked me if there was anything he could do about editors which drop all the data – I use EXIFCOPY from EXIFUTILS to copy it back from the original photo)

  2. Once tagged Search means you can find, sort, search and group the pictures. Search is available for XP, but  because is integrated everywhere in Windows Vista and 7 the experience is better: heir version of Windows explorer also makes it easy to tag pictures

  3. Some free software – Windows Live Photo Gallery (which also works on XP) makes it easier to work with  photos and do basic corrections (although it lacks a clone brush and the levels adjustment isn’t that sophisticated)

  4. There are interesting things you can do with the photos afterwards (e.g. building a collage with AutoCollage – which is running a 20% off promotion until the end of March. At £14.40 it’s a real bargain).

It seems the graphics card in my laptop has been on the blink for a couple of weeks – I’ve been getting loads of errors from my screen driver and some other odd behaviour – it finally gave up the ghost while I was on stage and when I try to boot the machine now I get some very interesting screen corruption. So I didn’t get to show the final collage. Here is what AutoCollage built with the pictures I showed (click for a bigger version)


Click for a bigger version


I showed my PowerShell scripts for tagging photos from the Suunto dive management software I use (Suunto were sponsoring the event, which was nice – I’ve got a very high opinion of Suunto, as much for their customer service as for their products and it would have been awkward if another make of dive computers was sponsoring things) . I talked about how this worked in an earlier post, and I’ve added  the latest versions of the files to this post for anyone who wants to try it. Here are some quick instructions:

  1. Try to remember to take a photo of the display on your dive computer at some point. This will allow you to calculate the error between the time on the camera and the time on the computer.

  2. Unzip the attached files

  3. Export the CSV files from the Suunto software  (in the 1.6 version I use* the command File/Export/ASCII in CSV format)

  4. Assuming you already have PowerShell installed, start PowerShell and enter the following command Run the following powershell command
    [reflection.assembly]::loadfile(“C:\<path To Where You Unzipped it >\OneImage.dll”)

  5. Then enter the following PowerShell command
    filter get-picture {param ($Path) new-object oneImage.exifimage $path}

  6. If you have a photo with of your computer use this powershell Command to find when it was taken
    (Get-picture “fullPathToYourPicutre“).dateTimeTaken
    You can work out the number of seconds difference between the time on the computer when the picture was taken and the time on the camera. If the Computer is ahead of the camera you want a positive number, and if it is behind you want a negative number.

  7. Next process the Suunto data with this command in powerShell
    <path to where you unzipped it>\prep-Divedata
    Note that if you are in the folder where you unzipped it, you need to enter the path as .\prep-divedata. This command takes about a minute to run on my system. If it looks like it has hung give it plenty of time.

  8. Read the warning in the right hand column of this blog – “This stuff is provided as is, with no warranty and confers no rights.” My code isn’t very extensively tested and there is a small chance it could screw up your photos. Make sure you have a backup before proceeding. Seriously.

  9. Now run the following command in powershell
    DIR <your file Selection> | foreach-object { <path to where you unzipped it>\tag-photo $_.fullName timeOffset}
    your file selection might be *.jpg, it might be c:\photo-Dump\dive40*.jpg, or whatever. As before if you are in the folder that holds the script you need to run it as .\tag-photo
    The timeOffset you worked out in step 6. If you don’t enter one everything will work on the assumption that computer and camera are in sync.


Officially there is no support for this (but officially I’m on leave and not posting here this week)


* Yes there is a newer version of dive manager, but I like to point out that 1.6 was designed to interface with the serial port, pre-dates Vista , never mind 7, and wasn’t intended for a 64 bit platform, yet here it is on Windows 7 , 64 bit downloading my data very nicely thank you. Which shows what happens if you write the software properly in the first place.

This post originally appeared on my technet blog.


Create a free website or blog at WordPress.com.

%d bloggers like this: