A question about VIN+VUSB conflict without diode protection ...

The official PYBD running MicroPython, and its accessories.
Target audience: Users with a PYBD
Post Reply
kesterlester
Posts: 23
Joined: Sat Nov 17, 2018 10:04 pm

A question about VIN+VUSB conflict without diode protection ...

Post by kesterlester » Sat Aug 22, 2020 11:49 am

Among the options for powering the D-series boards which are mentioned on the standard reference page are two I want to highlight:
  1. Providing 3.2V-4.8V on VIN.
  2. Powering over the Micro USB connector,
I intend (intended?) to use an encapsulated 3.3V power supply to power a D-series (mounted as a daughter board within a larger project) via VIN connector on the wbus as per method "1." above, and my project PCB (already made) is now designed around that principle.

At an earlier stage in the design process (see also this other thread) I was weighting up the pros and cons of using a 3.3v vs 5V power. In the end various considerations pushed me toward 3.3V so I omitted from my design a diode that I would otherwise have used to drop the 5V down to 4.8V or below as required in option 1. above.

However yesterday, I double checked the documentation and realised, to my horror, that I'd earlier failed to spot the following warning there:
If there is a chance that the USB port (or VUSB) will provide power as well as VIN, then VIN should be protected with a diode (eg Schottky diode or a FET reverse protector).
Hmm. It certainly is/was my intention to have the D-series powered primarily via VIN when deployed, but periodically connected via the USB for maintenance, viewing debug output, reflashing, firmware changes, etc.

Does this mean that my design, because it lacks a diode at the output of my 3.3V psu is borked? I.e. I will likely fry something if I plug in the USB at the same time as there is power coming at 3.3V on VIN?

I don't think I can add a diode between the 3.3V PSU and VIN since even a 0.15V diode drop (which I don't think is realistic at high-ish power currents) will take the VIN down to 3.15V which is already below the minimum recommended for powering by option 1. even if some people report success at powering at lower voltages. Likewise, I can't use the VBAT route as that's already in use for RTC timing backup purposes.

My question, therefore, is what is really my worst concern if I plug in a USB cable while having my 3.3V PSU attached to VIN without a diode? Is it damage to the PS I should worry about, or damage to the Pyboard-D, or damage to something else?

EDIT: Added after original posting:
Perhaps a solution lies within the "FET reverse protector"s mentioned in the docs, though I currently am ignorant about how to use there. I see some well written explanations here: https://www.maximintegrated.com/en/desi ... 6/636.html however they seem to indicate only very complicated solutions when using power supplies in the 3.3V range. The simple solutions on that page are only for 10V power supplied and above, I think?

User avatar
pythoncoder
Posts: 5956
Joined: Fri Jul 18, 2014 8:01 am
Location: UK
Contact:

Re: A question about VIN+VUSB conflict without diode protection ...

Post by pythoncoder » Sat Aug 22, 2020 4:30 pm

On the Pyboard D schematics the USB 5V supply Vusb is connected to Vin via a Schottky diode and a fuse. It will therefore apply nearly 5V to your 3.3V supply, which should be designed to be capable of accepting this without sinking significant current.

On a similar note, I don't know if you use the WBUS-DIP28 adaptor. If so, beware that the pin labelled Vin is actually an output.
Peter Hinch
Index to my micropython libraries.

Post Reply