Regeneration CubeMX (Appli) preparant le driver ST67W611M1 et la carte SD : - SPI4 (PE12/13/14, CS PF8) + DMA GPDMA1 canaux 4/5, SPI_RDY (PD12/EXTI12), CHIP_EN (PD13) et BOOT (PD15) pour la X-NUCLEO-67W61M1 sur l'Arduino - SDMMC1 + FatFs (appels d'init non generes dans main, IRQ SDMMC1 prio 14), PM14 en open-drain ; I2S6_CK sur PA5 pour liberer PC12 (SDMMC1_CK) - HAL UART retire ; USE_BSP_COM_FEATURE=0 - Audio preserve : ADF 4/16/24, prio IRQ 2, DMA canal 0 en priorite haute, GPDMA1_Channel2_IRQHandler deplace dans audio_irq.c (hors fichiers generes), BSP_MX_I2S6_Init (renommage dans le BSP pour eviter le conflit avec CubeMX) - Middlewares/ST/ST67W6X_Network_Driver, FatFs et sources HAL SPI/SD ajoutes (driver ST67 pas encore integre au build) Build et debug sous Linux : - gcc/toolchain-env.sh, gdbserver.sh, arm-gdb.sh : outils de STM32CubeIDE par glob ; flash.sh les retrouve ; ruby_compat.rb pour Ruby >= 3.2 (TouchGFX) - makefile_appli : sources SD/SPI/FatFs/audio_irq ; chmod +x des .out TouchGFX - Objets de build (*.o, *.d, *.su) retires de l'index (deja dans .gitignore) - AGENTS.md : toolchain Linux, configs VS Code (cppdbg et ST stlinkgdbtarget), pieges de l'extension ST (.settings/ide.store.json, preRunCommands reset) Verifie sur carte : audio OK, debug Appli/Boot OK. Co-Authored-By: Claude Sonnet 5.5 <noreply@anthropic.com>
STM32H7S78-DK Audio Effects Processor with TouchGFX
Project Overview
This dual-boot project consists of two components:
| Project | Directory | Purpose |
|---|---|---|
| Boot | /Boot/ |
Bootloader - initializes hardware, loads application from external flash |
| Appli | /Appli/ |
Main application - TouchGFX UI + audio processing |
Build & Flash
Prerequisites
- STM32CubeIDE (for CubeMX GUI, code generation)
- gcc-arm-embedded (
arm-none-eabi-gcc) - STM32CubeProgrammer (for flashing with external loader)
- TouchGFX 4.26.1 (for GUI generation)
Build Commands
From /gcc/ directory:
make # Build both Boot and Appli
make clean # Clean all build artifacts
Flashing Commands
From the repository root, with the board connected through the on-board ST-Link:
gcc/flash.sh all # Boot (internal flash) then Appli (external flash, with external loader)
gcc/flash.sh boot # Boot only
gcc/flash.sh appli # Appli only
gcc/flash.sh wraps STM32_Programmer_CLI -c port=SWD ap=1 mode=UR ... and uses
gcc/MX66UW1G45G_STM32H7S78-DK.stldr for the external flash at 0x70000000.
In VS Code: tasks Build + Flash All, and Debug Appli (F5) to debug — see .vscode/README.md.
See .vscode/flash_guide.md for complete flashing instructions including VS Code tasks.
Debugging in STM32CubeIDE
Debugging the code in an IDE can be complex because of the Bootloader and Application structure. To step through the code of the TouchGFX application in STM32CubeIDE, follow these steps:
- Generate code in TouchGFX Designer
- Open the project in STM32CubeIDE
- Launch a debug session for the Boot project
- Wait for the compilation and flashing to complete
- Terminate the debug session (Ctrl + F2)
- Launch a debug session for the Appli project
- Wait for the compilation and flashing to complete
- Click Resume (F8)
- Press the black NRST button on the STM32H7S78-DK board
- The application is now at a break point at the first line of main() in the Appli project. If not, click Resume (F8) once more
- Proceed by e.g. clicking Resume (F8) or Step Over (F6)
Performance Testing
Performance testing can be done using the GPIO pins designated with the following signals in CN10 connector on the underside of the board:
- VSYNC_FREQ - CN14-D2 (PF1)
- RENDER_TIME - CN14-D4 (PF2)
- FRAME_RATE - CN14-D7 (PF3)
- MCU_ACTIVE - CN15-D8 (PF4)