Go to Post Tolerance, forgiveness, humor, and lessons learned are tools we can find here. - JaneYoung [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 06-02-2006, 23:08
Rick TYler Rick TYler is offline
A VEX GUy WIth A STicky SHift KEy
VRC #0010 (Exothermic Robotics)
Team Role: Mentor
 
Join Date: Jan 2005
Rookie Year: 2005
Location: Redmond, Washington
Posts: 2,000
Rick TYler has a reputation beyond reputeRick TYler has a reputation beyond reputeRick TYler has a reputation beyond reputeRick TYler has a reputation beyond reputeRick TYler has a reputation beyond reputeRick TYler has a reputation beyond reputeRick TYler has a reputation beyond reputeRick TYler has a reputation beyond reputeRick TYler has a reputation beyond reputeRick TYler has a reputation beyond reputeRick TYler has a reputation beyond repute
Emergency: PID with Wheels Off the Ground

Our programmer is convinced that his encoder-enabled PD code isn't working right because the robot is on the cart with the wheels off the ground, and that it would work if it was tried on the floor. Is this your experience?

The biggest problem is speed oscillations in the wheels (speed goes up and down).

Thanks!
__________________
Exothermic Robotics Club, Venturing Crew 2036
VRC 10A, 10B, 10D, 10Q, 10V, 10X, 10Z, and 575
  #2   Spotlight this post!  
Unread 06-02-2006, 23:16
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: Emergency: PID with Wheels Off the Ground

Quote:
Originally Posted by Rick TYler
Our programmer is convinced that his encoder-enabled PD code isn't working right because the robot is on the cart with the wheels off the ground, and that it would work if it was tried on the floor. Is this your experience?

The biggest problem is speed oscillations in the wheels (speed goes up and down).

Thanks!
I had this problem too, and I can attest to the fact that it will help some to have it on the ground, but those oscillations will still be there. The PID loop relies on the mass of the robot to smooth out some of the oscillations, as well as a nice small timeslice. If the code takes too long between corrections, there will be no way to fix it without sacrificing "snappiness".

Hope this helps, and please correct me if I'm wrong!
__________________
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

Last edited by Eldarion : 06-02-2006 at 23:19.
  #3   Spotlight this post!  
Unread 06-02-2006, 23:17
Goldeye Goldeye is offline
Registered User
AKA: Josh Hecht
FRC #0694 (Stuypulse)
Team Role: College Student
 
Join Date: Jan 2005
Rookie Year: 2005
Location: New York
Posts: 145
Goldeye has a spectacular aura aboutGoldeye has a spectacular aura aboutGoldeye has a spectacular aura about
Send a message via AIM to Goldeye
Re: Emergency: PID with Wheels Off the Ground

Tuning this year's PD system (our first as a team) we were able to get it to run ok with wheels in the air (and then for some time before further modifications) by starting with a P gain too low than tuning it up till the oscillations just begin..
Keep in mind that the weight and friction of the robot acts as a serious D controller, which does prevent major oscillation.
I would just tune the P gain until you don't get a lot of major oscillation and then see how it works on the floor.
__________________
Team 694

2005 Championship - Galileo Semifinalist
2005 New York - Regional Chairmans Award
2005 New York - Semifinalist (Thanks 1257,1340)
  #4   Spotlight this post!  
Unread 06-02-2006, 23:20
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: Emergency: PID with Wheels Off the Ground

definately has to be on the floor - tuning it with the wheels in the air will only show that the code is working, you will still need to change the constants for th e dynamics of the bot when its on the floor

make sure you have a disable switch wired to the OI, keep someone on the switch while its being tested, then go for it on the carpet.

PS: your programmer knows his stuff! :^)
  #5   Spotlight this post!  
Unread 06-02-2006, 23:20
Rick TYler Rick TYler is offline
A VEX GUy WIth A STicky SHift KEy
VRC #0010 (Exothermic Robotics)
Team Role: Mentor
 
Join Date: Jan 2005
Rookie Year: 2005
Location: Redmond, Washington
Posts: 2,000
Rick TYler has a reputation beyond reputeRick TYler has a reputation beyond reputeRick TYler has a reputation beyond reputeRick TYler has a reputation beyond reputeRick TYler has a reputation beyond reputeRick TYler has a reputation beyond reputeRick TYler has a reputation beyond reputeRick TYler has a reputation beyond reputeRick TYler has a reputation beyond reputeRick TYler has a reputation beyond reputeRick TYler has a reputation beyond repute
Re: Emergency: PID with Wheels Off the Ground

Would either of you be willing to share your source with us? You can email it to me at gmail.com. Something is seriously wrong here and we are starting to seriously panic. Thankyouthankyouthankyou.
__________________
Exothermic Robotics Club, Venturing Crew 2036
VRC 10A, 10B, 10D, 10Q, 10V, 10X, 10Z, and 575
  #6   Spotlight this post!  
Unread 06-02-2006, 23:22
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: Emergency: PID with Wheels Off the Ground

