Hacking

Canon Camera Hacking With CHDK

This short and somewhat boring clip is the result of playing around with CHDK (Canon Hack Development Kit). I’m working on a stop-motion animation for Tinysaur, but sadly neither of my cameras (a Canon Digital Rebel XT and a Canon SD1100IS Point and Shoot) had a built in timer that would shoot over and over indefinitely. Using the CHDK Ultra Intervalometer script I set my camera to take a shot every .5 seconds. Although it didn’t quite go that fast… I’ll get to that in a bit.

CHDK is a firmware add-on for Canon point and shoot cameras that lets you control absolutely every aspect of the shot. It loads from your SD card at boot, so it’s non-permanent (although you can set it to auto load). It gives you access to a plethora of fine tuning options and display monitors, and also lets you run scripts to take pictures based on time, motion detection, etc. But the most exciting thing I found is that there’s a script which will let you trigger the camera with a hacked USB cord with a switch.

img_0149Mine is shown on the left, it’s not very pretty. I spliced a reset switch into the +5v (red) wire. It uses a USB port for power, which makes it a little silly, although ok for my uses. Ideally you’d rig up a power supply along with the switch. I would have but I only had AA battery holders and it needs between 3.5V and 5V of juice. There are some neat hacks listed on the CHDK wiki for making remote cables out of old joysticks and flashlights and whatnot.

There’s a ton of documentation, but it’s a bit scattered around the CHDK wiki. Here’s what I did to get the Ultra Intervalometer script up and running. The instructions are almost identical for the USB remote script:

Getting CHDK going:

  • Grab a spare SD card and format it. If it’s >2 gig and you think you’ll want to auto boot CHDK, format it as FAT16 (‘format X: /fs:fat’ from the comand line). Leave it in your machine’s SD reader (which, by the way, you need for this).
  • Make sure you have a CHDK compatible camera. My SD1100 works well with it (and without it, for that matter), apparently the latest version of that camera (SD1200) doesn’t yet have a version of CHDK for it. CHDK isn’t available for SLR cameras.
  • Check your camera’s firmware version. Create a blank file called ver.req on the SD card. Put the card in your camera. Make sure the camera is set to playback mode and turn it on. Press “Func Set” and “Disp” at the same time. A screen with the firmware version should pop up.
  • Download the appropriate version of CHDK. Unzip it onto your SD card.
  • While not necessary to get CHDK running, now is a good time to stick the Ultra Intervalometer script on the card, so you don’t have to take it out to do it later. Copy the script code and save it as something like ‘ult_interval.bas’ in the SCRIPTS subdirectory on the SD card.
  • Pop the SD card in your camera.
  • Make sure your camera is set to playback and turn it on. Hit ‘Menu’ and scroll down, you should see an option to update the firmware. Do it!
  • When you update the firmware, the ‘print’ button will blink for a bit, strange things will happen, and you should see the CHDK splash screen. Hooray!

Now you can use the ‘print’ button to switch between the normal boring Canon menus / normal shooting and “<ALT>” mode, which brings up a totally different list of options when you press the Menu button, and triggers a script when you press the shutter release rather than taking a picture.

Using Ultra Intervalometer

  • Make sure you’re in <ALT> mode
  • Press Menu and scroll down to Script Parameters
  • Select “Load script from file” and select ultra_interval.bas or whatever you called the script.
  • Set the script parameters (those under the heading Ultra Intervalometer) to your whim. Use left/right to increase or decrease parameter values.
    • Delay 1st Shot (mins) – this is the time between when you start the script and the first shot, in minutes
    • Delay 1st Shot (secs) – As above, but seconds
    • Number of Shots – how many to take
    • Interval (minutes) – number of minutes between shots
    • Interval (seconds) – number of seconds between shots
    • Inerval (10th seconds) – as above, with 10ths of seconds
  • Exit out of the menu (by hitting menu)
  • Press the shutter to start the script. The camera will fire at the interval you chose, hooray! Press the shutter again if you want to stop the script before it finishes.

When I set the interval to 1 second I noticed that the camera wasn’t actually shooting that often. The ‘review’ period, where it shows you waht you just took, seemed to be getting in the way. I exited out of <ALT> mode and was able to set the review time to 0 seconds in the camera’s normal menu. I also turned off AF-Zoom. It still takes a little bit of time to auto focus between each shot,  I haven’t dug through enough of the CHDK documentation to find out how to only focus at the start of the sequence.

Here’s a short (ok, still boring) clip of my walk from NYC Resistor down the street, in search of some tacos:

6 thoughts on “Canon Camera Hacking With CHDK”

  1. I installed CHDK on my Canon recently S3 IS recently as well. I love that it adds RAW support to that camera, and all the bracketing possibilities. What I’m really waiting for though is a lightning storm so I can try out the scripts that are supposed to be quick enough to capture lightning automagically.

  2. I thought the SD1100 already has a timelapse feature. Why do you need to use CHDK’s intervalometer?

    Do a search on Youtube for SD1100 and timelapse.

    1. In reply to you, Joe (albeit a little late). SD1100IS shoots at only 1″ or 2″ intervals AND the quality is minimized to create a video directly on the camera. With an intervalometer, one can take high res images (and in raw) as to make a higher definition video at set intervals (seconds, fractions of and minutes)

  3. Thank you! Your instructions on how to load CHDK on SD1100 IS makes so much more sense than the ones in the site itself. It was too technical for me but I wanted to give it a try. Here goes. 🙂

    I’ve used the timelapse that’s already on the SD1100. Seems to work fine.

  4. Did you work out how to speed up the shutter? I have a PowerShot SX200IS and I havent yet got it firing quicker than one shot every 2-3 seconds.

Leave a Reply

Your email address will not be published. Required fields are marked *