I recently bought a TowerPro SG-5010 servo and when I send it a signal, it doesn't move and it makes a faint clicking/ticking noise. I'm using a 5v power source and a Trinket m0 for the signal, and I had no problem controlling a micro servo I bought with exactly the same setup. I'm pretty new to microcontrollers so it's possible I'm missing something obvious, but as far as I can tell the motor is defective. Anyone have any ideas?
Thanks
Servo not moving
Moderators: adafruit_support_bill, adafruit
Please be positive and constructive with your questions and comments.
- adafruit_support_carter
- Posts: 29168
- Joined: Tue Nov 29, 2016 2:45 pm
Re: Servo not moving
Hobby servos are generally 5V, so using with 3V can be hit or miss. Do you have a 5V device you could test with? Like an Arduino UNO?
- insert_generic_username_here
- Posts: 8
- Joined: Mon Oct 16, 2017 5:05 pm
Re: Servo not moving
I'm only using 3V for the signal, the power is connected to a separate 5V source (and the ground of the Trinket is connected to the ground of the 5v source). That should be okay, shouldn't it?adafruit_support_carter wrote:Hobby servos are generally 5V, so using with 3V can be hit or miss. Do you have a 5V device you could test with? Like an Arduino UNO?
- adafruit_support_carter
- Posts: 29168
- Joined: Tue Nov 29, 2016 2:45 pm
Re: Servo not moving
That's the hit or miss part. With the control signal level only being 3V, the servo might not be getting the info it needs.That should be okay, shouldn't it?
There's a chance this could be a software or other hardware issue. Post a photo of your setup showing all connections and the full code your are using.
- insert_generic_username_here
- Posts: 8
- Joined: Mon Oct 16, 2017 5:05 pm
Re: Servo not moving
Here's a photo (obviously, the Pi and battery pack are actually connected when in use): http://imgur.com/a/X0pl9adafruit_support_carter wrote:Post a photo of your setup showing all connections and the full code your are using.
The code is just wiringpi typed into the Pi's bash:
Code: Select all
gpio -g mode 18 pwm
gpio pwm-ms
gpio pwmc 192
gpio pwmr 2000
gpio -g pwm 18 100 (or whatever)
- adafruit_support_carter
- Posts: 29168
- Joined: Tue Nov 29, 2016 2:45 pm
Re: Servo not moving
I thought you were working with a Trinket? Did you get the servo to work on the Trinket before moving to the Pi? Or are you just trying the Pi as a second option?
- insert_generic_username_here
- Posts: 8
- Joined: Mon Oct 16, 2017 5:05 pm
Re: Servo not moving
Sorry I forgot to mention that part, but I tried a RPi and got the exact same result--the micro servo worked fine but the larger one just makes a faint ticking noise. I don't have a 5v board on hand but I have an Arduino Nano coming in the mail tomorrow, so I'll give that a try and report back. There's nothing obviously wrong with my current setup, though, is there?
- adafruit_support_carter
- Posts: 29168
- Joined: Tue Nov 29, 2016 2:45 pm
Re: Servo not moving
Nothing obvious, no. Let's see what you get with the Arduino Nano.
- insert_generic_username_here
- Posts: 8
- Joined: Mon Oct 16, 2017 5:05 pm
Re: Servo not moving
Okay, so I tried it out with a 5v Arduino Nano, and I got the exact same results: small servo works fine, big servo doesn't move.
- adafruit_support_carter
- Posts: 29168
- Joined: Tue Nov 29, 2016 2:45 pm
Re: Servo not moving
OK. This should be a good test setup. Still not sure why the one servo isn't working though. Post a photo of your setup showing all connections.
- insert_generic_username_here
- Posts: 8
- Joined: Mon Oct 16, 2017 5:05 pm
Re: Servo not moving
Here: https://imgur.com/a/TldbM. I'm pretty sure the setup is okay because, like I said, my other servo works fine.
[EDIT: inlining image for reference]
[EDIT: inlining image for reference]
- adafruit_support_carter
- Posts: 29168
- Joined: Tue Nov 29, 2016 2:45 pm
Re: Servo not moving
OK, now that we are in Arduino land, what sketch are you using to run the servo?
- adafruit_support_bill
- Posts: 88093
- Joined: Sat Feb 07, 2009 10:11 am
Re: Servo not moving
Also, if you un-plug the servo, are you able to turn it by hand (there will be some resistance, but you should be able to turn it by hand)
- insert_generic_username_here
- Posts: 8
- Joined: Mon Oct 16, 2017 5:05 pm
Re: Servo not moving
Yeah, I can turn the motor by hand.
I tried both of the example servo sketches that come in the IDE.
I tried both of the example servo sketches that come in the IDE.
- adafruit_support_bill
- Posts: 88093
- Joined: Sat Feb 07, 2009 10:11 am
Re: Servo not moving
Sounds like probably a bad connection or defective board in the servo. If you contact [email protected] with a link to this thread we can send a replacement.
Please be positive and constructive with your questions and comments.