Hello, I am working on a development board, which will be connected to a power supply that feeds all the modules.
The problem is that the modules for which I am preparing the board exceed the power that a usb (and the internal regulator) can transfer, for which I want to implement a diode so that the current can flow from the source "MP1584EN" and the "ExP0" modules to the "WEMOS-D1-MINI-ESP32" MCU, but not vice versa, that is, if it is powered from the main source, the entire board receives voltage, but if it is powered from USB (programming) , only the MCU is powered.
I have found and tried a schematic (top schematic), which protects the MCU from polarity reversal, but how can I apply it to replace the "1n4001" diode in my diagram (bottom)?
The need to use a mosfet is the voltage drop, a normal diode subtracts between 0.4v and 0.7v, the supply voltage is 3.3, the problem is that one of the modules that I intend to use works at a minimum of 3v (both data and power), so I can NOT use a normal diode for this project.
Well, here I leave the exact diagram on which I base myself together with the url of the original page (in Spanish), the circuit works correctly, if you have any diagram that complies with what I say, please let me know, thanks
The IRF9530 is not being used to transmit any kind of signal, its only function is to allow the flow of current in a single direction.
Despite the fact that the board has an internal 3.3v regulator, the idea is to use the 3.3v power supply together with a filter for switched sources, thus having a single source with an efficiency of more than 90%
No, I can't use a dedicated source for that module, because I still have the problem of the logic signal, besides, the ExP0 port, among others, must be able to be used as a voltage input
Yes, I have taken it into account, but, it is still too much dropout, the closest I have seen, they had 500mA maximum current and a 0.25 dropout, which leaves only 0.05v of margin, Too close to the limit
no combination of diodes would allow the voltage of the set to be lowered, that is to say:
if they are put in series, the voltage drops are added and the current does not change, if they are put in parallel, the currents are added and the voltage drop does not change
(in theory, in practice, it is always worse)
Would it be possible to power everything from the normal power supply during programming, and not from USB? If so, that would seem to be the most direct solution.
I'm not sure I understand exactly what you need, but if you need to disconnect power to the downstream parts of the circuit, you could insert a P-channel mosfet into that line with a pulldown resistor from the gate to ground, so it would be on normally. But you would also connect USB power to the gate. So if USB is present, it would pull the gate high, turning off the mosfet. Of course you would need a logic level mosfet.
Except in case of a complete disaster, I think that the MP1584EN can take care of the reverse polarity "danger".
As for the other thing, a small normally closed relay powered by USB should work.
According to the datasheet for the D1 Mini ESP32, the 5V USB supply goes through diode D1 to connect to the 5V pin, and from there to the regulator. That means if you can find a way to solder a wire to D1, you can connect the wire to the gate of the mosfet. When USB is not connected, the gate pulldown resistor will turn on the mosfet, which will conduct in either direction. When USB is connected, the gate will be pulled high, turning off the mosfet, and the body diode will block any current flow back into the normal supply. But you will need a logic level mosfet.