servo motor init pos set problem

Hi,
I'm practicing constrained translational arm mechanism with Arduino and servo, and when I turn on the system, servo as usual first take a fast path to initial position to set its zero. This gives an ugly movement from the start. I don't know how to force it to at least do this in a smooth movement, slowly, and not to jump every time I turn it on :slight_smile:

Any idea please? Well sure it is possible to go to dc motor and PWM but that needs to add h-bridge, while a servo is directly commanded by Arduino - cheaper.

Unless the arm ends up in the same position every time it is powered down, then this behaviour is unavoidable for ordinary servos. A more advanced motor/encoder which allows the software to know the current position would be needed - standard servos can only be commanded not read.

If I got your point, that means that I must have a kind of turn-off-procedure that after turn-off command sets the arm to the position it's going to start from next time. If the system is shut down accidentally, jump will happen again, now how to totally avoid it please?

So I'd better use a stepper motor and couple it with a an encoder. Could you please leave some links to your favorite encoders you found people implemented on Arduino projects (from scratch) that you accept them as 'reliable' ones?

A little bit of work, but you can tap off of the pot wiper in the servo to get a voltage value relative to the position of the servo.

http://www.lynxmotion.net/viewtopic.php?f=2&t=2748

Thank you, nice post on Lynxmotion, I also have 2 ssc-32 controllers.

In summary, I think that it is easier to go with a dc, get the h-bridge out of some L293, an encoder and voila!

Thanks again!

In summary, I think that it is easier to go with a dc, get the h-bridge out of some L293, an encoder and voila!

If the system accidently shuts down, how will an encoder know the current position? You could put small pots at the arm joints to read the current position.

An encoder will still need some inializing/homing code, which you will need to do with the stepper motor anyway. Make sure the stepper motor/gearbox has enough torque for the rest of your mechanism and don't bother with the encoder.

Well, then stepper motors, but with pots for that accidental shut down, right?