Quote:
Originally Posted by garystjean
One weird thing I noticed was that after I played around with the simulation for a couple minutes and tried out the Smart Dashboard simulator the robot seemed to drop down below the floor (see attachment). I can only see the top-most part of the robot, the rest is below the ground level?
-Gary
|
This is caused by an awesome little bug in simulation time. I'll be posting a video tutorial on debugging very soon that goes deep into it, but for now, just do this...
1) find all instances of usePIDOutpout()
2) find where you call the set() method on your motor
3) wrap it in an if statement that checks if the output is NaN
EX:
Code:
public void usePIDOutput(){if (!Double.isNan(output)){motor.set(output)
}
}