Skip to content

Commit

Permalink
tests: pm: add soc pm tests and sample for stm32f4x chip
Browse files Browse the repository at this point in the history
Add soc power management test and blinky sample for the nucleo_f429zi
board.

Signed-off-by: Dawid Niedzwiecki <dawidn@google.com>
  • Loading branch information
niedzwiecki-dawid committed Nov 15, 2023
1 parent d63e9e7 commit 95b9f2e
Show file tree
Hide file tree
Showing 5 changed files with 28 additions and 1 deletion.
Original file line number Diff line number Diff line change
@@ -0,0 +1,11 @@
/*
* Copyright (c) 2023 Google LLC
*
* SPDX-License-Identifier: Apache-2.0
*/

/ {
chosen {
zephyr,cortex-m-idle-timer = &rtc;
};
};
2 changes: 2 additions & 0 deletions samples/boards/stm32/power_mgmt/blinky/prj.conf
Original file line number Diff line number Diff line change
Expand Up @@ -2,3 +2,5 @@ CONFIG_PM=y
CONFIG_PM_DEVICE=y
CONFIG_PM_DEVICE_RUNTIME=y
CONFIG_PM_DEVICE_RUNTIME_EXCLUSIVE=n
# Increase IDLE stack for the IDLE timer
CONFIG_IDLE_STACK_SIZE=640
4 changes: 3 additions & 1 deletion samples/boards/stm32/power_mgmt/blinky/sample.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -12,7 +12,9 @@ tests:
- "Device ready"
filter: dt_compat_enabled("zephyr,power-state") and
dt_enabled_alias_with_parent_compat("led0", "gpio-leds") and
dt_compat_enabled("st,stm32-lptim")
(dt_compat_enabled("st,stm32-lptim") or
dt_chosen_enabled("zephyr,cortex-m-idle-timer"))
extra_args: "CONFIG_DEBUG=y"
integration_platforms:
- nucleo_wb55rg
- nucleo_f429zi
11 changes: 11 additions & 0 deletions tests/subsys/pm/power_mgmt_soc/boards/nucleo_f429zi.overlay
Original file line number Diff line number Diff line change
@@ -0,0 +1,11 @@
/*
* Copyright (c) 2023 Google LLC
*
* SPDX-License-Identifier: Apache-2.0
*/

/ {
chosen {
zephyr,cortex-m-idle-timer = &rtc;
};
};
1 change: 1 addition & 0 deletions tests/subsys/pm/power_mgmt_soc/testcase.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -5,6 +5,7 @@ tests:
- cc1352r1_launchxl
- mec15xxevb_assy6853
- mec1501modular_assy6885
- nucleo_f429zi
- nucleo_wb55rg
- nucleo_l476rg
- twr_ke18f
Expand Down

0 comments on commit 95b9f2e

Please sign in to comment.