Tell me more ×
Electrical Engineering Stack Exchange is a question and answer site for electronics and electrical engineering professionals, students, and enthusiasts. It's 100% free, no registration required.

I'm creating a board which takes an external power source to drive motors which are controlled by a ULN2003A connected to the Raspberry Pi GPIO.

It would be nice if when the external power source is connected it could provide power to the Raspberry Pi itself through the 5V GPIO pin.

I appreciate this would require a voltage regulator, a polyfuse (to replace the one I'm bypassing that would normally protect the Micro B USB power input) and an ultrafast rectifier for reverse polarity protection.

My question is whether or not it is possible to detect that the Pi is already powered through USB and therefore block the back powering feature (to avoid having two sources connected).

Ideally if the user were to yank the Micro B USB cable the back powering would just kick in and take over. And likewise if the Micro B USB cable we re-inserted to disable it again. I don't really see how that could be possible so maybe it isn't!

share|improve this question
add comment (requires an account with 50 reputation)

1 Answer

It seems that what you are attempting is quite similar to what is implemented in the Arduino. See e.g. Arduino Uno's schematics. It requires a few external component (a MOSFET to serve as a switch, a diode, etc). to be implemented. I'm not familiar enough with the Raspberry Pi, so I dont know if this scheme could be implemented without modifying the board.

share|improve this answer
The Arduino actually implements the opposite of what is asked in the question: In the Arduino, the higher voltage source is used, so when an external 6-12 Volt supply is connected, it no longer draws from the USB, even if the USB remains connected. – Anindo Ghosh Jun 19 at 10:09
add comment (requires an account with 50 reputation)

Your Answer

 
discard

By posting your answer, you agree to the privacy policy and terms of service.

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