6
\$\begingroup\$

I have been trying to work out a circuit something like the following:

schematic

simulate this circuit – Schematic created using CircuitLab

I want VOUT to be 3V when the switch is open and 5V when the switch is closed. The simulation seems to give me what I want when the switch is open, but not when it's closed. What am I doing wrong? Is there a better way to do this? I was avoiding a common cathode diode pair to avoid the forward voltage drop.

\$\endgroup\$
  • \$\begingroup\$ Are you limited in the switch you are using? a single pole dual throw switch would easily swap between the two supplies \$\endgroup\$ – Gorloth Apr 21 '13 at 5:28
  • \$\begingroup\$ @Gorloth... the switch exists for the purposes of simulation only. It's meant to simulate the attaching and detatching of 5V power from the circuit. I don't want a mechanical switch ultimately. \$\endgroup\$ – vicatcu Apr 21 '13 at 5:40
  • \$\begingroup\$ what exactly is it doing when the switch is closed? what's the voltage at vout? \$\endgroup\$ – Gorloth Apr 21 '13 at 5:50
  • \$\begingroup\$ @Gorloth when the switch is closed VOUT should be 5V, when the switch is open VOUT should be 3V. \$\endgroup\$ – vicatcu Apr 21 '13 at 7:04
  • \$\begingroup\$ YOu say the desired behaviour of 3v or 5v at vout, but you also say when simulated it does not work when the switch is closed, but you specify how it's not working, if you are getting a vout that is ~3.6v then sounds liek a body diode issue that Brian mentions in his answer below \$\endgroup\$ – Gorloth Apr 21 '13 at 19:06
3
\$\begingroup\$

I came up with the following circuit that does what you ask:

Rail Switcher

5 volts from the "SWITCH" source will turn on M1 and M2, connecting the 3 volt rail to the load, and pulling current out of the right hand transistor of the differential pair Q3 and Q4. This turns off Q2 and shuts down the 5 volt rail. When Q1 turns off by applying 0 volts to "SWITCH", Q4 is biased on by the voltage divider comprised of R7 and R8, which turns on Q2 and the 5 volt rail. R2 then pulls up the gates of M2 and M1, shutting the 3 volt rail off. The arrangement of M1 and M2 prevents conduction from the 5 volt rail into the 3 volt rail when the 5 volt rail is connected.

In a real circuit there should probably be stopper resistors on the MOSFET gates.

Another way, in response to the "too many components" criticism:

comparator switch

If you don't want to use discretes, you can do it with a cross-coupled dual comparator. One IC and 4 resistors, plus the switches.

\$\endgroup\$
  • \$\begingroup\$ that is a crapload of components... \$\endgroup\$ – vicatcu Apr 22 '13 at 14:43
  • \$\begingroup\$ circuit in the update is more pallatable :) \$\endgroup\$ – vicatcu Apr 24 '13 at 19:29
1
\$\begingroup\$

Measure currents around the 3V MOSFET M2 when the switch is closed. I have a feeling that 5V on its drain is forward biassing the body diode and limiting VOUT to 3.6V (or some value dictated by M6's ON resistance. You may need a pair of MOSFETs there, in series, (usually with their sources connected together) to provide isolation in both directions.

(Edit: add schematic) Remember this is speculation, I haven't tested it : but the basic idea is this

schematic

simulate this circuit – Schematic created using CircuitLab

When on, (SW4 open) both transistors M2,M7 conduct.

When off, both transistors are off; their body diodes conduct in opposite directions, so neither conducts.

But I would welcome correction or improvements to the design

\$\endgroup\$
  • \$\begingroup\$ could you show what you're describing in a schematic? \$\endgroup\$ – vicatcu Apr 21 '13 at 19:18
  • \$\begingroup\$ I get VOUT = 1.372V in your circuit when SW4 is open.... \$\endgroup\$ – vicatcu Apr 21 '13 at 19:48
  • \$\begingroup\$ Count my circuit as a fail then. But you still haven't described what happens in the original circuit when SW4 is closed. \$\endgroup\$ – Brian Drummond Apr 21 '13 at 20:00
  • \$\begingroup\$ SW4 closed => VOUT = 4.375V, SW4 open => VOUT = 1.987V \$\endgroup\$ – vicatcu Apr 22 '13 at 14:50

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.