CCS C Software and Maintenance Offers
FAQFAQ   FAQForum Help   FAQOfficial CCS Support   SearchSearch  RegisterRegister 

ProfileProfile   Log in to check your private messagesLog in to check your private messages   Log inLog in 

CCS does not monitor this forum on a regular basis.

Please do not post bug reports on this forum. Send them to CCS Technical Support

PIC power consumption
Goto page 1, 2  Next
 
Post new topic   Reply to topic    CCS Forum Index -> General CCS C Discussion
View previous topic :: View next topic  
Author Message
Nick
Guest







PIC power consumption
PostPosted: Fri Jul 30, 2004 9:20 am     Reply with quote

I did a search on power consumption and found some topics but not how to get the actually power consumption. Can I measure this with a multimeter? or possible hook it up to a battery and take samples of the power loss?

Nick
ckielstra



Joined: 18 Mar 2004
Posts: 3680
Location: The Netherlands

View user's profile Send private message

PostPosted: Fri Jul 30, 2004 9:29 am     Reply with quote

A multimeter in series with your battery should be sufficient for most applications.
Nick
Guest







PostPosted: Fri Jul 30, 2004 10:40 am     Reply with quote

It shows 77-80ma, how can I take this information and apply it to how much drain it would place on a duracell 9volt? bascially how long will this thing last on a duracell 9volt. Anyone got a link or formula?

Thanks,
Nick
Mark



Joined: 07 Sep 2003
Posts: 2838
Location: Atlanta, GA

View user's profile Send private message Send e-mail

PostPosted: Fri Jul 30, 2004 10:43 am     Reply with quote

Take the capacity of the battery and divide by your current. The result is in hours roughly.
Nick
Guest







PostPosted: Fri Jul 30, 2004 11:01 am     Reply with quote

so a lithium 9volt has around 1200 mAh, so at 80ma it will drain the battery in around 15 hours? is that correct?

To get a 9 volt battery to 120 days will take the pic to only draw 10 ma?

does this sound correct?

Nick
Neutone



Joined: 08 Sep 2003
Posts: 839
Location: Houston

View user's profile Send private message

PostPosted: Fri Jul 30, 2004 11:13 am     Reply with quote

To get a 9 volt battery to 120 hours will take the pic to only draw 10 ma.

To get a 9 volt battery to 120 days will take the pic to only draw 410ua
Ttelmah
Guest







PostPosted: Fri Jul 30, 2004 2:32 pm     Reply with quote

Nick wrote:
It shows 77-80ma, how can I take this information and apply it to how much drain it would place on a duracell 9volt? bascially how long will this thing last on a duracell 9volt. Anyone got a link or formula?

Thanks,
Nick

