Skip to content

Commit

Permalink
changed units to rad
Browse files Browse the repository at this point in the history
  • Loading branch information
jpothen8 committed Feb 14, 2024
1 parent 43eb52b commit a8ead96
Showing 1 changed file with 6 additions and 6 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -40,8 +40,8 @@ class ControllerBindings(
)

private val m_appliedVoltage = mutable(Volts.of(0.0))
private val m_angle = mutable(Rotations.of(0.0))
private val m_velocity = mutable(RotationsPerSecond.of(0.0))
private val m_angle = mutable(Radians.of(0.0))
private val m_velocity = mutable(RadiansPerSecond.of(0.0))

val shooterRoutine = SysIdRoutine(
SysIdRoutine.Config(),
Expand All @@ -62,11 +62,11 @@ class ControllerBindings(
)
.angularPosition(
m_angle.mut_replace(
robot.shooter.leftMotor.position, Rotations
robot.shooter.leftMotor.position, Radians
)
)
.angularVelocity(
m_velocity.mut_replace(robot.shooter.leftVelocity.get(), RotationsPerSecond)
m_velocity.mut_replace(robot.shooter.leftVelocity.get(), RadiansPerSecond)
)
log.motor("shooter-right")
.voltage(
Expand All @@ -76,11 +76,11 @@ class ControllerBindings(
)
.angularPosition(
m_angle.mut_replace(
robot.shooter.rightMotor.position, Rotations
robot.shooter.rightMotor.position, Radians
)
)
.angularVelocity(
m_velocity.mut_replace(robot.shooter.rightVelocity.get(), RotationsPerSecond)
m_velocity.mut_replace(robot.shooter.rightVelocity.get(), RadiansPerSecond)
)
}
},
Expand Down

0 comments on commit a8ead96

Please sign in to comment.