Saibaba
Posts: 2
Joined: Thu Jan 18, 2018 9:48 am

Current through gpio pins

Thu Jan 18, 2018 10:40 am

<t>Hello, <br/>
If anyone is there , please help me with this. <br/>
I want to use 5 nano servo motors (hs-35hd whose current ratings are 60- 300mA, 300ma at full load conditons) at GPIO pins and a voice recognizer for 4 hours. Can I use a normal 7.4v 10000mah battery for this purpose. <br/>
My doubt is , whether these motors at gpio pins are able work for 4 hours or not .Becoz as far as i know the gpio pins can give 16mA max.</t>

User avatar
joan
Posts: 14073
Joined: Thu Jul 05, 2012 5:09 pm
Location: UK

Re: Current through gpio pins

Thu Jan 18, 2018 11:16 am

Those servos are rated for 4.8 volts. Feeding them 7.4 volts would shorten their life considerably, perhaps destroying them immediately if the internal circuit board is not designed to work at that voltage.

Get a UBEC or similar to drop the voltage of the battery to 5V.

You could then drive the servos (and the Pi if you want) from the 5V output of the UBEC.

The servos take three inputs, +ve, -ve, and control signal. Connect the +ve and -ve to the UBEC output. Connect the control signal to a Pi GPIO. Also connect the UBEC -ve (ground) to a Pi ground.

User avatar
rurwin
Forum Moderator
Forum Moderator
Posts: 4258
Joined: Mon Jan 09, 2012 3:16 pm
Contact: Website

Re: Current through gpio pins

Thu Jan 18, 2018 11:21 am

The control pins of servo motors do not take a huge amount of current. The current draw specified for the servos is for the motor itself which doesn't come from the GPIO I/O pins and so doesn't count in the 16mA limit.
You would probably be able to connect the servos to a Pi3's GPIO pins and power them through the Pi, but that's a maximum of 1.5A and a noisy signal with possible back-EMF. It's not a great idea; it could crash or even break the Pi.

A pi can certainly control one micro servo directly from the GPIO pins -- I've done it -- but I don't know what the maximum number of servos would be. I cannot find anywhere that says how much current a servo requires on its control pin, but I found one place (https://www.pololu.com/blog/17/servo-co ... -in-detail) that recommends 220 ohms in series as protection. That would suggest a maximum current of 5/220 = 23mA but I imagine the minimum is much lower than that. The only way to find out appears to be to test it. You would have to measure the voltage drop over that resistor using a dual-channel oscilloscope.

As for the power supply, it needs lower than 7.4V. Ideal would be 5V. At the very least the servos and Pi should be connected to the supply individually and you may need to have two separate supplies for the servos and the Pi. (In which case you join just the grounds together.)

Read that link though; there's a lot of useful information there.

Saibaba
Posts: 2
Joined: Thu Jan 18, 2018 9:48 am

Re: Current through gpio pins

Thu Jan 18, 2018 1:34 pm

Thank you

Return to “Beginners”