You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@nuttx.apache.org by ac...@apache.org on 2026/04/10 17:34:00 UTC
(nuttx) 02/02: Documentation: Power Management for ESP32-P4-Function-EV-Board
This is an automated email from the ASF dual-hosted git repository.
acassis pushed a commit to branch master
in repository https://gitbox.apache.org/repos/asf/nuttx.git
commit 6ef0d35894e71a4de58ce583dd2633b09fa14ca6
Author: Tiago Medicci Serrano <ti...@espressif.com>
AuthorDate: Mon Apr 6 16:49:02 2026 -0300
Documentation: Power Management for ESP32-P4-Function-EV-Board
This commit documents the power management defconfig for the
ESP32-P4-Function-EV-Board.
Signed-off-by: Tiago Medicci Serrano <ti...@espressif.com>
---
.../boards/esp32p4-function-ev-board/index.rst | 57 ++++++++++++++++++++++
1 file changed, 57 insertions(+)
diff --git a/Documentation/platforms/risc-v/esp32p4/boards/esp32p4-function-ev-board/index.rst b/Documentation/platforms/risc-v/esp32p4/boards/esp32p4-function-ev-board/index.rst
index 7202e309d2c..65cd8e10750 100644
--- a/Documentation/platforms/risc-v/esp32p4/boards/esp32p4-function-ev-board/index.rst
+++ b/Documentation/platforms/risc-v/esp32p4/boards/esp32p4-function-ev-board/index.rst
@@ -234,6 +234,63 @@ ostest
Runs OS tests from ``apps/testing/ostest``.
+pm
+-------
+
+This config demonstrate the use of power management.
+You can use the ``pmconfig`` command to check current power state and time spent in other power states.
+Also you can define time will spend in standby and sleep modes::
+
+ $ make menuconfig
+ -> Board Selection
+ -> (15) PM_STANDBY delay (seconds)
+ (0) PM_STANDBY delay (nanoseconds)
+ (20) PM_SLEEP delay (seconds)
+ (0) PM_SLEEP delay (nanoseconds)
+
+Timer wakeup is not only way to wake up the chip. Other wakeup modes include:
+
+- EXT1 wakeup mode: Uses RTC GPIO pins to wake up the chip. Enabled with ``CONFIG_PM_EXT1_WAKEUP`` option.
+- GPIO wakeup mode: Uses GPIO pins to wakeup the chip. Only wakes up the chip from ``PM_STANDBY`` mode and requires ``CONFIG_PM_GPIO_WAKEUP``.
+- UART wakeup mode: Uses UART to wakeup the chip. Only wakes up the chip from ``PM_STANDBY`` mode and requires ``CONFIG_PM_GPIO_WAKEUP``.
+
+Before switching PM status, you need to query the current PM status to call correct number of relax command to correct modes::
+
+ nsh> pmconfig
+ Last state 0, Next state 0
+
+ /proc/pm/state0:
+ DOMAIN0 WAKE SLEEP TOTAL
+ normal 0s 00% 0s 00% 0s 00%
+ idle 0s 00% 0s 00% 0s 00%
+ standby 0s 00% 0s 00% 0s 00%
+ sleep 0s 00% 0s 00% 0s 00%
+
+ /proc/pm/wakelock0:
+ DOMAIN0 STATE COUNT TIME
+ system normal 2 1s
+ system idle 1 1s
+ system standby 1 1s
+ system sleep 1 1s
+
+In this case, needed commands to switch the system into PM idle mode::
+
+ nsh> pmconfig relax normal
+ nsh> pmconfig relax normal
+
+In this case, needed commands to switch the system into PM standby mode::
+
+ nsh> pmconfig relax idle
+ nsh> pmconfig relax normal
+ nsh> pmconfig relax normal
+
+System switch to the PM sleep mode, you need to enter::
+
+ nsh> pmconfig relax standby
+ nsh> pmconfig relax idle
+ nsh> pmconfig relax normal
+ nsh> pmconfig relax normal
+
pwm
---