servo motor swivel rate

17 views
Skip to first unread message

Bill Carter

unread,
Jan 17, 2015, 12:21:07 PM1/17/15
to ioio-...@googlegroups.com
I am experimenting with servo motors. They seem to come in two kinds, continuous rotation and 'limited' rotation where the motor shaft will swivel some number of degrees in each direction. For these, the pulse width you are sending to the motor indicates the position you want the shaft to go to. But there doesn't appear to be anything that controls the speed at which it will swivel, right? It simply turns at the same rate each time to the appropriate position?

Assuming that is the case, is it appropriate to modify the rotation rate nicely by changing the pulse width gradually? I've experimented with this some and it is kind of problematic. Let's say you have told the IOIO to send a 1.8ms pulse and you want the shaft to move to the 1.2ms position. For maximum smoothness I guess you would have to send the IOIO hundreds of timed commands with a small additive increment each time? Or is there some better way to do it?



Ytai Ben-Tsvi

unread,
Jan 17, 2015, 12:26:44 PM1/17/15
to ioio-...@googlegroups.com

Your intuition is correct, this is how it is done indeed.
In practice you'd typically have a loop running at some fixed rate, comparable to the PWM frequency, which would repeatedly tell the servo arm where to be. If you want it to move slowly, the value will only change a little between two consecutive commands, etc.

On Jan 17, 2015 9:21 AM, "Bill Carter" <a11y...@gmail.com> wrote:
I am experimenting with servo motors. They seem to come in two kinds, continuous rotation and 'limited' rotation where the motor shaft will swivel some number of degrees in each direction. For these, the pulse width you are sending to the motor indicates the position you want the shaft to go to. But there doesn't appear to be anything that controls the speed at which it will swivel, right? It simply turns at the same rate each time to the appropriate position?

Assuming that is the case, is it appropriate to modify the rotation rate nicely by changing the pulse width gradually? I've experimented with this some and it is kind of problematic. Let's say you have told the IOIO to send a 1.8ms pulse and you want the shaft to move to the 1.2ms position. For maximum smoothness I guess you would have to send the IOIO hundreds of timed commands with a small additive increment each time? Or is there some better way to do it?



--
You received this message because you are subscribed to the Google Groups "ioio-users" group.
To unsubscribe from this group and stop receiving emails from it, send an email to ioio-users+...@googlegroups.com.
To post to this group, send email to ioio-...@googlegroups.com.
Visit this group at http://groups.google.com/group/ioio-users.
For more options, visit https://groups.google.com/d/optout.
Reply all
Reply to author
Forward
0 new messages