Little help needed to understand Dimmer for DC lamp?


Closed Thread
Results 1 to 15 of 15

Hybrid View

  1. #1
    Join Date
    Nov 2009
    Location
    London
    Posts
    251

    Question Little help needed to understand Dimmer for DC lamp?

    Hi, can someone help me understand how I can control the brightness of a DC halogen lamp 12/24V using my PIC. The PIC is suppose to get a pulse from a PLC circuit, first pulse the brightness to be 60%, 2nd pulse to be 100% & on 3rd pulse ALL lamps to be OFF.
    I would like to ask what will be the suitable PIC for this job and any ideas/help as how to start with this project (including schematic to control the lamps). Can 16F877A do the job? and also how many of these lamps can I control with one PIC. Thanks in advance.

  2. #2
    Join Date
    May 2008
    Location
    Italy
    Posts
    825


    Did you find this post helpful? Yes | No

    Default

    Can 16F877A do the job? and also how many of these lamps can I control with one PIC
    Yes. you can control two indipendent lamps, since you have two pwm channels per chip.

    There is a typo in the schematic First command duty cycle = 255 (full power)

    Al.
    Attached Images Attached Images  
    Last edited by aratti; - 7th April 2010 at 22:43.
    All progress began with an idea

  3. #3
    Join Date
    Nov 2009
    Location
    London
    Posts
    251


    Did you find this post helpful? Yes | No

    Red face Thanks

    Quote Originally Posted by aratti View Post
    Yes. you can control two indipendent lamps, since you have two pwm channels per chip.

    There is a typo in the schematic First command duty cycle = 255 (full power)

    Al.
    Thanks. I looked in the PBP Manual - it asks for Channel, Dutycycle,Frequency.

    From what you said, Duty cycle value should be from 0-255 (255 Full power)
    Channel will be the Port on which the lamp will be connected.
    What will be the frequency?

    Also the circuit you mentioned, can it work on 12V as well? Thanks

  4. #4
    Join Date
    May 2008
    Location
    Italy
    Posts
    825


    Did you find this post helpful? Yes | No

    Default

    From what you said, Duty cycle value should be from 0-255 (255 Full power)
    Yes.

    Channel will be the Port on which the lamp will be connected.
    Where you connect the interface, that drives that lamp.


    What will be the frequency?
    I have indicated 20 KHz (20000) but you should experiment variuos frequency and choose the one that gives you the best result. Remember that frequency must be the same for both channels. Refer to the table @ page 74 of PBP manual for max & min frequency available.


    Also the circuit you mentioned, can it work on 12V as well? Thanks
    Yes, but you should change the 10 K pullup resistor with a 4.7 K one. (On both channels)

    Edited: I have posted a new schematic with the correct pullup value for 12 volts and correctly wired, since in my previous post, schematic shows resistor wrongly connected (see the two schematics and note the mistake)
    Attached Images Attached Images  
    Last edited by aratti; - 9th April 2010 at 19:04.
    All progress began with an idea

  5. #5
    Join Date
    Jan 2009
    Location
    California, USA
    Posts
    323


    Did you find this post helpful? Yes | No

    Default

    Wouldn't it be easier just to use a single MOSFET as a low side driver?



    steve

  6. #6
    Join Date
    May 2008
    Location
    Italy
    Posts
    825


    Did you find this post helpful? Yes | No

    Default

    steve, the answer is yes, but you should use mosfet with logic level capability. These devices, anyway are not capable of high current as the normal mosfet, and you will end up to pay more than a normal mosfet plus a small NPN transistor.

    Al.
    Last edited by aratti; - 9th April 2010 at 22:41.
    All progress began with an idea

  7. #7
    Join Date
    Jan 2009
    Location
    California, USA
    Posts
    323


    Did you find this post helpful? Yes | No

    Default

    Which circuit are you using? The one Aratti posted requires a P-channel MOSFET.

    If you are using an N-channel MOSFET in a low-side driver circuit, then you probably need one with a lower gate threshold voltage.

    Either way, that MOSFET doesn't look well suited to the job.


    Steve

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