several oscillators


Closed Thread
Results 1 to 2 of 2

Hybrid View

  1. #1
    Join Date
    Apr 2009
    Posts
    6

    Default several oscillators

    HI,

    Im working on a project with HPWM, I need to get 1 pwm frequency between 1-29 kHz and a duty cycle from 0 to 99,9% by steps of 0,1%...
    I tried it with a 16 mHz oscillator but the duty cycle steps are 0,4% sometimes..
    so i want to use several oscillators... is there a way to do that?
    because just put another define in de program dont work..

  2. #2


    Did you find this post helpful? Yes | No

    Default

    Quote Originally Posted by ozzieB View Post
    HI,

    Im working on a project with HPWM, I need to get 1 pwm frequency between 1-29 kHz and a duty cycle from 0 to 99,9% by steps of 0,1%...
    I tried it with a 16 mHz oscillator but the duty cycle steps are 0,4% sometimes..
    so i want to use several oscillators... is there a way to do that?
    because just put another define in de program dont work..

    2 options which I can see are to go for a 40MHz pic and use the HPWM, or use software PWM of your own design (If you can accept the program running in a long loop. If yoiu need to pic to perform other tasks such as read buttons or get an A/D result, then wait for the longest PWM period (either high or low) and do the extra work then, making sure you return to the PWM code before a timer elapses for example.

Similar Threads

  1. Relaxation oscillators (for capacititive touch sensing)
    By HankMcSpank in forum mel PIC BASIC Pro
    Replies: 24
    Last Post: - 6th December 2009, 22:03
  2. multiply oscillators
    By ozzieB in forum mel PIC BASIC Pro
    Replies: 8
    Last Post: - 7th April 2009, 08:41
  3. timing questions with different oscillators
    By glkosec in forum General
    Replies: 1
    Last Post: - 22nd August 2007, 05:42
  4. Timers, oscillators, cycles... need basics please
    By flotulopex in forum mel PIC BASIC Pro
    Replies: 3
    Last Post: - 24th October 2006, 18:33
  5. Question about Oscillators
    By RossW in forum mel PIC BASIC Pro
    Replies: 6
    Last Post: - 11th August 2004, 16:17

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