Beware that this post is related to an SDK in maintenance mode
More Info: Consider nRF Connect SDK for new designs
This post is older than 2 years and might not be relevant anymore
More Info: Consider searching for newer posts

High current consumption System OFF mode

Hi,

I know that many people ask this question on different posts but I was not able to find the right solution for my case.

I am observing an average current of 4.7uA in System OFF mode instead of 0.3uA from the datasheet.

I’m using the BLE module BL651 from Laird Connectivity which contains a nrf52810.

I started from ble_app_beacon example with SDK 16.0. It uses s112 softdevice if I am not mistaken.

Here is my code:

int main(void)
{
    ret_code_t err_code;

    /* Initialize gpiote module */
    err_code = nrf_drv_gpiote_init();
    APP_ERROR_CHECK(err_code);
    
    /* Initialize led pin */
    nrf_drv_gpiote_out_config_t out_config = GPIOTE_CONFIG_OUT_SIMPLE(false);        /*Configure output led*/
    err_code = nrf_drv_gpiote_out_init(LED_PIN, &out_config);                        /*Initialize output led*/
    APP_ERROR_CHECK(err_code);                                                       /*Check potential error*/
    nrf_drv_gpiote_out_clear(LED_PIN);                                               /*Turn on LED to indicate that nRF5x is not in System-off mode*/

    nrf_delay_ms(3000U);

    /*Configure wake-up button*/
    nrf_drv_gpiote_in_config_t in_config = GPIOTE_CONFIG_IN_SENSE_LOTOHI(false);     /*Configure to generate interrupt and wakeup on pin signal low. "false" means that gpiote will use the PORT event, which is low power, i.e. does not add any noticable current consumption (<<1uA). Setting this to "true" will make the gpiote module use GPIOTE->IN events which add ~8uA for nRF52 and ~1mA for nRF51.*/
    in_config.pull = NRF_GPIO_PIN_PULLDOWN;                                            /*Configure pullup for input pin to prevent it from floting. Pin is pulled down when button is pressed on nRF5x-DK boards, see figure two in http://infocenter.nordicsemi.com/topic/com.nordic.infocenter.nrf52/dita/nrf52/development/dev_kit_v1.1.0/hw_btns_leds.html?cp=2_0_0_1_4*/
    err_code = nrf_drv_gpiote_in_init(ILS_PIN, &in_config, NULL);             /*Initialize the wake-up pin*/
    APP_ERROR_CHECK(err_code);                                                       /*Check error code returned*/
    nrf_drv_gpiote_in_event_enable(ILS_PIN, true);                            /*Enable event and interrupt for the wakeup pin*/

    /*Turn off LED to indicate the nRF5x is in System-off mode*/
    nrf_drv_gpiote_out_set(LED_PIN);
    
    /*Enter System-off*/
    NRF_POWER->SYSTEMOFF = 1;
    
    while(1)
    {
        // Wait for an event.
        __WFE();
        // Clear the internal event register.
        __SEV();
        __WFE();
    
    }

   
}

Here is the setup to measure current :

I supply the BLE651 with 3.0V directly by soldering wires on it. I measure current thanks to a PXI-4065 (National Instrument). On my circuit I have a button (and its pull down resistor) to wake up from system off and an LED (with its serie resistor) to indicate when device is awake. When programming the chip I use “Release” version (and not “debug”) and I disconnect the debugger (physically).

What I have tried:

  • Connect a pull down resistor to SWCLK because I read on another post saying that a floating SWCLK could cause the chip to stay in debug mode
  • Enable DCDC convertor with sd_power_dcdc_mode_set(NRF_POWER_DCDC_ENABLE );
  • Ensure that Constant Latency Mode is disabled by writing sd_power_mode_set(NRF_POWER_MODE_LOWPWR);
  • Disconnect the LED in case it sinks power
  • Replace NRF_POWER->SYSTEMOFF = 1; by sd_power_system_off();

I have seen on other post that it was important to wake up on GPIOTE PORT event instead of IN event for consumption purpose. I think my problem is not related to this because I use GPIOTE_CONFIG_IN_SENSE_LOTOHI(false) with “false” argument.

I also thought the problem came from the fact that I do not use an external 32kHz crystal but I have read on forums that since no clock source is enabled in power off mode there is no need to have a low power crystal.

Any idea to solve this problem ?

  • Hi

    In your code, it seems like you tell the device to go to system OFF mode, then immediately turn on to wait for an event. When using WFE(); the device will stay in system ON, waiting for an event to trigger it. You won't be able to wake the device from system OFF with an event, as the chip won't be on to detect one.

    I suggest you take a look at, for example, the ble_app_hrs example which uses the sleep_mode_enter() function in order to go to system OFF mode.

    Best regards,

    Simon

  • Hi,

    Thank you for the fast reply !

    So you mean that the device starts executing __WFE(); before it has time to enter SYSTEM OFF on the previous line ?

    I tried to empty the while(1) block after the NRF_POWER->SYSTEMOFF = 1; line but I got the same consumption.

    What I see in ble_app_hrs example is that the sleep_mode_enter() function is called in interrupt handlers. Can't I call it in the main() function ?

    Best regards

  • Hi

    Can you try running the following code? This should, per definition consume 0.3µA. If you're still measuring more than that in that case, then the chip is either faulty, or the current measurement is incorrect (either the measuring equipment is not accurate enough, or something external is drawing power).

    int main(void){
      NRF_POWER->SYSTEMOFF = 1;
      for(;;){}
    }

    Best regards,

    Simon

  • Hi,

    I tried your code:

    #include <stdbool.h>
    #include <stdint.h>
    #include "nrf_soc.h"
    
    int main(void)
    {
      NRF_POWER->SYSTEMOFF = 1;
      for(;;){}
    }

    But I am still measuring 4.6uA or 4.7uA.

    I managed to reach 3.8uA by defining NRF_LOG_ENABLED to 0 in the sdk_config.h

    Do you think of some modules I should disable in the sdk_config.h to lower consumption ?

    I am shure that my measurement equipment is accurate enough because it has a resolution of 10nA and I have already measured lower currents (~1uA) on other device.

    There is no external something on the circuit. Only the BL651 module from Laird. Maybe the cause could come from inside the module on the components next to the nrf52810 but I doubt it since Laird Connectivity announces the same 0.3nA current consumption on SYSTEM OFF mode.

    I think that maybe the fact that I am using a bread board and wires soldered to the module leads to increasing consumption. I cannot be sure that the weld quality is perfect or that contacts are really good in the breadboard. But I do not know if it could decrease the current of a value as big as 3uA.

    Best regards,

  • Hi

    Indeed, I don't think your equipment is the issue either by the description in your main post, but I wanted to include it just in case. Are you at all able to drop the breadboard when measuring, to see if the current draw drops at all, or do you have more than one of the BL651 modules, so you can check if the module you're using is faulty or not? There shouldn't be anything on the module itself drawing the extra current as far as I know, so it's either leaking through the breadboard or you've got a faulty chip (at least that's my bet).

    Best regards,

    Simon

Related