OCCRA
Go to Post I believe youth is contagious. I want to catch as much as I can! - Al Skierkiewicz [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

 
Reply
Thread Tools Rate Thread Display Modes
  #1   Spotlight this post!  
Unread 09-08-2017, 04:53 PM
SuperMario210 SuperMario210 is offline
Registered User
FRC #0254 (The Cheesy Poofs)
Team Role: Programmer
 
Join Date: Sep 2017
Rookie Year: 2015
Location: San Jose
Posts: 7
SuperMario210 is a splendid one to beholdSuperMario210 is a splendid one to beholdSuperMario210 is a splendid one to beholdSuperMario210 is a splendid one to beholdSuperMario210 is a splendid one to beholdSuperMario210 is a splendid one to beholdSuperMario210 is a splendid one to behold
Team 254 Presents: FRC 2017 Code

Team 254 is proud to present the code for our 2017 robot: Misfire. If you have any questions, feel free to ask!

Some highlights from this year's code:
Reply With Quote
  #2   Spotlight this post!  
Unread 09-08-2017, 07:23 PM
mikexcao's Avatar
mikexcao mikexcao is offline
FRC Discord Creator
AKA: Michael Cao
FRC #4150 (FRobotics)
Team Role: Leadership
 
Join Date: Jan 2016
Rookie Year: 2015
Location: Murrysville, PA
Posts: 44
mikexcao is just really nicemikexcao is just really nicemikexcao is just really nicemikexcao is just really nicemikexcao is just really nice
Re: Team 254 Presents: FRC 2017 Code

Looking forward to going through this code. Thanks for releasing it!
__________________
Michael Cao
2014 - 2017 | Team 4150 FRobotics | Vice President, Business, Programming, Leadership
Check out the FRC Discord Server!


Reply With Quote
  #3   Spotlight this post!  
Unread 09-08-2017, 07:40 PM
elizabetho elizabetho is offline
Registered User
FRC #1807 (Redbird Robotics)
Team Role: Leadership
 
Join Date: Apr 2017
Rookie Year: 2016
Location: NJ
Posts: 1
elizabetho will become famous soon enough
Re: Team 254 Presents: FRC 2017 Code

The code looks really neat and functions amazingly. Excited to read through it all. Congrats on yet another successful season!
Reply With Quote
  #4   Spotlight this post!  
Unread 09-08-2017, 10:58 PM
AirplaneWins AirplaneWins is offline
Registered User
FRC #2848
 
Join Date: Apr 2015
Location: Dallas
Posts: 57
AirplaneWins is an unknown quantity at this point
Re: Team 254 Presents: FRC 2017 Code

What led you guys to choosing the Nav-X over the Spartan Board?
__________________
Reply With Quote
  #5   Spotlight this post!  
Unread 09-09-2017, 09:18 AM
gerthworm's Avatar
gerthworm gerthworm is offline
Making the 1's and 0's
FRC #1736 (Robot Casserole)
Team Role: Mentor
 
Join Date: Jan 2015
Rookie Year: 2015
Location: Peoria, IL
Posts: 184
gerthworm is a glorious beacon of lightgerthworm is a glorious beacon of lightgerthworm is a glorious beacon of lightgerthworm is a glorious beacon of lightgerthworm is a glorious beacon of lightgerthworm is a glorious beacon of light
Re: Team 254 Presents: FRC 2017 Code

Code:
Hold 
 *  Once we collect enough kF samples, the shooter switches to the hold stage. This is the stage that we begin
 *  firing balls. We set kP, kI, and kD all to 0 and use the kF value we calculated in the previous stage for essentially
 *  open loop control.
Gain Scheduling. I like it!

Edit:
Thinking through this more, this seems like it should have been obvious to me - Clearly, spooling up the shooter from zero to setpoint, and imparting energy into playpieces are different actions. The same control method might work for both, but that depends.... I feel like going forwards, this is how I'd want to set up shooter software - tune in two phases for the different parts of the action.

Last edited by gerthworm : 09-09-2017 at 09:22 AM.
Reply With Quote
  #6   Spotlight this post!  
Unread 09-09-2017, 11:59 AM
SuperMario210 SuperMario210 is offline
Registered User
FRC #0254 (The Cheesy Poofs)
Team Role: Programmer
 
Join Date: Sep 2017
Rookie Year: 2015
Location: San Jose
Posts: 7
SuperMario210 is a splendid one to beholdSuperMario210 is a splendid one to beholdSuperMario210 is a splendid one to beholdSuperMario210 is a splendid one to beholdSuperMario210 is a splendid one to beholdSuperMario210 is a splendid one to beholdSuperMario210 is a splendid one to behold
Re: Team 254 Presents: FRC 2017 Code

Quote:
Originally Posted by AirplaneWins View Post
What led you guys to choosing the Nav-X over the Spartan Board?
It does a bunch of helpful stuff in hardware like temperature compensation, auto re-calibration, and angle integration.

With the Spartan Board you can still do all that but it requires running extra code on the RoboRIO.
Reply With Quote
  #7   Spotlight this post!  
Unread 09-10-2017, 11:12 AM
josh341 josh341 is offline
Registered User
FRC #0341
 
Join Date: Sep 2017
Location: Ambler, PA
Posts: 2
josh341 is an unknown quantity at this point
Re: Team 254 Presents: FRC 2017 Code

A few questions about the vision app:

1) Why does the app serve as a device administrator?

