Browse Source

HAL_ChibiOS: fixed flash layout for F7

thanks to @alielectric
mission-4.1.18
Andrew Tridgell 7 years ago
parent
commit
721f3cd5d1
  1. 8
      libraries/AP_HAL_ChibiOS/hwdef/common/flash.c

8
libraries/AP_HAL_ChibiOS/hwdef/common/flash.c

@ -97,12 +97,12 @@ static const uint32_t flash_memmap[STM32_FLASH_NPAGES] = { KB(16), KB(16), KB(16 @@ -97,12 +97,12 @@ static const uint32_t flash_memmap[STM32_FLASH_NPAGES] = { KB(16), KB(16), KB(16
#elif defined(STM32F7)
#if BOARD_FLASH_SIZE == 1024
#define STM32_FLASH_NPAGES 5
static const uint32_t flash_memmap[STM32_FLASH_NPAGES] = { KB(32), KB(32), KB(32), KB(128), KB(256) };
#define STM32_FLASH_NPAGES 8
static const uint32_t flash_memmap[STM32_FLASH_NPAGES] = { KB(32), KB(32), KB(32), KB(32), KB(128), KB(256), KB(256), KB(256) };
#elif BOARD_FLASH_SIZE == 2048
#define STM32_FLASH_NPAGES 9
static const uint32_t flash_memmap[STM32_FLASH_NPAGES] = { KB(32), KB(32), KB(32), KB(128), KB(256),
#define STM32_FLASH_NPAGES 12
static const uint32_t flash_memmap[STM32_FLASH_NPAGES] = { KB(32), KB(32), KB(32), KB(32), KB(128), KB(256), KB(256), KB(256),
KB(256), KB(256), KB(256), KB(256) };
#else
#error "BOARD_FLASH_SIZE invalid"

Loading…
Cancel
Save