implement full fwupdate stack

This commit is contained in:
2024-02-06 01:52:44 +01:00
parent 74dcdfd19b
commit ff6fcb75f0
4 changed files with 205 additions and 10 deletions

View File

@@ -0,0 +1,27 @@
#pragma once
#include "stdint.h"
#define BOOTLOADER_CALL_RETRY_TIME 1000
#define BOOTLOADER_CALL_MAX_TRIES 10
#define TASK_FLAG_WAIT 1
#define TASK_FLAG_RUNNING 2
#define UPDATE_ACK_WINDOW 4
#define UPDATE_DONE_MSG 0xFFFFD04EFFFFD04E
typedef struct {
char name[32];
uint8_t device;
} FirmwareUpdateArgs;
typedef struct {
uint32_t counter;
uint8_t data[4];
} FwFrame;
void FirmwareUpdateTask_start(FirmwareUpdateArgs args);