6 ms·
I once increased coin-cell run-time of a client’s hardware (ARM) platform from 1 month to 1.5 years simply by replacing almost all sleep() functions with low-po
by kahlonel 8y ago
I once increased coin-cell run-time of a client’s hardware (ARM) platform from 1 month to 1.5 years simply by replacing almost all sleep() functions with low-power-mode-enter.
- ddalex 8y agoI'd argue that, in this context, sleep() itself is buggy
- kahlonel 8y agoThat was a no-OS situation. sleep() is usually implemented as a calculated number of cycles of `nop`s in those SDKs.
- brokenmachine 8y agoSleep is different to low-power mode in embedded devices. Most (all?) microcontrollers have a wide range of low-power modes that disable more and more features of the chip to save power. So if you only need it to do something say once every minute, you can usually save a lot of battery life by using the low-power modes.