Toggle state between two circuits with two momentary switches

flipfloppower supplyswitches

I have two circuits each with their own 1.5v power supply. I would like to toggle state between the two circuits with a switch, so that hitting a momentary switch turns the light off on one and turns the light on on the other. I've been able to wire in the momentary switch on each circuit but I need them to toggle each other.

I've looked into flip-flops but I'm a bit lost and haven't been able to figure out the best way to connect the two independent circuits. No code, this needs to be done with discrete components.

Sorry if this is a stupid question, I'm still learning the basics. Thanks for any tips/pointers.

dual asic circuits

Best Answer

What you need to build is called a Bistable Multivibrator. Basically with a pulse as applied, the circuit will toggle from one state to the other.

With multivibrator circuits, you can have two output - one being the inversion of the other. With such an arrangement, you could then use something like an optocoupler to connect each output to one of the "black box" circuits.

Interestingly, this is exactly what a flip-flop is. If you get a D-type flip-flop with Q and !Q outputs, all you need to do is wire the D input to the !Q output, and connect your push button to the clock input. Finally you connect the Q an d !Q outputs to the two optocouplers which are then connected to your boards.

To improve things, you'll also need some debouncing on the push button to avoid multiple clock pulses. This can be done using an R-C circuit and a Schmitt trigger to generate a nice clock pulse from the push button.

I can draw up a circuit if that is easier to follow.