AP_RangeFinder: TFminiPlus driver outputs init failure to ground station

This commit is contained in:
ashvath 2020-01-16 22:22:51 +05:30 committed by Lucas De Marchi
parent b0ee6393ae
commit 54708d916b
1 changed files with 3 additions and 2 deletions

View File

@ -18,6 +18,7 @@
#include <utility>
#include <GCS_MAVLink/GCS.h>
#include <AP_HAL/AP_HAL.h>
extern const AP_HAL::HAL& hal;
@ -101,8 +102,8 @@ bool AP_RangeFinder_Benewake_TFMiniPlus::init()
}
if (val[5] * 10000 + val[4] * 100 + val[3] < 20003) {
hal.console->printf(DRIVER ": minimum required FW version 2.0.3, but version %u.%u.%u found\n",
val[5], val[4], val[3]);
GCS_SEND_TEXT(MAV_SEVERITY_ERROR, "TFMini: FW ver %u.%u.%u (need>=2.0.3)",
(unsigned)val[5],(unsigned)val[4],(unsigned)val[3]);
goto fail;
}