element14 Community
element14 Community
    Register Log In
  • Site
  • Search
  • Log In Register
  • Community Hub
    Community Hub
    • What's New on element14
    • Feedback and Support
    • Benefits of Membership
    • Personal Blogs
    • Members Area
    • Achievement Levels
  • Learn
    Learn
    • Ask an Expert
    • eBooks
    • element14 presents
    • Learning Center
    • Tech Spotlight
    • STEM Academy
    • Webinars, Training and Events
    • Learning Groups
  • Technologies
    Technologies
    • 3D Printing
    • FPGA
    • Industrial Automation
    • Internet of Things
    • Power & Energy
    • Sensors
    • Technology Groups
  • Challenges & Projects
    Challenges & Projects
    • Design Challenges
    • element14 presents Projects
    • Project14
    • Arduino Projects
    • Raspberry Pi Projects
    • Project Groups
  • Products
    Products
    • Arduino
    • Avnet & Tria Boards Community
    • Dev Tools
    • Manufacturers
    • Multicomp Pro
    • Product Groups
    • Raspberry Pi
    • RoadTests & Reviews
  • About Us
  • Store
    Store
    • Visit Your Store
    • Choose another store...
      • Europe
      •  Austria (German)
      •  Belgium (Dutch, French)
      •  Bulgaria (Bulgarian)
      •  Czech Republic (Czech)
      •  Denmark (Danish)
      •  Estonia (Estonian)
      •  Finland (Finnish)
      •  France (French)
      •  Germany (German)
      •  Hungary (Hungarian)
      •  Ireland
      •  Israel
      •  Italy (Italian)
      •  Latvia (Latvian)
      •  
      •  Lithuania (Lithuanian)
      •  Netherlands (Dutch)
      •  Norway (Norwegian)
      •  Poland (Polish)
      •  Portugal (Portuguese)
      •  Romania (Romanian)
      •  Russia (Russian)
      •  Slovakia (Slovak)
      •  Slovenia (Slovenian)
      •  Spain (Spanish)
      •  Sweden (Swedish)
      •  Switzerland(German, French)
      •  Turkey (Turkish)
      •  United Kingdom
      • Asia Pacific
      •  Australia
      •  China
      •  Hong Kong
      •  India
      • Japan
      •  Korea (Korean)
      •  Malaysia
      •  New Zealand
      •  Philippines
      •  Singapore
      •  Taiwan
      •  Thailand (Thai)
      • Vietnam
      • Americas
      •  Brazil (Portuguese)
      •  Canada
      •  Mexico (Spanish)
      •  United States
      Can't find the country/region you're looking for? Visit our export site or find a local distributor.
  • Translate
  • Profile
  • Settings
Raspberry Pi
  • Products
  • More
Raspberry Pi
Raspberry Pi Forum RasPi and PWM controlled LED strip
  • Blog
  • Forum
  • Documents
  • Quiz
  • Events
  • Polls
  • Files
  • Members
  • Mentions
  • Sub-Groups
  • Tags
  • More
  • Cancel
  • New
Join Raspberry Pi to participate - click to join for free!
Featured Articles
Announcing Pi
Technical Specifications
Raspberry Pi FAQs
Win a Pi
Raspberry Pi Wishlist
Actions
  • Share
  • More
  • Cancel
Forum Thread Details
  • State Verified Answer
  • Replies 26 replies
  • Answers 1 answer
  • Subscribers 677 subscribers
  • Views 3912 views
  • Users 0 members are here
  • raspberrypi
Related

RasPi and PWM controlled LED strip

freddyfred5
freddyfred5 over 11 years ago

Hello there people, I am currently working on a casemod, and I would like to use a RasPi as the controller for some LED strips (12v, pulling about 700ma each).

 

The RasPi will act as a webserver hosting a website for remotely controlling the strips, as well as viewing some information about the system (temp sensors, fan speed. don't care about these, they are up and running). But it will also control 2 12v LED strips, and these strips pull too much for the RasPi to control directly.

 

Now, I do have some TIP120's here, and as far as I can see they should work, but I am unsure of how to connect them.

 

Could someone here please help me with getting everything set up properly?

 

Parts:

PSU: Corsair CX

RasPi: Rev 1, model B

Lights: 12v, pulling around 700ma each

 

Wanted outcome:

PWM control on one LED strip

Normal (on, off) on the other

A living RasPi

 

Questions:

Could you help me set this up in a way that does not any part?

Do I need a capacitor in front of the RasPi to ensure no harm is done under startup? (Will 4700 microfarads do?)

Should I use a fuse, or is it unnecessary?

Am I asking too many questions?

  • Sign in to reply
  • Cancel
Parents
  • Former Member
    0 Former Member over 11 years ago

    I honestly in my opinion would use a 3.3v or 5v relay. But im not sure im only 14

    • Cancel
    • Vote Up 0 Vote Down
    • Sign in to reply
    • Verify Answer
    • Cancel
  • Robert Peter Oakes
    0 Robert Peter Oakes over 11 years ago in reply to Former Member

    Keep up the thinking , a very valid observation.

     

    Here is why it is mostly not done in this scenario (It is a valid approach but read on)

     

    If you use a relay (3V3 or 5V) you will still need a driver which will still probably be a ULN2003 or equivalent circuit (As there so cheap) as most controllers do not have the drive to switch a relay directly (Not without overloading the pin). As the load in this case is low voltage (Just high current) it is not necessary to add the addition of a relay as the driver already has the ability to control the LEDs.

     

    If the load was to be say mains voltage (~110V or ~220V depending on location) then it would be very prudent to provide Isolation between the load and your circuit. firstly to prevent  accidentally blowing up your board or other attached devices to the PI and also to protect you when touching the board or connected stuff. it also prevents mains interference and spikes (Board Killers) from getting to your stuff.

     

    So as a general rule if your load low voltage and don't need the isolation, a driver circuit like the ULN2003 is perfect for the job, you can always add a power MOSFET for very high currents. If you need to isolate the load for various reasons, then use a relay (Solid State or Mechanical). If your driving AC loads then a relay makes it easy. If you don't know what your going to control, a relay is a safe bet to have max flexibility

     

    Hope this clarifies and helps you to decide for future projects

    • Cancel
    • Vote Up 0 Vote Down
    • Sign in to reply
    • Verify Answer
    • Cancel
Reply
  • Robert Peter Oakes
    0 Robert Peter Oakes over 11 years ago in reply to Former Member

    Keep up the thinking , a very valid observation.

     

    Here is why it is mostly not done in this scenario (It is a valid approach but read on)

     

    If you use a relay (3V3 or 5V) you will still need a driver which will still probably be a ULN2003 or equivalent circuit (As there so cheap) as most controllers do not have the drive to switch a relay directly (Not without overloading the pin). As the load in this case is low voltage (Just high current) it is not necessary to add the addition of a relay as the driver already has the ability to control the LEDs.

     

    If the load was to be say mains voltage (~110V or ~220V depending on location) then it would be very prudent to provide Isolation between the load and your circuit. firstly to prevent  accidentally blowing up your board or other attached devices to the PI and also to protect you when touching the board or connected stuff. it also prevents mains interference and spikes (Board Killers) from getting to your stuff.

     

    So as a general rule if your load low voltage and don't need the isolation, a driver circuit like the ULN2003 is perfect for the job, you can always add a power MOSFET for very high currents. If you need to isolate the load for various reasons, then use a relay (Solid State or Mechanical). If your driving AC loads then a relay makes it easy. If you don't know what your going to control, a relay is a safe bet to have max flexibility

     

    Hope this clarifies and helps you to decide for future projects

    • Cancel
    • Vote Up 0 Vote Down
    • Sign in to reply
    • Verify Answer
    • Cancel
Children
  • iagorubio
    0 iagorubio over 11 years ago in reply to Robert Peter Oakes

    Great point Peter.

     

    Sometimes I forgot this is the Raspberry forum.

     

    You won't drive a 5V relay directly from the Pi GPIOs.

    • Cancel
    • Vote Up 0 Vote Down
    • Sign in to reply
    • Verify Answer
    • Cancel
element14 Community

element14 is the first online community specifically for engineers. Connect with your peers and get expert answers to your questions.

  • Members
  • Learn
  • Technologies
  • Challenges & Projects
  • Products
  • Store
  • About Us
  • Feedback & Support
  • FAQs
  • Terms of Use
  • Privacy Policy
  • Legal and Copyright Notices
  • Sitemap
  • Cookies

An Avnet Company © 2026 Premier Farnell Limited. All Rights Reserved.

Premier Farnell Ltd, registered in England and Wales (no 00876412), registered office: Farnell House, Forge Lane, Leeds LS12 2NE.

ICP 备案号 10220084.

Follow element14

  • X
  • Facebook
  • linkedin
  • YouTube