Need to drive 4 rgb leds, but have only 1 pin available...


Closed Thread
Results 1 to 12 of 12

Hybrid View

  1. #1


    Did you find this post helpful? Yes | No

    Default Re: Need to drive 4 rgb leds, but have only 1 pin available...

    Yes, but APA needs two legs. Data and clock,. Or I'm wrong?
    Last edited by louislouis; - 30th January 2020 at 13:16.

  2. #2
    Join Date
    Nov 2003
    Location
    Greece
    Posts
    4,132


    Did you find this post helpful? Yes | No

    Default Re: Need to drive 4 rgb leds, but have only 1 pin available...

    Yes, you are right. Forgot that, sorry!

    Ioannis

  3. #3
    Join Date
    Apr 2014
    Location
    OK
    Posts
    557


    Did you find this post helpful? Yes | No

    Default Re: Need to drive 4 rgb leds, but have only 1 pin available...

    If you are trying to get a specific color from your RGB, and you aren't needing to change that color, use different value resistors from VREF to your individual LED legs and use the PIC to provide ground. For brightness control, you could use that one PWM pin on your PIC and vary duty cycle. You wouldn't be able to change the colors, due to the fixed resistors.

  4. #4
    Join Date
    Sep 2009
    Posts
    755


    Did you find this post helpful? Yes | No

    Default Re: Need to drive 4 rgb leds, but have only 1 pin available...

    Quote Originally Posted by louislouis View Post
    Yes, but APA needs two legs. Data and clock,. Or I'm wrong?
    Not necessary, you can create clock and data using only one pin.
    eg
    https://www.romanblack.com/shift1.htm

  5. #5
    Join Date
    Feb 2013
    Posts
    1,124


    Did you find this post helpful? Yes | No

    Default Re: Need to drive 4 rgb leds, but have only 1 pin available...

    This is customizable backlight, so user will be setting the color. Idea with shift register is nice, but if I have to add an extra IC, I can add say 12F683 and use it directly to drive RGB leds. Footprint will be much smaller

  6. #6
    Join Date
    Sep 2009
    Posts
    755


    Did you find this post helpful? Yes | No

    Default Re: Need to drive 4 rgb leds, but have only 1 pin available...

    You missed the point...
    Use same RC circuit to drive APA LED. Apa have Data and Clock pin and you have one pin free.

  7. #7


    Did you find this post helpful? Yes | No

    Default Re: Need to drive 4 rgb leds, but have only 1 pin available...

    Out of the box. A small PIC device running the 4 LEDs and reading a 2 bit serial pattern with a longish pause to sync.
    George

Similar Threads

  1. Re: RGB Fading Using 3 LEDs and PWM
    By Fernandoangel in forum Off Topic
    Replies: 0
    Last Post: - 8th April 2012, 05:59
  2. Oh Dear. My head is spinning. HPWM RGB LEDs What to choose?
    By jimseng in forum mel PIC BASIC Pro
    Replies: 7
    Last Post: - 19th March 2012, 17:03
  3. TV remote controlled RGB LEDs
    By idtat in forum mel PIC BASIC Pro
    Replies: 0
    Last Post: - 22nd February 2009, 17:15
  4. RGB Fading Using 3 LEDs and PWM
    By Tissy in forum mel PIC BASIC Pro
    Replies: 27
    Last Post: - 20th February 2007, 15:53
  5. RGB Fading Using 3 LEDs and PWM
    By _abello in forum mel PIC BASIC Pro
    Replies: 0
    Last Post: - 19th April 2006, 15:50

Members who have read this thread : 1

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