i am trying to switch a 12v current on and off using a 4n25 optocoupler.
12v are hooked up to the collector - but when i turn on the diode - the emitter will only give me around 5 volts. i tried switching power supplies, even gave it 24v, which resulted in a 7v output from the emitter...
i have a digital pin connected to a 220ohm resistor to the anode, cathode goes to arduino ground.
i don't think the resistor between the arduino and the 4n25 is too big, the led should light up nicely... so where is all my current going?
The maximum collector current of a 4N25 is 50ma so you aren't going to get much out of it.
What are you trying to connect it to on the output side? A circuit diagram would be nice.
Well it is better. However if you have an 8R load then you are going to be shipping a fair bit of current into the amplifier.
You can try that but you are likely to get a bit of voltage drop with that arrangement. Measure the voltage at pin 6 with a meter when you turn it on.
I would also have a large capacitor of > 100uF across the supply of that amplifier.
I would go for a PNP transistor sourcing current properly.