2) Why did you opt for Android.mk instead of cmake for building your native code?
Reply With Quote
  #8   Spotlight this post!  
Unread 09-10-2017, 03:15 PM
SuperMario210 SuperMario210 is offline
Registered User
FRC #0254 (The Cheesy Poofs)
Team Role: Programmer
 
Join Date: Sep 2017
Rookie Year: 2015
Location: San Jose
Posts: 7
SuperMario210 is a splendid one to beholdSuperMario210 is a splendid one to beholdSuperMario210 is a splendid one to beholdSuperMario210 is a splendid one to beholdSuperMario210 is a splendid one to beholdSuperMario210 is a splendid one to beholdSuperMario210 is a splendid one to behold
Re: Team 254 Presents: FRC 2017 Code

Quote:
Originally Posted by josh341 View Post
A few questions about the vision app:

1) Why does the app serve as a device administrator?

2) Why did you opt for Android.mk instead of cmake for building your native code?
The app serves as device admin so that you don't get a pop-up every time you try to pin it.

When we were creating the app last year, we found an OpenCV sample that worked using android.mk and just went from there.
Reply With Quote
  #9   Spotlight this post!  
Unread 09-10-2017, 04:03 PM
connor.worley's Avatar
connor.worley connor.worley is offline
Lead Mentor
FRC #5499 (The Bay Orangutans)
 
Join Date: Mar 2011
Rookie Year: 2010
Location: Berkeley
Posts: 662
connor.worley has a reputation beyond reputeconnor.worley has a reputation beyond reputeconnor.worley has a reputation beyond reputeconnor.worley has a reputation beyond reputeconnor.worley has a reputation beyond reputeconnor.worley has a reputation beyond reputeconnor.worley has a reputation beyond reputeconnor.worley has a reputation beyond reputeconnor.worley has a reputation beyond reputeconnor.worley has a reputation beyond reputeconnor.worley has a reputation beyond repute
Re: Team 254 Presents: FRC 2017 Code

I'm interested in the Robot State Estimator described in the technical binder. How did you decide to approach the problem, what challenges did you encounter, etc?
__________________
Team 5499 (2015-present)
Team 973 (2016-2017)
Team 254 (2014-2015)

Team 1538 (2011-2014)

日本語副専攻です!話しましょう!
Reply With Quote
  #10   Spotlight this post!  
Unread 09-10-2017, 10:59 PM
SuperMario210 SuperMario210 is offline
Registered User
FRC #0254 (The Cheesy Poofs)
Team Role: Programmer
 
Join Date: Sep 2017
Rookie Year: 2015
Location: San Jose
Posts: 7
SuperMario210 is a splendid one to beholdSuperMario210 is a splendid one to beholdSuperMario210 is a splendid one to beholdSuperMario210 is a splendid one to beholdSuperMario210 is a splendid one to beholdSuperMario210 is a splendid one to beholdSuperMario210 is a splendid one to behold
Re: Team 254 Presents: FRC 2017 Code

Quote:
Originally Posted by connor.worley View Post
I'm interested in the Robot State Estimator described in the technical binder. How did you decide to approach the problem, what challenges did you encounter, etc?
We went with a pretty similar approach to pose estimation as last year and ended up reusing a bunch of Dropshot's position estimation code.

One new problem that we ran into this year was due to the increased complexity of our autonomous paths in addition to the lack of a substantial center drop, we had problems with the accuracy of our pose estimation. We tried to come up with a better kinematics model that would account for a shifting center of rotation when we turned, but we ended up just adding a "correction factor" which was basically a fudge factor that moved our waypoints over until we drove to the correct place.
Reply With Quote
  #11   Spotlight this post!  
Unread 09-14-2017, 10:53 AM
TheModMaster8's Avatar
TheModMaster8 TheModMaster8 is offline
Mentor
AKA: Braden Shepard
FRC #5492 (Robo Jockeys)
Team Role: Alumni
 
Join Date: Apr 2015
Rookie Year: 2009
Location: USA, Kentucky
Posts: 130
TheModMaster8 is a jewel in the roughTheModMaster8 is a jewel in the roughTheModMaster8 is a jewel in the rough
Re: Team 254 Presents: FRC 2017 Code

