Searching \ for '[EE] Multichannel PWM generation' in subject line. ()
Make payments with PayPal - it's fast, free and secure! Help us get a faster server
FAQ page: www.piclist.com/techref/io/pwm/index.htm?key=pwm
Search entire site for: 'Multichannel PWM generation'.

Exact match. Not showing close matches.
PICList Thread
'[EE] Multichannel PWM generation'
2005\08\24@163116 by Julio Jumpa

picon face
Hello,

I need to generate 6 duty-cycle-independent PWM signals (the frequency can be the same for all) for a simple microcontroler based project (motor speed control).

I've found that PICs go only up to 2 PWMs....I was thinking about using one 555 timer to generate a sawtooth wave and then a comparator for each of the 6 PWM..but then again, i would need a variable analog voltage to control the duty cycle...

I dont need much resolution...3 or 4bits would be fine and the PCB needs to be small (12cmx12cm max).

what would you suggest?

Thanks

Julio

2005\08\24@165036 by olin piclist

face picon face
Julio Jumpa wrote:
> I dont need much resolution...3 or 4bits would be fine and the PCB
> needs to be small (12cmx12cm max).
>
> what would you suggest?

Do it in software.  You didn't specify a minimum PWM frequency, so that will
work fine.


*****************************************************************
Embed Inc, embedded system specialists in Littleton Massachusetts
(978) 742-9014, http://www.embedinc.com

2005\08\24@165340 by Marcel Duchamp

picon face
For a software solution, try this:
www.dattalo.com/technical/software/pic/pwm256.txt
Scott shows  how to do 8 pwm outputs from a PIC.

Julio Jumpa wrote:
{Quote hidden}

2005\08\24@172340 by Scott Dattalo

face
flavicon
face
> For a software solution, try this:
> www.dattalo.com/technical/software/pic/pwm256.txt
> Scott shows  how to do 8 pwm outputs from a PIC.

Thanks for the plug Marcel, but I think you meant this one instead:

http://www.dattalo.com/technical/software/pic/pwm8.asm

Scott

2005\08\24@203935 by Jesse Lackey

flavicon
face
As others mentioned, do it in software.  It is pretty straightforward.
Use interrupts to run the PWM code, and check your work with an
oscilloscope as needed.

With an 18F running at 40Mhz, I have some (carefully coded and
macro-unrolled C) that does 32 channels with 250 levels @ about 16Khz
"slice time" and uses about 50% of the CPU.  This is used to switch FETs
to PWM LEDs.

Drop me a line if you'd like some code.

J


Julio Jumpa wrote:

{Quote hidden}

More... (looser matching)
- Last day of these posts
- In 2005 , 2006 only
- Today
- New search...