2nd order Low-pass passive RC filter on PWM


Closed Thread
Results 1 to 7 of 7
  1. #1
    Join Date
    Nov 2008
    Posts
    22

    Default 2nd order Low-pass passive RC filter on PWM

    I have working a PWM output driving the input of a 0 to 200mV digital panel meter, but would like some input/review of the filter. I'm running the uP @ 4MHz, the PWM at 3.9kHz with 10 bit resolution and it seems to run just fine for my application but I'm not sure if I can improve on the RC filter, it was basically pulled from the net and I can't seem to find a good online design program to help.

    I found by trial and error that the 1.46M voltage divider load worked well, any advantage / disadvantage to going higher?

    Any comments would be appreciated.


  2. #2
    Join Date
    Oct 2003
    Location
    holland
    Posts
    251


    Did you find this post helpful? Yes | No

    Default

    If you take a longer RC time, the ripple voltage will be smaller, but the time when the DC outputvoltage is stable is than longer.

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


    Did you find this post helpful? Yes | No

    Default

    Well higher impedance voltage divider may help or screw your reading depending at least of your instrument input impedance.

    However higher impedance of your voltage divider, the less you alter the RC filter.

    Personally, i would avoid a too high impedance to the instrument, maybe refine the whole design with a buffer in between.

    Some instruments also have their own low pass filter at the input, so I would compare a DVM reading with. Not as this sure that you really need to go crazy in your PWM filtering. First order might work as well.
    Steve

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

  4. #4


    Did you find this post helpful? Yes | No

    Default smoothing pwm

    did you try just using the 1 micro farad across the 46k ohm ?
    Attached Images Attached Images  
    Last edited by amgen; - 29th January 2009 at 09:57.

  5. #5
    Join Date
    Nov 2008
    Posts
    22


    Did you find this post helpful? Yes | No

    Default

    depending at least of your instrument input impedance.
    The input impedance is 1000M, pretty darn high.

    Some instruments also have their own low pass filter at the input
    Ahhhh, yes. I tried just connecting the PWM across the voltage divider and it looks great. I looked at the block diagram of the DPM and there is a filter on the input.

    did you try just using the 1 micro farad across the 46k ohm ?
    Looks like that might not be necessary.


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


    Did you find this post helpful? Yes | No

    Default

    Life is easier than we think sometime huh?

    Glad to know it's working as expected now.

    Enjoy!
    Steve

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

  7. #7
    Join Date
    Nov 2008
    Posts
    22


    Did you find this post helpful? Yes | No

    Default

    Quote Originally Posted by mister_e View Post
    Life is easier than we think sometime huh?
    And I just keep trying to make it harder. That's what happens when we don't look at the big picture and get lost in the trees.

    Still, it should be harder then that .... shouldn't it

    Thanks,
    Mark

Similar Threads

  1. Old and beyond help ?
    By DavidFMarks in forum mel PIC BASIC Pro
    Replies: 46
    Last Post: - 11th December 2008, 16:23
  2. "hello world" with 18f6680
    By dragons_fire in forum mel PIC BASIC Pro
    Replies: 91
    Last Post: - 6th February 2008, 07:06
  3. Problems with RC2 and RC3
    By Christopher4187 in forum General
    Replies: 11
    Last Post: - 29th May 2006, 18:19
  4. 2nd Order Digital Filter for 24-bit
    By sefayil in forum mel PIC BASIC
    Replies: 0
    Last Post: - 2nd December 2005, 22:55
  5. 4-line LCD Help - using PortA instead of B
    By Tom Gonser in forum mel PIC BASIC Pro
    Replies: 28
    Last Post: - 31st March 2005, 04:14

Members who have read this thread : 2

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