4#include <robot_driver/estimators/state_estimator.h>
19 void init(ros::NodeHandle& nh);
25 const Eigen::Vector3d& pos);
31 bool updateOnce(quad_msgs::RobotState& last_robot_state_msg);
37 Eigen::Matrix<double, 2, 2> A;
38 Eigen::Matrix<double, 2, 1> B;
39 Eigen::Matrix<double, 1, 2> C;
40 Eigen::Matrix<double, 1, 1> D;
43 std::vector<Eigen::Matrix<double, 2, 1>> x;
57 std::vector<double> high_pass_b_;
58 std::vector<double> high_pass_c_;
59 std::vector<double> high_pass_d_;
63 std::vector<double> low_pass_b_;
64 std::vector<double> low_pass_c_;
65 std::vector<double> low_pass_d_;
Implements complementary filter as an estimator within the ROS framework.
Definition comp_filter_estimator.h:7
Eigen::Vector3d imu_vel_estimate_
Best estimate of imu velocity.
Definition comp_filter_estimator.h:74
std::vector< double > low_pass_a_
Low Pass States.
Definition comp_filter_estimator.h:62
void mocapCallBackHelper(const geometry_msgs::PoseStamped::ConstPtr &msg, const Eigen::Vector3d &pos)
Helper function to filter mocap data.
Definition comp_filter_estimator.cpp:109
ros::NodeHandle nh_
Nodehandle to get param.
Definition comp_filter_estimator.h:80
Eigen::Vector3d mocap_vel_estimate_
Best estimate of velocity from mocap diff.
Definition comp_filter_estimator.h:71
bool updateOnce(quad_msgs::RobotState &last_robot_state_msg)
Perform CF update once.
Definition comp_filter_estimator.cpp:40
Filter low_pass_filter
Low pass filter.
Definition comp_filter_estimator.h:50
ros::Time last_mocap_time_
Last mocap time.
Definition comp_filter_estimator.h:77
CompFilterEstimator()
Constructor for CompFilterEstimator.
Definition comp_filter_estimator.cpp:3
Filter high_pass_filter
High pass filter.
Definition comp_filter_estimator.h:53
void init(ros::NodeHandle &nh)
Initialize Complementary Filter.
Definition comp_filter_estimator.cpp:5
Eigen::Vector3d vel_estimate_
Best estimate of velocity.
Definition comp_filter_estimator.h:68
std::vector< double > high_pass_a_
High Pass States.
Definition comp_filter_estimator.h:56
Definition state_estimator.h:18
Struct of second-order low/high pass filter with derivative/intergral.
Definition comp_filter_estimator.h:35