Commit f03c5bf5 authored by Francois Ramu's avatar Francois Ramu Committed by Benjamin Cabé
Browse files

boards: st: stm32f746g_disco with external flash for code execution

Add the configuration to download and execute code in the
external flash of the stm32f746 disco kit :
ext memory attribute to support code execution and external flash loader

Signed-off-by: default avatarFrancois Ramu <francois.ramu@st.com>
parent 13ede4ec
Loading
Loading
Loading
Loading
+2 −0
Changes for boards/st/stm32f746g_disco/board.cmake: 2 added lines, 0 removed lines.
Original line number Diff line number Diff line
@@ -2,6 +2,8 @@

# keep first
board_runner_args(stm32cubeprogrammer "--port=swd" "--reset-mode=hw")
board_runner_args(stm32cubeprogrammer "--extload=N25Q128A_STM32F746G-DISCO.stldr")

board_runner_args(jlink "--device=STM32F746NG" "--speed=4000")

# keep first
+9 −0
Changes for boards/st/stm32f746g_disco/stm32f746g_disco.dts: 9 added lines, 0 removed lines.
Original line number Diff line number Diff line
@@ -57,6 +57,15 @@
		zephyr,memory-attr = <( DT_MEM_ARM(ATTR_MPU_RAM) )>;
	};

	/* Declare attributes for the External flash Mem to allow code execution there */
	ext_memory: memory@90000000 {
		compatible = "zephyr,memory-region";
		reg = <0x90000000 DT_SIZE_M(16)>; /* max addressable area */
		zephyr,memory-region = "EXTMEM";
		/* Override ATTR_MPU_EXTMEM with ATTR_MPU_IO to allow access */
		zephyr,memory-attr = <( DT_MEM_ARM(ATTR_MPU_IO) )>;
	};

	aliases {
		led0 = &green_led_1;
		sw0 = &user_button;