iRobotEducation / create3_examples

Example nodes to drive the iRobot® Create® 3 Educational Robot
BSD 3-Clause "New" or "Revised" License
51 stars 12 forks source link

Python implementation of Coverage #32

Closed JonathanNash21 closed 1 year ago

JonathanNash21 commented 1 year ago

Hello,

I was wondering if there is an available python implementation for the coverage action available. I have something for it, but it doesn't work just quite yet - I believe it is because it only handles the ActionClient and does not create a node like the ros2 commands do. If that is what I need to do, is there somewhere in the docs you would suggest looking at to set up a node for this to work? I can also put what code I have here if that would help. Thank you!

alsora commented 1 year ago

Hi @JonathanNash21, there isn't a Python implementation of this example. I don't understand what you mean by "I believe it is because it only handles the ActionClient and does not create a node like the ros2 commands do".

Note that the purpose of these examples is to show how to use the Create 3 APIs (e.g. how do you create a dock/undock goal, how do you check hazards, etc) and this is equivalent between Python and C++.

I recommend you to get familiar with ROS 2 action in Python before trying to re-implement the coverage example, because a solid understanding of ROS 2 is a requirement before developing something like this. Once you have done that, the task should be trivial. You can have a look at https://docs.ros.org/en/humble/Tutorials/Intermediate/Writing-an-Action-Server-Client/Py.html