Netduino home hardware projects downloads community

Jump to content


The Netduino forums have been replaced by new forums at community.wildernesslabs.co. This site has been preserved for archival purposes only and the ability to make new accounts or posts has been turned off.
Photo

Power consumption / limits


  • Please log in to reply
17 replies to this topic

#1 Cabadam

Cabadam

    Advanced Member

  • Members
  • PipPipPip
  • 90 posts

Posted 16 April 2012 - 02:14 PM

I searched around about this, but couldn't really find everything I was looking for in the same place, and in a few places it seems to contradict, so I wanted to try to get clarification.

My questions in this post are relevant to the 5V/3V3 pins - not the various I/O pins.

First the general case of what I can safely power through the 5V and 3v3 pins:

The ND+ tech specs says:
"microcontroller max current: 200 mA total"

Is that the maximum the ND+ will draw for its own purposes (not for connected devices)?

This wiki page says the ND+ draws 80mA when active. Is this incorrect, or does that mean the previously mentioned 200mA is actually how much can be powered in all? In either case, at what voltage(s) are the 80mA and 200mA measured?

This wiki article introduces another value - 800mA for the DC outputs. But again - would that be at 5V or 3.3V (or each??)?

In this specific case, I have three things I'm intending to power:
1) ND+ = ?? mA @ ?? V
2) 60mA @ 3.3V
3) ~175mA @ 5V

I initially had the 5V piece pulled off as a separate step-down regular split off from the same 12V source that was powering the ND+. It worked fine for a little bit, output voltage seemed stable in my testing. But - saying it was cheaply made would be an understatement (this was a "retail" component - not something I made. Cheap, free shipping, seemed to do what I needed). However, it no longer outputs any measurable voltage, so I'm hoping I can actually get away with powering everything directly through the ND+ and simply remove that extra component.

Thanks,

#2 Paul Newton

Paul Newton

    Advanced Member

  • Members
  • PipPipPip
  • 724 posts
  • LocationBerkshire, UK

Posted 16 April 2012 - 05:14 PM

Hi Adam,

I thought this was really obvious until I took a fresh look at each of the pages you linked. If you're not sure, then the doubt starts to creep in :unsure:

The 200mA figure comes from the ARM datasheet, page 14: the total current drawn by all the I/O lines cannot exceed 200 mA.

The 80mA figure from the comparison page is the current taken by the Netduino plus when it is actively running a thread, but without any peripherals attached to it. I am 99.9% certain that the current would have been measured on the 5V input.
However since the Netduino uses a linear voltage regulator (not a switching one) for converting Vin to 5V, I think you would see almost the same current being drawn if you supplied 7 to 12V on the Vin pin.

The 800mA figure comes from the amount of current the regulators can supply. The data sheet for the MD33269DT family of regulators page 1 says Output current in excess of 800mA.
But you can't take 800mA from both regulators (at the same time) because the 5V regulator supplies current to the input of the 3.3V regulator. Hence this has to be the total current from the 5V and 3.3V pins combined.
Also note that if you are supplying your power from USB, the limit needs to be reduced to 500mA as this is the maximum you can draw from USB.

I think your power figures are fairly modest and will be OK.

EDIT: See post below - the wasted power in the regulator is around 2.2Watts, and this is too much. (The regulator will be hotter than 50 degrees C.) Thanks Guido for prompting a re-think.

I would estimate that the ND plus will draw approximately 80 + 60 + 175 mA = 315mA at 12Volts.

Since you are supplying power at 12V, over half of the power consumed by the Netduino will be wasted as heat in the 5V regulator. If you can, it would be better to use a lower voltage.

Hope this helps - Paul

#3 Mario Vernari

Mario Vernari

    Advanced Member

  • Members
  • PipPipPip
  • 1768 posts
  • LocationVenezia, Italia

Posted 16 April 2012 - 06:11 PM

Excellent, Paul!
Biggest fault of Netduino? It runs by electricity.

#4 Cabadam

Cabadam

    Advanced Member

  • Members
  • PipPipPip
  • 90 posts

Posted 16 April 2012 - 07:00 PM

Wow, great details Paul!

I thought this was really obvious until I took a fresh look at each of the pages you linked. If you're not sure, then the doubt starts to creep in :unsure:

