I'm assuming the "debugging" program is the one you listed, not "when the program is ran in with the debugger".
You didn't state if the robot is in auton or teleop. Auton is written in IterativeRobot style and (at a quick glance) should work. The teleop section seems to be in command based style but is not correct. Most of the code in teleopPeriodic() should be in the teleopInit() so it is only called once.
There are a number of programming resources at
http://wpilib.screenstepslive.com/s/4485/m/13809 and in particular, I would recommend the "Debugging a robot program" and learn how to set breakpoints and single-step through your code. A debugger is great for learning how your code is working and a tool every programmer should know how to use.