mothercup/mcm-ddc-ble/inc/app_bootset.h

29 lines
875 B
C

/**
* @file app_bootset.h
* @brief Structured read/write of the bootsetting record (0x01004000).
* Raw writes are not exposed: every modification goes through a
* field setter that recomputes the record CRC32, erases the sector,
* programs and verifies. CLI handlers are registered in cli_core.c.
*/
#ifndef __APP_BOOTSET_H__
#define __APP_BOOTSET_H__
#ifdef __cplusplus
extern "C" {
#endif
/** "bsdump": dump the bootsetting record fields + magic/CRC check result. */
void AppBootset_CmdBsdump(int argc, char* argv[]);
/** "bsset <field> <val>": modify one bootsetting field (see app_bootset.c). */
void AppBootset_CmdBsset(int argc, char* argv[]);
/** "appsw [1|2]": switch active boot bank (image CRC verified) and reboot. */
void AppBootset_CmdAppswitch(int argc, char* argv[]);
#ifdef __cplusplus
}
#endif
#endif /* __APP_BOOTSET_H__ */