Ask Your Question

Revision history [back]

click to hide/show revision 1
initial version

You can do the following:

import launch
from launch.actions import DeclareLaunchArgument, LogInfo
from launch.substitutions import LaunchConfiguration


def generate_launch_description():

ld = launch.LaunchDescription()
declare_id = DeclareLaunchArgument('id', default_value='75', description='an id')
target = ['robot_', LaunchConfiguration('id'), '/target']
loginfo = LogInfo(msg = target)

ld.add_action(declare_id)
ld.add_action(loginfo)

return(ld)