ROS Resources: Documentation | Support | Discussion Forum | Index | Service Status | ros @ Robotics Stack Exchange
Ask Your Question

Revision history [back]

Yes it is possible to do exactly what you want. The package you'll be using is ros_type_introspection this allows you to dynamically access the meta information of a message and extract the values from any message type.

There is tutorial that shows you how to do exactly what you're asking about here.

The only limitation of this technique is that you can't automatically create the original ros message type objects, you'd have to code for each one individually.

Hope this helps.