Yeah, that was basically what happened to me. Thought I had an idea, until I looked around to verify the details. Then the more I read, the more I was unsure I actually understood it.

The 200mA figure comes from the ARM datasheet, page 14: the total current drawn by all the I/O lines cannot exceed 200 mA.

Gotcha, so in terms of powering other components via the 5V or 3V3 pins, the 200mA is not a value I need to concern myself with.

The 80mA figure from the comparison page is the current taken by the Netduino plus when it is actively running a thread, but without any peripherals attached to it. I am 99.9% certain that the current would have been measured on the 5V input.
However since the Netduino uses a linear voltage regulator (not a switching one) for converting Vin to 5V, I think you would see almost the same current being drawn if you supplied 7 to 12V on the Vin pin.

Interesting - OK, learned new tidbit about linear vs switched regulators. Iin ~= Iout. Check.

The 800mA figure comes from the amount of current the regulators can supply. The data sheet for the MD33269DT family of regulators page 1 says Output current in excess of 800mA.
But you can't take 800mA from both regulators (at the same time) because the 5V regulator supplies current to the input of the 3.3V regulator. Hence this has to be the total current from the 5V and 3.3V pins combined.
Also note that if you are supplying your power from USB, the limit needs to be reduced to 500mA as this is the maximum you can draw from USB.

Ah, they are connected in series. So the 3.3V pull will affect the 5V - which is probably fine, the 3.3V current is pretty trivial. My power is not coming from USB.

Since you are supplying power at 12V, over half of the power consumed by the Netduino will be wasted as heat in the 5V regulator. If you can, it would be better to use a lower voltage.


Right now I am in fact using 12V, although I'm exploring some options to reduce that a bit. It sounds like I'm pretty safe on the current, possibly with a little wiggle room (there is a vague chance the 5V number might go up ~50mA) - especially if I can get the voltage down so heat doesn't start building up.

Thanks for all your clarifications - they were a lot of help. And hopefully I understand enough about this that I can sort this out myself on my next project.

#5 gbreder

gbreder

    Advanced Member

  • Members
  • PipPipPip
  • 53 posts
  • LocationGermany

Posted 16 April 2012 - 07:20 PM

Hi, Paul has quoted the relevant specification and a really important sentence: "...at 12V, over half of the power consumed by the Netduino will be wasted as heat..." The power regulator will transform everything above 5 volts to heat. If you power your board with 6 volts and you draw a current of 200mA there is about ((6-5)*0.2) 0.2W of "heat". If you power your board with 15V and you draw 200mA there is about ((15-5)*0.2) 2.0W of "heat". This is a lot because the regulator has nearly no heatsink. The calculation may be a bit oversimplified but you will get the idea. Somewhere on the forum I read a nice rule of thumb: If you can't touch the regulator with you finger (because it's to hot) rethink your power supply design. Regards Guido

#6 Paul Newton

Paul Newton

    Advanced Member

  • Members
  • PipPipPip
  • 724 posts
  • LocationBerkshire, UK

Posted 16 April 2012 - 08:27 PM

Hi All,

Guido's post has prompted me to do the calculation for the wasted heat and have another look at the data sheet:

315mA x (12V - 5V) = 0.315 x 7 = 2.2 Watts
That is quite a lot of power being dissipated in the regulator.

In the data sheet, there is not a simple maximum value for how much power the regulator can dissipate as heat. It depends on the package and how it is mounted to the PCB.

The package is a DPAK type, the graphs on page 6 show the maximum power that can be dissipated before reaching 50 degrees Celsius for a given size copper pad on the PCB. The curve for the DPAK in the top right of the page does not reach 2.2 Watts even with the maximum size PCB copper pad.

Given that I think the regulator is going to get too hot to touch.

So it will be important to drop the supply voltage. At 9V, the power will be 1.2Watts which is much better.

Paul

#7 Cabadam

Cabadam

    Advanced Member

  • Members
  • PipPipPip
  • 90 posts

Posted 17 April 2012 - 07:57 PM

