I have a camera that has OSD (on screen display settings) which are set by pushbuttons shorting to ground. There are some voltages at the top end of the switches, nominally 2-3.9 volts.
I want to remote control these with an Arduino Nano.
I can either short the switch contacts over with relay contacts or put a 1k or 10k resistor accross the contacts and the menu's function. So I thought all I needed was an arduino output pin with a 1k resistor, and make the Arduino pin go low. Also of course having a common ground. But it does not work.
I am using this test code to make the pin 12 go low. Any ideas?
There is a good chance that the camera either scans the buttons and/or uses a resistor in series with the voltage at the top end of the switches, so a 1K resistor (or any resistor) is unlikely to work.
Relay contacts would be a better solution if no further information is available. However, the Arduino will need a relay shield (easy but $$), or you could use reed relays with low current coils (less than 40 mA) with a diode across the coil to prevent voltage spikes (harder but cheaper). Note that the low current coils must operate with the output voltages (high and low) provided by the Arduino.
pinMode(12, OUTPUT);
pinMode(12, HIGH); // <-- this isn't right!!
pinMode mode may be INPUT, OUTPUT, or INPUT_PULLUP
digitalWrite(pin, HIGH ) is valid.
Your loop only turns the pin LOW. How will you see anything happening?
Maybe you want to try toggling LOW, then HIGH, and repeat and see if that does anything.
Also, if you see voltage on the top of the switch contacts, why do you not think it's possible that the voltage needs to go through the contacts and SUPPLY a voltage to the control?
Indeed, a relay is the way to go when interfacing to an unknown device to simulate (replicate) switch contacts.
Thanks both. Unfortunately I know nothiing about the camera circuitry, and was trying to avoid having to use relays.
Thanks for pointing out the Pinmode error, however the output does eventually go low. Physically holding a button down all the time brings up a menu page which stays there until you push another button, so if things had worked I would have seen the menu come up.
I did come across another method a while back using opto couplers so I will look around to try and find it again.
I thought by putting a resistor across the switch there was a chance to have used a pin output via 1k resistor to isolate the two a bit, but removing the resistor still did not short the switch. But thanks again both
Perhaps a Low Rds, Logic Level, N-channel MOSFET would do the trick. I've used them to trigger camera flashes which needed a low on the trigger pin.
AOI508 for example, drive the gate High thru a 200 ohm resistor, with a 10K to Gnd to hold it low during Arduino resets.
Many thanks |Crossroads, good idea. Won't get bits until after Christmas, but worth waiting to try. Shame a transistor could not be used accross the switch, got plenty of those. Have a good Christmas and New Year Regards