That's not the correct syntax for private parameters. Your example puts them into the same namespace as the node, but not the private namespace.<br><br>You can find full details here:<br><br><a href="http://www.ros.org/wiki/roslaunch/XML/param">http://www.ros.org/wiki/roslaunch/XML/param</a><br>
<br>For your code, it might look like:<br><br><node pkg="something" ... ><br>  <param name="port" value="/dev/ttyUSB0" /><br></node><br><br><div class="gmail_quote">On Wed, Jul 14, 2010 at 12:41 PM, Mike Purvis <span dir="ltr"><<a href="mailto:mpurvis@clearpathrobotics.com">mpurvis@clearpathrobotics.com</a>></span> wrote:<br>
<blockquote class="gmail_quote" style="margin: 0pt 0pt 0pt 0.8ex; border-left: 1px solid rgb(204, 204, 204); padding-left: 1ex;"><div>Hi everyone,</div><div><br></div>My current launch file structure is like so:<div><br></div>
<div><div><launch></div><div>  <env name="PYTHONPATH" value="$(env PYTHONPATH)" /></div><div>

  <group ns="clearpath/robots/$(optenv ID default)" clear_params="true"></div><div>    <param name="port" value="$(optenv CPR_SERIAL_PORT /dev/ttyUSB0)" /></div><div>    <param name="turn_radius" value="0.4" /></div>


<div><br></div><div>    ...</div><div><br></div><div>    <node pkg="clearpath_horizon" type="horizon.py" name="$(anon horizon)" output="screen" /></div><div>    <node pkg="clearpath_2dnav" type="simple.py" name="$(anon nav)" output="screen" /></div>


<div>    ....</div><div>  </group></div><div></launch></div></div><div><br></div><div>And then inside of horizon.py, I am able to access the parameter with rospy.get_param('port'). However, that parameter is really not relevant to any node except horizon.py. From my reading of the documentation, I should be able to make it private by putting the <param> tag inside the relevant node tag, and then calling it with rospy.get_param('~port'). However, this doesn't seem to work---I consistently just get the default parameter.</div>


<div><br></div><div>What am I doing wrong?</div><div><br></div><div>Thanks.</div>
<br>_______________________________________________<br>
ros-users mailing list<br>
<a href="mailto:ros-users@code.ros.org">ros-users@code.ros.org</a><br>
<a href="https://code.ros.org/mailman/listinfo/ros-users" target="_blank">https://code.ros.org/mailman/listinfo/ros-users</a><br>
<br></blockquote></div><br>