I've chosen a 11 minutes limit because the 5D video recording length is actually limited by the 4 GB file size limit of the FAT32 file system that the Compact Flash cards use. By using 11 minutes I make sure to stay below this file size limit so the camera is always controlled by the external device.
The current video DSLRs from Canon don't support video recording control over a remote cable. The only way to do that works via the built in infrared receiver e.g. when the camera is in Live View mode the 2-seconds-delay setting of the Canon RC-1 remote starts and stops video recording.
Thanks to very helpful info at doc-diy.net I was able to program an Arduino board to send the required IR signals for starting and stopping video recording. For Arduino board suppliers see arduino.cc/en/Main/Buy.
The IR signal code is quite straight forward. The delay between two IR bursts determines if the camera takes a picture immediately or with 2 seconds delay. If it is in Live View mode the 2 seconds delay setting records video.


You also need an infrared LED, a 180 ohms resistor and a switch. Any standard IR-LED from any electronics supplier will do. Connect one end of the resistor to digital pin 12 and the other to the longer lead (anode) of the IR-LED. Connect the shorter lead (cathode) to "GND". Finally wire a switch that shorts digital pin 7 to "GND" when activated.

Connect the Arduino board to your computer via USB cable and load the code below on the Arduino.
/*
Arduino sketch for simulating a Canon RC-1 IR remote control to start and stop video recording on a Canon 5D Mark II or 7D
2010, Martin Koch
http://controlyourcamera.blogspot.com/
Huge thanks go to http://www.doc-diy.net/photo/rc-1_hacked/index.php for figuring out the IR code.
*/
#define irLED 12
#define SWITCH 7
unsigned int pulseDuration = 10; //microseconds
//The required 15 microseconds pulseDuration didn't work since digitalWrite consumes some additional time
//thats adds to pulseDuration value. 10 to 12 microseconds worked for me.
unsigned int photo = 7330; //A 7330 microseconds delay between bursts shoots a photo.
unsigned int video = 5360; //A 5360 microseconds delay between bursts starts/stops video recording.
void setup() {
pinMode(irLED, OUTPUT);
pinMode(SWITCH, INPUT);
digitalWrite(SWITCH, HIGH); //turn on internal 20 k pullup resistor so the open input state is HIGH.
}
void loop() { //run again and again
if (digitalRead(SWITCH) == LOW) { //read switch input
shoot(video); //start video recording
delay(660000); //record for 11 min * 60 s * 1000 ms
shoot(video); //stop video recording
delay(1000); //1 s delay between stop and start of next clip
}
}
void shoot(unsigned int delayBetweenBursts) { //sends the IR signal
//send first 16 bursts
for(int i=0; i<16; i++) {
digitalWrite(irLED, HIGH);
delayMicroseconds(pulseDuration);
digitalWrite(irLED, LOW);
delayMicroseconds(pulseDuration);
}
delayMicroseconds(delayBetweenBursts);
//send second 16 bursts
for(int i=0; i<16; i++) {
digitalWrite(irLED, HIGH);
delayMicroseconds(pulseDuration);
digitalWrite(irLED, LOW);
delayMicroseconds(pulseDuration);
}
return;
}
After the upload has completed you can test the program. Enable the IR receiver on the 5D Mark II using the AF-DRIVE button and the large wheel on the back. Turn on Live View. Aim the IR LED at the camera and flip the start switch to start the continuously repeating 11 minutes video recording.
Note that the function depends on a light path. To avoid any interruption I recommend that you mount the IR-LED very close to the IR receiver of the camera.
For standalone operation disconnect the USB cable and connect the VIN and GND terminals of the Arduino board to a 7-12 V DC power source (e.g. a 9 V block battery as shown in the diagram above or a DC adapter).
A typical 9 V battery has a capacity of roughly 500 mAh. This should allow for about 25 hours operation of the Arduino interface assuming an average current consumption of 20 mA.
The photo above shows my first try with the IR-LED connected directly to digital pin 13 without any resistor. It works but the recommended way is to use a current limiting resistor on any digital output when using a LED. I used this LED calculator to get the resistor value of 180 ohms.
For a more compact package take a look at the Arduino Nano.
I recommend the book Getting Started with Arduino.
29 comments: