View Single Post
  #4   Spotlight this post!  
Unread 18-05-2016, 23:26
TimTheGreat's Avatar
TimTheGreat TimTheGreat is offline
ArchdukeTim
FRC #1418 (Vae Victis)
Team Role: Programmer
 
Join Date: Jan 2013
Rookie Year: 2011
Location: Falls Church
Posts: 236
TimTheGreat has a spectacular aura aboutTimTheGreat has a spectacular aura aboutTimTheGreat has a spectacular aura about
Re: Team 5895 Code Release for 2016

I like the state machines for teleop. Kind of similar to RobotPy's statefulAutonomous. Take a look at it here. It basically allows you to divide autonomous functions into states, and you can advance based on time or whenever you feel the state is over.

I really liked this feature of RobotPy, and since I wanted it for FTC, I mostly ported to Java. Take a look. It works pretty much the same way. As long as you implement the interface, all should work.

You guys should take a look at autonomous selectors, just to get rid of clutter. You have everything neatly organized into classes, why not go that extra step and make each separate autonomous it's own class as well?

As unorthodox as it is, I like the sped, speed, and speeed. Any reason you didn't declare the double before the switch, then assign a value to it with each case?

Also, looking through some of your intake update method, it seems to always be running, since you don't have a stop mode. Am I reading this right? Seems a little dangerous.
__________________
There are two ways of constructing a software design: One way is to make it so simple that there are obviously no deficiencies, and the other way is to make it so complicated that there are no obvious deficiencies. The first method is far more difficult.



2012 - Gracious Professionalism - Greater DC
2014 - Regional Finalist - Virginia | Industrial Design - Virginia | Regional Finalist - Greater DC
2015 - Innovation in Control - Greater DC
2016 - District Event Winner - VAHAY | Innovation in Control - VAHAY | District Event Winner - MDBET | Industrial Design - MDBET | District Champion - CHCMP | Innovation in Control - CHCMP
Reply With Quote