I am attempting to interface my Nikon D90 DSLR with an Arduino using the Arduino for focus/trigger. I have a cable that i took the trigger end apart, and found that there is no real electronics... just switches. There are three wires involved. Yellow, White, and Red
When you connect the yellow and white, it focuses the camera. It appears that there is 5 volts DC between yellow and white (yellow being the positive side). There is 1 mA of current draw between the two.
In order to take a picture, yellow and white must remain connected and then connected to the red wire. Between the yellow/white combination and the red wire, there is 5 volts DC (with the red side being the positive side). There is also 1 mA of current draw between the yellow/white and the red.
With this, it appears like it operates like the following.
Camera not active:
Yellow = +5v
White = gnd
short the +5v and gnd and the camera focuses
Camera Focused:
Yellow+white = gnd
red = +5v
short the +5v and gnd and the camera takes a picture
What i don't know is this... due to the fact that the camera has its own power source, and the arduino has its own power source, i don't know if i need some sort of isolation circut between the two powers (since it doesn't have a common power source/common ground).
I know i could use some sort of a relay on the ardino end to drive the camera end as the load of the relay, but i would prefer some mechanism that is smaller and faster/more reliable.
I am up for suggestions... can i use a transistor to switch it somehow? Would i need some sort of a opto-isolator IC? would a transistor or mosfet be required? I am using it for high speed photography, so the faster the switching circuitry the better (one of the reasons i don't want to rely on a mechanical relay).
First, reed relays can be very small, reasonably fast (switching times <10ms), and can be rated for hundreds of thousands of contact closures. I don't know if that's high-speed enough for you. Here's an example:
Second, yes, you can use a transistor. You could use an opto-isolator too. Simplest is to just try a general purpose transistor like a 2N3904 or 2N2222 (base terminal through 1k resistor to Arduino pin, emitter to white, collector to yellow). If that doesn't work it means the camera is fussy and might need a MOSFET to get closer to gnd.
I'm just beginning to try and learn electronic circuits... so in the case of using a transistor would i need to connect the two grounds together (between the camera and the arduino) to get a common ground?
Then put the camera positive on the collector, the common ground on the emitter, and the arduino trigger on the base?
thanks for the info. i forgot about the resistor for the base. so there are no issues putting the two grounds together to make a common ground? are there any components i need to put in for protection between the two ground supplies?
im posting from my phone right now, but i will post schematics on my design later for review and to be help for anyone else that may gain some benefit from it.
There shouldn't be any issues connecting the grounds together, the camera being battery powered, but frankly if I'm hooking up a >$700 piece of equipment to some electronics I'm going to be as careful as possible
For the sorts of speeds DSLRs work at, reed relays are perfectly adequate.
I built an intervalometer for mine using them, and measured the relay lag at less than 2ms.