LowPowerLab Forum

Hardware support => Moteino => Topic started by: SoLongSidekick on December 16, 2013, 12:13:47 PM

Title: Favorite way to power Moteinos?
Post by: SoLongSidekick on December 16, 2013, 12:13:47 PM
Hey all,

Obviously there are a ton of different options available for powering these bad boys, and I started to realize that there is for sure some really clever ideas out there. So what is your favorite way to power these guys?

Through my research (none applied at the moment) it seems these SparkFun Poly Li-ons would be perfect: https://www.sparkfun.com/products/339. They also have a smaller 400 mAh version.

Title: Re: Favorite way to power Moteinos?
Post by: Felix on December 16, 2013, 12:28:21 PM
Any 3.7-4.2 lipo will work. I have a bunch of those 400mAh from Sparkfun, they are about the size of a Moteino. Once I have the PowerShield ready, it should make for a very compact lipo battery powered Moteino solution, while also allowing for other power options like running from a single AA/AAA cell. Otherwise Straight powering Moteinos works from anything above 3.3V, I particularly like 9V batteries, some people don't though...
Title: Re: Favorite way to power Moteinos?
Post by: SoLongSidekick on December 16, 2013, 01:35:32 PM
Felix you are the man! Thanks!

Quick question (linked so I don't have to retype it): http://www.reddit.com/r/arduino/comments/1t0tf9/momentary_button_power_question/
Title: Re: Favorite way to power Moteinos?
Post by: jbeale on December 16, 2013, 02:17:02 PM
I've standardized on AA batteries for everything that I can, and have several 4xAA battery holders. With 4x AA Eneloop NiMH cells that gives you about 5 V at 2000 mAh.  This is of course larger than a 9V battery though.
Title: Re: Favorite way to power Moteinos?
Post by: Felix on December 16, 2013, 06:57:14 PM
SoLongSidekick - In that tutorial the voltage was 5V because it was feeding from the Arduino's 5V regulated output. In the case of Moteino you'd just connect that to Moteino's "3.3" pin, which is equivalent. No level shifting needed. You're merely pulling up that input by means of the momentary button.

jbeale - 4xAA is quite a punch. Should last foreeeever - if you're sleeping them of course ;)
Title: Re: Favorite way to power Moteinos?
Post by: hexibot43 on December 16, 2013, 11:04:41 PM
I would love to see a rechargeable battery with a solar cells shield.  For now I'm sticking with 9v (size does matter).  Once I get the base station and display node working on my project I'm going to give that a try.  I'd really like to see a battery that lasts a good 10 years!  Yeah right!   
Title: Re: Favorite way to power Moteinos?
Post by: Felix on December 17, 2013, 08:45:54 AM
In all reality I think technology changes too fast for anyone to keep say a Moteino for 10 years somewhere without changing the code or wanting to make some change/upgrade that requires physical operation. That's why I never lost too much sleep over squeezing the last possible nano amp out of Moteino. Others did that and I thought it was interesting and informational but seemed a bit pointless.
If someone can't spend $2 on a battery that will last 1 year, then they are probably in the wrong field. Typically they are the people that want a discount if they buy more than 1 moteino ;)

Now someone will find this post and slam me because the site name is LowPowerLab. I get it, but really Moteino is as low power as you can get without sweating too much, and I'd rather get more things done than spend 6 more months figuring out how to save a few extra nano amps. Besides there are so many cheap power options out there now...
Title: Re: Favorite way to power Moteinos?
Post by: hexibot43 on December 17, 2013, 11:19:47 AM
Felix,
     I'm glad you posted your comment on this subject.  I've decided you are right.  A good year out of a battery should be good enough.  I will listen to what you've said and not waste anymore time on battery life.  I would just really like to do away with the battery all together.  Or just not have to think about it. 
Title: Re: Favorite way to power Moteinos?
Post by: Felix on December 17, 2013, 12:35:52 PM
It's a trade off. I think battery life critical projects are outliers that are far less common than other things. I can think of one that I'd like to promote though - the MotionMote. On that one you could use as much battery life as you can get. Even so we're limited by the amount of current drawn by the sensor itself which has to always be ON. In which case a lipo could be used, a more expensive solution, but cheaper in the long term. So yeah ... there's always some kind of quick and cheap solution. You can spend years, and do 100 x PhD theses on saving battery life and coming up with smarter silicon that's more power efficient. I would personally like to rather spend that time building more things...
Title: Re: Favorite way to power Moteinos?
Post by: sketchy on December 17, 2013, 01:08:14 PM
I thought this post on battery power http://jeelabs.org/2010/12/03/what-is-%E2%80%9Cpower%E2%80%9D/ (http://jeelabs.org/2010/12/03/what-is-%E2%80%9Cpower%E2%80%9D/)

was clear and insightful.  I assume a product offering from lowpowerlab.com will be a battery (+ however you need to attach to moteino + arduino library (as needed)).

How would this product offering compare/contrast/be an example of the (cool info for electronic n00bs like myself) pointed out in the above post?
Title: Re: Favorite way to power Moteinos?
Post by: Felix on December 17, 2013, 01:59:17 PM
Umm .. you're probably asking about something that is either being worked on (mentioned here and on the blog as "PowerShield") or does not exist yet :)
Stay tuned for updates, whenever they become available.
Title: Re: Favorite way to power Moteinos?
Post by: KanyonKris on December 17, 2013, 06:08:35 PM
I was going to use a 9 volt battery, like Felix used for the Mailbox Notifier since I'm building something very similar. But I would like it to be more compact so I'm going to use two CR2032 Lithium (not rechargeable) button cells, 20mm diameter. Each CR2032 is 250mAh @ 3V so I'll have 500mAh at 6V. Since a 9 V battery is also around 500mAh I should get 9+ months out of two small batteries.

I'm tempted to budget more space for batteries and go with 3 AAA Eneloops. 3 X 750mAh each = 2250mAh which is a huge amount of power for a Moteino. And with the insignificant self-discharge rate of <10% per year, I should get 2+ years on one charge.

Rechargeable Lithium Ion batteries also pack a lot of charge in a small package, but watch out for self discharge. I've seen numbers of 2-8% per month. Sparkfun just says <8%. If it's 8% then 80% of the charge is gone in 10 months which is OK but not awesome. If it's 5% then only half the charge is lost. Will the Sparkfun 400mAh Lithium Ion battery last as long as a 9V battery? Maybe.

Lots of good choices for battery power these days.
Title: Re: Favorite way to power Moteinos?
Post by: SoLongSidekick on December 17, 2013, 06:57:37 PM
I've got one more question. I just picked up a few of the SF LiPoly batteries and am wondering how I would power a Moteino and a 5v device at the same time. Help a noob out haha.
Title: Re: Favorite way to power Moteinos?
Post by: Felix on December 17, 2013, 07:22:52 PM
You would need some kind of boost regulator to get that 3.7V up to 5V. PowerShield will do just that.
Title: Re: Favorite way to power Moteinos?
Post by: SoLongSidekick on December 18, 2013, 01:19:26 AM
Ah ok, I placed this on my order (https://www.sparkfun.com/products/12009). Will that work?

Also, do I need to cut the 3v logic level jumper on my FTDI Adapter and solder the 5v one to get it to work with an Arduino Pro Mini 5v (https://www.sparkfun.com/products/11113)?

Thanks for all the help bud.
Title: Re: Favorite way to power Moteinos?
Post by: Felix on December 18, 2013, 08:18:34 AM
Would that work to "level translate"? I think so, that's what it's for, never used that particular one but should work.
Before you cut the trace, try it as is, they provide 5V power and 3.3V logic. See this: http://lowpowerlab.com/shop/FTDI-Adapter
Title: Re: Favorite way to power Moteinos?
Post by: LazyGlen on December 18, 2013, 01:02:35 PM
Quote from: KanyonKris on December 17, 2013, 06:08:35 PM
... But I would like it to be more compact so I'm going to use two CR2032 Lithium (not rechargeable) button cells, 20mm diameter. Each CR2032 is 250mAh @ 3V so I'll have 500mAh at 6V. Since a 9 V battery is also around 500mAh I should get 9+ months out of two small batteries.
...

It has been a long time since I studied this stuff, but I think you are mistaken.
Qty (2) 2032 batteries with 250mAH @ 3v does not get you 500mAH @ 6v. If you put them in series (one atop the other) you get 250mAH at 6v. If you put them in parallel, (side by side, if you will) you get 500mAH at 3v.

The other thing to be careful of is - what conditions are used to generate the rating? I pulled up a Sony  CR2032 data sheet via a web search: http://www.cr2032.co/cms/prodimages/sony_cr2032_datasheet_13.pdf and at the top of the page it states that the standard discharge current is 0.2mA or 200 nano amps. According to Felix's testing posted here: http://lowpowerlab.com/blog/2012/12/24/moteino-coin-cell-battery-tests/ depending on what you are doing, you can easily exceed that.

Don't let me stop you, but be prepared for results that differ from expected.
[edit]
I knew I had seen some measurements! The coin cell tests were based on RFM12B, the rating for RFM69W is 45mA in transmit mode, 16mA in receive mode. So you will certainly be exceeding the standard discharge current when the radio is active.
[/edit]
Title: Re: Favorite way to power Moteinos?
Post by: SoLongSidekick on December 18, 2013, 01:59:20 PM
I did try, I think I either have a software problem on my end or there might be something wrong with my FTDI Adapter. I tried using it on both my Moteinos and nothing. Then just to sanity check tried it on a Arduino Pro Mini and still nothing.

Will try again when I get home from work.
Title: Re: Favorite way to power Moteinos?
Post by: Felix on December 18, 2013, 05:13:50 PM
You got an FTDI Adapter from my shop and it's not working? That would be a very low possibility.
How exactly are you using it, what steps are you taking? (Software wise...)
What is the target board you are choosing?
Title: Re: Favorite way to power Moteinos?
Post by: KanyonKris on December 19, 2013, 12:16:52 AM
Quote from: LazyGlen on December 18, 2013, 01:02:35 PM
It has been a long time since I studied this stuff, but I think you are mistaken.
Qty (2) 2032 batteries with 250mAH @ 3v does not get you 500mAH @ 6v. If you put them in series (one atop the other) you get 250mAH at 6v. If you put them in parallel, (side by side, if you will) you get 500mAH at 3v.

The other thing to be careful of is - what conditions are used to generate the rating? I pulled up a Sony  CR2032 data sheet via a web search: http://www.cr2032.co/cms/prodimages/sony_cr2032_datasheet_13.pdf and at the top of the page it states that the standard discharge current is 0.2mA or 200 nano amps. According to Felix's testing posted here: http://lowpowerlab.com/blog/2012/12/24/moteino-coin-cell-battery-tests/ depending on what you are doing, you can easily exceed that.

Don't let me stop you, but be prepared for results that differ from expected.
[edit]
I knew I had seen some measurements! The coin cell tests were based on RFM12B, the rating for RFM69W is 45mA in transmit mode, 16mA in receive mode. So you will certainly be exceeding the standard discharge current when the radio is active.
[/edit]
The capacity does add when multiple batteries are used together (think 2 buckets of water). But you are correct, those coin cells can't supply much current and that's a problem. In a similar microcontroller + radio application, one guy used a capacitor in parallel with the coin cell(s) to supply current to the radio when it transmitted every 10 seconds.

I don't feel like fiddling with coin cells + capacitor so I'm going with 3 AAA batteries. The enclosure won't be quite so tiny but it will be small enough for my application.

Thanks, LazyGlen, for helping me avoid some frustration.
Title: Re: Favorite way to power Moteinos?
Post by: LazyGlen on December 19, 2013, 07:35:53 AM
Quote from: KanyonKris on December 19, 2013, 12:16:52 AM
The capacity does add when multiple batteries are used together (think 2 buckets of water). But you are correct, those coin cells can't supply much current and that's a problem. In a similar microcontroller + radio application, one guy used a capacitor in parallel with the coin cell(s) to supply current to the radio when it transmitted every 10 seconds.

I don't feel like fiddling with coin cells + capacitor so I'm going with 3 AAA batteries. The enclosure won't be quite so tiny but it will be small enough for my application.

Thanks, LazyGlen, for helping me avoid some frustration.

Not to belabor the point, but for clarity and future reference. You double EITHER the voltage OR the capacity (AH) with 2 batteries, depending on series or parallel. A more thorough writeup is here: http://www.zbattery.com/Connecting-Batteries-in-Series-or-Parallel

I ordered some extra NiMH packs for my cordless phones a while back for an abandoned project, they look like (3) AAA batts shrink wrapped with a JST(?) connector. They are not much bigger than the Moteino with the FTDI header soldered on. They look to be perfect for powering up these little suckers. Plus with 4 cordless phones around the house, to recharge, I can just swap a pack, phone to Moteino and drop the phone into it's charger.

I'm glad I saved you some frustration, I always seem to cause myself more!
Title: Re: Favorite way to power Moteinos?
Post by: KanyonKris on December 19, 2013, 08:59:18 PM
Quote from: LazyGlen on December 19, 2013, 07:35:53 AM
Not to belabor the point, but for clarity and future reference. You double EITHER the voltage OR the capacity (AH) with 2 batteries, depending on series or parallel. A more thorough writeup is here: http://www.zbattery.com/Connecting-Batteries-in-Series-or-Parallel
How about some more belaboring? ;) Yes, the amp hours will not double, but 2 batteries do hold twice as much energy as 1. Amp hours are how much current a battery can supply in an hour. However batteries have internal resistance that determines how much current can flow out of a battery which is somewhat independent of how "big" the battery is, which you wisely pointed out with the small discharge rate of coin cell lithiums. Think of two buckets with holes in the bottom with one above the other (serial) - you won't get more water flowing with 2 buckets compared to 1 bucket, but you will have twice as much water so you'll get twice as much total water expelled.
Amp hours are useful for comparing batteries of the same type (ie alkaline or lithium ion), but they don't tell the whole story in terms of how much much electrical energy is stored. Here's a decent discussion - http://www.dcbattery.com/faq.html
Quote
I ordered some extra NiMH packs for my cordless phones a while back for an abandoned project, they look like (3) AAA batts shrink wrapped with a JST(?) connector. They are not much bigger than the Moteino with the FTDI header soldered on. They look to be perfect for powering up these little suckers. Plus with 4 cordless phones around the house, to recharge, I can just swap a pack, phone to Moteino and drop the phone into it's charger.
Be careful, many NiMH have high self-discharge rates and are often dead in a month, maybe 2 (like my cordless phones and previous generation cordless drill). There are low self-discharge NiMH like Eneloops that have a long shelf life and can be used essentially like alkalines.
Title: Re: Favorite way to power Moteinos?
Post by: LazyGlen on December 19, 2013, 10:39:37 PM
My wife tells me I argue too much and no one cares  :'(

We may even be arguing the same side, and I realize that you have already moved past the coin cell for your project. I'm feeling dense, but I'm trying to learn, and I'll keep asking questions till you get tired of answering them!

Point 6 on your link page says the same thing I did. I realize that putting 2 cells in the circuit doubles the energy available, but you can only double 1 variable, capacity or voltage. Capacity == volume and voltage == head or pressure.

The water-as-electricity analogy works, and I've used it myself, but don't forget that any voltage over 3.3v gets burned off by the on board regulator, putting an "extra hole" in our buckets that only spills on the floor (or heats up the enclosure in the case of electricity).

Quote
Be careful, many NiMH have high self-discharge rates and are often dead in a month, maybe 2 (like my cordless phones and previous general cordless drill). There are low self-discharge NiMH like Eneloops that have a long shelf life and can be used essentially like alkalines.
Thank you! This explains why the battery packs were dead on the shelf where I left them. The one that I popped into the phone does seem to have taken a charge, I don't know if or how badly they are damaged.

I guess since this directly relates to the "How do you power Moteinos" title of the thread, I'll put this out for critique:
Building a slight variation of a WattMote. Would like to monitor power conditions long term, including date, time and duration of any fluctuations or interruptions. So I intend to add this small 3.6v 1000mAH battery pack inside the Kill-a-Watt with a LM317 regulator setup for a (1000Mah/40 =) 25ma (or so) trickle charge sourced from the full wave rectified  ~14.4v signal. The Moteino should then not have problems interfering with the nearly fully used supply available from the on board 7805 that others have reported having issues with and requiring the monster cap to mitigate with the xBee solution. This allows me to not really worry about current draw (within reason) for what I can stuff into the case, as well as enabling me to store in on board RAM (or an SD-card - stuffed in) a time stamp (DS1307 stuffed in) of power loss and recovery. When I power up or come in rage with a receiving unit, I can get a full log of data.

LazyGlen
Title: Re: Favorite way to power Moteinos?
Post by: KanyonKris on December 20, 2013, 02:00:03 AM
While we were agreeing on some things, I was wrong on the primary issue you brought to my attention: 2 same batteries in series will double the voltage output, but the Amp-hours will only be that of one battery. I was the dense one, but it finally clicked. For some reason the Point 6 of the FAQ I referenced was more clear to me than the one you first pointed out, and your mention of voltage as head pressure finally got the light bulb to come on. I see my mistake now. Indeed 2 batteries have twice the energy, but in series that is already accounted for by the voltage doubling. If the Amp-hours also doubled then the power would be 4x, and that's wrong. Thank you for persevering.

Yes, the regulator burns more power the higher the voltage goes above 3.3. Three alkalines shouldn't be too bad (4.5 V), but I would do better to use Eneloops that fairly quickly drop to 1.2 V and stay pretty flat until nearly out of charge - and that would give me 3.6 V which should result in very little lost to the regulator. Hmm, could I risk bypassing the regulator? I'll check the datasheets.

As for your WattMote variation, the general idea makes sense but I wasn't able to follow the details enough to be sure it will work as you intend. Wire it up and try it?
Title: Re: Favorite way to power Moteinos?
Post by: LazyGlen on December 20, 2013, 07:42:19 AM
Quote from: KanyonKris on December 20, 2013, 02:00:03 AM
... Indeed 2 batteries have twice the energy, but in series that is already accounted for by the voltage doubling. If the Amp-hours also doubled then the power would be 4x, and that's wrong. Thank you for persevering.
I'm glad we are now on the same page, though I was hoping you had a secret that I just didn't 'get' method of getting more energy out of those cells.

Quote from: KanyonKris
Yes, the regulator burns more power the higher the voltage goes above 3.3. Three alkalines shouldn't be too bad (4.5 V), but I would do better to use Eneloops that fairly quickly drop to 1.2 V and stay pretty flat until nearly out of charge - and that would give me 3.6 V which should result in very little lost to the regulator. Hmm, could I risk bypassing the regulator? I'll check the datasheets.
My point on the regulator was more regarding the 6v of our previous discussion. I think you are fine with 3 Eneloops, bypassing the regulator seems like it would be more trouble than it is worth. A quick web search indicates the freshly charged voltage is 1.4 volts, which gives you 4.2v into the Moteino, which is more than I would feel comfortable with.

Quote from: KanyonKrisAs for your WattMote variation, the general idea makes sense but I wasn't able to follow the details enough to be sure it will work as you intend. Wire it up and try it?
I intend to. I just put it in here as a sanity check, in case anyone jumps up yelling "DON'T DO THAT!" or "but if you do this...".

I will write it up over on the projects page as I get further into it.
Title: Re: Favorite way to power Moteinos?
Post by: hexibot43 on December 20, 2013, 11:29:22 AM
     I am truly enjoying this respectful debate.  I feel that I've learned a lot as well.  It has prompted me to  think hard about using the 9v that I have become so accustom to using.  Thanks,  Mab

   
Title: Re: Favorite way to power Moteinos?
Post by: Felix on December 20, 2013, 12:53:46 PM
9V batteries surely won't be as efficient as 3 AA/AAAs, but it's convenience for me...
Title: Re: Favorite way to power Moteinos?
Post by: KanyonKris on December 21, 2013, 12:33:14 AM
9-10 months on a 9 V battery is good, nothing wrong with that.
Title: Re: Favorite way to power Moteinos?
Post by: Felix on December 21, 2013, 11:45:41 AM
you can prolly get more if you transmit once a minute instead of every 8 seconds.
Title: Re: Favorite way to power Moteinos?
Post by: KanyonKris on December 21, 2013, 01:57:17 PM
I'm using this for my remote Moteino (using the Lowpower library):

LowPower.powerDown(SLEEP_8S, ADC_OFF, BOD_OFF);

SLEEP_8S is the longest duration predefined. My guess is 8 seconds is the longest the watchdog timer can be set for.

So to go longer than 8 seconds between transmitting data, I take it I'd just have a counter loop to put the Moteino right back to sleep when it wakes up until the count was up (say to 7 which is close to 1 minute).

I don't need updates every 8 seconds. I'll do 32 (4x8) or 64 seconds.

I think I will blink the LED every time the Moteino wakes up (every 8 seconds) just as a heartbeat so I can see it's alive. And double blink when it transmits data. I may remove this later to save a tiny bit more power, but will probably leave it in, could be handy.
Title: Re: Favorite way to power Moteinos?
Post by: Felix on December 21, 2013, 02:11:17 PM
set up a counter, then every time you wake up from those 8 sleepy seconds, check the counter and go back to sleep ASAP. Ie if you want to wakeup every 32 seconds just sleep 4 times. If you need some exotic sleep time like 17 seconds, then use the narcoleptic library, it has the same functionality and has some functions to divide your given sleep time into chunks that will approximate it as closely as possible (watchdog can only sleep in fixed amounts of time, going from a few ms to a few sec):

https://code.google.com/p/narcoleptic/
Title: Re: Favorite way to power Moteinos?
Post by: SoLongSidekick on December 23, 2013, 04:40:06 PM
Quote from: Felix on December 18, 2013, 05:13:50 PM
You got an FTDI Adapter from my shop and it's not working? That would be a very low possibility.
How exactly are you using it, what steps are you taking? (Software wise...)
What is the target board you are choosing?

Using the Arduino IDE. I didn't put a whole lot of thought into it, I just wanted to perform a quick test. I stopped once I couldn't get the COM port to come up in the IDE.