luxonis / depthai-ros

Official ROS Driver for DepthAI Sensors.
MIT License
239 stars 173 forks source link

[Feature-Request] Move unless arguments as parameters to "<group>" instead of "<include>" for compatibility with multi-robot/sensor systems #472

Open hollydinkel opened 6 months ago

hollydinkel commented 6 months ago

Start with the why:

Describe why this feature would be useful to you and to other users. The current code does not work when running OAK-D Pro with robots and other frames.

Move to the what:

A clear and concise description of the feature you would like to get added to the depthai. I would like <include file="$(find depthai_descriptions)/launch/urdf.launch"> to be wrapped into a <group> on the noetic branch.

Move to the how:

If you already have an idea of how this new feature could be implemented, describe it here.

Current (lines 45-56 in camera.launch):

    <include unless="$(arg pass_tf_args_as_params)" file="$(find depthai_descriptions)/launch/urdf.launch">
        <arg name="base_frame" value="$(arg  name)" />
        <arg name="parent_frame" value="$(arg  parent_frame)"/>
        <arg name="camera_model" value="$(arg  camera_model)"/>
        <arg name="tf_prefix" value="$(arg  name)" />
        <arg name="cam_pos_x" value="$(arg  cam_pos_x)" />
        <arg name="cam_pos_y" value="$(arg  cam_pos_y)" />
        <arg name="cam_pos_z" value="$(arg  cam_pos_z)" />
        <arg name="cam_roll" value="$(arg  cam_roll)" />
        <arg name="cam_pitch" value="$(arg  cam_pitch)" />
        <arg name="cam_yaw" value="$(arg  cam_yaw)" />
    </include>

image

Requested revision:

    <group if="$(arg pass_tf_args_as_params)">
        <include file="$(find depthai_descriptions)/launch/urdf.launch">
            <arg name="base_frame" value="$(arg  name)" />
            <arg name="parent_frame" value="$(arg  parent_frame)"/>
            <arg name="camera_model" value="$(arg  camera_model)"/>
            <arg name="tf_prefix" value="$(arg  name)" />
            <arg name="cam_pos_x" value="$(arg  cam_pos_x)" />
            <arg name="cam_pos_y" value="$(arg  cam_pos_y)" />
            <arg name="cam_pos_z" value="$(arg  cam_pos_z)" />
            <arg name="cam_roll" value="$(arg  cam_roll)" />
            <arg name="cam_pitch" value="$(arg  cam_pitch)" />
            <arg name="cam_yaw" value="$(arg  cam_yaw)" />
        </include>
    </group>

image image