There have been a lot of threads about low power applications before. There are a whole lot of things that must be done to get consumption down.
First ensure that no pins are left as 'inputs', with nothing conncted.
Second, look at anything the PIC is driving. Can you switch it off/disable it, for at least part of the time?.
Third look at the peripherals in the PIC itself. Some draw significant amounts of power (these are listed in the data sheet). Make sure you disable all parts you don't actually need.
Next (can't count beyond three.. :-), work out how slow you can run the chip. Faster clock rates=more consumption.
Then look at the support chips. Simple things like a 78x regulator, can draw 10mA themselves. The low power versions drop this a little, but specialist low power regulators can reduce that by factors of a thousand or more - be careful though, many of these are more prone to oscillation, so careful board design becomes important.
Then consider if the chip can be sent to 'sleep' when it is not actually doing something.
If you combine all these, it is possible to use the PIC in very low power applications. I have some, which have average consumption figures, below 300uA, yet are doing a suprising amount of work.
77mA, is a hellish figure, but probably implies there is a lot going on.

Best Wishes
Eric Minbiole



Joined: 10 Jun 2004
Posts: 16
Location: USA

View user's profile Send private message Visit poster's website

PostPosted: Sat Jul 31, 2004 11:42 am     Reply with quote

Radio Shack used to sell a great book called "Enercell Battery Guidebook". It has sections for virtually every standard type of battery (AA, D, C, 9V, 'coin cells', lithium, etc). Within each section, they have nice tables and graphs giving approximate lifespans for a given current drain. I have a couple of copies, and its been invaluable for designing battery-powered devices.

Though RS doesn't sell it anymore, a quick Google search found several people selling used copies.

P.S. Though the batteries listed in the book are for the RS brand, the data is still relevant to other brands-- One brand of alkaline battery is not that different from another.
dbotkin



Joined: 08 Sep 2003
Posts: 197
Location: Omaha NE USA

View user's profile Send private message Send e-mail Visit poster's website

PostPosted: Mon Aug 02, 2004 8:19 am     Reply with quote

Powering a PIC circuit from a 9V is probably not your best approcah, unless you need that 9V for some other part of the circuit. If you don't need anything higher than, say, 4.5V or so, you may want to re-think this approach.

With a 9V battery you have a couple of choices. Either you use a run of the mill linear regulator, or a switcher. A 5V linear regulator will waste around 45% of your power as heat, assuming you use a (more expensive) low Iq regulator. A switcher can be better, but will add complexity and cost to the circuit. You could instead use (for example) three AA alkaline cells in series and get 4.5V with no regulator - which saves money & PCB space, and there are three fewer components to fail.

As noted by others, you can also probably get your average current consumption down by taking a careful look at where you can cut it back. A couple of examples:

I had a thermometer that needed to take temperature measurements and update a display periodically. Timing was not at all critical, so I used the WDT to wake up from SLEEP every couple of seconds. Incidentally, mine will run for a month or two on 3 AAA alkalines, or about a week with a 9V alkaline and a 78L05 regulator!

For another project, most of the time is spent in SLEEP mode until user input is detected using PORTB IOC. Sleep current is under .005 uA, when it wakes up it draws about 2 mA max. This is with a 12F675, so of course it's going to draw a lot less than a 16F877.

You may or may not be able to reduce your current consumption significantly, but like I said, unless you really need 9V somewhere, I'd take a look at that first. Alkaline AAs are a LOT cheaper than 9V lithium cells!
Nick
Guest







PostPosted: Mon Aug 02, 2004 11:37 am     Reply with quote

good idea,

If I run 3 AA batteries with 1200ma each in series. Do I add up them for the total battery capacity? so that would be around 3600ma?

Nick
Mark



Joined: 07 Sep 2003
Posts: 2838
Location: Atlanta, GA

View user's profile Send private message Send e-mail

PostPosted: Mon Aug 02, 2004 12:07 pm     Reply with quote

Nope, only in parallel would the capacity increase.
Nick
Guest







PostPosted: Mon Aug 02, 2004 12:23 pm     Reply with quote

I got the power consumption down to 10ma, now its only powering the RTC and EEPROM. How realistic is to get a battery to power that for 120 days? with an off the shelf battery? let see if I got my math correct... it will take 28800ma to power for 120 days. Is that correct?

Nick
Gabriel Caffese



Joined: 09 Oct 2003
Posts: 39
Location: LA PLATA, ARGENTINA

View user's profile Send private message Visit poster's website MSN Messenger

PostPosted: Mon Aug 02, 2004 1:45 pm     Reply with quote

Nick,

10ma is too much !!
You can lower it more. For example, you could "feed" the EEPROM with an I/O pin, as to turn it on only when needed to read or write.
Wich micro are you using ? I managed to draw 5ua on an 16LF88, using watchdog and Timer1 (of course, in sleep mode).
You should turn off all peripherals that are not in use, and put all your output pins in a defined state (or put the as inputs), etc, etc.

Gabriel.-
Mark



Joined: 07 Sep 2003
Posts: 2838
Location: Atlanta, GA

View user's profile Send private message Send e-mail

PostPosted: Mon Aug 02, 2004 1:59 pm     Reply with quote

I guess one would need a description of the circuit in order to make suggestions on reducing the power.
valemike
Guest







PostPosted: Mon Aug 02, 2004 2:02 pm     Reply with quote

I don't know if this has been mentioned, but while we're on the topic of reducing power consumption of the PIC...

I am using a 16LF 18-pin pic that has an internal oscillator (37 khz) powered with 3V (2 1.5V AAA batteries in series). I noticed that when the internal oscillator is used, it would draw significantly more current than if you use an external 32 khz oscillator.

So my lesson learned is: Use the external oscillator in lieu of the convenient internal one.

-Mike
Display posts from previous:   
Post new topic   Reply to topic    CCS Forum Index -> General CCS C Discussion All times are GMT - 6 Hours
Goto page 1, 2  Next
Page 1 of 2

 
Jump to:  
You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum
You cannot vote in polls in this forum


Powered by phpBB © 2001, 2005 phpBB Group