rsasaki0109 / lidar_localization_ros2

3D LIDAR Localization using NDT/GICP and pointcloud map in ROS 2 (Not SLAM)
BSD 2-Clause "Simplified" License
249 stars 48 forks source link

specifying the lidar frame id #25

Open space192 opened 1 year ago

space192 commented 1 year ago

Is it possible to set the frame id of the lidar in the parameters.yaml file ?

rsasaki0109 commented 1 year ago

The following frame IDs can be set, but there is no transformation from the scan's lidar frame to the base_link. https://github.com/rsasaki0109/pcl_localization_ros2/blob/main/src/pcl_localization_component.cpp#L9-L11 This means that the base_link and the lidar frame must match, or the conversion must be done at a different node beforehand.

If needed, for example, you might have to implement it referring to the following: https://github.com/autowarefoundation/autoware.universe/blob/main/localization/ndt_scan_matcher/src/ndt_scan_matcher_core.cpp#L492-L506C1