// Copyright (c) FIRST and other WPILib contributors. // Open Source Software; you can modify and/or share it under the terms of // the WPILib BSD license file in the root directory of this project. package frc.robot; import edu.wpi.first.wpilibj.Joystick; import edu.wpi.first.wpilibj.XboxController; import edu.wpi.first.wpilibj2.command.Command; import edu.wpi.first.wpilibj2.command.Commands; import edu.wpi.first.wpilibj2.command.RunCommand; import edu.wpi.first.wpilibj2.command.button.CommandXboxController; import edu.wpi.first.wpilibj2.command.button.JoystickButton; import frc.robot.subsystems.Drive; public class RobotContainer { CommandXboxController manette = new CommandXboxController(0); Joystick joystick1 = new Joystick(0); Drive drive = new Drive(); public RobotContainer() { configureBindings(); // drive.setDefaultCommand(new RunCommand(()->{ // drive.drive(manette.getLeftX(), manette.getLeftY(), manette.getRightX()); //},drive)); drive.setDefaultCommand(new RunCommand(()->{ drive.drive(joystick1.getX(), -joystick1.getY(), joystick1.getZ()); },drive)); } private void configureBindings() { JoystickButton button =new JoystickButton(joystick1, 1); } public Command getAutonomousCommand() { return Commands.print("No autonomous command configured"); } }