I've been exploring lower voltage options and it actually looks like the simpler option for me might end up having a separate outright 5V power source (that just goes directly to the wall) rather than trying to drop and convert my already available 24VAC source. I'm trying to stay towards "ready-made" components because I do not know enough about how to put together these things. 24VAC -> 12V DC was easily available, so that is what I was using. 24VAC -> 9VDC (or even the lowest 7.5VDC) is not something that I could find. I could try to get another adjustable DC->DC step-down regulator, but I had rather bad luck with the first one I had (which is what prompted this whole topic), so I'm not sure I want to go that route again. On the other hand, there are all sorts of 5V wall adapters. I was trying hard to keep my system to "one plug" but that might not be worth the trouble. Of course, if I end up at the 5V route, I just supply power to the 5V components independently - not through the Netduino, and then the heat doesn't even matter anymore.

#8 Paul Newton

Paul Newton

    Advanced Member

  • Members
  • PipPipPip
  • 724 posts
  • LocationBerkshire, UK

Posted 17 April 2012 - 09:04 PM

Hi again,

The problem is that the Netduino's 5V regulator has to get rid of the unwanted voltage (and its current) as heat. What if we add another component to take up some of that heat....

Working with the 315mA @ 12V estimate:
The Netduino needs 7V or more on the Vin connection.
12V - 7V = 5V. So how can we get rid of 5V?

A very exotic component - the resistor!

R = V / I = 5 / 0.315 = 15.87 ohms
Lets use a 15ohm resistor, and put it in series with the Netduino plus. (Between the 12V supply and the Vin pin.)

When the Netduino plus and peripherals are all taking current, the 15 ohm resistor will drop V = I x R = 0.315 x 15 = 4.7V.
So the voltage at the Vin pin will only be 12 - 4.7 = 7.3V.
This means that the regulator now only has to get rid of 7.3 - 5 = 2.3V at 315mA.
P = V x I = 2.3 x 0.315 = 0.72 Watts. Less than half the power before.

But, what happens when the Netduino plus takes less current?

Well the Wiki page says the Netduino plus only takes 53mA when idle. (Lets also assume that when idle, all the peripherals are off and not taking any current.)
At 53mA, the 15 ohm resistor will only drop V = I x R = 0.053 x 15 = 0.8V.
So Vin will now be 12 - 0.8 = 11.2V.
The regulator is going to have to get rid of more volts now, 11.2 - 5 = 6.2V, but this is not a disaster because the current is lower now.
So the power = 6.2 x 0.053 = 0.33Watts.

Now at maximum and minimum currents, the regulator is dissipating much less power and should be fine.

But where did the power go?

In the resistor...
At 315mA, the resistor is going to dissipate 4.7 x 0.315 = 1.48Watts
That is going to mean a hot resistor. Typically the leaded resistors you will have to hand will be 1/4Watt - so it will be necessary to use a power resistor rated at 2W or more (they are not expensive).
If you don't just happen to have a power resistor to hand, you could put several lower value resistors in series to add up to 15ohms, or several higher value resistors in parallel. By using multiple resistors, you are sharing out the power between them.

For example, if you put eight 1/4Watt 120ohm resistors in parallel, you get a 15ohm 2Watt resistor.

Obviously the above is all based on the 315mA estimate. If the design needs more current, the voltage drop in the resistor will increase. If it goes above 5V, you will need to use a lower value resistor. With 15 ohms, the current at which this will happen is I = V / R = 5 / 15 = 333mA.

This is not a very green way of handling the power, it would still be better to use a 9V (or even better 7.5V) input, but I believe this will do the job.

Paul

#9 gbreder

gbreder

    Advanced Member

  • Members
  • PipPipPip
  • 53 posts
  • LocationGermany

Posted 18 April 2012 - 08:15 AM

