Gazebo | Ignition | Community
Ask Your Question
1

Plugin Inter-communication and Timing

asked 2014-12-05 03:52:17 -0500

gajan gravatar image

updated 2014-12-05 06:00:34 -0500

Hi,

I have the following setup in Gazebo 2.2.5:

  1. Plugin A publishes a .proto message at every ConnectWorldUpdateBegin event.

  2. Plugin B: subscribes to the above message AND runs a method at every ConnectWorldUpdateBegin event. This method works on the last received message.

Now my questions are:

  1. Is there any synchronization happening between the Gazebo message passing and raising the ConnectWorldUpdateBegin events? Can I assume the maximum delay in the messages in my setting above is one period (i.e., one update step)

  2. Is there a mechanism to directly call another plugin's public method? Is there a reason for having the following variable private in Model.hh? (calling directly would make things more deterministic)

    private: std::vector<modelpluginptr> plugins;

Thank you for your time.

G

edit retag flag offensive close merge delete

1 Answer

Sort by ยป oldest newest most voted
1

answered 2014-12-05 16:38:24 -0500

nkoenig gravatar image

The transport mechanism run independently from events, including the ConnectWorldUpdateBegin event.

You can't call another plugin's public method directly. You can talk between plugins using pub/sub.

edit flag offensive delete link more

Question Tools

Stats

Asked: 2014-12-05 03:52:17 -0500

Seen: 315 times

Last updated: Dec 05 '14