uavcannode_gps_demo:Add UAVCAN bootloader AppDescriptor

This commit is contained in:
David Sidrane
2021-02-22 10:31:39 -08:00
committed by Lorenz Meier
parent dd3c3098f2
commit 500fe5c98c
2 changed files with 21 additions and 0 deletions
@@ -78,5 +78,6 @@ px4_add_module(
DEPENDS
git_libcanard
git_public_regulated_data_types
drivers_bootloaders
version
)
@@ -65,6 +65,9 @@
#include "libcancl/pnp.h"
#include "libcancl/registerinterface.h"
#include "boot_app_shared.h"
/****************************************************************************
* Pre-processor Definitions
****************************************************************************/
@@ -76,6 +79,23 @@
/****************************************************************************
* Private Data
****************************************************************************/
/*
* This is the AppImageDescriptor used
* by the make_can_boot_descriptor.py tool to set
* the application image's descriptor so that the
* uavcan bootloader has the ability to validate the
* image crc, size etc of this application
*/
boot_app_shared_section app_descriptor_t AppDescriptor = {
.signature = APP_DESCRIPTOR_SIGNATURE,
.image_crc = 0,
.image_size = 0,
.git_hash = 0,
.major_version = APP_VERSION_MAJOR,
.minor_version = APP_VERSION_MINOR,
.board_id = HW_VERSION_MAJOR << 8 | HW_VERSION_MINOR,
.reserved = {0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff }
};
O1HeapInstance *my_allocator;
static uint8_t uavcan_heap[O1_HEAP_SIZE]