connecting two devices to the same 5V power pin

March 23, 2023, 09:22

Johann

I'm unsing the raspberry pi 4 model B for a project and we need to power two 5V servos, 1 ultra sonic sensor, 1 soil moisture sensor and also a control device for a stepper motor. the pi has two 5V and two 3,3V pins but we need 1 more. Thats why I wanted to ask if it's possible to power something from the above with the same pin?

andy_s

you should never power high-load devices through pi.

andy_s

for example servo

andy_s

let alone several.

Johann

oh I've got that out of a totorial so I thought it might be ok

Johann

what would be high load?

andy_s

as long as it provides necessary voltage for them and you connect grounds and you make sure no parasitic voltage feeds through pwm input from servo to pi

andy_s

then of course 🙂

Johann

like this:

andy_s

servos need stabilised voltage of 5V iirc.

andy_s

also 6V for that driver is not sufficient.

andy_s

and you definitely cannot use simple resistor.

andy_s

What?

andy_s

Do you use a laptop to power your fridge?

andy_s

Well, how do you power that pi?

Johann

via usb c from my laptop

andy_s

Say whatnow?

andy_s

Pi that needs >1A powered from laptop that delivers <500mA?

Johann

yeah at the moment, we are doing this so we can work with it: https://howchoo.com/pi/raspberry-pi-gadget-mode

andy_s

work with it?

andy_s

the what ?

Johann

open its directory in a terminal on the laptop and write and start python scripts

andy_s

that's what SSH is for

Johann

yeah we don't have wifi where we are working

andy_s

yes you do

andy_s

your laptop does have wifi

andy_s

so does pi

andy_s

so does your phone

Johann

well it's our university wifi where you have to log in with your student account every time

Johann

and then we found that totorial and gave it a try

andy_s

so? why do you care about other's wifi networks?

andy_s

it's like owning a car and complaining you have to steal keys from neighbor to use his car

andy_s

or rather than "steal keys" i should've used "sign a waiver"

Johann

yeah we didn't really look into it, after it worked via usb we were just happy that it works but we wanted to try connecting via wifi anyway it the next days

Johann

and connect the pi to a bench power supply

andy_s

well

andy_s

since you have bench psu

andy_s

why don't you power all of it off of it?

Johann

🤔

andy_s

you only need higher voltage for stepper motor

Johann

yeah taht would be a good idea

andy_s

it would, wouldn't it...

andy_s

or any proper 5V PSU with enough amps

andy_s

and by proper i mean stabilised.

andy_s

voltage must not deviate based on power

andy_s

or just get a DC-DC converter with 5V output

andy_s

that contains BMS as well so it cuts off when battery voltage gets too low (based on battery specs)

andy_s

aka step down with battery protection

andy_s

commonly found in many powerbanks

Johann

would it be easier?

andy_s

of course.

andy_s

or second output of bench psu

Johann

alright then, I'll try that, ty for your help