Building a simulation for an existing ROS2 robot

asked 2023-05-01 19:43:52 -0600

hellvetica42 gravatar image

Hi,

me and my team are building a soccer robot for the MSL RoboCup competition. We are at a point where we need a simulation using ROS2 to make developing code for tactics and other systems easier. I need to build gazebo plugins that subscribe and publish to our existing topics so I can make our existing code interface with a simulation. Since our robots run on omniwheels the idea is to just use a cylinder with low friciton and use gazebo to add forces to it instead of our motor controller node and use a service to stick the ball to the robot when 'dribbling' etc. Something similar to this project from the chinese team: https://github.com/nubot-nudt/gazebo_... (this is built on ros1 though)

The problem I'm running into is lack of documentation. The newer versions of gazebo (gazebo garden) have next to no docs related to plugins and ros2 integration. I then went through plugin tutorials for older verisons of gazebo (gazebo11) and while I understand plugins a bit more than before, it's still not clear to me how to make them interface with ROS2. Do i just make a plugin a node somehow?

I'm relatively new to gazebo so some pointers would be much appreciated. Ideally I would like a simple plugin example that subscribes to a topic and uses that data to interface with the gazebo/physics system and/or publishes data from the simulation to a topic. (for example the current position of a model in space). Any resources/tutorials/docs that you know of that can help me in this would be very much appreciated. Thanks

edit retag flag offensive close merge delete

Comments

azeey gravatar imageazeey ( 2023-05-03 00:35:39 -0600 )edit

Thank you. I did not come across that and it's exactly what i need

hellvetica42 gravatar imagehellvetica42 ( 2023-05-03 06:47:42 -0600 )edit

Glad to hear that helped. I'm trying to understand why people aren't able to find it. I suspect google is not listing those pages. What was your experience? Any feedback would be welcome.

azeey gravatar imageazeey ( 2023-05-03 09:49:23 -0600 )edit