mirror of
https://github.com/ArduPilot/ardupilot
synced 2025-02-01 21:48:28 -04:00
HAL_ChibiOS: setup watchdog_reset internal error
This commit is contained in:
parent
d5c2b77573
commit
63d21d995a
@ -28,6 +28,7 @@
|
||||
#include "hwdef/common/stm32_util.h"
|
||||
#include "hwdef/common/watchdog.h"
|
||||
#include <AP_BoardConfig/AP_BoardConfig.h>
|
||||
#include <AP_InternalError/AP_InternalError.h>
|
||||
|
||||
#include <hwdef.h>
|
||||
|
||||
@ -208,6 +209,10 @@ static void main_loop()
|
||||
stm32_watchdog_init();
|
||||
}
|
||||
|
||||
if (hal.util->was_watchdog_reset()) {
|
||||
AP::internalerror().error(AP_InternalError::error_t::watchdog_reset);
|
||||
}
|
||||
|
||||
while (true) {
|
||||
g_callbacks->loop();
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user