Skip to content
Snippets Groups Projects
Commit 155e431d authored by Joan Vallvé Navarro's avatar Joan Vallvé Navarro
Browse files

more versatile topic suffixes

parent 6b8f1ac5
No related branches found
No related tags found
2 merge requests!3After cmake and const refactor,!1new release
......@@ -24,8 +24,8 @@ SubscriberGnss::SubscriberGnss(const SensorBasePtr& sensor_ptr) :
void SubscriberGnss::initSubscriber(ros::NodeHandle& nh, const std::string& topic)
{
sub_ = nh.subscribe(topic+std::string("_obs"), 1, &SubscriberGnss::callbackObservation, this);
sub_nav_ = nh.subscribe(topic+std::string("_nav"), 1, &SubscriberGnss::callbackNavigation, this);
sub_ = nh.subscribe(topic+std::string("obs"), 1, &SubscriberGnss::callbackObservation, this);
sub_nav_ = nh.subscribe(topic+std::string("nav"), 1, &SubscriberGnss::callbackNavigation, this);
}
......@@ -37,7 +37,7 @@ void SubscriberGnss::callbackObservation(const iri_gnss_msgs::Observation::Const
GnssUtils::ObservationsPtr obs_ptr = std::make_shared<GnssUtils::Observations>();
GnssUtils::fillObservation(*obs_ptr, msg);
GnssUtils::SnapshotPtr snapshot_ptr = std::make_shared<GnssUtilsSnapshot>(obs_ptr, last_nav_ptr_);
GnssUtils::SnapshotPtr snapshot_ptr = std::make_shared<GnssUtils::Snapshot>(obs_ptr, last_nav_ptr_);
CaptureGnssPtr new_capture = std::make_shared<CaptureGnss>(TimeStamp(msg->header.stamp.sec, msg->header.stamp.nsec),
sensor_ptr_,
snapshot_ptr);
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment