[wpilib] Fix acceleration getter for DCMotorSim (#7449)

This commit is contained in:
Nicholas Armstrong
2024-11-30 01:15:00 -05:00
committed by GitHub
parent 0941251375
commit b91864a5ec
2 changed files with 2 additions and 2 deletions

View File

@@ -52,7 +52,7 @@ units::radians_per_second_t DCMotorSim::GetAngularVelocity() const {
units::radians_per_second_squared_t DCMotorSim::GetAngularAcceleration() const {
return units::radians_per_second_squared_t{
(m_plant.A() * m_x + m_plant.B() * m_u)(0, 0)};
(m_plant.A() * m_x + m_plant.B() * m_u)(1, 0)};
}
units::newton_meter_t DCMotorSim::GetTorque() const {