View Single Post
  #4   Spotlight this post!  
Unread 10-04-2013, 00:42
DjScribbles DjScribbles is offline
Programming Mentor
AKA: Joe S
FRC #2474 (Team Excel)
Team Role: Mentor
 
Join Date: Oct 2011
Rookie Year: 2012
Location: Niles MI
Posts: 284
DjScribbles is a splendid one to beholdDjScribbles is a splendid one to beholdDjScribbles is a splendid one to beholdDjScribbles is a splendid one to beholdDjScribbles is a splendid one to beholdDjScribbles is a splendid one to beholdDjScribbles is a splendid one to beholdDjScribbles is a splendid one to behold
Re: Clutter from autonomous

I have considered command based, but I feel it's a bit too abstract for a teaching tool, even if it would produce cleaner code.

We do currently break our code down into classes (shooter, collector, pid control, etc), however my gripe is these constructs still live in myrobot.cpp

Our teleop is pretty simple, and an autonomous routine taken by itself isn't so bad, but the sheer volume of autonomous routines (5 at the moment, with 3 or 4 deprecated, and at least one more on the way) leads to a large amount of code if it lives in one file. Moving the routines into seperate files would require passing all objects in myRobot.cpp by reference, or creating a .h file.
Reply With Quote