Gazebo | Ignition | Community
Ask Your Question
0

How to interface a C program with Gazebo (without ROS) ?

asked 2022-06-16 08:58:17 -0500

Clement gravatar image

Hello,

Is there a way to interface a C program with Gazebo ? Let's say I have a C program for making autonomous navigation with my robot, and I want to validate it in simulation.
I just need to replace the sensor input by a subscription to the sensor data coming from gazebo, and to export the actuators commands to gazebo.
Is it possible to do that ? I don't see any C API for Gazebo.
I don't want to use ROS, because it means that I would have to rewrite the sequencer in the ROS node.

Thanks in advance

edit retag flag offensive close merge delete

2 Answers

Sort by ยป oldest newest most voted
0

answered 2022-06-24 02:45:54 -0500

Clement gravatar image

I think the best way is to use sockets to make the C program communicate with a ROS node that will make the bridge with Gazebo.

edit flag offensive delete link more
0

answered 2022-06-22 08:37:31 -0500

this post is marked as community wiki

This post is a wiki. Anyone with karma >75 is welcome to improve it.

I think there is a gazebo transport system that allows you to interact with the gazebo server using messages. https://github.com/gazebosim/gz-trans...

https://gazebosim.org/api/transport/1...

I also have a hard time finding good documentation.

edit flag offensive delete link more

Comments

The doc says: "C++ is the native implementation and so far the only way to use the library. We hope to offer different wrappers for the most popular languages in the future."

Clement gravatar imageClement ( 2022-06-24 02:45:03 -0500 )edit
Login/Signup to Answer

Question Tools

1 follower

Stats

Asked: 2022-06-16 08:58:17 -0500

Seen: 25 times

Last updated: Jun 24