Expected current consumption in the nRF52832 when using Zephyr RTOS.

Hi,

I am using nRF52832 board and I want to understand the current consumption in the board will differs while running the code in zephyr RTOS platform and without zephyr RTOS platform. I want to know analysis behind the current consumption evaluation if we are using the Zephyr RTOS platform will increase compared to the without using Zephyr RTOS.

Can please guide me through this. Will the expected current consumption increase in Zephyr RTOS vs without Zephyr RTOS?

Details:

Hardware: nRF52832 board. 

Software: visual studio. version (1.87.2)

SDK: nrFConnect for Visual Studio. Version (v2.5.2)

Thanks in advance,

Naveed

Parents Reply Children
  • Hi,

    Thank you for your response. Sorry for the delayed response, I was occupied for other tasks.

    I am trying to create a new project in VS Code in zephyr RTOS platform and I want to measure the current consumption of the device.

    I am using the nRF52832 board, Created a project in VS code with main function and one idle thread(while loop with no functions). In the main function I have disconnected all the GPIO's in the board which may drive some current.

    I am following the below API's to disable the GPIO's in the main. 

            nrf_gpio_cfg_input(2,NRF_GPIO_PIN_NOPULL);
            nrf_gpio_input_disconnect(2);
            nrf_gpio_cfg_input(3,NRF_GPIO_PIN_NOPULL);
            nrf_gpio_input_disconnect(3);
            nrf_gpio_cfg_input(30,NRF_GPIO_PIN_NOPULL);
            nrf_gpio_input_disconnect(30);
    Same steps followed to disable all the other GPIOs. Is this correct, what is the correct way to disable the GPIO?
    I am using joule scope to measure the current readings. Below are the current consumption readings observed in the joule scope.
    1. For an idle thread with no other GPIOs configured, current consumption is around 4mA.
    2. For an idle thread with all the GPIOs configured to disconnect state, current consumption is around  5.4mA.
    3. For single thread with one led blinking continuously, current consumption is around 3.4mA,
    4. When two led is continuously on-state the current consumption is around 13mA.
    Also tried adding the below configuration as well. there is no change in the current readings.   
    • Adding CONFIG_SERIAL=n in project config file.
    • Adding CONFIG_PM_DEVICE=y in project config file. 
    Please help me to understand what is happening here?
    1. Why the current is increased from 4mA to 5.4mA when all the GPIOs are disconnected and not when led is blinking(it shows 3.4mA)?
    2. What is the current reading should be expected for an idle thread? (It should be in micro amps?).
    3. What are the things to be taken care while creating a new project in the visual studio?
    4. What are the basic configuration setting to be taken in the main function before adding the application code?
    5. What are the CONFIG macros to be enable or disable in the project config file to minimize the power consumption?

    Regards,

    Naveed

Related