Go to Post It's not hard, it just requires thought. - Matt Leese [more]
Home
Go Back   Chief Delphi > Technical > Programming
CD-Media   CD-Spy  
portal register members calendar search Today's Posts Mark Forums Read FAQ rules

 
Closed Thread
Thread Tools Rate Thread Display Modes
  #1   Spotlight this post!  
Unread 28-01-2006, 01:10
NextPerception NextPerception is offline
Sleep-Deprived
AKA: Matt
FRC #0437 (Richardson Robotics)
Team Role: Mentor
 
Join Date: Sep 2004
Rookie Year: 2005
Location: Richardson, TX
Posts: 69
NextPerception has a spectacular aura aboutNextPerception has a spectacular aura aboutNextPerception has a spectacular aura about
Send a message via AIM to NextPerception
servo output accuracy

Is the accuracy of the two servos controlling the camera limited by the servo potentiometer's output or would I be able to modify the program to give me degrees with one number past the decimal? (like 43.7 instead of just 44)

I realized while i was righting this that it may be the pwm's themselves causing the limit (0-255) but there may be around it so i am still going to post this ...

This is my first year programming one of these things so...
  #2   Spotlight this post!  
Unread 28-01-2006, 01:47
Eldarion's Avatar
Eldarion Eldarion is offline
Electrical Engineer / Computer Geek
AKA: Eldarion Telcontar
no team (Teamless Orphan)
Team Role: Alumni
 
Join Date: Nov 2005
Rookie Year: 2005
Location: Númenor
Posts: 558
Eldarion has a reputation beyond reputeEldarion has a reputation beyond reputeEldarion has a reputation beyond reputeEldarion has a reputation beyond reputeEldarion has a reputation beyond reputeEldarion has a reputation beyond reputeEldarion has a reputation beyond reputeEldarion has a reputation beyond reputeEldarion has a reputation beyond reputeEldarion has a reputation beyond reputeEldarion has a reputation beyond repute
Send a message via AIM to Eldarion Send a message via Yahoo to Eldarion
Re: servo output accuracy

Quote:
Originally Posted by NextPerception
Is the accuracy of the two servos controlling the camera limited by the servo potentiometer's output or would I be able to modify the program to give me degrees with one number past the decimal? (like 43.7 instead of just 44)

I realized while i was righting this that it may be the pwm's themselves causing the limit (0-255) but there may be around it so i am still going to post this ...

This is my first year programming one of these things so...
The limitation is in the entire servo system, I.E. both the servos and the standard PWM signal used to control them.

You will only have 255 "ticks" of resolution regardless, so there is no reason to go into decimals.