Hi,
the really hot resistor is a possible way but I wouldn't recommend it. I've build a switching power supply my self (based on the LM2596, but they are also available fully assembled.

For example the TSR1 module is very easy to use: One Pin is Vin, one is Ground and the last puts out your 5V. And this goes up to 2.5Amps 1Amp without a heatsink.

Regards
Guido

P.S.: Paul pointed out that the maximum power output is 1A instead of 2.5A. Thanks.

Edited by gbreder, 19 April 2012 - 07:33 AM.


#10 Paul Newton

Paul Newton

    Advanced Member

  • Members
  • PipPipPip
  • 724 posts
  • LocationBerkshire, UK

Posted 18 April 2012 - 05:36 PM

Hi,
the really hot resistor is a possible way but I wouldn't recommend it. I've build a switching power supply my self (based on the LM2596, but they are also available fully assembled.

For example the TSR1 module is very easy to use: One Pin is Vin, one is Ground and the last puts out your 5V. And this goes up to 1 Amp without a heatsink.

Regards
Guido


Hi Guido,

Yes, what I described is certainly not ideal. Switching regulators are a much better option if the price is right.

The family of regulators you added the link to will accept up to 36V DC input, and will output up to 1Amp at various voltages. They are a drop-in replacement for the 78xx family of regulators.

The 5V one is the "TSR 1-2450"
The 12V one is the "TSR 1-24120"

In the UK the prices are about £7 each for these, so unfortunately they are more expensive than the 7805 and 7012 1A regulators which come in at around £1. (But, the TSRs don't need a heat sink so there is a saving in cost and space there.)

It would not be difficult to take the 24V AC, rectify and smooth it to give 34V DC. One or both of the regulators could then be fed with the 34V DC and generate the 5v and 12V* rails.

*I'm not sure if Adam actually needs the 12V rail for other equipment, or whether it is just a stepping stone from 24V AC to 5V DC.

Paul

#11 Cabadam

Cabadam

    Advanced Member

  • Members
  • PipPipPip
  • 90 posts

Posted 18 April 2012 - 07:47 PM

Sorry for the delayed response. Been harder for me to focus on this the last couple days, work got busy!

I'll re-read in some more detail later and respond to some of the other comments, but wanted to give a quick response.

The 24VAC is being used by other components, but I am NOT using the 12VDC elsewhere (well.. I am for this, but it will actually accept 5-15V, so downconverting to 5V wouldn't (shouldn't? :)) pose a problem.

In fact, I've noticed the wifi bridge tends to run rather warm, so dropping to 5V might benefit it as well.

#12 Cabadam

Cabadam

    Advanced Member

  • Members
  • PipPipPip
  • 90 posts

Posted 21 April 2012 - 05:04 PM

OK, getting back to this now.

I've decided to kind of split my approach to this based on your feedback.

Short term: I just want to get this working. I purchased a 5V (3A) wall plug. So, now I am providing two separate power sources (24VAC and 5VDC), but I've got everything wired up to it, and it seems to be working great. The 5V components are all split directly off of the wall plug - not going through the ND+, so there isn't any concern about sending too much current through it. It also means I'm not using the ND+'s linear regulators, which helped drop the power usage a bit too. With every 5V relay turned on (something I'll never do in practice), I'm still only at ~6.6W. Way under the 5*3=15W provided by the 5V adapter.


Longer term: I've been playing with the Eagle software to work up a design to provide my 5VDC power directly from the 24AC, instead of requiring an extra wall plug. I'm using the TSR-1 you recommended. As this is the first time I've tried to put components together like this, I wouldn't mind a sanity check.

There are two concerns I had when I designed this:
1) The capacitor and voltage rating
Ignore the rating listed in the Eagle part, I'm assuming I can pretty much stick whatever capacitor I want in the same location - I just needed a part. The real one I'm looking at is one I can pick up locally (Radio Shack part number listed). It is 35V, 1000uF. Paul - you mentioned the 24V AC would rectify out to about 34V DC. That sounds dangerously close. I was reading this post which said it would actually come out more towards 30VDC, which is a LITTLE more breathing room. Is that still too close? If I need to step up to a larger capacitor, I can and will, it would just be nice to not have to order and pay shipping on tiny cheap parts :)

2) Dual purpose capacitor?
I initially added the capacitor to smooth out the ripple from the bridge rectifier. Looking at the datasheet for the TSR-1, it says there should also be a capacitor coming in if the input voltage is >32VDC - again, very close to where I am. Would this capacitor satisfy both requirements (it looks like it is connected into the same place), or does there need to be two separate capacitors connected in parallel?


If this all works out sensibly, I'll grab the parts and test on a breadboard, but I've also done a board layout for this that I'll probably send to something like this service - seems cheap for this small of a board.

Appreciate any feedback you guys have.

Thanks!

Attached Files



#13 gbreder

gbreder

    Advanced Member

  • Members
  • PipPipPip
  • 53 posts
  • LocationGermany

Posted 21 April 2012 - 06:57 PM

