Closed hanggaga closed 5 years ago
Indeed, currently the examples are quite empty and would benefit from a PR... You may want to give it a try though, in case the instructions there still work with minimal changes.
Otherwise you can get inspiration from rostful code.The backend class does access to topics information and pub sub messages : https://github.com/pyros-dev/rostful/blob/master/rostful/api_0_1/flask_views.py#L105 but you will have to untangle the web/json formatting code from the pyros API call.
But depending on what you want to do, this may or may not be the best approach. If you re are indeed a newbie, you should first learn from the ROS tutorials.
Pyros is about interfacing multiprocess systems(like ROS, or a web backend), using python. Interfacing between python and ROS can overall be done in 5 different ways :
Pyros is currently doing 2, and I have been working on and off, when time/resources permit, on a few packages for 3, as the code would be much simpler (except a few python tricks) and more maintainable overall.
Thank you for your prompt reply.
I'm newbie. I need a simple code to publisher/subscriber information with the topics I want. please help!.