Class SwerveModuleRealIO

java.lang.Object
frc.robot.subsystems.DriveTrain.SwerveModule
frc.robot.subsystems.DriveTrain.SwerveModuleRealIO

public class SwerveModuleRealIO extends SwerveModule
  • Field Details

    • steer_motor

      public com.ctre.phoenix6.hardware.TalonFX steer_motor
    • drive_motor

      public com.ctre.phoenix6.hardware.TalonFX drive_motor
    • steer_sensor

      public com.ctre.phoenix6.hardware.CANcoder steer_sensor
  • Constructor Details

    • SwerveModuleRealIO

      public SwerveModuleRealIO(int drive_port, int steer_port, int sensor_port)
  • Method Details

    • getSpeed

      public double getSpeed()
    • getPosition

      public double getPosition()
    • getAngle

      public edu.wpi.first.math.geometry.Rotation2d getAngle()
    • getModuleState

      public edu.wpi.first.math.kinematics.SwerveModuleState getModuleState()
    • getModulePosition

      public edu.wpi.first.math.kinematics.SwerveModulePosition getModulePosition()
    • setDrive

      public void setDrive(double speedMetersPerSecond)
    • setSteer

      public void setSteer(double volts)