Right Hand, meet Left Hand

I am trying desperately not to use the word “stupid”, especially in conjunction with intensifiers such as “incredibly”, “unbelievably” or “predictably”.

My delightful spouse got me a new camera for christmas this year. It’s waterproof, shockproof and a bunch of other neat things. And it has wifi. So when I made some cool modifications to my printrbot, I took some pictures. And more pictures of the improved things I printed.

Then I wanted to transfer those pictures to my mac for editing, and like an idiot I thought I would do it with the camera’s built-in wifi. Well, no. First, the camera doesn’t connect to other wifi networks; it sets up its own custom network. You’re supposed to download an app to your smartphone and use it to join the custom network by scanning a QR code displayed on the camera’s screen and then download the pictures. The huge clunky desktop app supplied with the camera has never heard of wifi. It has no interest in wifi. It will work only if you pull out the SD card (shortening the life of the waterproof seal on the battery compartment) and put it in a readier, or plug in the fragile custom USB connector (shortening the life of the waterproof seal on the connector compartment).

Because it would be way too much to expect the desktop-software division of a big camera company to talk to the camera division about new features in the camera and how to support them. So my apparent only wireless option was to transfer the photos to my phone by app and thence by bluetooth or dropbox or pony express to the desktop. Um.

I did some searching, and I found out that when you join the custom network the camera is at 192.168.0.10, and that it has builtin webserver that you can reach from your desktop to look at thumbnails, and to look at or download the images one by one using the browser’s save function. But nothing about the protocol that the smartphone apps use.

A little further down the same thread, and hurrah! Same smart person has figured out a way to use *n*x command-line tools to lie to the camera’s web server and request all the files in the image directories.

Wonderful, but it doesn’t work. I go back to the camera in my browser and notice that one of the directory names is different from the one used by this guy’s camera. Try again, and bingo. Now I can crop my pictures and upload them. Maybe soon I’ll even write a script to, say, make a new directory each time labeled by date, or even to handle the wifi connection automatically.

And for those of you who have an Olympus TG-4 and haven’t already figured this out for yourselves, here is the incantation to connect to your camera from your computer and grab all the pictures (into the current directory, so be careful):

wget -q -O - http://192.168.0.10/DCIM/107OLYMP | awk -F\" '/wlansd\[[0-9]/ {print "http://192.168.0.10" $2}' | sed -E 's/(.*(JPG|MOV|AVI))(.+)/\1/' | sed 's/,/\//' | xargs wget

UPDATE: I am probably wrong about the number in the directory name. The SD card I was using was previously used in a different camera, and the *OLYMP directory is numbered one higher than the directory for the other camera’s photos. So you may have to browse to find the right number for yours.

This entry was posted in probably boring, things that don't work and tagged , . Bookmark the permalink.

Leave a Reply

Fill in your details below or click an icon to log in:

WordPress.com Logo

You are commenting using your WordPress.com account. Log Out / Change )

Twitter picture

You are commenting using your Twitter account. Log Out / Change )

Facebook photo

You are commenting using your Facebook account. Log Out / Change )

Google+ photo

You are commenting using your Google+ account. Log Out / Change )

Connecting to %s