[wpimath] Add usage reporting for state-space classes (#8453)

- LinearQuadraticRegulator
- Kalman filters
- Pose estimators
- LinearSystemLoop

Fixes #2925.
This commit is contained in:
Peter Johnson
2025-12-06 09:17:02 -08:00
committed by GitHub
parent 0d1dd84e86
commit baa6379267
20 changed files with 95 additions and 0 deletions

View File

@@ -146,6 +146,22 @@ class WPILibMathShared : public wpi::math::MathShared {
HAL_Report(HALUsageReporting::kResourceType_PathWeaverTrajectory,
count);
break;
case wpi::math::MathUsageId::kController_LinearQuadraticRegulator:
HAL_Report(HALUsageReporting::kResourceType_LinearQuadraticRegulator,
count);
break;
case wpi::math::MathUsageId::kEstimator_KalmanFilter:
HAL_Report(HALUsageReporting::kResourceType_KalmanFilter, count);
break;
case wpi::math::MathUsageId::kEstimator_PoseEstimator:
HAL_Report(HALUsageReporting::kResourceType_PoseEstimator, count);
break;
case wpi::math::MathUsageId::kEstimator_PoseEstimator3d:
HAL_Report(HALUsageReporting::kResourceType_PoseEstimator3d, count);
break;
case wpi::math::MathUsageId::kSystem_LinearSystemLoop:
HAL_Report(HALUsageReporting::kResourceType_LinearSystemLoop, count);
break;
}
}