Lego dolly time lapse

A couple of days ago I made a short time lapse video.
I used a Nikon D80 camera with 18mm zoom lens and an Arduino for the timing and displacement work. On Nikon cameras it’s really easy to remote control them with a wire or ir signals.

Here are some pictures I took of the contraption.

Lego pull mechanism with camera cart in the background

Some technical Lego came in handy as a camera cart and pull mechanism. To get a reliable and constant displacement there is a transmission that slows the movement of motor. A tiny thread is wound round the final axis. This thread pulls the cart and camera a small distance before each photo is taken.

Overview of the Lego/Arduino camera trigger & displacement

The motor is powered by a power adapter delivering approximately 4V. A transistor switches the load on and off.

Close up of the breadboard and components.

A small ir-led is wired up to trigger the camera via the Nikon remote protocol.

On Lucky Larry there is some useful code I used for the ir triggering.
To this code I added some functions for a displacement motor so you can do tracking shots.
Here is the Arduino code:

LUCKYLARRY.CO.UK - IR Remote control for Nikon using Arduino
Mimics the infrared signal to trigger the remote for any Nikon camera
which can use the ML-L1 and ML-L3 remotes. Can be used as an intervalometer
for time lapse photography.
The IR sequence I used is originally taken from:
You should be able to use my pulse methods to alter to suit other cameras/ hardware.
micros() is an Arduino function that calls the time in Microseconds since your program
first ran. Arduino doesn't reliably work with microseconds so we work our timings by
taking the current reading and then adding our delay on to the end of it rather than rely
on the in built timer.
Added displacement function to make tracking shots possible. There is also an option
to trigger the camera with serial input from the computer
int pinIRLED = 13; // assign the Infrared emitter/ diode to pin 13
int motorpin = 12;
int motoron = 1000; //ms
int photodelay = 20000; //ms
int movementdelay = 1000; //ms
boolean serial = 0; // choose 1 if you want to trigger the photo with the serial interface.

void setup() {
pinMode(pinIRLED, OUTPUT); // set the pin as an output
pinMode(motorpin, OUTPUT);
if (serial){Serial.begin(9600);}
// sets the pulse of the IR signal.
void pulseON(int pulseTime) {
unsigned long endPulse = micros() + pulseTime; // create the microseconds to pulse for
while( micros() < endPulse) {
digitalWrite(pinIRLED, HIGH); // turn IR on
delayMicroseconds(13); // half the clock cycle for 38Khz (26.32×10-6s) - e.g. the 'on' part of our wave
digitalWrite(pinIRLED, LOW); // turn IR off
delayMicroseconds(13); // delay for the other half of the cycle to generate wave/ oscillation
void pulseOFF(unsigned long startDelay) {
unsigned long endDelay = micros() + startDelay; // create the microseconds to delay for
while(micros() < endDelay);
void takePicture() {
for (int i=0; i < 2; i++) {
pulseON(2000); // pulse for 2000 uS (Microseconds)
pulseOFF(27850); // turn pulse off for 27850 us
pulseON(390); // and so on
} // loop the signal twice.

// Turn the motor for "motoron" milliseconds
void displace(){
digitalWrite(motorpin, HIGH);
digitalWrite(motorpin, LOW);

void loop() {
//check if serial triggering is on
if ( != -1) {
//Auto triggering: first runs the motor, then waits for the motor/movement to stop,
// and then takes a picture and sits out the interval.

Things that can be improved:
– Make a camera cart with less friction.
– Use a thread which doesn’t stretch. With this thread a displacement step can stretch the thread instead of moving the cart.
– Solder all the electronic connections for improved reliability.
– Install a flyback diode to prevent voltages from building up due to motor movement.

This is the final result:

It’s interesting how the lower clouds flow in a different direction then the higher clouds.

Now I have to find an interesting time lapse subject!

This entry was posted in Arduino and tagged , , . Bookmark the permalink.

2 Responses to Lego dolly time lapse

  1. Pingback: Two-axis panning time lapse rig built from Lego | You've been blogged!

  2. Hey Jochem, congratz want je staat op!

Leave a Reply

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

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

Google+ photo

You are commenting using your Google+ 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 )

Connecting to %s