I have an electromagnet and a 12V power supply. I would like to apply +12V to the electromagnet at some times and -12V at other times.
My current thought is to use four transistors (two NPN, two PNP) in a matrix (see diagram). I have two concerns:
- When all four transistors are open, the "inside" leads will be floating. Is this a problem? If so, would a pulldown resistor on the "inside" sides mitigate it?
- Using two transistors (one each side) would be cheaper and take up less space, but I can't figure out a way to do it (even with diodes) that doesn't short out the power supply. Is there an easy way to do this (besides adding a second -12V supply)?
Thanks!