Re: [ros-users] read parameter in launch file

Top Page
Attachments:
Message as email
+ (text/plain)
Delete this message
Reply to this message
Author: User discussions
Date:  
To: User discussions
Subject: Re: [ros-users] read parameter in launch file
On Tue, Oct 5, 2010 at 11:04 AM, Axelrod, Benjamin <> wrote:
> Is there any way to read a parameter in a launch xml file?  For example, I
> set the value of a parameter at the top of the file, then lower in the file
> I read the parameter and use it for something.  Or must this type of thing
> be done through environment variables?  If so, this seems like a strange
> restriction.  Is there any reasoning behind this?


Not sure what your use case is, but there are other options available.

You can set a parameter at the top of a launch file and use it in
several nodes using the searchParam() method, which works even with
included launch files and subordinate namespaces.
--
 joq