Pages: 1 [2]   Go Down
Author Topic: Servo Control  (Read 4410 times)
0 Members and 1 Guest are viewing this topic.
0
Offline Offline
Tesla Member
***
Karma: 148
Posts: 9753
Arduino rocks
View Profile
 Bigger Bigger  Smaller Smaller  Reset Reset

People really need to do a reality check on servo based cam pan/tilt systems. Nobody can expect to get a $15 hobby servo pan/tilt to compare to a $1.5k servo pan/tilt, or a $150k professional cam conrol system. As to hobby servo based pan/tilt systems, the quality of operation depends a lot on the quality of design and control used in the construction.

http://www.servocity.com/html/pt-2100_pan__tilt_system.html
http://www.servocity.com/html/pan_tilt_roll___accessories.html
Logged

Consider the daffodil. And while you're doing that, I'll be over here, looking through your stuff.   smiley-cool

New Hampshire
Offline Offline
God Member
*****
Karma: 17
Posts: 781
There are 10 kinds of people, those who know binary, and those who don't.
View Profile
WWW
 Bigger Bigger  Smaller Smaller  Reset Reset

I tired 1000 delay after the attach, I should do that after the command to, didn't try that.

I will try thanks.

You should try to make your code a little smarter about how much delay it needs.  All servos have an advertised speeds, typically in seconds per 60º (which has always seemed rather odd to me, but that's the standard).  A bit of quick math can give you a value of say, milliseconds per degree.

So say your servo takes 0.17 second to rotate 60 degrees (that's fairly typical for a hobby servo, not too fast, not too slow).  That is 170ms to rotate 60º or 170/60 = 2.83ms to rotate 1º.   Round that up to 3ms per degree.

As long as you keep track of your current position, and your target position, you can easily calculate how long it will take for your servo to move to the new position.

I'd also recommend handling the pan & tilt together.  That way it pans and tilts at the same time, one synchronous, smooth operation, as opposed to first panning, then tilting serially.
Logged


Seattle, WA USA
Online Online
Brattain Member
*****
Karma: 654
Posts: 50950
Seattle, WA USA
View Profile
 Bigger Bigger  Smaller Smaller  Reset Reset

Quote
which has always seemed rather odd to me, but that's the standard
Given the typical use for a hobby servo, such as steering a car, positioning a rudder, operating as a throttle, etc., 60 degrees is generally the full range that the servo needs to sweep. How much throttle travel do you have, and how much servo movement is required to make the throttle travel that far?
Logged

New Hampshire
Offline Offline
God Member
*****
Karma: 17
Posts: 781
There are 10 kinds of people, those who know binary, and those who don't.
View Profile
WWW
 Bigger Bigger  Smaller Smaller  Reset Reset

Quote
which has always seemed rather odd to me, but that's the standard
Given the typical use for a hobby servo, such as steering a car, positioning a rudder, operating as a throttle, etc., 60 degrees is generally the full range that the servo needs to sweep. How much throttle travel do you have, and how much servo movement is required to make the throttle travel that far?

Well there you go.  Makes more sense knowing that.  Guess I've never used hobby servos in the manner they were designed for. smiley
Logged


Pages: 1 [2]   Go Up
Jump to: