Hi, i have a question about powering servos with the same powersupply as the arduino. Where the servos Vin and GND is connected directly to the powersupply, and so is the arduino (See image). Is this the right way of doing it?
That should work fine provide you really have a "battery" with an output that NEVER exceeds 5v.
I don't recall seeing 5v batteries anywhere. What exactly have you got?
If you have a battery pack with a regulated 5v output (for example as a USB charger) I would be concerned if it would produce enough current for the servo.
...R
Oh yeah.
It is not a battery but a powersupply so it should not exceed 5v and have enough current.
I was more worried if this configuration would encounter any problems when the servos move, maybe the voltage would drop under 5v for a split second, and make the arduino reset.
But thanks for the answer.
mikkelcv:
maybe the voltage would drop under 5v for a split second, and make the arduino reset.
That could certainly happen if the power supply cannot provide enough amps. The usual advice is to allow 1 amp per servo.
By the way, why did you say you were using a battery when you are not?
...R