diff --git a/Tools/AP_Periph/AP_Periph.cpp b/Tools/AP_Periph/AP_Periph.cpp index ba93746080..4d228cdab3 100644 --- a/Tools/AP_Periph/AP_Periph.cpp +++ b/Tools/AP_Periph/AP_Periph.cpp @@ -57,15 +57,6 @@ void loop(void) static uint32_t start_ms; -/* - declare constant app_descriptor in flash - */ -#if CONFIG_HAL_BOARD == HAL_BOARD_CHIBIOS -const struct app_descriptor app_descriptor __attribute__((section(".app_descriptor"))); -#else -const struct app_descriptor app_descriptor; -#endif - AP_Periph_FW::AP_Periph_FW() #if HAL_LOGGING_ENABLED : logger(g.log_bitmask) @@ -131,12 +122,7 @@ void AP_Periph_FW::init() logger.Init(log_structure, ARRAY_SIZE(log_structure)); #endif - printf("Booting %08x:%08x %u/%u len=%u 0x%08x\n", - app_descriptor.image_crc1, - app_descriptor.image_crc2, - app_descriptor.version_major, app_descriptor.version_minor, - app_descriptor.image_size, - app_descriptor.git_hash); + check_firmware_print(); if (hal.util->was_watchdog_reset()) { printf("Reboot after watchdog reset\n"); diff --git a/Tools/AP_Periph/AP_Periph.h b/Tools/AP_Periph/AP_Periph.h index 9ea2763a4c..54f6f7a9cf 100644 --- a/Tools/AP_Periph/AP_Periph.h +++ b/Tools/AP_Periph/AP_Periph.h @@ -15,6 +15,7 @@ #include #include #include "../AP_Bootloader/app_comms.h" +#include #include "hwing_esc.h" #include #include diff --git a/Tools/AP_Periph/can.cpp b/Tools/AP_Periph/can.cpp index 44d9df9f98..64618726b7 100644 --- a/Tools/AP_Periph/can.cpp +++ b/Tools/AP_Periph/can.cpp @@ -31,7 +31,6 @@ #if CONFIG_HAL_BOARD == HAL_BOARD_CHIBIOS #include -#include "../AP_Bootloader/app_comms.h" #include #include #include diff --git a/Tools/AP_Periph/wscript b/Tools/AP_Periph/wscript index 937d91294a..dd83e39bca 100644 --- a/Tools/AP_Periph/wscript +++ b/Tools/AP_Periph/wscript @@ -64,6 +64,7 @@ def build(bld): 'AP_ESC_Telem', 'AP_Stats', 'AP_EFI', + 'AP_CheckFirmware', ] bld.ap_stlib( name= 'AP_Periph_libs',