Hi, I would get a capacitor with a higher voltage. Something like 50V to 60V. If the TSR-1 needs 22uF you should get exactly the 22uF. If you need 1000uF for the rectifier you should get one and put them both in parallel. But I would put the rectifier capacitor near the rectifier and the TSR cap near the TSR. This should give the best result. Capacitor theory (oversimplified): Small caps can filter very small ripple (but not huge ripple) because they take little time to load and unload. Huge caps can filter huge ripple (but not small ripple) because it takes a long time to load and unload. Regards Guido

#14 Paul Newton

Paul Newton

    Advanced Member

  • Members
  • PipPipPip
  • 724 posts
  • LocationBerkshire, UK

Posted 21 April 2012 - 09:01 PM

I wouldn't mind a sanity check.

There are two concerns I had when I designed this:
1) The capacitor and voltage rating
Ignore the rating listed in the Eagle part, I'm assuming I can pretty much stick whatever capacitor I want in the same location - I just needed a part. The real one I'm looking at is one I can pick up locally (Radio Shack part number listed). It is 35V, 1000uF. Paul - you mentioned the 24V AC would rectify out to about 34V DC. That sounds dangerously close. I was reading this post which said it would actually come out more towards 30VDC, which is a LITTLE more breathing room. Is that still too close? If I need to step up to a larger capacitor, I can and will, it would just be nice to not have to order and pay shipping on tiny cheap parts :)

2) Dual purpose capacitor?
I initially added the capacitor to smooth out the ripple from the bridge rectifier. Looking at the datasheet for the TSR-1, it says there should also be a capacitor coming in if the input voltage is >32VDC - again, very close to where I am. Would this capacitor satisfy both requirements (it looks like it is connected into the same place), or does there need to be two separate capacitors connected in parallel?

Hi Adam,

The post you linked to has a perfectly good explanation of what the rectified voltage will be with a load on it. The calculations were aimed at working out if the power supply could give enough output for those loads.
When you are selecting the voltage of components, you need to take the opposite case which is when the power supply is unloaded. Then the voltages in the circuit will be at their highest

AC voltages are quoted as RMS "Root Mean Square". The idea is to allow an AC voltage to be compared to a DC one. If you took the peak voltage of an AC supply and not the RMS value, you might think you were going to get lot more power, but would be mistaken because the AC wave is a sinewave and only spends a tiny amount of time at the peak voltage.

To convert an RMS value into the peak value, you multiply by the square root of 2 (1.414...).
So measuring from ground to the positive or negative peaks, your 24V AC should have a peak voltage of 24 x 1.414 = 33.936V.
(Measuring from peak to peak, you should have 24 x 2 x 1.414 = 67.872V)

Should?

I am assuming that you are in the USA, and that your wall power supply is a 120V:24V transformer. All electricity suppliers quote the nominal voltage they supply electricity at. The actual voltage of the mains supply can go up or down within a range due to power stations coming on line, the load going up or down, being close to or far away from the power station, etc.
According to this Wikipedia page, the voltage in the USA is between 100V and 127V AC. So assuming your power supply is a simple transformer, if the input voltage changes by a percentage, so will the output.
Hence the maximum output is actually 127/120 x 24 = 25.4V AC, and the minimum is 100/120 x 24 = 20V AC.

Your circuit uses a full bridge rectifier, so that means there will be two diodes in series with the 24V AC power input at all times, this means you will lose approximately 2 x 0.7V = 1.4V from the peak voltage.

Taking the maximum AC output from your transformer, gives 25.4 x 1.414 - 1.4 = 34.52V peak after rectification.
If your power supply is not a transformer, and hence is not affected by fluctuations of the mains voltage, then you will get 24 x 1.414 - 1.4 = 32.54V peak after rectification.

When you add a smoothing capacitor, if there is no load on the circuit, the capacitor will charge up to this peak voltage (34.5V or 32.5V DC). As soon as you add a load, it will droop, but you have to allow for the peak when components have ratings.

Hence, I agree with Guido that you really want to use a higher voltage capacitor.
High value capacitors are normally electrolytic, these do not like being connected the wrong way round, or being fed too high a voltage. They show the displeasure by exploding.
If you look at the top of a radial electrolytic capacitor, you will normally see score marks in the aluminium casing. These marks are designed to help the casing split open and release the smoke slowly rather than with a bang.


