diff --git a/rmf_obstacle_detector_laserscan/src/LaserscanDetector.cpp b/rmf_obstacle_detector_laserscan/src/LaserscanDetector.cpp index 00a592a9..f20fcd21 100644 --- a/rmf_obstacle_detector_laserscan/src/LaserscanDetector.cpp +++ b/rmf_obstacle_detector_laserscan/src/LaserscanDetector.cpp @@ -381,6 +381,8 @@ void LaserscanDetector::process() return; auto msg = std::make_unique(); + msg->header.frame_id = _latest_scan->header.frame_id; + msg->header.stamp = this->get_clock()->now(); std::size_t id = 0; for (const auto& scan : scan_obstacles) {