|
|
|
![]() |
|
|||||||
|
||||||||
![]() |
| Thread Tools |
Rating:
|
Display Modes |
|
#16
|
||||
|
||||
|
Re: Team 254 2013 FRC Code
Quote:
The bigger issue is if the other library receives updates from the original source. Then you have to re-implement the changes into the updates. If the custom change were in runtime logic (not detected by a compile error, like the Poof's would be) then your robot wouldn't act correctly, causing a lot of wasted time in trying to figure out why. Here's an example of a situation where I was forced to modify COTS code at work. It required a full write-up and sign-off by the program manager. This type of thing isn't detected by a compiler, but it caused several runtime Exceptions when we tried to load the map format. At work, we use NASA WorldWind. WorldWind has some static file name extensions that are hard-coded to lower case. On Linux, the files we have are upper case, and case matters on Linux. One of the map formats we use contains the upper-case file names in a header table embedded within a single file binary file -- not possible to change. Additionally, if the issue were brought up to NASA, the fix would likely be seen in WorldWind 1.5 or 1.6, whereas we're using 1.4. WorldWind 1.5, at the time the decision was made, was having hotspot issues on Linux -- so waiting for a fix in an update was considered a risk. Thus, we had to modify WorldWind's code (added .toUpperCase() in the proper spots). We then CM'ed the specific patch files so we would know exactly what changes had to be made in the future. Any time we want to update WorldWind (perhaps in the project's next iteration), we can pull the patch files out of the code repository and analyze if they're still relevant. |
|
#17
|
|||||
|
|||||
|
Re: Team 254 2013 FRC Code
As a Java programmer, lets just say this has fulfilled the second letter of this great organization we compete in for me.
*picks jaw up off of floor* |
|
#18
|
||||
|
||||
|
Re: Team 254 2013 FRC Code
Did Team 254 use visioning on OverKill? If not, how did the drivers line up to shoot so accurately?
|
|
#19
|
||||
|
||||
|
Re: Team 254 2013 FRC Code
We deemed it an unnecessary complexity, given the wide goals and ability to use the pyramid for alignment. We just made sure the drivers got a lot of practice.
|
|
#20
|
|||||
|
|||||
|
Re: Team 254 2013 FRC Code
Thanks to everyone at 254 for the yearly release of your software. Since you began doing this, 254 software releases have been a source of inspiration and learning for me as a programmer. I especially appreciate the style guide. I will be using it to format 399 code for release later this month.
As a user of a variant of cheesy drive, I've observed that negative inertia calculations and outputs help prevent overshooting during turns by momentarily outputting a calculated output(whose sign is opposite the actual turning direction) to help act as a tuneable brake. This makes turning on a dime and other quick yaw-axis motions a little more controllable when coupled with the rest of the cheesy drive algorithm. Cheesy drive aids controllability on robots that are fast(14+fps) and can turn quickly because of that. Last edited by Jeremy Germita : 05-05-2013 at 23:33. |
|
#21
|
|||
|
|||
|
Re: Team 254 2013 FRC Code
This route would require maintaining a fork of the library and requiring anyone who wants to build our software to use the forked library. Putting it in our source tree makes it easier to maintain AND gives the added benefit of giving compile time errors if something changes upstream.
|
|
#22
|
||||
|
||||
|
Re: Team 254 2013 FRC Code
Thanks for posting, I find going through other teams code to be the best way to learn new ways of approaching problems.
I haven't gotten through all the source yet, but it is nice to be able to see how your code has matured through the season. It interesting to look back to see what other teams were working on to prep for regionals and champs. If we can get our code cleaned up, we will be releasing ours as well this year. We've also made some changes to your PID Tuner from last year, it allows us to make changes to the gains and modify set points on the fly through the web page. Certainly would have been more useful for last years game, but it's still a great tool to have in the toolbox. ![]() |
|
#23
|
||||
|
||||
|
Re: Team 254 2013 FRC Code
Thanks to team 254 for posting their code. This is very instructional to the mentors as well as our student programmers
I have a number of questions, but a few are quite simple. You have defined a pressureTransducer in your code to read the pneumatic pressure. Where in the system is this transducer located? I ask because we got into some questions on the legality of using any form of transducer on the high pressure side (120psi) of the pneumatics system. I am also assuming that since you are using the smaller Vlair compressor (as seen on some photos I have seen of the robot) that you are not cycling very much air and therefore the compressor does not have to run very long (and burn out). Is this correct? Thanks for the great opportunity you are giving other teams to learn from your development. Enjoy! |
|
#24
|
||||
|
||||
|
Re: Team 254 2013 FRC Code
From what I understand, the pressure transducer on the 120 psi side is not legal, but many teams have gotten away with it.
|
|
#25
|
|||||
|
|||||
|
Re: Team 254 2013 FRC Code
Curious, what rule gives you this idea?
|
|
#26
|
||||
|
||||
|
Re: Team 254 2013 FRC Code
Quote:
The VIair compressor is rated for about the same output, but weighs about half as much as the older compressors. Ours took 2-4 minutes to charge before each match and would usually run most of the match. |
|
#27
|
|||||
|
|||||
|
Re: Team 254 2013 FRC Code
We are not using a Viair compressor. We're using a Thomas compressor that is similar in size to the Viair (but a little smaller). We use a ton of air. Our compressor can barely keep up with our air usage. There have been a handful of times where we didn't quite have enough air when we started our hang and would end up taking awhile to get off the ground.
We are using the pressure sensor to determine when we are below 60 PSI. Before championships our shooting performance would degrade dramatically at that point, as well as the aforementioned hanging issues. |
|
#28
|
||||
|
||||
|
Re: Team 254 2013 FRC Code
Regarding the legality of pressure transducers on the high side. This was a question I asked directly to the QA and was told that they are illegal. Pretty clear there. If you read the rules it states the the ONLY things allowed on the high side are the compressor, high-pressure gauge, pressure relief valve, storage tanks and the regulator. Nothing else. However, as someone else pointed out it was not checked very well and teams got away with it in a number of instances.
The Vlair compressor has a 9% duty cycle rating that makes it very difficult to use on a pneumatic intensive robot as it will tend to overheat. I have heard of instances where teams have gotten away with running them for awhile, but I have also heard many stories where these compressors have failed as well. I cannot guarantee that the CheesyPoofs used the 090C or found a better model, but I was just going by the pictures I have seen. Educated guess, no assumptions. (sorry for being off-topic). Another item of the code the I will have to spend a long time trying to digest is the large number of 'controller' classes that are used. Not just a simple PID controller, but a number of other things (like the StateSpaceController). It is going to take awhile to unwrap this code in my brain. ![]() Again Thanks! Enjoy! |
|
#29
|
||||
|
||||
|
Re: Team 254 2013 FRC Code
Wow, you guys did a great job with organizing your code. I love that the PID controller doesn't need to start it's own thread to call the pidSet() method. Also, I think you forgot to update your feed-forward value when the table listen finds a change in the pid gains. You check to see if the key is named "f", but you never end up comparing/changing "f".
Code:
private ITableListener listener = new ITableListener() {
public void valueChanged(ITable table, String key, Object value, boolean isNew) {
if (key.equals("p") || key.equals("i") || key.equals("d") || key.equals("f")) {
if (gains.getP() != table.getNumber("p", 0.0) || gains.getI() != table.getNumber("i", 0.0) ||
gains.getD() != table.getNumber("d", 0.0)) {
System.out.println("Got new PID gains!");
gains.set(table.getNumber("p", 0.0), table.getNumber("i", 0.0), table.getNumber("d", 0.0));
}
} else if (key.equals("setpoint")) {
if (goal != ((Double) value).doubleValue()) {
setGoal(((Double) value).doubleValue());
}
} else if (key.equals("enabled")) {
if (isEnabled() != ((Boolean) value).booleanValue()) {
if (((Boolean) value).booleanValue()) {
enable();
} else {
disable();
}
}
}
}
};
|
|
#30
|
|||||
|
|||||
|
Re: Team 254 2013 FRC Code
We did not use the pressure transducer on the high pressure side of the comp bot. It was only used that way on the practice bot to give us an idea of how much air we were consuming.
Last edited by Travis Covington : 27-06-2013 at 16:30. |
![]() |
| Thread Tools | |
| Display Modes | Rate This Thread |
|
|