Hope this helps...
__________________
CMUCam not working? Tracks sporadically? Try this instead: http://www.falconir.com!
PM me for more information if you are interested (it's open source!).

Want the FIRST Email blasts? See here: http://www.chiefdelphi.com/forums/sh...ad.php?t=50809

"The harder the conflict, the more glorious the triumph. What we obtain too cheaply, we esteem too lightly; it is dearness only that gives everything its value."
-- Thomas Paine

If it's falling apart it's a mechanical problem. If it's spewing smoke it's a electrical problem.
If it's rampaging around destroying things it's a programming problem.

"All technology is run on 'Magic Smoke' contained within the device. As everyone knows, whenever the magic smoke is released, the device ceases to function."
-- Anonymous

I currently speak: English, some German, Verilog, x86 and 8051 Assembler, C, C++, VB, VB.NET, ASP, PHP, HTML, UNIX and SQL
  #3   Spotlight this post!  
Unread 28-01-2006, 02:19
NextPerception NextPerception is offline
Sleep-Deprived
AKA: Matt
FRC #0437 (Richardson Robotics)
Team Role: Mentor
 
Join Date: Sep 2004
Rookie Year: 2005
Location: Richardson, TX
Posts: 69
NextPerception has a spectacular aura aboutNextPerception has a spectacular aura aboutNextPerception has a spectacular aura about
Send a message via AIM to NextPerception
Re: servo output accuracy

Wow. thanks for the quick reply!
well i guess if it can't be done it can't be done... (although it could be done with a 10 turn pot geared to the servo output shaft so 10 turns=180 deg then have a circuit that puts that onto two inputs to give me 65536 values to work with instead of just 256 but no way in hell i am going to go through all that...)

I just did the math and it looks like at half court and over about 12 feet to one side it would be only about a 3 inch error in either direction without decimals. (and that isn't including the allowable error to prevent oscillation in the default code)
  #4   Spotlight this post!  
Unread 28-01-2006, 02:33
Eldarion's Avatar
Eldarion Eldarion is offline
Electrical Engineer / Computer Geek
AKA: Eldarion Telcontar
no team (Teamless Orphan)
Team Role: Alumni
 
Join Date: Nov 2005
Rookie Year: 2005
Location: Númenor
Posts: 558
Eldarion has a reputation beyond reputeEldarion has a reputation beyond reputeEldarion has a reputation beyond reputeEldarion has a reputation beyond reputeEldarion has a reputation beyond reputeEldarion has a reputation beyond reputeEldarion has a reputation beyond reputeEldarion has a reputation beyond reputeEldarion has a reputation beyond reputeEldarion has a reputation beyond reputeEldarion has a reputation beyond repute
Send a message via AIM to Eldarion Send a message via Yahoo to Eldarion
Re: servo output accuracy

Quote:
Originally Posted by NextPerception
Wow. thanks for the quick reply!
well i guess if it can't be done it can't be done... (although it could be done with a 10 turn pot geared to the servo output shaft so 10 turns=180 deg then have a circuit that puts that onto two inputs to give me 65536 values to work with instead of just 256 but no way in hell i am going to go through all that...)

I just did the math and it looks like at half court and over about 12 feet to one side it would be only about a 3 inch error in either direction without decimals. (and that isn't including the allowable error to prevent oscillation in the default code)
That's pretty much where I ended up. I guess FIRST made the target 30" wide for a reason after all!
__________________
CMUCam not working? Tracks sporadically? Try this instead: http://www.falconir.com!
PM me for more information if you are interested (it's open source!).

Want the FIRST Email blasts? See here: http://www.chiefdelphi.com/forums/sh...ad.php?t=50809

"The harder the conflict, the more glorious the triumph. What we obtain too cheaply, we esteem too lightly; it is dearness only that gives everything its value."
-- Thomas Paine

If it's falling apart it's a mechanical problem. If it's spewing smoke it's a electrical problem.
If it's rampaging around destroying things it's a programming problem.

"All technology is run on 'Magic Smoke' contained within the device. As everyone knows, whenever the magic smoke is released, the device ceases to function."
-- Anonymous

I currently speak: English, some German, Verilog, x86 and 8051 Assembler, C, C++, VB, VB.NET, ASP, PHP, HTML, UNIX and SQL
  #5   Spotlight this post!  
Unread 28-01-2006, 02:53
sciguy125 sciguy125 is offline
Electrical Engineer
AKA: Phil Baltar
FRC #1351
Team Role: College Student
 
Join Date: Jan 2005
Rookie Year: 2004
Location: Sunnyvale, CA
Posts: 519
sciguy125 has a reputation beyond reputesciguy125 has a reputation beyond reputesciguy125 has a reputation beyond reputesciguy125 has a reputation beyond reputesciguy125 has a reputation beyond reputesciguy125 has a reputation beyond reputesciguy125 has a reputation beyond reputesciguy125 has a reputation beyond reputesciguy125 has a reputation beyond reputesciguy125 has a reputation beyond reputesciguy125 has a reputation beyond repute
Send a message via AIM to sciguy125 Send a message via MSN to sciguy125 Send a message via Yahoo to sciguy125
Re: servo output accuracy

Quote:
Originally Posted by Eldarion
The limitation is in the entire servo system, I.E. both the servos and the standard PWM signal used to control them.

You will only have 255 "ticks" of resolution regardless, so there is no reason to go into decimals.

Hope this helps...
If I understand the system correctly, the limitation is in the signal being put out by the controller. It may have changed recently, but I'm pretty sure that older servos (probably from before the mid-90's) were completely analog. Older hobby radios (and lower-end new ones) were also analog. This gives you whatever resolution you are mechanically capable of having.

My newer futaba radio has 10-bit resolution. The earlier digital futabas had 9-bit. Barring an ingenious marketing scam, this would imply that the servos themselves are capable of at least 10-bit resolution.

As for the IFI system, it'd be an interesting trick to increase the PWM signal resolution.
__________________

-----BEGIN GEEK CODE BLOCK-----
Version: 3.12
GE/S/P a-- e y-- r-- s:++ d+ h! X+++
t++ C+ P+ L++ E W++ w M-- V? PS+ PE+
5- R-- tv+ b+ DI+++ D- G
------END GEEK CODE BLOCK------
  #6   Spotlight this post!  
Unread 28-01-2006, 04:03
NextPerception NextPerception is offline
Sleep-Deprived
AKA: Matt
FRC #0437 (Richardson Robotics)
Team Role: Mentor
 
Join Date: Sep 2004
Rookie Year: 2005
Location: Richardson, TX
Posts: 69
NextPerception has a spectacular aura aboutNextPerception has a spectacular aura aboutNextPerception has a spectacular aura about
Send a message via AIM to NextPerception
Re: servo output accuracy

well i checked the rules and R67 says something like we can't control anything with our own pwm and the output has to go straight from the servo to the robot controller

that means we cant use a 16 bit digital analog converter to convert the servos into "high def" servos...

come on first! the fcc wants us all to switch to high def!
(that wasn't serious for those who take everything seriously)

i don't think the 3 inches is going to a problem as long as our teams launcher is accurate and very repeatable. (and from what we've tested so far this shouldn't be a problem)

Last edited by NextPerception : 28-01-2006 at 04:19.
  #7   Spotlight this post!  
Unread 06-02-2006, 12:28
Keith Watson Keith Watson is offline
Registered User
FRC #0957 (WATSON)
Team Role: Mentor
 
Join Date: Feb 2006
Rookie Year: 2006
Location: Wilsonville, OR
Posts: 112
Keith Watson is just really niceKeith Watson is just really niceKeith Watson is just really niceKeith Watson is just really nice
Re: servo output accuracy

Servo accuracy includes 2 other things not mentioned.

One is "centering", or how well the output wheel exactly goes to the commanded position. It can vary between brands and between models in a given brand. Digital servos have much better centering accuracy.

The other is the range of motion of the output wheel versus the PWM range IFI uses of 256. Servos can have ranges in degrees of 60, 75, 90, 120, 180, etc. So one PWM step can give a different angle depending on the servo.
__________________
Keith Watson - Professional Software Engineer
No relation to "Kevin" Watson, who created the camera tracking code.
  #8   Spotlight this post!  
Unread 06-02-2006, 12:57
KenWittlief KenWittlief is offline
.
no team
Team Role: Engineer
 
Join Date: Mar 2003
Location: Rochester, NY
Posts: 4,213
KenWittlief has a reputation beyond reputeKenWittlief has a reputation beyond reputeKenWittlief has a reputation beyond reputeKenWittlief has a reputation beyond reputeKenWittlief has a reputation beyond reputeKenWittlief has a reputation beyond reputeKenWittlief has a reputation beyond reputeKenWittlief has a reputation beyond reputeKenWittlief has a reputation beyond reputeKenWittlief has a reputation beyond reputeKenWittlief has a reputation beyond repute
Re: servo output accuracy

there are other restrictions on the accuracy of a servo: the load (resistance to movement), temp, voltage of the supply battery.....

Servos are designed to use on radio controller vehicles, where the operator applies a command to the servo, sees what the vehicle does, then fine-tunes his inputs

I have never seen an accuracy or precision spec for RC servos.
  #9   Spotlight this post!  
Unread 06-02-2006, 19:36
Keith Watson Keith Watson is offline
Registered User
FRC #0957 (WATSON)
Team Role: Mentor
 
Join Date: Feb 2006
Rookie Year: 2006
Location: Wilsonville, OR
Posts: 112
Keith Watson is just really niceKeith Watson is just really niceKeith Watson is just really niceKeith Watson is just really nice
Re: servo output accuracy

I have never seen published centering specs either, just word of mouth. But it is easily measurable. People with high speed planes typically need servos with high accuracy.
__________________
Keith Watson - Professional Software Engineer
No relation to "Kevin" Watson, who created the camera tracking code.
  #10   Spotlight this post!  
Unread 07-02-2006, 11:23
Mike Bortfeldt Mike Bortfeldt is offline
Registered User
FRC #1126 (& 1511)
Team Role: Mentor
 
Join Date: Oct 2004
Rookie Year: 2004
Location: Rochester, NY
Posts: 119
Mike Bortfeldt has much to be proud ofMike Bortfeldt has much to be proud ofMike Bortfeldt has much to be proud ofMike Bortfeldt has much to be proud ofMike Bortfeldt has much to be proud ofMike Bortfeldt has much to be proud ofMike Bortfeldt has much to be proud ofMike Bortfeldt has much to be proud of
Re: servo output accuracy

If you want to try using a higher resolution PWM signal to see what happens, I posted some code for PWMs 13-16 here that can easily be modified to give you more control over the signal width.

Mike
Closed Thread


Thread Tools
Display Modes Rate This Thread
Rate This Thread:

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

vB code is On
Smilies are On
[IMG] code is On
HTML code is Off
Forum Jump

Similar Threads
Thread Thread Starter Forum Replies Last Post
Servo behavior question / advanced servo/PIC programming question DanL Electrical 12 18-10-2005 18:33
Servo command confusion?!?!?!?! [527]phil Programming 9 15-07-2005 20:10
Servo Compact Design Problems!!! Dominator_Legen Electrical 22 07-04-2005 18:15
Servo Help Dominator_Legen Motors 3 11-03-2005 19:50
heres the code. y this not working omega Programming 16 31-03-2004 15:18


All times are GMT -5. The time now is 01:19.

The Chief Delphi Forums are sponsored by Innovation First International, Inc.


Powered by vBulletin® Version 3.6.4
Copyright ©2000 - 2017, Jelsoft Enterprises Ltd.
Copyright © Chief Delphi