PWM Pic 18F4331

For Flowcode users to discuss projects, flowcharts, and any other issues related to Flowcode 2 and 3.

Moderators: Benj, Mods

Post Reply
vincevg
Posts: 1
Joined: Mon Mar 03, 2008 9:07 am
Contact:

PWM Pic 18F4331

Post by vincevg »

Hi,
I'l trying to use PWM 0 to 7 on PIC 18F4331. Is it possible with FLocode 3 PWM module if not is it possible with C module and how to ?

Thank's

User avatar
Benj
Matrix Staff
Posts: 15312
Joined: Mon Oct 16, 2006 10:48 am
Location: Matrix TS Ltd
Has thanked: 4803 times
Been thanked: 4314 times
Contact:

Re: PWM Pic 18F4331

Post by Benj »

Hello

Using Flowcode's PWM component you can interface a maximum of 2 PWM channels.

We have examples of how to bit bang extra PWM channels if required. This is very simple to acheive using a timer interrupt.
http://www.matrixmultimedia.com/mmforum ... =26&t=6732

If you have to use the hardware PWM channels eg due to program restrictions then you will have to refer to the device datasheet and use C code in Flowcode to configure the remaining 6 channels. The datasheet chapter on PWM is quite long and drawn out so it might be worth printing out this section and having a good read and re-read to make sure you know how all the pieces fit together. This is how I generate component code for more complex devices anyway.

Post Reply