nRF5340: Build Error During Power Measurement in Low Power Mode (SDK v2.6.1)

Hello,

I’m working on an nRF5340 project and trying to measure power consumption in low power mode using SDK v2.6.1. I followed the instructions provided on your website   but I encountered a build error.

Details:

  • SDK Version: v2.6.1
  • Custom Board : nrf5340-nrf7002

Build Configuration in vs code:  board = nrf7002dk-nrf5340-cpuapp-ns

Reference :

https://docs.nordicsemi.com/bundle/ncs-1.6.0/page/zephyr/reference/power_management/index.html

Steps I followed:
1. Set up the SDK environment as per the documentation.
2. Configured the project for low power mode.
3. Attempted to build the project using the provided instructions.

Troubleshooting steps I’ve tried:
- Rechecked the configuration.
- Cleaned and rebuilt the project.
- Ensured all dependencies were correctly installed.

Despite these steps, the error persists. Could you please assist me in resolving this issue?

Error:


FATAL ERROR: command exited with status 1: 'C:\ncs\toolchains\cf2149caf2\opt\bin\cmake.EXE' --build 'c:\ncs\v2.6.1\Waggle_Sensors\application\Node_1\build'

Thank you.

Parents Reply
  • Hi,
    error code is given below 

    Main/main.c:212:
    undefined reference to `pm_power_state_force'
    c:/ncs/toolchains/cf2149caf2/opt/zephyr-sdk/arm-zephyr-eabi/bin/../lib/gcc/arm-zephyr-eabi/12.2.0/../../..
    /../arm-zephyr-eabi/bin/ld.bfd.exe: C:/ncs/v2.6.1/Waggle_Sensors/application/Node_1/src/

    Main/main.c:213:
    undefined reference to `pm_device_state_set'
    collect2.exe: error: ld returned 1 exit status
    ninja: build stopped: subcommand failed.
    FATAL ERROR: command exited with status 1: 'C:\ncs\toolchains\cf2149caf2\opt\bin\cmake.EXE' --build
    'c:\ncs\v2.6.1\Waggle_Sensors\application\Node_1\build'

Children
Related