ROS Resources: Documentation | Support | Discussion Forum | Index | Service Status | ros @ Robotics Stack Exchange
Ask Your Question

Nico.Zhou's profile - activity

2018-07-25 04:14:36 -0500 received badge  Student (source)
2017-11-08 07:44:04 -0500 received badge  Famous Question (source)
2017-03-01 22:08:19 -0500 commented answer How to set the parameter to let message_filters enter callback function

Yes,I have done it with three topics before. It works fine.

2017-03-01 21:25:30 -0500 commented answer How to set the parameter to let message_filters enter callback function

You can check it on my github

2017-03-01 21:24:34 -0500 commented answer How to set the parameter to let message_filters enter callback function

If the rate of all the topics is similar then the parameter values is not very important. The reason I fail to sync the data is I use the message filter in a wrong way. It works fine now after I change the code.

2017-03-01 20:09:57 -0500 received badge  Notable Question (source)
2017-03-01 18:41:26 -0500 received badge  Popular Question (source)
2016-07-20 07:27:38 -0500 asked a question How to set the parameter to let message_filters enter callback function

I want to use message_filters to get the image and imu message at the same time,but it's works sometimes because of different imu message frequency, I want to know how to set ApproximatePolicy param,here shows the code

  message_filters::Subscriber<Image> image1_sub(nh, "/stereo/left/image_raw", 1);
  message_filters::Subscriber<Image> image2_sub(nh, "/stereo/right/image_raw", 1);
  message_filters::Subscriber<Imu> imu_sub(nh, "/inertial_tf/imu", 1);
  message_filters::Subscriber<NavSatFix> gps_sub(nh, "/inertial_tf/gps", 1);
  typedef ApproximateTime<Image, Image,Imu,NavSatFix> ApproximatePolicy;
  typedef message_filters::Synchronizer<ApproximatePolicy> ApproximateSync;

  boost::shared_ptr<ApproximateSync> approximate_sync_;
  approximate_sync_.reset( new ApproximateSync(ApproximatePolicy(2000),
                                               image1_sub, image2_sub,imu_sub,gps_sub) );
  approximate_sync_->registerCallback(boost::bind(&imgimumsgFilter::callback,
                                                      &iif, _1, _2, _3, _4));

it works fine with this param when the frequency of image is 20Hz, and frequency of IMU is 100Hz, but when the frequency of IMU change to 60Hz,it did't work ,even I change the subscribe queue size and approximate time ,it is still didn't work and can't enter the callback function, so I want to know how to set this param correctly.Thanks!

2016-06-06 14:34:02 -0500 received badge  Famous Question (source)
2016-05-16 02:00:57 -0500 received badge  Scholar (source)
2016-05-16 02:00:52 -0500 commented answer Can I use robot_localization package with only imu data? If I could,how to config the package?

Thanks for your answer Tom, I'm think about fuse visual odometry, hope I can get good result.

2016-05-10 03:09:20 -0500 received badge  Notable Question (source)
2016-05-10 03:08:09 -0500 received badge  Popular Question (source)
2016-05-02 04:01:25 -0500 received badge  Enthusiast
2016-04-25 03:51:22 -0500 asked a question Can I use robot_localization package with only imu data? If I could,how to config the package?

I want to fuse IMU and GPS data with robot_localization package used in an autonomous car, but there will have some time that I can't obtain the GPS data and IMU is the only source I can get to calculate position. I have a high precise IMU,but the error is huge when I use robot_localization without gps, so my question is can I use robot_localization package with only imu data.If I could,how to config the package correctly? Here is my launch file:

<launch>
  <node pkg="tf2_ros" type="static_transform_publisher" name="bl_imu" args="0 0 0 0 0 0 1 base_link imu_link" />
  <node pkg="tf2_ros" type="static_transform_publisher" name="bl_gps" args="0 0 0 0 0 0 1 imu_link gps_link"/>
  <node pkg="robot_localization" type="ekf_localization_node" name="ekf_localization_global" clear_params="true">
    <param name="frequency" value="30"/>
    <param name="sensor_timeout" value="2"/>
    <!--param name="map_frame" value="map"/-->
    <param name="odom_frame" value="odom"/>
    <param name="base_link_frame" value=" base_link"/>
    <param name="world_frame" value="odom"/>
    <param name="imu0" value="/imuData"/>
    <rosparam param="imu0_config">[false, false, false,
                                   true,  true,  true,
                                   false, false, false,
                                   true, true, true,
                                   true,  true,  true]</rosparam>
    <param name="imu0_differential" value="true"/>
    <param name="imu0_remove_gravitational_acceleration" value="true"/>
    <param name="two_d_mode" value="true"/>
    <param name="odom0" value="/odometry/gps"/>
    <rosparam param="odom0_config">[true,  true,  true,
                                   false, false, false,
                                   false, false, false,
                                   false, false, false,
                                   false, false, false]</rosparam>
  </node>
  <node pkg="robot_localization" type="navsat_transform_node"
      name="navsat_transform_node"  respawn="true" output="screen">
    <param name="magnetic_declination_radians" value="0.157"/>
    <param name="yaw_offset" value="1.570796327"/>
    <remap from="/imu/data" to="/imuData"/>
    <remap from="/gps/fix" to="/gpsData"/>
  </node>
  <node pkg="rviz" type="rviz" name="rviz_imu_gps_fuse" output="screen" args="-d $(find robot_localization)/robot_localization.rviz"/>
</launch>
2016-04-24 06:35:06 -0500 received badge  Supporter (source)
2016-04-21 09:10:06 -0500 commented question ekf_localization with gps and imu

Yeah,it helped me, thanks so much

2016-04-21 01:55:13 -0500 commented question ekf_localization with gps and imu

Can you send me the link for the plug-in. Thanks