Measuring Current Consumption with Power Profiler Kit II

Originally published at: Measuring Current Consumption with Power Profiler Kit II - Golioth

IoT devices are usually battery-operated and, more often than not, need to run on a single battery charge for multiple years. Before we know it, MCU power consumption becomes a huge deal when developing a product. Measuring power consumption of an MCU can be challenging since it does not depend on just one thing. It depends on multiple factors like clock frequency, what is connected to the outputs, which peripherals are enabled, and also the different MCU-specific power modes in use. With known average current consumption and battery voltage, we can easily calculate the lifetime of a battery charge. Notice the word average; we are interested in the average current consumption over some fixed time period. To maximize battery life, developers must minimize power consumption over the life of the product. For this blog post, we are going to measure current consumption with the Power Profiler Kit II. We’ll utilize a well-known friend as the target, the nRF9160 DK. Device Operating Modes Most battery-powered devices spend much of their time asleep, waking up to perform their functions, and then going back to sleep. For these applications, battery life depends, at least, on three major aspects of the microcontroller: Run/Active mode: device is using the most power (fetching sensor data, communication with the Cloud, running algorithms, etc.) Standby/Idle mode: the “do-nothing” state (an idle thread, sleeping in a while loop, etc.) Sleep Mode: deepest internal power saving mode the system can enter (System OFF mode in the case of nRF9160 DK) The “do-nothing” state of the microcontroller often has many different forms. Start-up time, that being how long it takes the microcontroller to go from the do-nothing state to running the…