This post is older than 2 years and might not be relevant anymore
More Info: Consider searching for newer posts

Thingy91 Power consumption

Hi Dev team,

I am working around with the Thiny91 and wanted to have more information regarding the power consumption characteristics of the board.

I have a program running on the Thingy91 that connects to my server to send sensor data through MQTT, every 5 mins. In the meantime, I want to go into the lowest power consumption mode and wake up only to send data and then back to the low power mode in between.

I currently have a power consumption of around 1.5 mA in the low power mode and I want to reduce it further to the datasheet values. I also have enabled PSM mode with : 

CONFIG_LTE_PSM_REQ_RPTAU="10101010"
CONFIG_LTE_PSM_REQ_RAT="00000001"

and I see that it is configured by the network correctly as well. 

I had a few questions regarding the power consumption of the Thingy91 board :

(1). I get sensor data through my UART every 5 mins, so I cant have CONFIG_SERIAL = n in my prj.conf . That maybe 1 cause for this significantly high power consumption. Can I enable and disable the UART in runtime and will that make any difference to the power consumption in this case.

(2). The Thingy91 user guide says that , the 3.3V power domain can be powered down to save power when Thingy91 is in sleep mode. How can this be done ?

(3). Will it be logical to turn off the modem in order to save power during the sleep mode ?  

(4). Does modem firmware affect the power measurements ?

(5). To measure power power consumption, I use Joulescope and remove the USB power to the Thingy91. Thus, I am unable to view the logs in my link monitor when measuring power. Is there any other way to view the logs while measuring current (like Segger RTT Viewer) and how do I enable that .

(6). Any other power saving tips that could help reduce power for the Thingy91.

Regards,

