Ask Your Question
0

performance evaluation of callbacks

asked 2018-12-06 05:01:11 -0600

Hi there,

I was wondering about how to measure the performance in terms of execution time per sec of a specific callback (from a topic subscription or service). Does anyone know if ROS provide such a "feature" ? I'd like to avoid reinventing the wheel :-)

Bests, Augusto

edit retag flag offensive close merge delete

1 Answer

Sort by ยป oldest newest most voted
0

answered 2018-12-06 05:18:28 -0600

I don't know of a specific feature for timing callback functions but you should be able to record the time using ros::Time::now() at the beginning and end of the function. Subtracting one from the other will give you the duration of the callback execution.

This will not give you the timing of the message passing system though, just the callback function itself.

edit flag offensive delete link more

Your Answer

Please start posting anonymously - your entry will be published after you log in or create a new account.

Add Answer

Question Tools

2 followers

Stats

Asked: 2018-12-06 05:01:11 -0600

Seen: 60 times

Last updated: Dec 06 '18