How to 18F4431 PPWM


Closed Thread
Results 1 to 3 of 3
  1. #1
    Join Date
    Jun 2006
    Posts
    37

    Default How to 18F4431 PPWM

    Hi!
    any code regarding the use of power PWM module pf 18F4431. I have PICDEM MC LV board. It has a CD that gives source code in asm. I use pic basic so i need some help in configuring PPWM.
    thanks.

  2. #2
    Join Date
    Sep 2004
    Location
    montreal, canada
    Posts
    6,898


    Did you find this post helpful? Yes | No

    Default

    you will need to be more specific in your requirement. There's A LOT of different way to use that one.

    How many channels
    which frequency
    etc etc

    maybe you could post yor ASM code or read that one and learn from it
    http://www.picbasic.co.uk/forum/show...xt%2A+modifier
    Steve

    It's not a bug, it's a random feature.
    There's no problem, only learning opportunities.

  3. #3
    Join Date
    Jun 2006
    Posts
    37


    Did you find this post helpful? Yes | No

    Default some more info

    I have attached a file in asm.How can we do this in pic basic pro which has been done in this file.i.e to control a BLDC motor.but mainly first i want to just understand how to use this PPWM module.check its outputs with scope then build my own code.i have read app notes "AN900" regarding control of motor. it explains nicely all the detail except code is in asm.
    I tried to do it myself also, just output a 20Khz signal om PWM outputs using PPWM:

    while true
    PTCON0=00000000 'page 8,step 1
    PTPERL=$63 'a guess
    PTPERH=$00
    PWMCON0=01000000 'step 3
    PWMCON1=00000000 'step 4
    DTCON=00001010 ' a guess
    OVDCOND=00000000 'step 6
    OVDCONS=00000000
    'POVD=00000000
    'SEVTCMP=$0000
    'step 8
    PDC0L=$00
    PDC0H=$00
    PDC1L=$00
    PDC1H=$00
    PDC2L=$00
    PDC2H=$00
    PDC3L=$00
    PDC3H=$00

    SEVTCMPL=$00
    SEVTCMPH=$00
    TRISC.0=1
    PTCON1=10000000 'or PTCON1.7=1
    wend
    Attached Files Attached Files

Similar Threads

  1. 18F4431 Quaduature Encoder
    By Rleonard in forum mel PIC BASIC Pro
    Replies: 28
    Last Post: - 7th June 2013, 08:32
  2. 18F4431 - Complementary mode PWM
    By AndrewC in forum mel PIC BASIC Pro
    Replies: 12
    Last Post: - 15th December 2011, 11:23
  3. 18f4431; driving a stepper IN HARDWARE mode
    By DDDvvv in forum mel PIC BASIC Pro
    Replies: 4
    Last Post: - 21st January 2010, 16:49
  4. 18f4431 pwm4 and pwm 5 issues
    By lothar in forum mel PIC BASIC Pro
    Replies: 7
    Last Post: - 9th April 2009, 16:48
  5. 18F4431 and Melabs USB programmer ?
    By AndrewC in forum General
    Replies: 14
    Last Post: - 27th March 2009, 05:20

Members who have read this thread : 0

You do not have permission to view the list of names.

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts