Breaking News
Design How-To

How to get the most out of a single timer on an MCU

NO RATINGS
Page 1 / 2 Next >
More Related Links
View Comments: Newest First | Oldest First | Threaded View
nandorocha13
User Rank
Rookie
re: How to get the most out of a single timer on an MCU
nandorocha13   8/28/2012 4:45:50 PM
NO RATINGS
Pictures are broken

Plavalli
User Rank
Rookie
re: How to get the most out of a single timer on an MCU
Plavalli   8/22/2012 11:08:19 PM
NO RATINGS
Can't get to see the pictures.

Keroronsk
User Rank
Rookie
re: How to get the most out of a single timer on an MCU
Keroronsk   8/21/2012 9:28:11 AM
NO RATINGS
Seems like pictures is broken.

mr_bandit
User Rank
Rookie
re: How to get the most out of a single timer on an MCU
mr_bandit   3/29/2011 3:54:41 AM
NO RATINGS
There is a much simpler method - still using the same timer with the same discussion on frequency. Just maintain a counter - if unsigned: if( counter .ge. thresh ) { set output high } if( counter .ge. 100 ) { counter = 0; set output low } If a signed value, set the counter to (- thresh) and test for .ge. 0, then for (100 - thresh). The unsigned is the easiest. This method avoids the modulo - a very expensive operation. Also, obviously set the initial conditions properly. Might also want to put the whole logic in an if( doing_pwm ) to turn the PWM on and off.

Rakshith Amarnath
User Rank
Rookie
re: How to get the most out of a single timer on an MCU
Rakshith Amarnath   3/20/2011 9:15:05 PM
NO RATINGS
Good going Ajit n Co :) Liked your idea. Will try to apply this keeping the limitations in mind.

Flash Poll
Radio
LATEST ARCHIVED BROADCAST
EE Times editor Junko Yoshida grills two executives --Rick Walker, senior product marketing manager for IoT and home automation for CSR, and Jim Reich, CTO and co-founder at Palatehome.
Like Us on Facebook

Datasheets.com Parts Search

185 million searchable parts
(please enter a part number or hit search to begin)
EE Times on Twitter
EE Times Twitter Feed
Top Comments of the Week