3
\$\begingroup\$

I have designed a circuit which powers a small microcontroller (50 mA max) by USB. The circuit (I hope) will allow a laptop or PC to occasionally attach to the microcontroller to download collected data. I have some questions on my design shown below:

  1. Do I need both diodes D1 and D2? Or Just D2?
  2. The microcontroller board will be continuously powered thru J1. Can I hot-plug a PC or laptop on J3 to occasionally monitor and download data?

\$\endgroup\$
  • 4
    \$\begingroup\$ If J1 is always providing power, why don't you just cut the Vcc1 for J3? \$\endgroup\$ – DKNguyen Jun 12 at 23:32
  • \$\begingroup\$ J1 from my experience also has a limited MTBF so redundancy is good. \$\endgroup\$ – Sunnyskyguy EE75 Jun 12 at 23:45
  • \$\begingroup\$ DKNguyen, I wasn't sure what problems might occur in cutting Vcc from J3. J1 provides power from a completely different source from a laptop or PC on J3. J3 is only occasionally used (a few minutes per day) some will be connected and disconnected mostly. \$\endgroup\$ – Doug12745 Jun 13 at 0:06
  • \$\begingroup\$ Sunnyskyguy EE75, J3 will be disconnected most of the time. The intent is to not require a dedicated PC just to provide power. \$\endgroup\$ – Doug12745 Jun 13 at 0:09
  • \$\begingroup\$ I'm beginning to think that D1 is not really needed, but D2 would block any current flow back into the PC. \$\endgroup\$ – Doug12745 Jun 13 at 0:10
4
\$\begingroup\$

Do I need both diodes D1 and D2? Or Just D2?

Even if D1 might not be necessary, I would retain both for protection of each individual circuit (If the device can tolerate the voltage drop caused by the diode). I, personally, would want D2 to ensure protection to my computer USB port.

Furthremore, since J1 will power the microcontroller continously and J3 is only occasionally used, I would argue that the VCC line of J3 need not be connected. This would imply that D1 and D2 are not necessary at all in this case!

Ensure that your common grounds are connected, and you should be good.

The microcontroller board will be continuously powered thru J1. Can I hot-plug a PC or laptop on J3 to occasionally monitor and download data?

Assuming J3 vcc is not connected, you should be fine.

If J3 VCC is connected, you might want a capacitor to ground just to filter out as much noise as possible on the VCC line that might be caused by plugging in another source.

\$\endgroup\$
  • 1
    \$\begingroup\$ Thanks for the idea of a cap on J3 Vcc. I am going to take the advice given in yours and others posts and eliminate J3 Vcc. The front-end of the uC circuit uses the FTDI recommended filtering (ferrite and 3 caps) so I don't think additional caps would be needed here but would be useful in other circumstances. \$\endgroup\$ – Doug12745 Jun 13 at 17:02
4
\$\begingroup\$

Depending on the supplies, cabling etc. it's quite possible that adding diodes to the USB 5V supply may well reduce the voltage enough to put it out of spec. And you don't need them anyway if J1 is always present as J3 has its own source of power. Hence:

enter image description here

\$\endgroup\$
  • \$\begingroup\$ Yes, J3 will always have Vcc sources as it is a PC/LTop. Removing Vcc from J3 eliminates the diodes and the 0.7V voltage drops. J1 will be the only source of power for the microcontroller, so when J1 power is removed, J3 is useless and just hangs there. \$\endgroup\$ – Doug12745 Jun 13 at 16:56
1
\$\begingroup\$

Below is the final design based on iput from responders:

enter image description here

\$\endgroup\$

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.