diff --git a/ports/stm32/flash.c b/ports/stm32/flash.c index 85bcee5a97..f050ca5acd 100644 --- a/ports/stm32/flash.c +++ b/ports/stm32/flash.c @@ -159,8 +159,13 @@ static const flash_layout_t flash_layout[] = { #define FLASH_LAYOUT_IS_HOMOGENEOUS (1) #define FLASH_LAYOUT_START_ADDR (FLASH_BASE) +#if defined(STM32H7A3xx) || defined(STM32H7A3xxQ) +#define FLASH_LAYOUT_SECTOR_SIZE (0x2000) +#define FLASH_LAYOUT_NUM_SECTORS (256) +#else #define FLASH_LAYOUT_SECTOR_SIZE (0x20000) #define FLASH_LAYOUT_NUM_SECTORS (16) +#endif #else #error Unsupported processor