Initial bootloader implementation

Took a publicly available XMODEM bootloader and made it work on HK32F.

Known issues:
- Erase is super slow on this MCU. The upload routine erases all flash before loading, which means the first packet seems to hang. This also erases possibly persistent data stored in unused pages on flash.
This commit is contained in:
true
2023-06-25 01:41:36 -07:00
parent 861caf8bce
commit a47cfa7fa5
83 changed files with 39624 additions and 0 deletions

File diff suppressed because it is too large Load Diff

View File

@@ -0,0 +1,37 @@
/**
******************************************************************************
* @file system_hk32f030m.h
* @author Rakan.Z/laura.C
* @version V1.0
* @brief API file of system clk config
* @changelist
******************************************************************************
*/
#ifndef __SYSTEM_HK32F030M_H
#define __SYSTEM_HK32F030M_H
#ifdef __cplusplus
extern "C" {
#endif
/** hk32f030m_System_Exported_types */
extern uint32_t SystemCoreClock; /*!< System Clock Frequency (Core Clock) */
extern const uint16_t AHBPrescTable[16]; /*!< AHB prescalers table values */
extern const uint8_t APBPrescTable[8]; /*!< APB prescalers table values */
extern void SystemInit(void);
extern void SystemCoreClockUpdate(void);
#ifdef __cplusplus
}
#endif
#endif /*__SYSTEM_HK32F030M_H */