rosparam returns string not yaml array
I'm trying to define an array in yaml file and load into parameter server in launch file. The following bit of code
XmlRpc::XmlRpcValue temp;
nhp.searchParam("/r_arm/position/my_param", temp);
ROS_ASSERT(temp.getType() == XmlRpc::XmlRpcValue::TypeArray);
Fails with the assertion that "temp" is an XmlRpcValue::TypeString not an array, even though
rosparam get /r_arm/position/my_param
[0.0, 0.0, 0.0, 0.0, 0.0, 0.0]
shows the array.
They yaml code looks like:
{r_arm:{position:{
my_param:[0.0,0.0,0.0,0.0,0.0,0.0]
,my_param2:[0.0,0.0,0.0,0.0,0.0,0.0]
},force:{
...
Any ideas what I am doing wrong?
(ros Groovy version)