bsps/stm32h7: add configuration and enable build of stm32h757i-eval-m4 BSP

This is minimalist configuration for the stm32h757i-eval-m4 BSP provided
here. The only general enhancement worth mention is a flash origin address
configuration which is needed for simplification as M4 core boots
from second flash bank which starts at 0x8100000 by default. The boot
address of the core may be changed by using STM32CubeProgrammer. If done
so then also BSP configuration needs to be changed accordingly.

As the BSP variant is running on M4 core, there is also more configuration
changes required here. E.g. boot core and ABI (compilation flags)
in comparison with stm32h757i-eval BSP. On the other hand, C code is shared
completely with this BSP variant.

Sponsored-By:   Precidata
This commit is contained in:
Karel Gardas
2022-05-16 15:18:37 +02:00
parent 7cb73a34d4
commit 250254ff8f
11 changed files with 66 additions and 3 deletions

View File

@@ -8,7 +8,14 @@ default:
- -mcpu=cortex-m7
- -mfpu=fpv5-d16
- -mfloat-abi=hard
default-by-variant: []
default-by-variant:
- value:
- -mthumb
- -mcpu=cortex-m4
- -mfpu=fpv4-sp-d16
- -mfloat-abi=hard
variants:
- arm/stm32h757i-eval-m4
enabled-by: true
links: []
name: ABI_FLAGS

View File

@@ -0,0 +1,24 @@
SPDX-License-Identifier: CC-BY-SA-4.0 OR BSD-2-Clause
arch: arm
bsp: stm32h757i-eval-m4
build-type: bsp
cflags: []
copyrights:
- Copyright (C) 2022 Karel Gardas <karel@functional.vision>
cppflags: []
enabled-by: true
family: stm32h7
includes: []
install: []
links:
- role: build-dependency
uid: grp
- role: build-dependency
uid: tststm32h757i-eval
source:
- bsps/arm/stm32h7/boards/stm/stm32h757i-eval/stm32h7-config-clk.c
- bsps/arm/stm32h7/boards/stm/stm32h757i-eval/stm32h7-config-osc.c
- bsps/arm/stm32h7/boards/stm/stm32h757i-eval/stm32h7-config-per.c
- bsps/arm/stm32h7/boards/stm/stm32h757i-eval/system_stm32h7xx.c
- bsps/shared/cache/nocache.c
type: build

View File

@@ -51,6 +51,8 @@ links:
uid: optmemflashsz
- role: build-dependency
uid: optmemflashlatency
- role: build-dependency
uid: optmemflashorigin
- role: build-dependency
uid: optmemitcmsz
- role: build-dependency

View File

@@ -3,7 +3,7 @@ content: |
MEMORY {
NULL : ORIGIN = 0x00000000, LENGTH = ${STM32H7_MEMORY_NULL_SIZE:#010x}
ITCM : ORIGIN = ${STM32H7_MEMORY_NULL_SIZE:#010x}, LENGTH = ${STM32H7_MEMORY_ITCM_SIZE:#010x}
FLASH : ORIGIN = 0x08000000, LENGTH = ${STM32H7_MEMORY_FLASH_SIZE:#010x}
FLASH : ORIGIN = ${STM32H7_MEMORY_FLASH_ORIGIN:#010x}, LENGTH = ${STM32H7_MEMORY_FLASH_SIZE:#010x}
DTCM : ORIGIN = 0x20000000, LENGTH = ${STM32H7_MEMORY_DTCM_SIZE:#010x}
SRAM_AXI : ORIGIN = 0x24000000, LENGTH = ${STM32H7_MEMORY_SRAM_AXI_SIZE:#010x}
SRAM_1 : ORIGIN = 0x30000000, LENGTH = ${STM32H7_MEMORY_SRAM_1_SIZE:#010x}

View File

@@ -11,6 +11,9 @@ default-by-variant:
- value: CORE_CM7
variants:
- arm/stm32h757i-eval
- value: CORE_CM4
variants:
- arm/stm32h757i-eval-m4
enabled-by: true
format: '{}'
links: []

View File

@@ -8,6 +8,7 @@ default-by-variant:
variants:
- arm/stm32h7b3i-dk
- arm/stm32h757i-eval
- arm/stm32h757i-eval-m4
enabled-by: true
format: '{}'
links: []

View File

@@ -0,0 +1,19 @@
actions:
- get-integer: null
- env-assign: null
build-type: option
default: 0x8000000
default-by-variant:
- value: 0x8100000
variants:
- arm/stm32h757i-eval-m4
enabled-by: true
format: '{:#010x}'
links: []
name: STM32H7_MEMORY_FLASH_ORIGIN
description: |
Origin address of the internal flash.
type: build
SPDX-License-Identifier: CC-BY-SA-4.0 OR BSD-2-Clause
copyrights:
- Copyright (C) 2020 embedded brains GmbH (http://www.embedded-brains.de)

View File

@@ -3,7 +3,11 @@ actions:
- env-assign: null
build-type: option
default: 0x200000
default-by-variant: []
default-by-variant:
default-by-variant:
- value: 0x100000
variants:
- arm/stm32h757i-eval-m4
enabled-by: true
format: '{:#010x}'
links: []

View File

@@ -8,6 +8,7 @@ default-by-variant:
variants:
- arm/stm32h7b3i-dk
- arm/stm32h757i-eval
- arm/stm32h757i-eval-m4
enabled-by: true
format: '{}'
links: []

View File

@@ -10,6 +10,7 @@ default-by-variant:
- value: GPIOB
variants:
- arm/stm32h757i-eval
- arm/stm32h757i-eval-m4
enabled-by: true
format: '{}'
links: []

View File

@@ -20,6 +20,7 @@ default-by-variant:
- value: STM32H757xx
variants:
- arm/stm32h757i-eval
- arm/stm32h757i-eval-m4
enabled-by: true
format: '{}'
links: []