Can you use 2 PWM's simultaneously?


Closed Thread
Results 1 to 10 of 10

Hybrid View

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


    Did you find this post helpful? Yes | No

    Default

    Another idea, even if not the best, having a 2XHPWM frequency, fed the HPWM output on a INT pin, enable the interrupt, and play with the duty in the Interupt handler... in my head it's working but i know i miss something in it....

    OR create your own with a Timer interrupt.. but geez, a little bit more tricky if you really need it 100% stable.

    Or, a double I2C DAC could be intereting... something like MAX518 if you can deal with a 8 bit resolution. They're not too cheap but great and simple to use.

    There's still the Digital pot way, or, or ,or... man it's incredible how many ways you can do it )


    What is the purpose of those PWMs?

    EDIT: Darrel already done a SSPWM solution bellow but the frequency range is probably out of what you need
    http://www.pbpgroup.com/modules/wfse...p?articleid=12
    Last edited by mister_e; - 29th June 2006 at 23:15.
    Steve

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

  2. #2


    Did you find this post helpful? Yes | No

    Default

    Hi Steve. The purpose is for motor control. I already made a circuit using the pulsout command. It works but, if I can have HPWM running the motors in the backround, it frees-up the PIC to do other things like checking battery voltage, turn on lights, monitor the motor FET's for shorts, etc. I've pretty much decided I'll have to use a 28 pin PIC such as 16F73.

Similar Threads

  1. How to drive the Vinculum VDIP1 in UART mode
    By BrianT in forum Code Examples
    Replies: 41
    Last Post: - 23rd May 2013, 12:34
  2. USB-FTDI[UM232R] with PIC16f877a
    By bjox in forum USB
    Replies: 1
    Last Post: - 23rd February 2008, 22:40
  3. Help with sound command in 2 programs
    By hyperboarder in forum mel PIC BASIC Pro
    Replies: 4
    Last Post: - 5th July 2007, 20:36
  4. Microcontroller with 2 way paging application problem
    By oneohthree in forum mel PIC BASIC Pro
    Replies: 30
    Last Post: - 20th April 2007, 17:27
  5. having problems with Hantronix 20x4 lcd
    By Rhatidbwoy in forum mel PIC BASIC Pro
    Replies: 16
    Last Post: - 22nd December 2005, 12:22

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