ROS Resources: Documentation | Support | Discussion Forum | Index | Service Status | ros @ Robotics Stack Exchange
Ask Your Question
2

ROS2 middleware message sequence number?

asked 2021-12-15 17:42:43 -0500

rblilja gravatar image

As the message sequence number has been removed from the standard header I'm looking into options of detecting dropped messages. What are my options?

So far I have looked into:

  • Extracting it from the middleware layer, seems still not possible: Foxy Message API Review
  • Creating new custom messages with a sequence field is of course possible, but limits interoperability with existing/third party code. So I'm trying to avoid this solution.

All help appreciated!

I'm on Ubuntu with Foxy and FastDDS.

Thanks!

edit retag flag offensive close merge delete

Comments

Relevant issue and documentation entry, would also like to see suggestions for this

ljaniec gravatar image ljaniec  ( 2021-12-15 19:50:21 -0500 )edit

1 Answer

Sort by » oldest newest most voted
0

answered 2021-12-16 10:28:57 -0500

Mike Scheutzow gravatar image

My advice is to think twice before you design a node that relies on message sequence numbers.

In a distributed network system like ROS where multiple nodes can publish to a topic, it is very expensive to coordinate the sequence number generation (and even if you decide the cost is worth it, then it still might fail due to network problems or node restarts.) I'll also point out you have no way to prevent multiple publishers from existing in the system.

You'll have a more robust system if you find some other mechanism to check whatever it is you want to check.

edit flag offensive delete link more

Comments

Indeed. I shall clarify that I’m only interested in knowing if a message has been lost i.e. not using any sort of retransmission scheme. I’m also under the assumption that only one publisher exist. A very simple setup and need.

However. I still agree with you. It is just that a sequence count would have made things simple in my specific case.

rblilja gravatar image rblilja  ( 2021-12-16 17:13:48 -0500 )edit

Question Tools

4 followers

Stats

Asked: 2021-12-15 17:42:43 -0500

Seen: 497 times

Last updated: Dec 16 '21