Electronic – Switch between power supplies with a MOSFET

mosfetpower supplyswitches

I'm new here and my knowledge in electronics is basic, so what I'm trying to do is to switch between two power sources, one at 5V an other at 12V, I already made a circuit that kinda works, but I have to use a diode on the 5V source to lower the real voltage and I don't want that. Is there any way to do that without draining the 5V source?

It would be no problem if the draining would be on the 12V source.
Circuit

L.E Looks like that I was wrong, the 3V source does nothing there, I've tried other configurations and I've got nothing, seems that the easiest way to do it is with a relay.

enter image description here

Also I'll try using a Schottky diode as @gbulmer told me in the comment.

Best Answer

The problem with your +3V source is that it is ground referenced.

A MOSFET turns on based on a voltage differential between its Gate and Source pins. If you have access to a 15V supply, that'd turn on the FET if its datasheet calls for 3V Vgs.

You can use a schottky diode to prevent a voltage drop in the +5V rail.

If you're using a physical switch on the 3V, why don't you just use that switch on the 12V with a schottky?