Control Arduino with Canon Camera

Hey, my project intention is creating a camera slider for great timelapse videos.

On pretty much every page i found about controlling the slider with an Arduino, the camera is controlled by the Arduino (like here: http://openmoco.org/node/212).

The idea is now to do a reverse thing, let the camera control the Arduino and use the monitor of the camera to set it up. Also the synchronisation between camera and slider can be very precise this way (shutter events and stuff). The custom firmware on the camera is called Magic Lantern (http://magiclantern.wikia.com/) and is based on DryOs, as far as i got that right.

So I ordered an "Arduino Duemilanove" to create a pattern in Windows on how to control the motor for the slider.

First of all, is it possible to send those commands from the camera via USB to the Arduino?

Maybe there are some other people out here intresting in creating this...

Really glad for every answer I get :slight_smile:

Thank you,
subsonic

Hi,

It is certainly possible to interface the camera and Arduino via USB host shield. Potentially your sketch could watch for the appearance of an Object Created event returned from a CanonEOS::EventCheck which would indicate a photo was taken since the last time that command was responded to, there's more info here.

I don't know this will give you tighter control than having the external intervalometer control the body and rig, but it sure does sound like an interesting angle to investigate.

Have you found another way since posting this question?
Geoff

You didn't say what kind of camera you have. If it's a Canon DSLR I'm not sure how you'd get more precision by having the camera control the Arduino/slider instead of Arduino controlling the camera. When you press the shutter button it releases within 100ms. You need more precision than this? You can't take it any faster. If you want the slider and camera to sync within 1ms you simply anticipate this delay. I don't see why you need any communication from the camera. You have to assume it's focused when you half-press. You can assume it takes the picture when you full-press. Please explain what you're trying to accomplish. I participated in ML development, so I can answer any questions you have about that. I have created a slider and an interface to Bescor MP101.

Hey, thank you very much about your answers. The link was helpful to me!
Im owning a Canon 550D. Sorry for not writing this.

About the implementation idea:
Magic Lantern (the firmware on the camera) has a built in intervalometer function. Using this function with an extra for controlling the arduino. So after sending the shutterEvent, wait the seconds set for exposure plus some delay and then move the slider.

About the why question:
The Dollyshield is awesome, but it is not very cheap if you buy it as a complete thing. For the DIY-Kit you need some advanced knowledge in that stuff and equipment. If you got that done, you have no housing for the arduino and its shield, the display might be okay for setting those things up, but the camera display is much more comfortable and you get to use the D-Pad.
Im intrested in learning to program those things and thought this might me a great project.

Thanks for your great work on MagicLantern. It makes a Canon Camera so much better.

My Arduino still didn't arrive.. hopefully he comes this week.

The most burning question is, how can i send commands via USB to the Arduino in Magic Lantern?

Thank you very much for you help, i hope you understand why i like this idea.

What about this:

  1. Catch the shoot event by tapping the Flash Shoe
  2. Feed it to Arduino Interupt
  3. do (after some delay ?) the slider stepping on interupt

-bino-

You cannot easily modify ML to send specific commands by USB. If it was tethered to a PC you could intercept those signals. I don't think this is the way to go.

Binooetomo has a great idea. It is much simpler and will work.

I choose to move the slider at a constant speed. It can be very slow using a stepper motor. Even if the time lapse is an hour interval you can slow it down enough so it only moves a few cm. As long as it is mechanically smooth with a string to absorb the shock of the individual steps, you can expose up to about 1 second without blurring. In this case there is no need to get feedback from the camera to Arduino. You can still use the ML intervalometer.

Hi.
Great project!
I`m just in a similar project right now :slight_smile:

Ordered a bunch of hardware, but I'm still uncertain how to control it.

using a 550d with ml.

I'm a little bit afraid of frying my arduino if i connect it right to my hotshoe pc sync adapter, but i think these is the way i'm going.

Does somebody know how the pc signal is?
is it high/low or connection/no connection between those two wires...

and is the signal "high" all the time the curtain is open?

hope for good answers :slight_smile:

Well, the USB host shield claims to control Canon Cameras, I have no idea if it is compatible with ML:
http://www.circuitsathome.com/products-page/arduino-shields/usb-host-shield-2-0-for-arduino

Why do you need feedback from the camera? When you electrically press the shutter you know when it will take the picture exactly by trial and error, about 250ms later. If you are using the ML intervalometer, you can move the slider at the same time. Why would you want to use the USB host shield to control the camera if you are just pressing the button anyway? I have done this, and you can control more parameters. But why would you want to? I'm sure you have a reason, I'm just asking.

Well, I can tell why i would like some signal out from the camera.
I do not want to use the usb because of complexity, but a pc sync cable (used to trigger remote flash on cord.)

and with the magic lantern, i can use a timelapsefunction, which can calculate so the movie would be nice and smooth exposures when taking pictures of a sunset.
these do increase the shuttertime after a while.

and therefor i would like to have a signal from the camera when telling its don taking pictures, or the whole time its taking a pict. :slight_smile:

but that seams complicated, and i guess i loose the magic lantern functionality that creates smooth video :stuck_out_tongue:

Found out some few nice information for my setup now... :smiley:

The trigger pin on the canon flash is 5 volt to ground.

i guess the camera hot shoe is optoisolated from the camera sinse there is never a voltage on the shoe. only resistance (4-5 ohm)

So, i connected my camera to the arduino, and found out that the shoe is "high" all the time the camera takes a picture.

And that's good news :smiley:

These could be used as a bussy signal to the arduino :slight_smile:

and what the arduino do when low... well, that's up to me :slight_smile:

Hope these information is nice to know for more than just me.

Wow thanks for all the input!

The idea with the Flash Shoe is great, with your information about the "all time 5V while taking picture" the problem really is pretty much solved.
Sadly my Hardware still didn't arrive.. crap!

Maybe some one can still explain to me, why is it complicated to send out information via USB - what has to be done to get that working?

ehem, my mistake...

Not all time 5v. it is all time connected while taking pict :slight_smile:
It works like a switch :slight_smile:

So you need to feed it with you own voltage, or ground.

I am working on the same problem, while creating a intervalometer with an arduino is pretty straight forward, the functionality of the bulb ramping of Magic Lantern is worth letting the camera control the slider. I'm using a belt drive stepper motor to move my slider and this seems to produce some vibration, so I'm going to use the ML bulb ramping function to do a Move Shoot Move arrangement. This will minimize image blur since the shutter is only open when the camera is stationary. Does anyone have a pin out of the hot shoe for a Canon EOS 60d? Are you sure the pin-outs are optoisolated from the camera. I don't care that much about my Arduino board as long as it doesn't kill my camera.

VeroMartin:
I am working on the same problem, while creating a intervalometer with an arduino is pretty straight forward, the functionality of the bulb ramping of Magic Lantern is worth letting the camera control the slider. I'm using a belt drive stepper motor to move my slider and this seems to produce some vibration, so I'm going to use the ML bulb ramping function to do a Move Shoot Move arrangement. This will minimize image blur since the shutter is only open when the camera is stationary. Does anyone have a pin out of the hot shoe for a Canon EOS 60d? Are you sure the pin-outs are optoisolated from the camera. I don't care that much about my Arduino board as long as it doesn't kill my camera.

I'm so confidence on my measurements as I can be.
I am going to use the 5 volt on center pin, and shorted to ground as a "hold" signal.
100% NO. but confidence enough to try it on my 550d, YES :slight_smile:

I have a TF-326 Flash Hot Shoe to PC Sync Adapter for CANON, and going to use it to an analog input on the arduino, had some problems when it was connected on a digital pin on my test rig (it could not sense the "open" circuit. so it only got one "hold" when camera was triggered.)

I got my stand alone arduino and a usb programmer a while ago, but i cant make the usb programmer do its work, so i have ordered a standard uno, which i steal the ship from, and use the arduino board as a programmer instead :slight_smile:

I hope you manage to do what you want it to, and please feel free to ask.
I'm sorry for late updates, just finished school, and been trolling for a decent work lately, but these Monday, MAGIC :smiley: I got a job :slight_smile:
I think we are on the same page on these project :slight_smile:

interesting project here. I think I will keep an eye out for the 7D version of magic lantern!

I'm building a shoot move shoot rig. When using the hotshoe's busy signal i notice a considerable delay after releasing the shutter button. i hooked up the gnd and +5v directly to the arduino. Any thoughts anyone?

Bottom line in display says: 'Camera shutter open'. You can hear the shutter and see the delay.

Going back many months... There is no need for the camera to control the Arduino. Yes, the Bulb ramp function in ML is cool. I know, because I helped write it! But it is trivial to do the same thing in C using manual shutter mode instead. Again, the data only needs to go one way, from Arduino to camera. Yes, there is a delay. You can calculate it experimentally, it is constant. Then anticipate it in the code.

I take it back, you cannot write the Bulb ramp code on the arduino without access to the exposure data. But there is no need for it if you set the exposure correctly. You only need exposure data to determine how long the shutter is open. You can make some maximum assumptions to avoid knowing this.

Or just ignore it completely! Assuming an exposure of less than 20 seconds, just move the slider slowly without synching.

I appreciate your input but i am not looking for another way to make my project work. I want it working my way. I'm a little stubborn... guilty! :wink:

When i set up the camera in manual mode, imho it should not be necessary to copy the shutter time setting to the camera by hand.

The way i want my rig to work:

  1. Arduino tels canon to take a picture
  2. Canon tels arduino the shutter closed (picture taken)
  3. Arduino tels dc motor to start turning
  4. CNY70 encoder on pulley tels arduino how far pulley has turned
  5. Arduino tels dc motor to stop turning
  6. Arduino tels canon to take a picture
  7. Canon tels arduino the shutter closed (picture taken)
  8. ... you see where this is going don't you :wink:

Only thing that needs to be set up in the arduino is the number of pictures and the total duration of the process. Arduino should calculate how far to turn the pulley after each shot and how long the delay should be between shots. If the delay is constant i could do a few initialisation shots before starting the actual sequence so the arduino can determine the shutter speed. Or is the delay the same for every Canon? 60D?

Bulb ramping is fase 2. Haven't given it much thought... well actually i have but can't seem to figure out how to set it up in ML. :smiley: LRTimelapse holy grail workflow is working for me.