How to reduce power consumption to uA level for nrf5340

hi professor,

I'm using nrf5340 to design project,now I wan to reduce power consumption to uA level.According to https://devzone.nordicsemi.com/nordic/nordic-blog/b/blog/posts/optimizing-power-on-nrf53-designs?CommentId=ae95c50b-10df-43ad-938f-ac5b9f33677a, I set the CPU power consumption to the lowest using system_off, and measured the power consumption with ppk 2, which still showed 1.25ma.I think the power consumption of nrf5340 can reach the lowest uA level. Please give me some suggestions to further reduce power consumption.


My product design diagram is shown in the following figure,All devices except for the CPU have been powered off at the low power status:

Now i will show i have done something to reduce power:

1、make app core to enter system off mode by system_off().

2、make unused peripheral to disable status by overlay file.

/* overlay file */
#include <dt-bindings/regulator/npm1300.h>
#include <zephyr/dt-bindings/input/input-event-codes.h>

my_spi: &spi4 {
status = "okay";
compatible = "nordic,nrf-spim";
pinctrl-0 = <&spi4_default_alt>;
pinctrl-1 = <&spi4_sleep_alt>;
pinctrl-names = "default", "sleep";
};

&pinctrl {

spi4_default_alt: spi4_default_alt {
group1 {
psels = <NRF_PSEL(SPIM_SCK, 0, 8)>,
<NRF_PSEL(SPIM_MOSI, 0, 9)>,
<NRF_PSEL(SPIM_MISO, 0, 10)>;
};
};

spi4_sleep_alt: spi4_sleep_alt {
group1 {
psels = <NRF_PSEL(SPIM_SCK, 0, 8)>,
<NRF_PSEL(SPIM_MOSI, 0, 9)>,
<NRF_PSEL(SPIM_MISO, 0, 10)>;
low-power-enable;
};
};
};

arduino_spi: &spi4 {
cs-gpios = <&gpio1 5 GPIO_ACTIVE_LOW>; /* D10 */
};

&button0 {
/delete-property/ gpios;
};

&button2 {
gpios = <&gpio0 25 (GPIO_ACTIVE_LOW | GPIO_PULL_UP)>;
};

&button3 {
gpios = <&gpio0 27 (GPIO_ACTIVE_LOW | GPIO_PULL_UP)>;
};

&button0 {
gpios = <&gpio0 23 0>;
};

&uart0_default {
group1 {
psels = <NRF_PSEL(UART_TX, 1, 12)>;
};

group2 {
psels = <NRF_PSEL(UART_RX, 0, 31)>;
};
};

&uart0 {
current-speed = <9600>;
};

&uart0_sleep {
group1 {
psels = <NRF_PSEL(UART_TX, 1, 12)>;
};

group2 {
psels = <NRF_PSEL(UART_RX, 0, 31)>;
};
};
&nfct {
status = "disabled";
};
&usbd {
status = "disabled";
};
arduino_serial: &uart1 {
status = "disabled";
};
&qspi {
status = "disabled";
};

&led3 {
gpios = <&gpio0 16 (GPIO_ACTIVE_LOW)>;
};

&gpio_fwd {
status = "disabled";
uart {
gpios = <&gpio0 24 0>;
};
};

&i2c1_default {

group1 {
psels = <NRF_PSEL(TWIM_SCL, 1, 13)>, <NRF_PSEL(TWIM_SDA, 1, 14)>;
bias-pull-up;
};
};
&i2c1_sleep {
group1 {
psels = <NRF_PSEL(TWIM_SDA, 1, 14)>, <NRF_PSEL(TWIM_SCL, 1, 13)>;
bias-pull-up;
};
};

&pwm0_default {
group1 {
psels = <NRF_PSEL(PWM_OUT0, 0, 30)>;
low-power-enable;
};
};

&pwm0_sleep {
group1 {
psels = <NRF_PSEL(PWM_OUT0, 0, 30)>;
low-power-enable;
};
};

