ROS Resources: Documentation | Support | Discussion Forum | Index | Service Status | ros @ Robotics Stack Exchange |
1 | initial version |
Policy in ROS versioning is that communication between different versions (e.g. kinetic <--> noetic) ought to work provided the format of the messages is the same at both ends.
The message type in question - sensor_msgs/BatteryState - changed between versions melodic and noetic (fields were added for battery temperature). ROS nodes on the robot (pre-installed and/or pre-compiled against kinetic) publish messages in the old BatteryState format. ROS nodes running on a client under noetic look up the format for BatteryState when they are compiled (C++) or executed (Python), find the new format, and thus cannot connect to topics using the old BatteryState format because the two are not identical. There is no automatic translation between earlier and later versions of messages.
There is no magic trick to apply here to make the connection failure go away. Rather, you need to choose from one of a list of practical solutions, which are detailed here. Each of them resolves the format mismatch in a different way, and which you choose would depend upon the constraints of your application.
2 | No.2 Revision |
Policy in ROS versioning is that communication between different versions (e.g. kinetic <--> noetic) ought to work provided the format of the messages is the same at both ends.
The message type in question - sensor_msgs/BatteryState - changed between versions melodic and noetic (fields were added for battery temperature). ROS nodes on the robot (pre-installed and/or pre-compiled against kinetic) publish messages in the old BatteryState format. ROS nodes running on a client under noetic look up the format for BatteryState when they are compiled (C++) or executed (Python), find the new format, and thus cannot connect to topics using the old BatteryState format because the two are not identical. There is no automatic translation between earlier and later versions of messages.
There is no magic trick to apply here to make the connection failure go away. Rather, you need to choose from one of a list of practical solutions, which are detailed here. Each of them resolves the format mismatch in a different way, and which you choose would depend upon the constraints of your application.
I think that covers the options.
3 | No.3 Revision |
Policy in ROS versioning is that communication between different versions (e.g. kinetic <--> noetic) ought to work provided the format of the messages is the same at both ends.
The message type in question - sensor_msgs/BatteryState - changed between versions melodic and noetic (fields were added for battery temperature). ROS nodes on the robot (pre-installed and/or pre-compiled against kinetic) publish messages in the old BatteryState format. ROS nodes running on a client under noetic look up the format for BatteryState when they are compiled (C++) or executed (Python), find the new format, and thus cannot connect to topics using the old BatteryState format because the two are not identical. There is no automatic translation between earlier and later versions of messages.
There is no magic trick to apply here to make the connection failure go away. retro-fit support for noetic in a way that is transparent to the end users. Rather, you need to choose from one of a list of practical solutions, which are detailed here. Each of them resolves the format mismatch in a different way, and which you choose would depend upon the constraints of your application.
I think that covers the options.
4 | No.4 Revision |
Policy in ROS versioning is that communication Communication of topics between nodes built on different versions of ROS (e.g. kinetic <--> noetic) ought seems generally to work provided the format of the messages is the same at both ends.ends. However, gvdhoorn describes the official policy as "there are no guarantees, if it works, it's nice, but don't expect nor assume it to work" (see comment to this answer).
The message type in question - sensor_msgs/BatteryState - changed between versions melodic and noetic (fields were added for battery temperature). ROS nodes on the robot (pre-installed and/or pre-compiled against kinetic) publish messages in the old BatteryState format. ROS nodes running on a client under noetic look up the format for BatteryState when they are compiled (C++) or executed (Python), find the new format, and thus cannot connect to topics using the old BatteryState format because the two are not identical. There is no automatic translation between earlier and later versions of messages.
There is no magic trick to apply here to retro-fit support for noetic in a way that is transparent to the end users. Rather, you need to choose from one of a list of practical solutions, which are detailed here. Each of them resolves the format mismatch in a different way, and which you choose would depend upon the constraints of your application.
I think that covers the options.
In our application we had a commercial robot with many units already in the field, running Kinetic, and publishing BatteryState. Our user base includes robotics researchers but also inexperienced programmers with limited familiarity with command-line tools, etc., who might become frustrated if the solution were too esoteric. We chose the last of the options above because it seemed likely to go smoothly for most users, and did not place constraints on them (for which operating system or ROS version they installed - ROS versions being fairly tightly linked to OS version, in practice, at least for less advanced users). The only additional onus on end users is that clients they author themselves must receive the internal format (borrowed from Kinetic) rather than the ROS-provided standard format (for Noetic, and probably later versions). Operationally, we'll recognise when they miss this, since the error message will be familiar.