hwdef: CubeOrange: flash-from-sd-card support

This commit is contained in:
Peter Barker 2022-12-01 13:28:19 +11:00 committed by Peter Barker
parent d9045997a0
commit 6c6a76bfd4
4 changed files with 27 additions and 7 deletions

View File

@ -63,3 +63,18 @@ PA8 nVDD_5V_PERIPH_EN OUTPUT LOW
# enable DFU by default # enable DFU by default
ENABLE_DFU_BOOT 1 ENABLE_DFU_BOOT 1
# enable flashing from SD card:
include sdcard.inc
# enable FAT filesystem support (needs a microSD defined via SDMMC)
define HAL_OS_FATFS_IO 1
define AP_BOOTLOADER_FLASH_FROM_SD_ENABLED 1
# FATFS support:
define CH_CFG_USE_MEMCORE 1
define CH_CFG_USE_HEAP 1
define CH_CFG_USE_SEMAPHORES 0
define CH_CFG_USE_MUTEXES 1
define CH_CFG_USE_DYNAMIC 1
define CH_CFG_USE_WAITEXIT 1
define CH_CFG_USE_REGISTRY 1

View File

@ -4,3 +4,6 @@
MCU STM32H7xx STM32H743xx MCU STM32H7xx STM32H743xx
include hwdef.inc include hwdef.inc
# build ABIN for flash-from-bootloader support:
env BUILD_ABIN True

View File

@ -118,13 +118,8 @@ PC5 PRESSURE_SENS ADC1 SCALE(2)
PC6 USART6_TX USART6 PC6 USART6_TX USART6
PC7 USART6_RX USART6 PC7 USART6_RX USART6
# Now setup the pins for the microSD card, if available. # Now setup the pins for the microSD card
PC8 SDMMC1_D0 SDMMC1 include sdcard.inc
PC9 SDMMC1_D1 SDMMC1
PC10 SDMMC1_D2 SDMMC1
PC11 SDMMC1_D3 SDMMC1
PC12 SDMMC1_CK SDMMC1
PD2 SDMMC1_CMD SDMMC1
# More CS pins for more sensors. The labels for all CS pins need to # More CS pins for more sensors. The labels for all CS pins need to
# match the SPI device table later in this file. # match the SPI device table later in this file.

View File

@ -0,0 +1,7 @@
# pins for SD card:
PC8 SDMMC1_D0 SDMMC1
PC9 SDMMC1_D1 SDMMC1
PC10 SDMMC1_D2 SDMMC1
PC11 SDMMC1_D3 SDMMC1
PC12 SDMMC1_CK SDMMC1
PD2 SDMMC1_CMD SDMMC1