septentrio-gnss / septentrio_gnss_driver

ROS 1 & 2 driver for Septentrio GNSS & INS receivers
BSD 3-Clause "New" or "Revised" License
84 stars 43 forks source link

Namespace handling #107

Closed abaeyens-imod closed 9 months ago

abaeyens-imod commented 1 year ago

Issue description

Specifying a namespace when launching the Septentrio node does not effect the names of the published topic - they are always published in the root name space.

For topics like /insnavgeod this is not much of an issue, it's clear they're from the Septentrio and there aren't other nodes that publish such topics, but for others like /imu and /pose this will cause confusion. Also, preferably nodes ought to operate in a given namespace when they are launched in that given namespace.

Steps to reproduce the issue

  1. Setup Septentrio hard & software
  2. Specify which namespace to launch the Septentrio nodes with in the Septentrio launch file
  3. Launch with that launch file
  4. Look at the names of the published topics

What's the expected result?

arne@laptop:~$ ros2 topic list
/<namespace>/insnavgeod
/<namespace>/imu
/<namespace>/pose
etc.

What's the actual result?

arne@laptop:~$ ros2 topic list
/insnavgeod
/imu
/pose
etc.

Additional details

This is likely due to the topics being defined with a preceding slash in septentrio_gnss_driver/src/septentrio_gnss_driver/communication/message_handler.cpp, e.g.

publish<INSNavCartMsg>("/insnavcart", last_insnavcart_);

instead of

publish<INSNavCartMsg>("insnavcart", last_insnavcart_);

Version

Compiled septentro_gnss_driver from source, branch ros2, HEAD commit 207c37bc.

Thank you in advance for addressing this. Should you need more details or information, please don't hesitate to ask.

thomasemter commented 1 year ago

Thank you for the report. This is indeed handled incorrectly and will be fixed.

abaeyens-imod commented 9 months ago

Thank you for resolving this!