boards: st: Add script to perform power off/power
When flashing STM32N6 in USB-DFU mode, as required when running test automation using twister, it is first required to power-off/power-on the board to set board ready for USB-DFU (thanks to specific BootROM configuration). Provide a script that performs this operation using STM32CubeProgrammer. This scipt could be provided in twister map.yaml file on 'pre_script' property of board entry. Signed-off-by: Erwan Gouriou <erwan.gouriou@st.com>
This commit is contained in:
parent
b859423051
commit
4ea07702b2
1 changed files with 9 additions and 0 deletions
9
boards/st/common/scripts/board_power_reset.sh
Executable file
9
boards/st/common/scripts/board_power_reset.sh
Executable file
|
@ -0,0 +1,9 @@
|
|||
#!/usr/bin/env bash
|
||||
#
|
||||
# Copyright (c) 2025 STMicroelectronics
|
||||
#
|
||||
# SPDX-License-Identifier: Apache-2.0
|
||||
|
||||
STM32_Programmer_CLI -c port=swd mode=UR --power off index=0 --power on index=0 > /dev/null
|
||||
|
||||
sleep 1
|
Loading…
Add table
Add a link
Reference in a new issue