View Single Post
  #3   Spotlight this post!  
Unread 22-03-2013, 19:31
nydnh01 nydnh01 is offline
Registered User
AKA: Naresh Hing
FRC #1601 (Quantum Samurai)
Team Role: Alumni
 
Join Date: Feb 2011
Rookie Year: 2011
Location: Richmond Hill, NY
Posts: 43
nydnh01 is an unknown quantity at this point
Re: Joystick Command not working

We are using this code to do the drive on our base robot. It has worked in the past with our actual robot and connected the same way our actual robot is wired. I have uploaded the code to the basebot and it seems to not work. All of our jaguars have a solid light indicating a pwm signal and the joystick does not work on commanding the robot. When ever I connect the joystick the button the joystick color on the setup is different indicating the DS is reading the joystick. Does anyone know any solution?
[public class TankDrive extends Thread {
public void run(){
while(true){
Joystick USB1 = new Joystick(1);
RobotDrive drive = new RobotDrive(2,3,1,4);


drive.tankDrive(USB1.getRawAxis(2), USB1.getRawAxis(4));
}

}}
]
Reply With Quote