As for having multiple capacitors in your circuit, Guido has it right again. Different size capacitors have different ripple smoothing properties at different frequencies.
When the manufacturer of an active component (like a voltage regulator or amplifier) says to fit a certain value capacitor on the power supply input (or output), it is usually because they have found the device can become unstable without it. For example, if you don't fit the suggested capacitor, the output of the voltage regulator might have an oscillation on it - really annoying in an audio circuit!

Paul

#15 Cabadam

Cabadam

    Advanced Member

  • Members
  • PipPipPip
  • 90 posts

Posted 22 April 2012 - 02:39 AM

Your assumptions are correct - in the US, and yes, it is a simple 120V to 24V transformer.

So the average voltage of the DC might be within specs of the 35V capacitor, but there are peaks in the ripple, which are what could blow the capacitor. No need to have that! AFTER the capacitors, those peaks should be reduced much closer towards the average.

I'm not doing too bad on this project so far by my standards (killed 1 transformer, and blew fuse in my multimeter - both my fault and I know why), no need to add to the list if I can avoid it!

I've updated my plan to include two capacitors. Both rated at 50V, one higher capacitance near the bridge, one lower (22uF) near the TSR-1.

Speaking of the TSR-1, I started looking around at where I might by that sucker. Three places came up - one won't tell me how much shipping is until after I place the order - which is non-cancellable. One wants just under $20 shipping. And one website doesn't seem to want to let me actually order it.

I started poking around on Digikey (which is where I am getting the capacitors I think), and I found this:
http://www.murata-ps...er/oki-78sr.pdf

Seems to be similarly efficient and shouldn't need a heatsink - also gives me slightly more wattage than the TSR-1. I think that should do the job. The datasheet seems to suggest I might not even need the 22uF capacitor (although it says it can be added if really needed). I'll probably leave it in anyway.

Do you see anything wrong with it as a replacement for the TSR-1?

#16 Paul Newton

Paul Newton

    Advanced Member

  • Members
  • PipPipPip
  • 724 posts
  • LocationBerkshire, UK

Posted 22 April 2012 - 07:24 AM

Yes it looks like a drop in replacement. Note that page 10 of the data sheet "the small print" does talk about input and output filtering capacitors. It recommends low ESR capacitors. If you have not heard of these before, they are like regular ones, but have a very low internal resistance so that the filter's capacitance is not affected by a virtual resistor in series with it. You will probably get away with no capacitors, or normal capacitors. But, if you can get the low ESR ones, and they come in a package you can use, then that would be better. Also note that there are four versions, 3.3V / 5V with vertical / horizontal mounting. So if the footprint on the board matters be careful which orientation you buy. The vertical (upright) 5V one is OKI-78SR-5/1.5-W36-C, the horizontal one has an "H" in the part number: OKI-78SR-5/1.5-W36H-C. The UK digikey price is £3, so not too expensive either. Paul

#17 Cabadam

Cabadam

    Advanced Member

  • Members
  • PipPipPip
  • 90 posts

Posted 22 April 2012 - 04:40 PM

Yeah, I'm going for the vertical one ($4.30 US, which I'm happy about). Haha, hopefully it doesn't turn into a case of "you get what you pay for". Parts are now on order now. Thanks to both for all the help.

#18 gbreder

gbreder

    Advanced Member

  • Members
  • PipPipPip
  • 53 posts
  • LocationGermany

Posted 22 April 2012 - 10:25 PM

Hi, the low resistance of the tantalum caps tends to set them on fire if they are loaded and then short-circuited or if the caps grow old or something unexpected happens to you circuit... This is a fact you should be aware of. My recommendation is to avoid tantalum but on the other side it is recommended by the vendor because the circuit is designed for tantalum caps and it would provide the best result. On most designs I would put normal caps in the circuit and I would check if the result is good enough. (This reminds me to buy a scope :) ) Guido




0 user(s) are reading this topic

0 members, 0 guests, 0 anonymous users

home    hardware    projects    downloads    community    where to buy    contact Copyright © 2016 Wilderness Labs Inc.  |  Legal   |   CC BY-SA
This webpage is licensed under a Creative Commons Attribution-ShareAlike License.