Commit 0da4a492 authored by Niklas Yann Wettengel's avatar Niklas Yann Wettengel
Browse files

read scan topic from parameterserver

parent 96d618ef
...@@ -9,8 +9,10 @@ HomerNavigationNode::HomerNavigationNode() ...@@ -9,8 +9,10 @@ HomerNavigationNode::HomerNavigationNode()
= nh.subscribe<nav_msgs::OccupancyGrid>("/map", 3, &HomerNavigationNode::mapCallback, this); = nh.subscribe<nav_msgs::OccupancyGrid>("/map", 3, &HomerNavigationNode::mapCallback, this);
m_pose_sub = nh.subscribe<geometry_msgs::PoseStamped>( m_pose_sub = nh.subscribe<geometry_msgs::PoseStamped>(
"/pose", 3, &HomerNavigationNode::poseCallback, this); "/pose", 3, &HomerNavigationNode::poseCallback, this);
std::string scan_topic;
nh.param<std::string>("/homer_scan_topic", scan_topic, "/scan");
m_laser_data_sub = nh.subscribe<sensor_msgs::LaserScan>( m_laser_data_sub = nh.subscribe<sensor_msgs::LaserScan>(
"/scan", 3, &HomerNavigationNode::laserDataCallback, this); scan_topic, 3, &HomerNavigationNode::laserDataCallback, this);
m_down_laser_data_sub = nh.subscribe<sensor_msgs::LaserScan>( m_down_laser_data_sub = nh.subscribe<sensor_msgs::LaserScan>(
"/front_scan", 3, &HomerNavigationNode::laserDataCallback, this); "/front_scan", 3, &HomerNavigationNode::laserDataCallback, this);
m_start_navigation_sub m_start_navigation_sub
......
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment