Please help me bridge two pins to make a trigger for a light

Hello everyone.

I'm trying to turn on a light with my iPhone by using my Arduino board and the C2-TTL cable that I just got. The issue is the desktop light has it's own circuit board and controller that it uses for motion detection, so I took it apart and found the 2 wires needed to complete the switch and turn the light on. The light turns on when I touch these 2 wires together and turns off when you touch the wires together a second time. So my goal is simple, just touch 2 wires together for a split second.

I already made a simple circuit that is using Arduino to send a 'high' signal out of pin 7 and trips a relay to connect the 2 leads when the Arduino board receives the signal from my iPhone app that I made. The relay acts as my switch to turn the light on/off by completing the circuit, but now I want to completely remove the relay from the equation and only use Arduino to connect the two wires digitally. I figured I need to set 1 pin to an input for one of the leads and another pin to an output for the other lead, then just tell Arduino to bridge the connection and take input 1 and connect it to output 2 to send the signal to the light's control board to turn on. But I'm not sure how to put the sketch together to take one pin's input and send it out of another pin's output.

How would I write the sketch to do this? Can anyone help me out with the code? It sounds easy but I can't find much on this topic so any help would be greatly appreciated.

Thanks!!

rhaleluk: Hello everyone.

I'm trying to turn on a light with my iPhone by using my Arduino board and the C2-TTL cable that I just got. The issue is the desktop light has it's own circuit board and controller that it uses for motion detection, so I took it apart and found the 2 wires needed to complete the switch and turn the light on. The light turns on when I touch these 2 wires together and turns off when you touch the wires together a second time. So my goal is simple, just touch 2 wires together for a split second.

I already made a simple circuit that is using Arduino to send a 'high' signal out of pin 7 and trips a relay to connect the 2 leads when the Arduino board receives the signal from my iPhone app that I made. The relay acts as my switch to turn the light on/off by completing the circuit, but now I want to completely remove the relay from the equation and only use Arduino to connect the two wires digitally. I figured I need to set 1 pin to an input for one of the leads and another pin to an output for the other lead, then just tell Arduino to bridge the connection and take input 1 and connect it to output 2 to send the signal to the light's control board to turn on. But I'm not sure how to put the sketch together to take one pin's input and send it out of another pin's output.

How would I write the sketch to do this? Can anyone help me out with the code? It sounds easy but I can't find much on this topic so any help would be greatly appreciated.

Thanks!!

You're better off isolating the circuitry using the relay, any particular reason for not using it?

Do you know what the voltage is across these lines, or what the current draw is when shorted?

I want to do away with the relay because I was just using that to cheat at first to prove the concept, now I want to take my project to the next step and do away with the relay altogether so I can make the connection happen instantly. I'm hacking up a desktop lamp to sync it with my camera on my Mac, except I replaced the light bar with a xenon strobe to come on when I take a picture. I have the whole thing working already and I've been using my iPhone to trigger it to test it, but the relay isn't fast enough it seems. I tried to compensate for the delay but I think the issue is the relay since it's mechanical.

I'm not sure of the voltage or current draw on this trigger. Can I set 1 lead as an analog input and then just read that value and send it to another pin as an output? I don't want to try this without knowing the result because I don't want to burn the board out or damage the light's controller either, so I'm reluctant to just plug it up and try it.

Essentially, I just need to touch 2 wires together at a precise time to trigger the light when the camera shutter opens on my mac. I think it'll be easier for me to get the syncing done if the whole process is being controlled digitally with a precise delay that can be programmed on the arduino side. With a relay, the delay seems to have 2-3ms of latency that changes because the coil in the relay is mechanical.

Any help would be great.. I was trying to have this done already but I've been hung up on this one last part.

rhaleluk: Can I set 1 lead as an analog input and then just read that value and send it to another pin as an output?

You would need to tie the grounds together for the devices. In that case, you may as well just use a simple switching transistor. You'd still need to know the voltage/current requirements in order to do that, though.

Ok.. Now I'm really not sure if this is possible. Keep in mind I'm hacking up multiple devices to try to make all this work. The 2 leads that I'm trying to use as my trigger wires are from the flash strobe that I took apart, connecting these 2 wires triggers the flash to fire. I was hoping Arduino board can handle this action for me so I can time it to work precisely when the camera shutter fires.

I just tested the 2 trigger leads with my meter and it seems these leads are coming directly from the capacitor because they have 320v power and ground on them. It seems like it's a direct short, power to ground, and when you short the two the flash strobe fires, then it recharges again.

Would it be even possible to handle that much voltage? I was thinking this wire was like a ground lead and when it sees the ground, then it fires.

A thyristor could do the job. An Arduino cannot handle that voltage. A high voltage MOSFET might also handle it. Either way, you would be better off driving the switching element with a low voltage transistor, to protect the Arduino.

rhaleluk: I want to do away with the relay because I was just using that to cheat at first to prove the concept, now I want to take my project to the next step and do away with the relay altogether so I can make the connection happen instantly. I'm hacking up a desktop lamp to sync it with my camera on my Mac, except I replaced the light bar with a xenon strobe to come on when I take a picture. I have the whole thing working already and I've been using my iPhone to trigger it to test it, but the relay isn't fast enough it seems. I tried to compensate for the delay but I think the issue is the relay since it's mechanical.

Now the problem is becoming a little bit clearer.

How much time do you have after your Mac starts taking the picture, to trigger the flash?

And what processing, networking sending/receiving and so on has to happen to get from the initial trigger to the final hardware output that controls the flash? Without knowing your overall system I can only guess, but my guess is the timing is not feasible.

That is what my concern was.. Whether or not it's even feasible.

The relay can do the trick to get it working - but the timing would essentially be impossible because there is too many variables between my Mac and the flash.

Ok.. I figured this was going to be the case. Thanks!