Go to Post Chit Chat is frivilous but CD would be a colder place without it. - Koko Ed [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

 
 
 
Thread Tools Rate Thread Display Modes
Prev Previous Post   Next Post Next
  #1   Spotlight this post!  
Unread 27-12-2016, 16:29
PopeRyanI PopeRyanI is offline
Registered User
FRC #2410 (Metal Mustangs Robotics)
Team Role: Programmer
 
Join Date: Dec 2014
Rookie Year: 2012
Location: Kansas
Posts: 19
PopeRyanI is an unknown quantity at this point
Am I Using Command-Based Correctly?

Hello all,

After reading a lot about it on this forum, I decided to try out using the Command Based framework for our FRC robot. In years past, my team mostly just wrote code using the SampleRobot base class and put all of the code in one file (well, and the headers). As a result, I was curious about the Command Based model because of its emphasis on dividing up the code which helps with having multiple people be able to program at the same time, something we have not done very much.

I recently tried to port our offseason robot code over to the Command Based model. It is not perfect and does not have an autonomous, but does work for the most part. I posted it here: https://github.com/ryanp73/CommandBa...ree/master/src

I looked at numerous examples from other teams online and eventually came up with this code. One of the things I noticed that initially stopped me using this framework was the presence of the boilerplate code and especially just the inefficiency of having so many files; however, I still like how it prevents repetition in addition to the easier ability to run things for set periods of time and run things concurrently.

So to return to my question: am I doing this correctly? What suggestions would you give to improve this code and/or do things differently?
Reply With Quote
 


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 11: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