if a PID loop totally wacks out then usually:

A. you have the polarity of a feedback signal backwards or

2. you have your gain way too high.
  #7   Spotlight this post!  
Unread 06-02-2006, 23:27
Rick TYler Rick TYler is offline
A VEX GUy WIth A STicky SHift KEy
VRC #0010 (Exothermic Robotics)
Team Role: Mentor
 
Join Date: Jan 2005
Rookie Year: 2005
Location: Redmond, Washington
Posts: 2,000
Rick TYler has a reputation beyond reputeRick TYler has a reputation beyond reputeRick TYler has a reputation beyond reputeRick TYler has a reputation beyond reputeRick TYler has a reputation beyond reputeRick TYler has a reputation beyond reputeRick TYler has a reputation beyond reputeRick TYler has a reputation beyond reputeRick TYler has a reputation beyond reputeRick TYler has a reputation beyond reputeRick TYler has a reputation beyond repute
Re: Emergency: PID with Wheels Off the Ground

Quote:
Originally Posted by Rick TYler
Would either of you be willing to share your source with us? You can email it to me at gmail.com. Something is seriously wrong here and we are starting to seriously panic. Thankyouthankyouthankyou.
That would be rhtyler@gmail.com. (And thank you for your comments, too, Ken.)
__________________
Exothermic Robotics Club, Venturing Crew 2036
VRC 10A, 10B, 10D, 10Q, 10V, 10X, 10Z, and 575
  #8   Spotlight this post!  
Unread 07-02-2006, 00:06
Rick TYler Rick TYler is offline
A VEX GUy WIth A STicky SHift KEy
VRC #0010 (Exothermic Robotics)
Team Role: Mentor
 
Join Date: Jan 2005
Rookie Year: 2005
Location: Redmond, Washington
Posts: 2,000
Rick TYler has a reputation beyond reputeRick TYler has a reputation beyond reputeRick TYler has a reputation beyond reputeRick TYler has a reputation beyond reputeRick TYler has a reputation beyond reputeRick TYler has a reputation beyond reputeRick TYler has a reputation beyond reputeRick TYler has a reputation beyond reputeRick TYler has a reputation beyond reputeRick TYler has a reputation beyond reputeRick TYler has a reputation beyond repute
Re: Emergency: PID with Wheels Off the Ground

Status: it works better on the ground. Tuning is underway. Thanks, everyone.
__________________
Exothermic Robotics Club, Venturing Crew 2036
VRC 10A, 10B, 10D, 10Q, 10V, 10X, 10Z, and 575
  #9   Spotlight this post!  
Unread 07-02-2006, 08:51
kaszeta's Avatar
kaszeta kaszeta is offline
Registered User
FRC #0095 (Grasshoppers)
Team Role: Mentor
 
Join Date: Feb 2004
Rookie Year: 2002
Location: Lebanon, NH
Posts: 334
kaszeta is a glorious beacon of lightkaszeta is a glorious beacon of lightkaszeta is a glorious beacon of lightkaszeta is a glorious beacon of lightkaszeta is a glorious beacon of light
Re: Emergency: PID with Wheels Off the Ground

Quote:
Originally Posted by Rick TYler
Our programmer is convinced that his encoder-enabled PD code isn't working right because the robot is on the cart with the wheels off the ground, and that it would work if it was tried on the floor. Is this your experience?
When your robot isn't dragging 130+ lbs around, the PID controller will generally be massively overcontrolling. As the other poster says, the mass of the system is basically a very large D control. So I'd really recommend dialing back the control while it's on the blocks.

Last year, I ended up having the team code in two sets of PID constants: the normal tuned ones, and some majorly scaled back ones for testing the robot up on blocks so that you can tell that autonomous code is doing the right thing.

Since we're talking about it, the other major PID caveats are:

1. Making sure you sanity check your integral control (i.e. put a cap on the integral so that it can't overflow and wrap around, since that causes a major spazz)

2. Make sure you are applying the corrections in the right direction. And check your math to make sure you aren't overflowing variables.

3. The I and D control should be small.

4. Resist the temptation to adjust all the factors at once.
  #10   Spotlight this post!  
Unread 07-02-2006, 11:37
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: Emergency: PID with Wheels Off the Ground

we always had a PID enable switch on our OI, when we used PID for steering or velocity.

Some drivers preferred driving open loop, and it allowed you to test the bot with the wheels up.
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
PID cmd_drive can't drive straight? gnormhurst Programming 4 18-02-2005 01:54
Lots of Wheels and F = u x N archiver 2001 17 23-06-2002 23:37
Good or bad: back wheels coming off the ground Gui Cavalcanti Technical Discussion 2 17-03-2002 22:09
Our wheels don't touch the ground! ahecht General Forum 12 29-01-2002 19:35
"Motors and Drive train edition" of Fresh From the Forum Ken Leung CD Forum Support 6 29-01-2002 12:32


All times are GMT -5. The time now is 07:28.

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