|
| 1 | +.. zephyr:code-sample:: nxp_mcu_poweroff |
| 2 | + :name: NXP MCU Poweroff |
| 3 | + :relevant-api: sys_poweroff |
| 4 | + |
| 5 | + Use poweroff on NXP MCUs. |
| 6 | + |
| 7 | +Overview |
| 8 | +******** |
| 9 | + |
| 10 | +This example shows how to poweroff an NXP MCU. In this example, |
| 11 | +the wakeup source can be the MCU internal counter or the wakeup |
| 12 | +button/gpio. If the counter is used, the MCU will wake up after |
| 13 | +5 seconds. If the wakeup button is used, the MCU will wake up |
| 14 | +after the wakeup button is pressed. |
| 15 | + |
| 16 | +Building, Flashing and Running |
| 17 | +****************************** |
| 18 | + |
| 19 | +Building and Running for NXP FRDM-MCXA153 |
| 20 | +========================================= |
| 21 | +Build the application for the :zephyr:board:`frdm_mcxa153` board. |
| 22 | +Note: After wakeup, the chip goes through the entire reset process. |
| 23 | + |
| 24 | +.. zephyr-app-commands:: |
| 25 | + :zephyr-app: samples/boards/nxp/poweroff |
| 26 | + :board: frdm_mcxa153 |
| 27 | + :goals: build flash |
| 28 | + :compact: |
| 29 | + |
| 30 | +Building and Running for NXP FRDM-MCXA156 |
| 31 | +========================================= |
| 32 | +Build the application for the :zephyr:board:`frdm_mcxa156` board. |
| 33 | +Note: After wakeup, the chip goes through the entire reset process. |
| 34 | + |
| 35 | +.. zephyr-app-commands:: |
| 36 | + :zephyr-app: samples/boards/nxp/poweroff |
| 37 | + :board: frdm_mcxa156 |
| 38 | + :goals: build flash |
| 39 | + :compact: |
| 40 | + |
| 41 | +Building and Running for NXP FRDM-MCXA166 |
| 42 | +========================================= |
| 43 | +Build the application for the :zephyr:board:`frdm_mcxa166` board. |
| 44 | +Note: After wakeup, the chip goes through the entire reset process. |
| 45 | + |
| 46 | +.. zephyr-app-commands:: |
| 47 | + :zephyr-app: samples/boards/nxp/poweroff |
| 48 | + :board: frdm_mcxa166 |
| 49 | + :goals: build flash |
| 50 | + :compact: |
| 51 | + |
| 52 | +Building and Running for NXP FRDM-MCXA276 |
| 53 | +========================================= |
| 54 | +Build the application for the :zephyr:board:`frdm_mcxa276` board. |
| 55 | +Note: After wakeup, the chip goes through the entire reset process. |
| 56 | + |
| 57 | +.. zephyr-app-commands:: |
| 58 | + :zephyr-app: samples/boards/nxp/poweroff |
| 59 | + :board: frdm_mcxa276 |
| 60 | + :goals: build flash |
| 61 | + :compact: |
| 62 | + |
| 63 | +Building and Running for NXP FRDM-MCXN236 |
| 64 | +========================================= |
| 65 | +Build the application for the :zephyr:board:`frdm_mcxn236` board. |
| 66 | +Note: After wakeup, the chip goes through the entire reset process. |
| 67 | + |
| 68 | +.. zephyr-app-commands:: |
| 69 | + :zephyr-app: samples/boards/nxp/poweroff |
| 70 | + :board: frdm_mcxn236/mcxn236 |
| 71 | + :goals: build flash |
| 72 | + :compact: |
| 73 | + |
| 74 | +Building and Running for NXP FRDM-MCXN947 |
| 75 | +========================================= |
| 76 | +Build the application for the :zephyr:board:`frdm_mcxn947` board. |
| 77 | +Note: After wakeup, the chip goes through the entire reset process. |
| 78 | + |
| 79 | +.. zephyr-app-commands:: |
| 80 | + :zephyr-app: samples/boards/nxp/poweroff |
| 81 | + :board: frdm_mcxn947/mcxn947/cpu0 |
| 82 | + :goals: build flash |
| 83 | + :compact: |
| 84 | + |
| 85 | +Building and Running for NXP MIMXRT595-EVK |
| 86 | +========================================== |
| 87 | +Build the application for the :zephyr:board:`mimxrt595_evk` board. |
| 88 | +Note: After wakeup, the chip goes through the entire reset process. |
| 89 | + |
| 90 | +.. zephyr-app-commands:: |
| 91 | + :zephyr-app: samples/boards/nxp/poweroff |
| 92 | + :board: mimxrt595_evk/mimxrt595s/cm33 |
| 93 | + :goals: build flash |
| 94 | + :compact: |
| 95 | + |
| 96 | +Sample Output |
| 97 | +============= |
| 98 | +FRDM-MCXA153, FRDM-MCXA156, FRDM-MCXA166, FRDM-MCXA276 FRDM-MCXN236, FRDM-MCXN947, |
| 99 | +MIMXRT595-EVK, output |
| 100 | +---------------------------------------------------------------------------------------- |
| 101 | + |
| 102 | +.. code-block:: console |
| 103 | +
|
| 104 | + *** Booting Zephyr OS build v4.2.0-rc1-255-gf71b531cb990 *** |
| 105 | + Press 'enter' key to power off the system |
| 106 | + Will wakeup after 5 seconds |
| 107 | + Powering off |
| 108 | +
|
| 109 | +FRDM-MCXN236 output |
| 110 | +-------------------- |
| 111 | + |
| 112 | +.. code-block:: console |
| 113 | +
|
| 114 | + *** Booting Zephyr OS build v4.2.0-rc3-17-g70b7c64e1094 *** |
| 115 | + Press 'enter' key to power off the system |
| 116 | + Will wakeup after press wakeup button |
| 117 | + Powering off |
0 commit comments