Adeel. 

  • Hi,

    I was able to proceed with this a bit further. I tested the power save modes samples from ncs 1.4.0. 

    I tested the system off example in : C:\Users\adeel\ncs\v1.4.0\zephyr\samples\boards\nrf\system_off

    I also tested the blinky sample in : C:\Users\adeel\ncs\v1.4.0\zephyr\samples\basic\blinky

    The current was around 1.5 mA when I tested it without any modifications. 

    I followed this guide to try and work with power optimization : developer.nordicsemi.com/.../app_power_opt.html

    After this, I disabled the UART and also the 3.3 V power domain supply through the following functions :  

    err = adp536x_init(ADP536X_I2C_DEV_NAME);


    err = adp536x_buckbst_enable(false);

    Now, I reach a current of about : 0.4 mA (approx 400 uA). 

    What can be the further steps to reduce the current consumption of the Thingy91. What more can I turn off in order to reach the lowest power consumption ?

    Reagrds,

    Adeel.

  • Hi,

    (1). I get sensor data through my UART every 5 mins, so I cant have CONFIG_SERIAL = n in my prj.conf . That maybe 1 cause for this significantly high power consumption. Can I enable and disable the UART in runtime and will that make any difference to the power consumption in this case.

    Yes, you can enable and disable the UART at runtime. One way to do it is to use the power management API in zephyr. This will make a difference in power consumption. The UART consumes about 4-600 uA. By turning it off you should ideally get down to 3-4 uA (unless something else is consuming power as well of course).

    #include <device.h>
    #include "power/power.h"
    
    const struct device *console, *uart1;
    
    void main(void)
    {
      // Turn off logging (which is using UART0):
      console = device_get_binding(DT_LABEL(DT_CHOSEN(zephyr_console)));
      device_set_power_state(console, DEVICE_PM_OFF_STATE, NULL, NULL);
      
      // Turn off UART1:
      uart1 = device_get_binding(DT_LABEL(DT_NODELABEL(uart1)));
      device_set_power_state(uart1, DEVICE_PM_OFF_STATE, NULL, NULL);
      
      .......
    
    }

    and in prj.conf:

    CONFIG_DEVICE_POWER_MANAGEMENT=y

     

    (2). The Thingy91 user guide says that , the 3.3V power domain can be powered down to save power when Thingy91 is in sleep mode. How can this be done ?

     Yes that is correct. I see that you already figured this out in your previous answer. You can use the adp536x library functions

    adp536x_init(ADP536X_I2C_DEV_NAME);
    adp536x_buckbst_enable(false);

     

    (3). Will it be logical to turn off the modem in order to save power during the sleep mode ?  

    Usually you would just send the AT+CFUN=0 command to disconnect from the network and let the modem stay in idle mode. You can then issue new AT commands for reconnecting. Or you can use the LTE link control API. Something link this:

    #include <modem/lte_lc.h>
    
    void main(void){
      int err;
      err = lte_lc_offline();
      
      ......
      
    }

    And in prj.conf:

    CONFIG_NETWORKING=y
    CONFIG_NET_SOCEKTS=y
    CONFIG_NET_SOCKETS_OFFLOAD=y
    
    CONFIG_AT_HOST_LIBRARY=y
    CONFIG_BSD_LIBRARY=y
    
    CONFIG_LTE_LINK_CONTROL=y
    #do not automatically connect to the network:
    CONFIG_LTE_AUTO_INIT_AND_CONNECT=n

    You should get a current consumption of 2.2uA in this mode.

    Alternatively, if the network supports it, you can use PSM mode. In PSM mode the modem is in sleep, but you are still attached to the network, meaning that the energy needed to reconnect to the network is minimal, since it does not have to do the scanning procedure etc. The idle current in PSM mode is 2.7uA.

     

    (4). Does modem firmware affect the power measurements ?

    The modem FW should not affect the power measurements when the modem is turned off. If the modem is turned on and connected/trying to connect to the network it will affect the current consumption.

     

    (5). To measure power power consumption, I use Joulescope and remove the USB power to the Thingy91. Thus, I am unable to view the logs in my link monitor when measuring power. Is there any other way to view the logs while measuring current (like Segger RTT Viewer) and how do I enable that .

     If you want to measure current at the same time as you see the logs you should leave the USB cable plugged in and use the default UART logging module. You can still measure current to the nRF91 and nRF52 through the current measurement headers. However, this is not very useful for debugging current consumption, since the UART module is consuming current. You can turn off RX in the logging module to save some power. NRF_UARTE0->TASKS_STOPRX = 1; And the UART will consume about 50uA instead of 600uA.

    You can use RTT as well if you have a debugger that supports RTT, and connected it to the SWD header. The problem is that in order to use RTT the chip has to be in debug mode, which is consuming 3-4 mA. So it's not that useful at all when measuring current.

     

    (6). Any other power saving tips that could help reduce power for the Thingy91.

     You should start with a simple project where you get the 3-4 uA idle current, and then add one peripheral/feature after another.

    You can also try System OFF mode which will completely shut down the nRF91 and then see what floor current you are able to achieve, and use that as a base line for later measurements.

    Remember that on the thingy91 there are both a nRF91 and a nRF52. If you are not going to use the nRF52 you might want to consider putting this to system OFF mode to save current. Check out the thingy91 schematics to see which external sensors are connected to which nRF chip.

  • Hi Stian,

    Thanks for the detailed answer Slight smile.

    You can also try System OFF mode which will completely shut down the nRF91 and then see what floor current you are able to achieve, and use that as a base line for later measurements.

    Yes, I am using the System Off sample in the zephyr folder as a base line. I have progressed further and I am now able to achieve a current of around 120 uA. I understand that the Thingy91 has nRF91, nrf52 and other external sensors that add to the power consumption as a whole.

    I turned off the UART now by CONFIG_SERIAL = n both in spm and the application.

    I also turned the 3.3 V supply so the LED's, color sensor, buzzer all are off due to this. 

    If you are not going to use the nRF52 you might want to consider putting this to system OFF mode to save curren

    I further want to reduce the current to around 20-30uA. I am not using the nrf52 so I want to switch it off as well. How can this be done ?

    Further, I wanted to know how much current the BME680 environment sensors and the adxl362 accelerometer consumes, and how could I turn it off as I don't need that as well right now. 

    Regards,

    Adeel.

  • Hi Stian,

    Is there any file available to run in the Thingy91 to turn off the nrf52840. 

    I tried to run the system_off sample on the Thingy91 by choosing the board (thingy91_nrf52840) and by switching SW2 to nrf52. I tried to build the file but I got an error. 

    I am doing this in order to put the nrf52840 in system off mode.

    Is there any pre-compiled sample already present to put the nrf52840 into system off mode.

    Regards,

    Adeel.

  • Hi, you can use the connectivity bridge application. Build it for thingy91_nrf52840. It will wake up to relay the UART from the nRF91 when you plug in the USB cable. When you unplug the cable it will go to system OFF mode.

    I tried measuring on the connectivity bridge application on the nRF52, unplugging the USB, and the blinky application on the nRF91 where I turned off logging and UART1 using the code I posted earlier, as well as shutting down the 3.3V buckboost. I got an average current of 10uA on the Lipo power input.

Related