|
Re: PIDController Rotate
I appreciate all of the help Ether, but I don't think you are understanding what I am asking, and that is probably my fault for not explaining enough. What I am currently doing is working on rewriting our competition code that was done in Labview in Java. One of the programming sub-teams off-season projects this year is going to be learning to use the Java environment by reprogramming our robot from Logomotion. I am doing it myself so that I know how to do it when the students are working on it and can help them when they have questions. The problem that I ran into was that I needed an output that would go straight to a speed controller that would cause the robot to rotate. From what I can tell the PIDController in Java works differently than the ones in C++ and Labview. It works more like the CANJaguar where you give it the value and it does all of the calculations and outputs to the speed controllers for you. I think I have remedied that by writing a PIDOutput class that implements PIDOutput and tells the RobotDrive to rotate instad of telling one specific speed controller to move. I have attached the two code files, but don't quote me on anything because I have not tested it at all.
Last edited by notmattlythgoe : 27-05-2011 at 10:07.
|