Hi everyone,
My current launch file structure is like so:
<launch>
<env name="PYTHONPATH" value="$(env PYTHONPATH)" />
<group ns="clearpath/robots/$(optenv ID default)" clear_params="true">
<param name="port" value="$(optenv CPR_SERIAL_PORT /dev/ttyUSB0)" />
<param name="turn_radius" value="0.4" />
...
<node pkg="clearpath_horizon" type="horizon.py" name="$(anon horizon)" output="screen" />
<node pkg="clearpath_2dnav" type="simple.py" name="$(anon nav)" output="screen" />
....
</group>
</launch>
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.
What am I doing wrong?
Thanks.