How would i set up an Arduino to do time lapse photography?
I did this by splicing into my Canon's remote shutter release (it has 3 conductors, so I used an 1/8" stereo headphone jack as the connector). That way I can put the ends back together and use it like normal, or I can plug it into an arduino and control it digitally. I drive it by connecting a digital output from the arduino to the base of a transistor (the other two connectors on the transistor went to ground and another of the conductors from the cable). You'll have to experiment with your cable to find what works on your particular camera model. If I'd had an optoisolator it would have made sense to use that instead of the transistor.
After that, it's a matter of figuring out how to sleep your arduino. You can start with a basic call to delay(). For truly long runs you may wish to use the watchdog timer or a RTC to the system.
- You want to keep the button "pressed" for just long enough to trip the shutter - 100ms is probably good.
- Turn off auto-focus. Set your lens on manual focus, otherwise you'll get unpredictable results. In low light you may not get anything at all.
- Alternatively, set the camera to single exposure mode and leave the button down except for a short period before each new exposure. You won't know when the exposure goes off each time, but you'll have a good chance of getting one some time while you have it down.
Google for "arduino intervalometer". The triggering method depends on what kind of camera you have. Most (hopefully all) dSLRs have external remotes, and most of those are electronic, so you can drive an optoisolator from the Arduino to make the shutter connection. Canon's consumer line of dSLRs (like the Rebel XT) have an IR remote, so you could use an IR LED to send the shutter command. Failing either of those, you could always use a servo to press the button.
I had written a little while back a detailed guide to implementing one's first arduino intervalometer. The link is here: Arduino Intervalometer Basics
The difference between this and other examples, is that it provides not only the standard "pinmode, delay, pinmode"-style control, but also introduces the reader to non-blocking timing concepts, and discusses the benefits and drawbacks of each programming method. In addition, it walks the reader through a series of tests to make sure they understand the concept well before they try to hook up the camera.
Of course, no one can tell you how to control your camera, unless you tell us what kind of camera you are using. But, in most cases, it is pretty simple.
Then, once you really get into it, check out the whole openmoco project, which does a lot more than just interval shooting. =)
If you're using a compact canon camera, try using chdk. This project provides hacked firmware for many different models and allows for things like time lapse control. It's not an Arduino, but it will get the job done.
There is a great example of Arduino motion tiggered camera
It uses a PIR (Pyroelectric InfraRed) sensor to switch the camera on when the motion is detected.