10struct TrackingWheelConfig;
22 Eigen::Matrix<float, 1, 3> H;
23 float measurementNoise;
24 float xProcessNoise = 0.01f, yProcessNoise = 0.01f, thetaProcessNoise = 0.001f;
27 EIGEN_MAKE_ALIGNED_OPERATOR_NEW
36 PoseEKF(
float initial_x,
float initial_y,
float initial_theta);
46 void setProcessNoise(
float xNoise,
float yNoise,
float thetaNoise,
float measNoise);
55 void predict(
float dx_local,
float dy_local,
float dtheta);
63 void updateIMU(
float measured_theta,
float dynamic_R);
76 void updateTrackingWheels(
const std::vector<TrackingWheelConfig>& configs,
const Eigen::VectorXf& measured_deltas,
77 float dx_local,
float dy_local,
float dtheta,
float wheel_noise);
92 float getX()
const {
return x(0); }
98 float getY()
const {
return x(1); }
113 void setPose(
float new_x,
float new_y,
float new_theta);
Extended Kalman Filter implementation for maintaining the robot's pose.
void predict(float dx_local, float dy_local, float dtheta)
The prediction step of the EKF based on local relative movements.
float getY() const
Get current Y position.
EIGEN_MAKE_ALIGNED_OPERATOR_NEW PoseEKF(float initial_x, float initial_y, float initial_theta)
Construct a new Pose EKF object.
float getTheta() const
Get current heading angle.
void updateIMU(float measured_theta, float dynamic_R)
Update the state using absolute heading measured by an IMU.
void updateTrackingWheels(const std::vector< TrackingWheelConfig > &configs, const Eigen::VectorXf &measured_deltas, float dx_local, float dy_local, float dtheta, float wheel_noise)
Update the state using unpowered tracking wheels data.
void setPose(float new_x, float new_y, float new_theta)
Reset the state to a specific pose.
float getX() const
Get current X position.
void setTrackingWheelNoise(float xNoise, float yNoise, float thetaNoise)
Set specific process noises when using tracking wheels.
void setProcessNoise(float xNoise, float yNoise, float thetaNoise, float measNoise)
Set the process noise values for the Kalman filter matrices.