Monday, November 30, 2015

Interval shooting

We had a 32h smoking (like BBQ) session and I wanted to take a picture every 30 seconds.

With the Olympus Air it was quite easy with a shell script (linux or mac) running on a notebook, connected over WiFi:

#!/bin/bash

# switch cam to rec mode (out of standalone)
curl -v --header 'Host: 192.168.0.10' --header 'User-Agent: OlympusCameraKit' "http://192.168.0.10/switch_cameramode.cgi?mode=rec&lvqty=1280x960"
sleep 1

# enable liveview (necessary to take pictures for some reason) 
curl -v --header 'Host: 192.168.0.10' --header 'User-Agent: OlympusCameraKit' "http://192.168.0.10/exec_takemisc.cgi?com=startliveview&port=5555"
sleep 1

# loop to take a picture, then wait 30 seconds
while [ 1 ]: do
 curl -v --header 'Host: 192.168.0.10' --header 'User-Agent: OlympusCameraKit' http://192.168.0.10/exec_takemotion.cgi?com=newstarttake
 sleep 30
done

That worked for 24h, then the camera refused to take photos. After a reboot everything worked again. 


1 comment:

  1. Hello, Peter!
    I stumbled upon this post while trying to find a way to control my Olympus TG Tracker action camera. I was able to retrieve a XML file with camera commands and tried to figure out a few with variable success, due to my poor coding experience and ability. Although the commands are somewhat straightforward, I lack the proper understanding of the XML sintax to make a better use of them.
    My goal is, just like yours, to create a simple intervalometer for the camera, since it lacks this function.
    I hope you can help me out with this project, since it would be useful on my work.
    Thank you!

    ReplyDelete