How many programmers do you all have on your programming team?
__________________
2009-2011: (FLL) Robot Builder / Operator
2012: (FRC Team 2783) Fabrication / HumanPlayer / FLL Ref
2013: (FRC Team 2783) Fabrication / HumanPlayer / FLL Ref
2014: (FRC Team 2783) Fabrication Student Lead / HumanPlayer / FLL Ref
2015: (FRC Team 2783) Fab Student, Teacher / HumanPlayer / Backup Driver / FLL Ref / FLL Mentor of 6 Teams
2016: (FRC Team 5492) Fabrication Student Lead / Driver / FLL Mentor of Crestwood Elementary
Past Alliance:(2783, 1208, 4154)(2783, 1002, 4265)(2783, 1182, 3868)(2783, 451, 4028)(2783, 1208!, 1288)(5492, 63, 1014)


Reply With Quote
  #12   Spotlight this post!  
Unread 09-14-2017, 11:13 AM
AirplaneWins AirplaneWins is offline
Registered User
FRC #2848
 
Join Date: Apr 2015
Location: Dallas
Posts: 57
AirplaneWins is an unknown quantity at this point
Re: Team 254 Presents: FRC 2017 Code

What was the purpose of the Twist2D function? What made it necessary this year?
__________________
Reply With Quote
  #13   Spotlight this post!  
Unread 09-16-2017, 01:10 AM
SuperMario210 SuperMario210 is offline
Registered User
FRC #0254 (The Cheesy Poofs)
Team Role: Programmer
 
Join Date: Sep 2017
Rookie Year: 2015
Location: San Jose
Posts: 7
SuperMario210 is a splendid one to beholdSuperMario210 is a splendid one to beholdSuperMario210 is a splendid one to beholdSuperMario210 is a splendid one to beholdSuperMario210 is a splendid one to beholdSuperMario210 is a splendid one to beholdSuperMario210 is a splendid one to behold
Re: Team 254 Presents: FRC 2017 Code

Quote:
Originally Posted by AirplaneWins View Post
What was the purpose of the Twist2D function? What made it necessary this year?
It's actually the same thing as the RigidTransform2d.Delta class from last year. We just renamed it for convenience.
Reply With Quote
  #14   Spotlight this post!  
Unread 09-16-2017, 01:57 AM
SuperMario210 SuperMario210 is offline
Registered User
FRC #0254 (The Cheesy Poofs)
Team Role: Programmer
 
Join Date: Sep 2017
Rookie Year: 2015
Location: San Jose
Posts: 7
SuperMario210 is a splendid one to beholdSuperMario210 is a splendid one to beholdSuperMario210 is a splendid one to beholdSuperMario210 is a splendid one to beholdSuperMario210 is a splendid one to beholdSuperMario210 is a splendid one to beholdSuperMario210 is a splendid one to behold
Re: Team 254 Presents: FRC 2017 Code

Quote:
Originally Posted by TheModMaster8 View Post
How many programmers do you all have on your programming team?
We have around 15 students on our programming team.
Reply With Quote
  #15   Spotlight this post!  
Unread 09-17-2017, 12:28 AM
Jared Russell's Avatar
Jared Russell Jared Russell is online now
in hibernation
FRC #0254 (The Cheesy Poofs), FRC #0341 (Miss Daisy)
Team Role: Engineer
 
Join Date: Nov 2002
Rookie Year: 2001
Location: San Francisco, CA
Posts: 3,276
Jared Russell has a reputation beyond reputeJared Russell has a reputation beyond reputeJared Russell has a reputation beyond reputeJared Russell has a reputation beyond reputeJared Russell has a reputation beyond reputeJared Russell has a reputation beyond reputeJared Russell has a reputation beyond reputeJared Russell has a reputation beyond reputeJared Russell has a reputation beyond reputeJared Russell has a reputation beyond reputeJared Russell has a reputation beyond repute
Re: Team 254 Presents: FRC 2017 Code

Quote:
Originally Posted by AirplaneWins View Post
What was the purpose of the Twist2D function? What made it necessary this year?
Our robot moves in a 2D plane with two translational dimensions (x and y) and one rotational dimension (yaw). Sometimes we want to know where we will end up given an instantaneous parametric velocity (dx/ds, dy/ds, dtheta/ds) and a value for the parameter (ex. time duration if the parameter 's' represents time). A simple way to do this is to assume that in a given period 'ds' the robot moves in a straight line and then turns (or visa versa)...to obtain this, just multiply each component by 'ds'. If 'ds' and curvature of the motion is small, this is a pretty good approximation. However, if 'ds' and curvature are large, this can introduce error that gets compounded over time, since in reality never move in a straight line, since we are simultaneously translating and rotating.

Luckily, there is a precise formula for obtaining a new pose assuming constant curvature displacement which we can borrow from the mathematical field of differential geometry (often used in PhD-level robot kinematics and computer vision). The term "twist" is borrowed from this field because constant-curvature displacement can be thought of as representing the twisting of a screw (especially if you think about the 3D case where there is also a "pitch" velocity). The "exp" and "log" functions likewise refer to the group exponential and group logarithm functions that are well defined in this field (for obtaining a new pose from a twist, and obtaining a twist from a pose, respectively).
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 05:30 PM.

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