If I receive a parameter update and want to check if its the correct type, how could I do this?
Because if I set a param over cmd line and write 1 instead of 1.0, no exception is thrown when receiving the param with false type.
void handleChangedParameters( const rcl_interfaces::msg::ParameterEvent::SharedPtr& event )
{
for ( auto& changed_parameter : event->changed_parameters )
{
auto paramName = changed_parameter.name;
if ( paramName == controllerFrequency )
{
log_info(" is integer: {}", changed_parameter.value. == XXX ? "true" : "false" )
updateFrequencyParam( changed_parameter.value.integer_value );
}
}
}
Originally posted by madmax on ROS Answers with karma: 496 on 2019-08-12
Post score: 0