selfcheck.py: fix rangefinder checking

This commit is contained in:
Oleg Kalachev
2019-03-15 17:39:24 +03:00
parent bfcba26df2
commit 60ebdab19f

View File

@@ -208,11 +208,11 @@ def check_optical_flow():
def check_rangefinder():
# TODO: check FPS!
try:
rospy.wait_for_message('mavros/distance_sensor/rangefinder_3_sub', Range, timeout=0.5)
rospy.wait_for_message('mavros/distance_sensor/rangefinder_sub', Range, timeout=0.5)
except rospy.ROSException:
failure('no randefinder data from Raspberry')
try:
rospy.wait_for_message('mavros/distance_sensor/rangefinder_0', Range, timeout=0.5)
rospy.wait_for_message('mavros/distance_sensor/rangefinder', Range, timeout=0.5)
except rospy.ROSException:
failure('no rangefinder data from PX4')