View Single Post
  #3   Spotlight this post!  
Unread 02-15-2016, 07:00 PM
CyberTeam5713 CyberTeam5713 is offline
Registered User
FRC #5713
 
Join Date: Feb 2016
Location: Michigan
Posts: 25
CyberTeam5713 is an unknown quantity at this point
help im new to this

I was researching how to program xbox controller to arcade and use one analog stick. Im using talons so what is speed control? and how do i program the xbox controller

public void teleopPeriodic() {
while (isOperatorControl() && isEnabled()) {
drive.setSafetyEnabled(true);
double speedControl = 1;
double joystickLeftY = mXboxController.getRawAxis(1)*speedControl;
double joystickLeftX = mXboxController.getRawAxis(0)*-1*speedControl;
drive.arcadeDrive(joystickLeftY, joystickLeftX);
Reply With Quote