Inverting the o/p of hardware PWM


Closed Thread
Results 1 to 11 of 11

Hybrid View

  1. #1
    Join Date
    Feb 2006
    Location
    Brussels, Belgium
    Posts
    104


    Did you find this post helpful? Yes | No

    Default

    Quote Originally Posted by Dave View Post
    AndrewC, Why not just use a transistor and a couple of resistors?

    Dave Purola,
    N8NTA
    To invert the signal or drive the leds ? These are Luxeon leds running at high power. They work best on constant current sources and buckpuks are great for driving them.

    If I can do it with a simple line of code why add external parts ? Actually, my led drivers only go up to 1000mA and my leds can take 1500mA so I may just make my own constant current drivers (two transistors and a couple of resistors per channel) in which case 5V will be ON This particular project is for lighting a macrophotography stage - while focussing / adjusting I use the leds at constant low power but for actual exposures switch to a single high power pulse. Three channels for left, right and backlight.

  2. #2
    Join Date
    Mar 2003
    Location
    Commerce Michigan USA
    Posts
    1,166


    Did you find this post helpful? Yes | No

    Default

    AndrewC, I dont know what constant current has to do with inverting the control signal?

    Dave Purola,
    N8NTA

  3. #3
    skimask's Avatar
    skimask Guest


    Did you find this post helpful? Yes | No

    Default

    Question (maybe more of a comment) concerning taking pictures and using PWM to drive LEDs for lighting...

    Won't your PWM frequency have to be REALLY high to keep the camera's shutter from seeing the flickering?
    LEDs, unlike incandescent light bulbs, can actually turn on and off at those high speeds, whereas an incandescent light bulb will glow during the off time.
    I'm thinking that even with a really fast shutter on a camera, the film (or CCD, or whatever) is going to see that 'flickering' caused by the PWM driven LEDs.

  4. #4
    Join Date
    Feb 2006
    Location
    Brussels, Belgium
    Posts
    104


    Did you find this post helpful? Yes | No

    Default

    Quote Originally Posted by skimask View Post
    Question (maybe more of a comment) concerning taking pictures and using PWM to drive LEDs for lighting...

    Won't your PWM frequency have to be REALLY high to keep the camera's shutter from seeing the flickering?
    LEDs, unlike incandescent light bulbs, can actually turn on and off at those high speeds, whereas an incandescent light bulb will glow during the off time.
    I'm thinking that even with a really fast shutter on a camera, the film (or CCD, or whatever) is going to see that 'flickering' caused by the PWM driven LEDs.
    Well you know the bit where I say "but for actual exposures switch to a single high power pulse" ....... Actually if you have an exposure time longer than say 10 PWM cycles it wouldn't matter. The advantage of a single high power flash is to freeze motion.

    Dave: the point being that if I stick with the OEM drivers I have, I need to invert the signal. If I make my own constant current sources I don't need to invert the signal but need to add some extra components - so the choice is to add some components to invert the signal, or add some components so as not to have to invert the signal. Or I was hoping to find a magic instruction that inverted a PIC o/p pin.

    Darrel: 1023 - you know I keep missing zeroes Same happens with registers, I keep thinking Pin1 or Bit1 is the first one. Duh !

Similar Threads

  1. Variable PWM PIC18F2431
    By trr1985 in forum mel PIC BASIC Pro
    Replies: 7
    Last Post: - 12th June 2009, 06:03
  2. Hardware PWM Question?
    By jhorsburgh in forum General
    Replies: 1
    Last Post: - 18th August 2008, 03:07
  3. PWM: Vernacular/Function (Newbee)
    By TerryN in forum mel PIC BASIC Pro
    Replies: 2
    Last Post: - 3rd July 2008, 16:58
  4. 3 Hardware PWM.
    By sirvo in forum mel PIC BASIC Pro
    Replies: 4
    Last Post: - 30th January 2008, 12:21
  5. pics with 3 hardware PWM ports
    By CBUK in forum mel PIC BASIC Pro
    Replies: 4
    Last Post: - 5th August 2004, 00:14

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