Thanks for the suggestions! I like putting it into the disabledInit() function.
Still having some problems though.
Code:
public class Robot extends IterativeRobot {
public static double speed;
Preferences prefs;
//Other stuff
}
public void disabledInit(){
speed = prefs.getDouble("speed", .5);
}
And then later on in a different class
Code:
value = Robot.speed;
However we're having issues where we're getting an unhandled exception for a null pointer in the disabledInit function, so the driver station is listing as "no robot code"
Any suggestions?