Continue to Site

Welcome to EDAboard.com

Welcome to our site! EDAboard.com is an international Electronics Discussion Forum focused on EDA software, circuits, schematics, books, theory, papers, asic, pld, 8051, DSP, Network, RF, Analog Design, PCB, Service Manuals... and a whole lot more! To participate you need to register. Registration is free. Click here to register now.

Calculate the maximum power consumption of an Microcontroller

hioyo

Advanced Member level 4
Full Member level 1
Joined
Aug 18, 2021
Messages
116
Helped
0
Reputation
0
Reaction score
1
Trophy points
18
Activity points
898
May I know how to calculate the power consumption of a uC.

Assume it is working at 3.3V and it's 5 GPIO's are connected to 5 LED's .Duty cycle is 50%.
 
Solution
Basically if I have a load that I switch on and off, then its power
dissipation is proportional to the time I have it on. Duty cycle
= Ton / (Ton + Toff ). So if I have a 100W light bulb, and I switch
it on and for equal times, then duty cycle = 50%, and the effective
power being consumed over time is 50%.

That concept is used in micros where they service a task, then go to sleep.
So overall power consumed is duty cycle X ( micro power + other loads that
get switched off) + loads that do not get switched off .



Regards, Dana.

danadakk

Advanced Member level 5
Advanced Member level 5
Joined
Mar 26, 2018
Messages
2,282
Helped
350
Reputation
718
Reaction score
527
Trophy points
113
Activity points
10,049
Duty cycle of what ?

You need to know :

1) Clock rates of micro
2) All GPIO loads
3) Code execution effects on micro
4) Micro type
5) Internal micro peripheral loads and power specs.....

This is best done with a DAQ or oscilloscope doing data logging of the whole system.

Designers use datasheet specs for guidelines. Then add external system
power consuming devices to that.

Your question is like how tall is a building in Russia, with no other info
or parameters. Simply unanswerable.


Regards, Dana.
 

KlausST

Super Moderator
Staff member
Advanced Member level 7
Joined
Apr 17, 2014
Messages
23,242
Helped
4,738
Reputation
9,497
Reaction score
5,125
Trophy points
1,393
Activity points
153,951
Hi,

I fully agree with Dana.

Additionally it depends on where you measure the current ... and how the LEDs are connected.

Klaus
 

hioyo

Advanced Member level 4
Full Member level 1
Joined
Aug 18, 2021
Messages
116
Helped
0
Reputation
0
Reaction score
1
Trophy points
18
Activity points
898
Duty cycle of what ?

You need to know :

1) Clock rates of micro
2) All GPIO loads
3) Code execution effects on micro
4) Micro type
5) Internal micro peripheral loads and power specs.....

This is best done with a DAQ or oscilloscope doing data logging of the whole system.

Designers use datasheet specs for guidelines. Then add external system
power consuming devices to that.

Your question is like how tall is a building in Russia, with no other info
or parameters. Simply unanswerable.


Regards, Dana.
Hi Dana,

Please don't feel bad .This question is asked in an interview.(Lost my Job,currently searching).
Duty cycle here means LED is on for half the time of PWM.
If you can suggest any material so that I can study will be helpful.

Regards
 

KlausST

Super Moderator
Staff member
Advanced Member level 7
Joined
Apr 17, 2014
Messages
23,242
Helped
4,738
Reputation
9,497
Reaction score
5,125
Trophy points
1,393
Activity points
153,951
Hi,

don´t push the effort to someone else.

Since there are countless different options and ways ... it´s better you chose one of your interest.

****
One simple example:
One can measure the microcontroller current at VCC or at GND. Let´s choose to measure it on the VCC side.

Now you have two options to connect a LED to the microcontroller:
* cathode points to microcontroller --> LED current is not seen on microcontroller VCC
* or anode points to microcontroller --> LED current runs through microcontroller VCC

****

Make a simple drawing on your own. And use a colored pen to depict the current flow.

Klaus
 

danadakk

Advanced Member level 5
Advanced Member level 5
Joined
Mar 26, 2018
Messages
2,282
Helped
350
Reputation
718
Reaction score
527
Trophy points
113
Activity points
10,049
Basically if I have a load that I switch on and off, then its power
dissipation is proportional to the time I have it on. Duty cycle
= Ton / (Ton + Toff ). So if I have a 100W light bulb, and I switch
it on and for equal times, then duty cycle = 50%, and the effective
power being consumed over time is 50%.

That concept is used in micros where they service a task, then go to sleep.
So overall power consumed is duty cycle X ( micro power + other loads that
get switched off) + loads that do not get switched off .



Regards, Dana.
 
Last edited:
Solution

LaTeX Commands Quick-Menu:

Part and Inventory Search

Welcome to EDABoard.com

Sponsor

Top