0
$\begingroup$

So I started building this 3D printed Bluetooth robotic arm that can be controlled via MIT app inventor from HowToMechatronics.com. After connecting all the servos and running the code, the servos seem to be jittering and doesn't follow the orders from the app. I have tried to increases the voltage from the external power supply and have also tested each servo individually but the outcome however was the same. Please do let me know if you have any suggestions or advice regarding this issue, I would be happy to try them out.

The setup I have, is approximately the following: enter image description here

This is the link for the codes: https://github.com/darren-noyce/RoboticArm.git

If someone could help me to understand what's wrong, I would greatly appreciate it. Thanks.

$\endgroup$
8
  • 1
    $\begingroup$ There is an Arduino example in the IDE that controls a servo. Start with that and get 1 servo working. Then add more servos. When that works, add input from the Serial console to control servo positions using manual data input. Then add the bluetooth module. If you have problems, start simple and build out. It's harder to debug a complex program like the one you link to. $\endgroup$
    – jkp
    Jun 14 at 10:18
  • $\begingroup$ Also, try using a separate power supply for the servos. The problem might be that they draw too much power, which will drop the voltage and reset the Arduino. $\endgroup$
    – jkp
    Jun 14 at 10:20
  • $\begingroup$ I did ran the servos individually then add more servos but when I got to adding the third servo, the servos just doesn't move at all anymore, not even jittering. I also did try both connecting it to a external power supply and powering it through the Arduino board. The results simply was the same. $\endgroup$
    – darren
    Jun 14 at 10:58
  • $\begingroup$ So 2 servos work, but 3 doesn't? Take the code for 3 servos, but only attach two of them. The arduino will not know the difference, it will just emit it's control signal. If it moves the two remaining servos, your code is working and the problem is power. If not, the problem is in the code. Don't increase voltage. Most hobby servos are 6V. Increase Amperes instead. $\endgroup$
    – jkp
    Jun 15 at 7:30
  • $\begingroup$ ok so i just ran the code and three servos were moving accordingly ,but when i add a fourth servo and ran the codes, the fourth servo only move for a while and then stopped moving. $\endgroup$
    – darren
    Jun 15 at 8:09
1
$\begingroup$

I have working with multiple servo for serial manipulator control. I recommend this following step to troubleshoot :

  1. Make sure u gave it the right voltage

Read the datasheet and make sure your power source match with datasheet

  1. Make sure u gave the right control signal

Read again the datasheet, what period of your servo control system.

  1. Give more power

I see you try to increase the voltage to power your servo. DON'T! Do not give it more voltage than it stated at datasheet (I burnt 3 servos lol). Give your servo with same voltage but more amperage. In my case I use 5v 2 Amp and it didnt move. But when i change to 5v 10 Amp it work perfectly fine.

  1. Since u ever increase voltage, check if your servo still working, maybe it already broken.

Hope that help

$\endgroup$
1
$\begingroup$

Servo motors draw a lot of current. A 9-gram micro servo is the only servo you can drive off of an Arduino, and that means barely loading it. You will definitely need a separate power source for your servos. Remember, the arduino can only deliver 100 milliamps, so you should avoid using Arduino power sources as much as possible. You also need ot make sure that the voltage on the servos is correct. I see 3 larger servos and 3 smaller servos. Are they all really 5 volt servos? I would guess that the larger servos are 7.2 or 9 or 12 volt servos. No matter how you slice it, you need to redo your power supply setup before continuing further. I concur with other users: you should start small and then add more as you go. If 1 or 2 servos work, but more don't work, it probably has to do with your power requirements.

EDIT:

Given your comment with the servo code, and your arduino pin choice, I suggest you look at a pinout diagram. Given your code, you are using non-pwm pins to drive servos. That is a mistake. Use PWM pins only.

$\endgroup$
2
  • $\begingroup$ Currently I'm trying to get only 3 micro servos moving by connecting it to an external dc power supply, even after increasing the voltage, the servos still show no signs of movement at all. The servos I'm using are the SG90 mirco servos. Here is the link for the codes I'm using: github.com/darren-noyce/experiment-4/blob/… $\endgroup$
    – darren
    Jun 15 at 3:21
  • $\begingroup$ I also forgot to mention that you are not using curly braces {} in your for loops. You need to create a basic minimal example of your servo controlling code. Not to be rude, but your starting code is garbage. I suggest you research how the servo library works. The servo control function call is a non-blocking call, so it will return whether the servo gets to its destination or not. You should also do more research into C++/C software development as it appears you don't have a lot of experience with Arduino (looking at your code). $\endgroup$ Jun 15 at 12:53
0
$\begingroup$

Since 1 servo at a time works, can you try 2 at time, then 3 at a time, and so on?

There is also a chance that you are seeing either noise or cross talk between the servo channels.

$\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.