Go to Post You must wear safety glasses at all times, so please bring them. - Don Wright [more]
Home
Go Back   Chief Delphi > Technical > Programming > C/C++
CD-Media   CD-Spy  
portal register members calendar search Today's Posts Mark Forums Read FAQ rules

 
Reply
Thread Tools Rate Thread Display Modes
  #1   Spotlight this post!  
Unread 19-02-2013, 14:21
Anyun Anyun is offline
Co-Captain Team 1308
FRC #1308 (Wildcats)
Team Role: Programmer
 
Join Date: Aug 2012
Rookie Year: 2009
Location: Cleveland
Posts: 13
Anyun is an unknown quantity at this point
Gyro to readjust shooter?

So we've essentially finished our robot, but we have a small problem and we were wondering if a Gyro sensor would work to fix it. Our frisbee shooter is mounted on two separate threaded rods controlled by separate speed controllers and motors. Because the one side is heavier, we have the motors running at separate speeds to move it up and down. However, even with a large amount of fine tuning there is some unevenness in the shooter's orientation after some use (it should be parallel to the ground).

We were wondering if a Gyro could be used to adjust the shooter constantly back to the angle it started at when it was turned on (so we wouldn't have to use an accelerometer), and if so, what the code look like.

Thanks!
Reply With Quote
  #2   Spotlight this post!  
Unread 19-02-2013, 15:11
Alan Anderson's Avatar
Alan Anderson Alan Anderson is offline
Software Architect
FRC #0045 (TechnoKats)
Team Role: Mentor
 
Join Date: Feb 2004
Rookie Year: 2004
Location: Kokomo, Indiana
Posts: 9,113
Alan Anderson has a reputation beyond reputeAlan Anderson has a reputation beyond reputeAlan Anderson has a reputation beyond reputeAlan Anderson has a reputation beyond reputeAlan Anderson has a reputation beyond reputeAlan Anderson has a reputation beyond reputeAlan Anderson has a reputation beyond reputeAlan Anderson has a reputation beyond reputeAlan Anderson has a reputation beyond reputeAlan Anderson has a reputation beyond reputeAlan Anderson has a reputation beyond repute
Re: Gyro to readjust shooter?

A gyro will drift enough during a match, and lose accuracy during bumps and collisions, to make it a very poor solution for what you want. An accelerometer might work well, letting you detect "down" based on gravity and thus compensate for tilt. Why don't you want to use one?

I'd suggest a mechanical solution, though: Chain the two threaded rods together so that they always move in sync with each other.
Reply With Quote
  #3   Spotlight this post!  
Unread 09-03-2013, 17:46
meltbox360 meltbox360 is offline
Registered User
FRC #4302
 
Join Date: Jan 2012
Location: Chicago, Il
Posts: 32
meltbox360 is a glorious beacon of lightmeltbox360 is a glorious beacon of lightmeltbox360 is a glorious beacon of lightmeltbox360 is a glorious beacon of lightmeltbox360 is a glorious beacon of light
Re: Gyro to readjust shooter?

We tested a gyro and unless you have a clever way to reset the angle to calibrate it every thirty seconds it won't be very accurate. You may want to look into potentiometers for measuring the angle. Although in your case the potentiometer solution does not seem practical. An accelerometer may be your best bet unless you want to go with the mechanical solution suggested above.

Last edited by meltbox360 : 09-03-2013 at 17:48.
Reply With Quote
  #4   Spotlight this post!  
Unread 11-03-2013, 10:02
JefferMC JefferMC is offline
Registered User
AKA: Jeff Corbett
FRC #1319 (Flash)
Team Role: Mentor
 
Join Date: Nov 2012
Rookie Year: 2005
Location: United States
Posts: 44
JefferMC will become famous soon enough
Re: Gyro to readjust shooter?

We tried using a gyro for our shooter angle because placement of an encoder was "inconvenient." However, as the others have said, the drift is a problem; you have to take the shooter to a known position to re-calibrate the gyro fairly often as it will drift a degree in 10 seconds. Or not; it's very random.

We have switched to an encoder.
Reply With Quote
  #5   Spotlight this post!  
Unread 19-03-2013, 14:49
Anyun Anyun is offline
Co-Captain Team 1308
FRC #1308 (Wildcats)
Team Role: Programmer
 
Join Date: Aug 2012
Rookie Year: 2009
Location: Cleveland
Posts: 13
Anyun is an unknown quantity at this point
Re: Gyro to readjust shooter?

How exactly should the encoder be programmed.
Reply With Quote
  #6   Spotlight this post!  
Unread 19-03-2013, 16:16
Alan Anderson's Avatar
Alan Anderson Alan Anderson is offline
Software Architect
FRC #0045 (TechnoKats)
Team Role: Mentor
 
Join Date: Feb 2004
Rookie Year: 2004
Location: Kokomo, Indiana
Posts: 9,113
Alan Anderson has a reputation beyond reputeAlan Anderson has a reputation beyond reputeAlan Anderson has a reputation beyond reputeAlan Anderson has a reputation beyond reputeAlan Anderson has a reputation beyond reputeAlan Anderson has a reputation beyond reputeAlan Anderson has a reputation beyond reputeAlan Anderson has a reputation beyond reputeAlan Anderson has a reputation beyond reputeAlan Anderson has a reputation beyond reputeAlan Anderson has a reputation beyond repute
Re: Gyro to readjust shooter?

I don't think an encoder could give you useful information on how misaligned your shooter has gotten. You might perhaps be able to use two encoders, one on each threaded rod, and move the motors to keep them synchronized.

Is there a good reason you can't use a mechanical solution to ensure that the rods are always moving together?
Reply With Quote
Reply


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


All times are GMT -5. The time now is 03:34.

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