Chief Delphi

Chief Delphi (http://www.chiefdelphi.com/forums/index.php)
-   Programming (http://www.chiefdelphi.com/forums/forumdisplay.php?f=51)
-   -   What base class do you use when programming? (http://www.chiefdelphi.com/forums/showthread.php?t=130269)

E Dawg 12-08-2014 13:43

What base class do you use when programming?
 
What base class do you use when programming and why?

madhav 12-08-2014 14:50

Re: What base class do you use when programming?
 
Simple robot for life

JohnFogarty 12-08-2014 14:54

Re: What base class do you use when programming?
 
Iterative Robot based for life. Actually I'm moving to command based this year.

Oblarg 12-08-2014 15:19

Re: What base class do you use when programming?
 
Last year we used iterative robot, because finite state machines are very easy to write and we didn't want to deal with concurrency.

We may look at multithreading this year.

madhav 12-08-2014 15:36

Re: What base class do you use when programming?
 
Quote:

Originally Posted by Oblarg (Post 1396183)
We may look at multithreading this year.

We might try multithreading as well. But we want to shy away from CommandBased and try to write our own.

Jared Russell 12-08-2014 18:01

Re: What base class do you use when programming?
 
java.lang.Object

Poseidon5817 12-08-2014 18:11

Re: What base class do you use when programming?
 
Simple Robot, considering moving to Iterative Robot.

madhav 12-08-2014 22:20

Re: What base class do you use when programming?
 
Quote:

Originally Posted by Jared Russell (Post 1396205)
java.lang.Object

I second this

Kingland093 12-08-2014 22:47

Re: What base class do you use when programming?
 
We use simple because it's well… simple.
One of our programmers briefly experimented with iterative

Bryce Paputa 12-08-2014 22:50

Re: What base class do you use when programming?
 
I'm not going to say that they're wrong, but anyone not using command based should seriously consider it. It does make some simple things more complicated, but greatly helps readability and maintainability, and it makes chaining actions together and responding to inputs very easy.

nathanwalters 13-08-2014 01:13

Re: What base class do you use when programming?
 
IterativeRobot. What it lacks in simplicity it makes up for in flexibility.

wmarshall11 13-08-2014 07:52

Re: What base class do you use when programming?
 
Quote:

Originally Posted by Bryce Paputa (Post 1396242)
I'm not going to say that they're wrong, but anyone not using command based should seriously consider it. It does make some simple things more complicated, but greatly helps readability and maintainability, and it makes chaining actions together and responding to inputs very easy.

Having spent serious time and energy trying to make complex actions work safely with SimpleRobot, switching to CommandBased was probably the best programming decision 11 ever made. Not having logic sprinkled through all levels of your code is the best thing ever.

notmattlythgoe 13-08-2014 08:15

Re: What base class do you use when programming?
 
Quote:

Originally Posted by wmarshall11 (Post 1396251)
Having spent serious time and energy trying to make complex actions work safely with SimpleRobot, switching to CommandBased was probably the best programming decision 11 ever made. Not having logic sprinkled through all levels of your code is the best thing ever.

We switched to Java 2 seasons ago and went straight for the Command Based structure, and we have been all aboard ever since. As a professional Java developer and ex-CS teacher I feel it teaches excellent practices and is pretty simple to pick up as a beginner.

EricS-Team180 13-08-2014 10:52

Re: What base class do you use when programming?
 
In 2013 and 2014, we used Brad Miller's Robot Builder to create a Command based structure in C++. I agree with the comments of Bryce Paputa, wmarshall11, and notmattlythgoe on the Command based approach.
Plus, I like Brad's "pictures-to-code". It introduces the students to the practice used extensively in my field of aero gas turbine controls - and elsewhere.
We'll use it, again, in 2015.

Prior to that we used the Iterative Robot framework, for the same reasons nathanwalters posted.

Eric

Cel Skeggs 14-08-2014 14:30

Re: What base class do you use when programming?
 
We implement IgneousApplication. :D
More specifically, we use our team's event-based robot framework (the CCRE), which we think is nicer than the command-based framework because it gives us lots of useful tools without forcing a specific structure in the way that command-based does.
Also, event-based control seems to be a better option to program robots than cycle-based control or thread-based control, as far as I can tell. (Though we occasionally still use those in the places where they are helpful.)


All times are GMT -5. The time now is 16:37.

Powered by vBulletin® Version 3.6.4
Copyright ©2000 - 2017, Jelsoft Enterprises Ltd.
Copyright © Chief Delphi