Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Why namespace is fixed as node_name #2761

Open
hyunseok-yang opened this issue Jun 1, 2023 · 8 comments
Open

Why namespace is fixed as node_name #2761

hyunseok-yang opened this issue Jun 1, 2023 · 8 comments

Comments

@hyunseok-yang
Copy link
Contributor

I'd like to apply namespace in realsense node, but it fixed a namesapce as a node name by default.
Is this right apporach...?
Or if there is a any intention?

@MartyG-RealSense
Copy link
Collaborator

Hi @hyunseok-yang Are you trying to set a custom namespace for your camera in your launch of the RealSense ROS wrapper? If you are then you can do this by setting the camera parameter in the ROS1 wrapper:

roslaunch realsense2_camera rs_camera.launch camera:=cam_1

For ROS2 I believe that it would be something like this:

ros2 launch realsense2_camera rs_launch.py camera_name1:=cam1

If you are trying to do something other than set a namespace in the launch then please provide further information. Thanks!

@hyunseok-yang
Copy link
Contributor Author

Hi @hyunseok-yang Are you trying to set a custom namespace for your camera in your launch of the RealSense ROS wrapper? If you are then you can do this by setting the camera parameter in the ROS1 wrapper:

roslaunch realsense2_camera rs_camera.launch camera:=cam_1

For ROS2 I believe that it would be something like this:

ros2 launch realsense2_camera rs_launch.py camera_name1:=cam1

If you are trying to do something other than set a namespace in the launch then please provide further information. Thanks!

Hi,
I think this should be modified like this.
namespace=LaunchConfiguration("camera_name"), ==> namespace=LaunchConfiguration("namespace"),

          launch_ros.actions.Node(
                package='realsense2_camera',
                namespace=LaunchConfiguration("namespace") ,
                name=LaunchConfiguration("camera_name"),

@MartyG-RealSense
Copy link
Collaborator

MartyG-RealSense commented Jun 2, 2023

Thanks very much @hyunseok-yang

The only example that I have of setting camera_name in ROS2 that I have, which I based my own suggestion on, is the launch file rs_multi_camera_launch.py

https://github.com/IntelRealSense/realsense-ros/blob/ros2-development/realsense2_camera/launch/rs_multi_camera_launch.py

@hyunseok-yang
Copy link
Contributor Author

Thanks very much @hyunseok-yang

The only example that I have of setting camera_name in ROS2 that I have, which I based my own suggestion on, is the launch file rs_multi_camera_launch.py

https://github.com/IntelRealSense/realsense-ros/blob/ros2-development/realsense2_camera/launch/rs_multi_camera_launch.py

All I need was actually topic names from realsensenso node as /{namespace}/{camera_name}/blah~blah.

So I would like to sugget like in new PR(#2764).

@MartyG-RealSense
Copy link
Collaborator

Thanks so much @hyunseok-yang for your PR!

As this issue is associated with your PR, I have added an Enhancement label to it so that it is kept open whilst your PR is active. Thanks again!

@hyunseok-yang
Copy link
Contributor Author

Thanks so much @hyunseok-yang for your PR!

As this issue is associated with your PR, I have added an Enhancement label to it so that it is kept open whilst your PR is active. Thanks again!

Do I need to assign someone else for that PR?

@MartyG-RealSense
Copy link
Collaborator

No you don't need to assign reviewers or assign yourself. The Intel RealSense developer team should assign a reviewer themselves at a future date.

@hyunseok-yang
Copy link
Contributor Author

No you don't need to assign reviewers or assign yourself. The Intel RealSense developer team should assign a reviewer themselves at a future date.

Ok Thanks! have a good day!

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

2 participants