ROS Resources: Documentation | Support | Discussion Forum | Index | Service Status | ros @ Robotics Stack Exchange |
1 | initial version |
Exposing python code inside a c++ is not recommended. Most people trying to do this will do something like exec'ing a child process and parsing the command line output if really necessary. But that's very brittle.
The ROS style approach would be to create messages which provide the "defines" or constants to all languages. And expose the functionality as a ROS service or matching pub/sub topics which can then transition from c++ to python and back.