&arduino_i2c {
npm1300_ek_pmic: pmic@6b {
compatible = "nordic,npm1300";
reg = <0x6b>;

npm1300_ek_gpio: gpio-controller {
compatible = "nordic,npm1300-gpio";
gpio-controller;
#gpio-cells = <2>;
ngpios = <5>;
};

npm1300_ek_regulators: regulators {
compatible = "nordic,npm1300-regulator";
/* limits are set to min/max allowed values */
npm1300_ek_buck1: BUCK1 {
regulator-min-microvolt = <1800000>;
regulator-max-microvolt = <3300000>;
/delete-property/ regulator-init-microvolt;
};
npm1300_ek_buck2: BUCK2 {
regulator-min-microvolt = <1000000>;
regulator-max-microvolt = <3300000>;
regulator-init-microvolt = <1800000>;
regulator-always-on;
regulator-boot-on;
/delete-property/ retention-microvolt;
/delete-property/ enable-gpios;
/delete-property/ retention-gpios;
/delete-property/ pwm-gpios;
};

npm1300_ek_ldo1: LDO1 {
regulator-min-microvolt = <1800000>;
regulator-max-microvolt = <3300000>;
regulator-init-microvolt = <1800000>;
regulator-initial-mode = <NPM1300_LDSW_MODE_LDO>;
/delete-property/regulator-always-on;
regulator-boot-on;
/delete-property/ enable-gpios;
};

npm1300_ek_ldo2: LDO2 {
regulator-min-microvolt = <1800000>;
regulator-max-microvolt = <3300000>;
regulator-init-microvolt = <3300000>;
regulator-initial-mode = <NPM1300_LDSW_MODE_LDO>;
regulator-always-on;
regulator-boot-on;
/delete-property/enable-gpios;
};
};
npm1300_ek_charger: charger {
compatible = "nordic,npm1300-charger";
term-microvolt = <4200000>;
term-warm-microvolt = <4000000>;
current-microamp = <400000>;
dischg-limit-microamp = <1000000>;
vbus-limit-microamp = <500000>;
thermistor-ohms = <10000>;
thermistor-beta = <3380>;
charging-enable;
vbatlow-charge-enable;
};
npm1300_ek_buttons: buttons {
compatible = "gpio-keys";
pmic_button0: pmic_button_0 {
gpios = < &npm1300_ek_gpio 0 GPIO_ACTIVE_HIGH>;
label = "Pmic button switch 0";
zephyr,code = <INPUT_KEY_0>;
};
};
npm1300_ek_leds: leds {
compatible = "nordic,npm1300-led";
nordic,led0-mode = "host";
nordic,led1-mode = "charging";
nordic,led2-mode = "error";
};
};
};
&led2 {
gpios = <&gpio0 30 0>;
};
  • Hi,

    Could you attach your prj.conf file too?

    Please make sure that you have logging disabled. Also, are you using the regulator in LDO or DCDC mode? DCDC helps in reducing power consumption.

    Regards,

    Priyanka

  • hi,

    the prj.conf show below,CONFIG_LOG is n and CONFIG_BOARD_ENABLE_DCDC_APP=y,
    CONFIG_BOARD_ENABLE_DCDC_NET=y,CONFIG_BOARD_ENABLE_DCDC_HV=y

    CONFIG_BT=y
    CONFIG_BT_DEBUG_LOG=y
    CONFIG_BT_SMP=y
    CONFIG_BT_SIGNING=y
    CONFIG_BT_PERIPHERAL=y
    CONFIG_BT_DIS=y
    CONFIG_BT_ATT_PREPARE_COUNT=5
    CONFIG_BT_PRIVACY=y
    CONFIG_BT_DEVICE_NAME="Zephyr Peripheral"
    CONFIG_BT_DEVICE_APPEARANCE=833
    CONFIG_BT_DEVICE_NAME_DYNAMIC=y
    CONFIG_BT_DEVICE_NAME_MAX=65
    CONFIG_BT_KEYS_OVERWRITE_OLDEST=y
    CONFIG_BT_SETTINGS=y
    CONFIG_BT_L2CAP_TX_MTU=247
    CONFIG_BT_BUF_ACL_RX_SIZE=251

    CONFIG_BT_USER_PHY_UPDATE=y
    CONFIG_BT_USER_DATA_LEN_UPDATE=y
    CONFIG_BT_GAP_AUTO_UPDATE_CONN_PARAMS=y

    CONFIG_BT_GATT_CLIENT=y
    CONFIG_BT_ATT_PREPARE_COUNT=2
    CONFIG_BT_CONN_TX_MAX=10
    CONFIG_BT_L2CAP_TX_BUF_COUNT=10
    CONFIG_BT_L2CAP_DYNAMIC_CHANNEL=y
    CONFIG_BT_CTLR_PHY_2M=y
    CONFIG_BT_CTLR_RX_BUFFERS=2
    CONFIG_BT_BUF_ACL_TX_COUNT=10
    CONFIG_BT_BUF_ACL_TX_SIZE=251
    CONFIG_BT_CTLR_DATA_LENGTH_MAX=251
    #######DC DC Power######################
    CONFIG_BOARD_ENABLE_DCDC_APP=y
    CONFIG_BOARD_ENABLE_DCDC_NET=y
    CONFIG_BOARD_ENABLE_DCDC_HV=y

    ##################date time################
    CONFIG_DATE_TIME=y
    CONFIG_DATE_TIME_AUTO_UPDATE=y
    CONFIG_DATE_TIME_MODEM=n
    CONFIG_DATE_TIME_NTP=n

    ###################filesystem #############
    CONFIG_NVS=y
    #CONFIG_SETTINGS=y
    CONFIG_DISK_ACCESS=y
    CONFIG_FILE_SYSTEM=y
    CONFIG_FAT_FILESYSTEM_ELM=y
    CONFIG_FILE_SYSTEM_MAX_FILE_NAME=64
    CONFIG_FS_FATFS_MAX_SS=2048

    ##################dsp########################
    CONFIG_FPU=y
    CONFIG_NEWLIB_LIBC=y
    CONFIG_NEWLIB_LIBC_NANO=n
    CONFIG_CMSIS_DSP=y
    CONFIG_CMSIS_DSP_MATRIX=y
    CONFIG_CMSIS_DSP_FASTMATH=y
    CONFIG_NEWLIB_LIBC_FLOAT_PRINTF=y

    #############################################
    #CONFIG_NO_OPTIMIZATIONS=y
    CONFIG_NRFX_QSPI=n
    CONFIG_LOG_PROCESS_THREAD_SLEEP_MS=100
    CONFIG_MINIMAL_LIBC_MALLOC_ARENA_SIZE=128
    CONFIG_PPI_TRACE=y
    CONFIG_NRFX_TIMER1=y
    CONFIG_NRFX_TIMER2=y
    #CONFIG_NRFX_PWM=y
    CONFIG_NRFX_PWM0=y
    ###################spi########################
    CONFIG_GPIO=y
    CONFIG_NRFX_GPIOTE=y
    CONFIG_NRFX_DPPI=y
    CONFIG_NRFX_SPIM1=y
    CONFIG_NRFX_SPIM2=y
    CONFIG_NRFX_SPIM3=y
    CONFIG_NRFX_SPIM4=y

    ##############UART#############################
    CONFIG_NRFX_UARTE0=y
    CONFIG_UART_ASYNC_API=y
    CONFIG_SERIAL=y

    # enable to use thread names
    CONFIG_THREAD_NAME=y
    ###############i2c###############################
    CONFIG_NRF_FUEL_GAUGE=y
    CONFIG_I2C=y
    CONFIG_NRFX_TWIM1=y
    ##############use k_malloc#########
    CONFIG_HEAP_MEM_POOL_SIZE=4096
    CONFIG_BT_RX_STACK_SIZE=4096
    ############main stack#####################
    CONFIG_MAIN_STACK_SIZE=4096
    CONFIG_SYSTEM_WORKQUEUE_STACK_SIZE=2304
    CONFIG_HW_STACK_PROTECTION=y
    CONFIG_NRFX_GPIOTE_NUM_OF_EVT_HANDLERS=2

    ###############reboot enable##############
    CONFIG_REBOOT=y
    CONFIG_LOG=n
    CONFIG_CONSOLE=y
    CONFIG_UART_CONSOLE=n
    CONFIG_RTT_CONSOLE=y
    CONFIG_USE_SEGGER_RTT=y
    CONFIG_ASSERT=y
    CONFIG_STDOUT_CONSOLE=y
    CONFIG_RESET_ON_FATAL_ERROR=n
    CONFIG_EXTRA_EXCEPTION_INFO=y

    ##################buzzer##########################
    CONFIG_PWM=y
    #CONFIG_PWM_LOG_LEVEL_DBG=y

    CONFIG_REGULATOR=y
    CONFIG_SENSOR=y
    CONFIG_LED=y

    ###############pm cfg###########################
    CONFIG_PM=y
    CONFIG_PM_DEVICE=y
    CONFIG_POWEROFF=y

  • Hi,

    Please try to avoid any floating GPIO pins. If they are not used, maybe try to configure them as disconnected. Also, from your dts file, for the nPM1300 there is the LDO2 and BUCK2 etc. set to always on. If these regulators are not being used, try to turn them off.

    -Priyanka

Related