Maybe you can change your requirement. For example, instead of a toggle, use a momentary push for on and a long push for off. That might be easier and might lend itself more readily to an op-amp circuit.
Maybe you can change your requirement. For example, instead of a toggle, use a momentary push for on and a long push for off. That might be easier and might lend itself more readily to an op-amp circuit.
So your intent is that the Arduino only turns the circuit off? I don't think the opto as drawn can turn it on.
That is a good point. Of course by design intent the Arduino won't be able to turn the circuit on; it won't be active. Maybe an FET output opto-isolator?
You never said the Arduino is powered by this power source. If so, the Arduino doesn't need isolation. A simple transistor can ground the gate of X2, turning it, and the entire power unit off. Optoisolators are more expensive than transistors, buy a good margin... not to mention smaller.
Have something to add? Share your thoughts — no account required.
Ask the community — no account required