Re:The End of Arduino 101: Intel Leaves Maker Market
by Grazester on Tuesday July 25, 2017 @02:54PM
(#14850762)
This is relevant to my interests being that I just got into this Arduino thing. Thank you
Re:The End of Arduino 101: Intel Leaves Maker Market
by HeyLaughingBoy on Tuesday July 25, 2017 @04:59PM
(#14851801)
Bear in mind that while what he said is correct, there are other concerns on an assembled board, as opposed to the bare chip. Arduino has a voltage regulator that is always consuming current. The Power LED is always consuming current. You should be sure to set pin 13 (the indicator LED) as an output and turn it off, since even as an input, there will be leakage current through the LED. The other active components on the board have their own quiescent current levels, etc.
You can get an AVR device to run on a coin cell for months or years (I have a design that does just that). You'd have to modify an Arduino significantly to do the same.
Re:The End of Arduino 101: Intel Leaves Maker Market
by gh02t on Wednesday July 26, 2017 @11:26AM
(#14856994)
Very true, though there are some better Arduino variants. The Pro mini is the canonical "low power" Arduino as it uses a very efficient LDO regulator. I also use bare ATTiny's for a lot of uses, they don't require any passives and can run directly from a LiPo as long as you use a protected cell or connect a feedback line to the ADC.
https://playground.arduino.cc/Learning/ArduinoSleepCode
There are libraries that do this automatically on Arduino too, allowing you to schedule [cooperative] multitasking and sleep the uC between tasks. E.g.
https://github.com/arkhipenko/TaskScheduler
is really good, I've used it before. You basically queue up a list of task callbacks and a schedule in your `setup()` and then do a call to `tasks.execute()` in `loop()`, which pops off the next task that is due in a queue or sleeps otherwise. It's simple, but much more straightforward than manually using `if millis() - last > delta1... else sleep()` and not as rigid as using the timer ISRs (which really serve a different purpose).
On more complex platforms you can also use an RTOS, which is kind of like a more beefed up version of this model. Actually you can do this on AVR too, but I haven't ever seen anybody actually use FreeRTOS/ChibiOS/whatever on AVR.