Current code uses the advanced tf2 interfaces, that returns a pose with stamp 0 (we request time 0 to get the latest available transform when getting robot pose). We then overwrite with time now, what is not realistic. Worse, if localization goes off, getRobotPose will keep providing the latest available tf without any warning. If we are not using costmaps, that means that the robot will keep moving while thinking he's standing!
This PR changes to the simple tf2 interfaces that returns the stamp of the latest available tf, and considers it as non valid if older than tf_timeout. Exe path will fail in that case, and the robot will stop, even if not using costmaps.
Moreover, using the simple tf2 interface allows us to simplify in turn the interface of the utility functions.
:warning: Not tested on Kinetic or older that use TF 1. Can anyone do it? :warning:
Current code uses the advanced tf2 interfaces, that returns a pose with stamp 0 (we request time 0 to get the latest available transform when getting robot pose). We then overwrite with time now, what is not realistic. Worse, if localization goes off, getRobotPose will keep providing the latest available tf without any warning. If we are not using costmaps, that means that the robot will keep moving while thinking he's standing!
This PR changes to the simple tf2 interfaces that returns the stamp of the latest available tf, and considers it as non valid if older than tf_timeout. Exe path will fail in that case, and the robot will stop, even if not using costmaps. Moreover, using the simple tf2 interface allows us to simplify in turn the interface of the utility functions.
:warning: Not tested on Kinetic or older that use TF 1. Can anyone do it? :warning: