From aafc5be1c2007b3f05a794ccfcdb6164ecee17a0 Mon Sep 17 00:00:00 2001 From: Andrew Tridgell Date: Wed, 11 Mar 2020 12:20:04 +1100 Subject: [PATCH] AP_HAL: added in_expected_delay() allows for error message suppression when delays are expected --- libraries/AP_HAL/Scheduler.h | 8 +++++++- 1 file changed, 7 insertions(+), 1 deletion(-) diff --git a/libraries/AP_HAL/Scheduler.h b/libraries/AP_HAL/Scheduler.h index f66ea91921..4e8349a637 100644 --- a/libraries/AP_HAL/Scheduler.h +++ b/libraries/AP_HAL/Scheduler.h @@ -36,7 +36,13 @@ public: A value of zero cancels the previous expected delay */ virtual void expect_delay_ms(uint32_t ms) { } - + + /* + return true if we are in a period of expected delay. This can be + used to suppress error messages + */ + virtual bool in_expected_delay(void) const { return false; } + /* end the priority boost from delay_microseconds_boost() */