-
Notifications
You must be signed in to change notification settings - Fork 38
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
ROS2 Reliable QoS Support #48
Comments
Currently, the Note that the ros2mqtt.ros.subscriber = create_generic_subscription(
ros_topic, msg_type, ros2mqtt.ros.queue_size, bound_callback_func); mqtt2ros.ros.publisher = create_generic_publisher(
mqtt2ros.ros.topic, ros_msg_type, mqtt2ros.ros.queue_size); These functions actually require to pass an I guess it would make sense to add more configuration options to |
Hi @lreiher, thanks for the explanation.
I noticed that this also guarantees me compatibility with the "reliable" topics, although I suppose it doesn't guarantee me reliability. |
I think it make sense to have explicit QoS support for the mqtt->ros converison, but for the ros -> mqtt conversion since the subscribers are created lazily, isn't it as simple as doing: get_publisher_info_by_topic instead of get_topic_names_and_types and then using the QoS matching the publisher? |
at the risk of hijacking, I am working on a patch locally that adds configuration like this:
its not just setting the QoS, its being explicit with the ros message type creation (explicitly about the mqtt->ros direction) But I am not sure that doing something similar in the other direction is really useful since it seems fine to me to just wait until we see a publisher and get the type and qos information from them. |
Cool that you are working on flexibly defining QoS! For the ros-to-mqtt connections, how about also offering the flexible configuration, but also allowing to the QoS parameters to |
sure, I could do that. I did implement that auto qos fix I suggested and it does work. I don't mind adding in the explicit for that direction flow direction as well. |
Sounds great, looking forward to a PR! |
Hello,
I'm trying to use the mqtt_client to subscribe to ROS2 topics with QoS of type RELIABLE, VOLATILE but i get the error of incompatible QoS:
[mqtt_client-1] [WARN] [1704882384.623365432] [mqtt_client]: New publisher discovered on topic '/laser/data', offering incompatible QoS. No messages will be sent to it. Last incompatible policy: RELIABILITY_QOS_POLICY
I saw in the documentation that it is possible to change the QoS of MQTT topics. Is it possible to do the same thing for ROS2 topics as well?
The text was updated successfully, but these errors were encountered: