Saturday, 28 February 2009

Shannon's Box

Claude Shannon, father of information theory, apparently once invented a box whose sole purpose was to, when switched on, turn itself off again. Recently I've got into scripting with CHDK (Canon Hackers Development Kit) - a firmware enhancement for Canon cameras. It allows you to turn your cheap point-and-shoot camera into something better, for free. Long exposures, very rapid shots, motion detection - you name it. I can tell I'm at the start of a beautiful friendship ... look at this!

You can write and upload scripts to automate processes. The language is uBASIC - really intuitive and easy. My first script is pretty basic - it has been to tell the camera to, when switched on, automatically take 3 photos and then turn itself off! I therefore called it Shannon's Box:

 rem Author Daniel Buscombe  
@title Shannon's Box
@param a Shoot Count
@default a 3
shoot full
for n=2 to a
shoot full
if n=a then goto "shutdown"
next n

More, I'm sure, on CHDK in the following months.

No comments: