View Single Post
  #1   Spotlight this post!  
Unread 15-02-2011, 09:03
derekwhite's Avatar
derekwhite derekwhite is offline
Java Virtual Machine Hacker
no team (FIRST@Oracle)
Team Role: Programmer
 
Join Date: May 2009
Rookie Year: 2009
Location: Burlington, MA
Posts: 127
derekwhite is on a distinguished road
Re: Robot driving off.

Bluedog24,

You can print out the values of your joystick - perhaps they aren't zero as you expect.

Robby,

It's a good idea not run your control loop flat out - you only get new joystick values every 50ms, so delaying 5ms isn't going to hurt anything. This will allow camera code, dashboard code, etc to get a chance to run.

In fact, there's a new method DriverStation.waitForData(long ms) that would be handy to use.
Reply With Quote