[ros-users] passing arguments to an executable with roslaunc…

Top Page
Attachments:
Message as email
+ (text/plain)
Delete this message
Reply to this message
Author: Steven Bellens
Date:  
To: ros-users
Subject: [ros-users] passing arguments to an executable with roslaunch
Hi,

I'm trying to start a rosnode with the roslaunch command and a launch file.
The command I use to start the program manually is:

'rosrun ocl_2.0 deployer-gnulinux -s deployer.xml'

which executes 'deployer-gnulinux' in the ocl_2.0 package with
arguments '-s deployer.xml'
My pelican.launch file contains:

<launch>
<node name="pelican" pkg="ocl_2.0" type="deployer-gnulinux" args="-s
deployer.xml" output="screen"/>
</launch>

but when I launch this with 'roslaunch pelican.launch' it says:
"...
Exception:too many positional options
Allowed options:
  -h [ --help ]           Show program usage
  -s [ --start ] arg      Deployment configuration file (eg 'config-file.xml')
  --site-file arg         Site deployment file (eg 'Deployer-site.cpf' or
                          'Deployer-site.xml')
  -l [ --log-level ] arg  Level at which to log from RTT (case-insensitive)
                          Never,Fatal,Critical,Error,Warning,Info,Debug,Realtim
                          e
  --no-consolelog         Turn off RTT logging to the console (will still log
                          to 'orocos.log')
  --require-name-service  Require CORBA name service
  --DeployerName arg      Name of deployer component (the --DeployerName flag
                          is optional)
..."


Which looks like the args don't get passed in the right way to the
program executable. What exactly happens when this roslaunch command
is executed and the args are passed to the goal program? Is it
possible roslaunch adds extra elements here? How can I make roslaunch
pass the right arguments to the program executable?

best regards,

Steven