Two identical servos, different pulse width?

Hello all,

I've just started playing with my (newish) Arduino, and have come up against my first issue, hence my first post :slight_smile:

I am ultimately looking to use the Arduino for a third year CS project (a bike computer) but at the moment I'm just trying to fiddle around with some servos.

I have two identical Futaba S3003 'standard' servos, connected to two output pins on the Arduino. They are currently being controlled by the 'MultipleServos' sketch which I nabbed from principialabs.com, and Python chatting to the Arduino via serial.

I don't have much experience with electronics, so please excuse my ignorance (Google and myself are well acquainted :D), but with this Arduino sketch, the MIN and MAX pulses are hard coded. So, if you connect more than one servo, they use the same pulse range. I thought this would be fine as I am using two identical servos. But, for one of them, the default range (MIN = 600, MAX = 2400) is fine, whilst for the other, it isn't.

The python code works by sending a servo ID and movement value (0-180) over the serial, which is converted to a pin number and pulse width. With one of the servos all values appear to work flawlessly. With the other, any value above 177 causes the servo to vibrate, presumably because it is vainly trying to push itself past its maximum movement range.

What is the best solution to this problem? Is is just to reduce the pulse range, and lose some degree of movement on the working servo? Or are my min/max pulse values wrong? Perhaps the working servo is not quite moving to its full extent in one direction? I tried looking for a Futaba S3003 datasheet without success.

Is it usual for identical servos to behave differently like this? I assume the movement range cannot be altered, so are my only options to reduce pulse width/change min/max values/limit movement values to [0-177]?

Cheers, any help is much appreciated. I hope I can soon be contributing something worthwhile instead of asking rambling questions!

Thom

// EDIT

I have found the datasheet, but this does not include any values regarding pulse timings. I guess there are approximate 'standard' values across most servos? I'll have a play with changing the pule widths to some other values suggested by various hobby sites.

// EDIT 2

By changing the MIN to 500 and MAX to 2300 things seem to be working OK, but there appears to be slightly shy of 180 degrees movement... am I missing something here? Or is it usual to get 'approximately' 180 degrees of movement?
Thanks

Inexpensive servos of the type you are using are manufactured with fairly wide tolerances, so what you are seeing is not surprising. I think you will need to use trial and error to find min and max values for each that gets the movement as close as possible without either servo binding (being driven outside its working range). The manufacturers of that servo don't guarantee you will get 180 degrees so don't be too disappointed if you dont

OK thanks, I thought that might be the case. Sorry for the slightly obvious question, but I want to be sure of all these things before I move on to more complicated applications.

Cheers!

Thom

Thom, no need to apologize. I re-read my reply and it may have come across as unintentionally flip. Best of luck with your project.

Not at all! It's just I am used to contributing to other 'n00bs' on linux fora etc., so I do try to do my research before asking the experts; in this case I could have done a little more reading first :smiley:

I'm sure I'll be asking some more questions about this project in the near future. I'm off to find an ultrasonic rangefinder to continue my tinkering - I need to learn as much as I can before the dreaded real world job starts eating my time!

The reply wasn't flippant - it was just what I needed.

Cheers,
Thom