How to wire up WS2811 RGB LEDs to the Raspberry Pi

  Рет қаралды 40,371

TeCoEd

TeCoEd

Күн бұрын

Пікірлер: 134
@mikehlusak1371
@mikehlusak1371 10 ай бұрын
1000 thank you's! I have tried getting these going every few months, then I give up. Finally 100% working; thanks!!
@TeCoEd
@TeCoEd 10 ай бұрын
Excellent glad that the video was useful. 👍
@kayajones9215
@kayajones9215 4 жыл бұрын
This video was amazing for me, thank you sm. others are so confusing and you go over everything and give an explanation thank you again
@TeCoEd
@TeCoEd 4 жыл бұрын
I'm so glad!
@ZenerFox
@ZenerFox Жыл бұрын
I am confused about what to do when the arrow goes up. Does that mean that I have to use the male end to connect the green and white wires to the raspberry pi and white and red to the adapter?
@TeCoEd
@TeCoEd Жыл бұрын
The arrow is the direction the data flows in, it indicates which end to attach the data cable from your Pi to. If the arrow is pointing up then go to the bottom other end of the LEDs and attach the wires from that end.
@windowblotter
@windowblotter 4 жыл бұрын
I'm going to running the same setup, just a slightly different program to light the LEDs. Anyway, do I have to use the 2 wires hanging off to the side? Could I use the positive red wire on the connector instead and run it to the positive terminal on the power supply? And could I also just attach two ground wires to the negative terminal and route one of them to the ground on the pi, and then one of them back to the LED strip? (I'd prefer to do it this way, it's just more convenient and saves a bit of space in my setup. Please let me know if this works. Thank you).
@TeCoEd
@TeCoEd 4 жыл бұрын
The connector is used to join the red and white wires to the power supply, you don't have to use it. As long as there is a separate power supply and only the data and ground run from the Pi pins then it will work.
@windowblotter
@windowblotter 4 жыл бұрын
@@TeCoEd Forgot to ask, but does this work with the WS2812B LED strip? Thanks. I have that one lying around as well that I might want to go ahead and test
@TeCoEd
@TeCoEd 4 жыл бұрын
@@windowblotter it should do.
@synthstatic9889
@synthstatic9889 Жыл бұрын
Great video! My string of LEDs came with a male connector that is supposed to plug the LEDs into the controller pins (rasberry pi pico in this case) the connector has a power wire. Should I remove the power wire before plugging it into my pi?
@TeCoEd
@TeCoEd Жыл бұрын
Yes, have you got an external power supply for the LEDs?
@synthstatic9889
@synthstatic9889 Жыл бұрын
Yes
@TeCoEd
@TeCoEd Жыл бұрын
@@synthstatic9889 OK, so use the power supply and remove the wire before plugging in.
@synthstatic9889
@synthstatic9889 Жыл бұрын
@@TeCoEdwill do. Thanks!
@loudthing87
@loudthing87 2 жыл бұрын
Where is your music from? It's catchy.
@TeCoEd
@TeCoEd 2 жыл бұрын
Here is the link for the music. soundimage.org/
@canaust96
@canaust96 Жыл бұрын
The sudo pip3 install returns the error “this environment is externally managed…” I have pi 4 and just installed 64bit OS. I’ve tried the .venv route with no luck. Any ideas?
@TeCoEd
@TeCoEd Жыл бұрын
Hi. Try pip3 install, pip install. Remove the sudo.
@davisspradling5456
@davisspradling5456 Жыл бұрын
I can only get one light to come up on for some reason and it seems to be the first light. My lights show the data arrow pointing up on every light where I noticed that yours point down. Could this be the problem?
@TeCoEd
@TeCoEd Жыл бұрын
What power supply are you using? This can be the cause.
@JuanGiovaniLandaCervante-hz6iv
@JuanGiovaniLandaCervante-hz6iv 6 ай бұрын
Se pueden controlar 1600 leds?
@Codebyakshay
@Codebyakshay Жыл бұрын
The lines are so basic 😂i am amazed thanks tho ❤❤ respect from india
@TeCoEd
@TeCoEd Жыл бұрын
kzbin.infoszkbxcfkrbU
@DanFagerburg
@DanFagerburg 2 жыл бұрын
I am having trouble getting my lights to respond to the python I write. I have no way of knowing why my GPIO pins may not be working- Help?
@TeCoEd
@TeCoEd 2 жыл бұрын
Some things to check, 1) the LEDs are compatible, you are using the version of the LED library, Pi software is up to date. Let me know how you get on.
@TobiasHolmPiano
@TobiasHolmPiano 4 жыл бұрын
Well done and helpful - thank you! :)
@TeCoEd
@TeCoEd 4 жыл бұрын
glad it helped, I spent many hours looking for an easy guide, did not find one, so I made one instead!
@normhapp8629
@normhapp8629 4 жыл бұрын
Very good video. One question: is the data from the RP 5v or 3.5v? Another video said that you need a voltage converter to get 5 volts on the light string data line. Thanks, Norm
@TeCoEd
@TeCoEd 4 жыл бұрын
The data is from GPIO pin 18 I think. The 5volts is provided by a separate power supply.
@normhapp8629
@normhapp8629 4 жыл бұрын
@@TeCoEd I looked at the RP specs and GPIO is 3.5v (on) or 0 (off). That being said, your configuration works on your video. Possibly could become a problem addressing a large number of lights. However, thanks again, your video is one of the best I have seen.
@TeCoEd
@TeCoEd 4 жыл бұрын
@@normhapp8629 I see. Yes you can power the LEDs with the 5v pin however it is not a constant and you may get full LEDs. Suitable for small LEDs though.
@josephhansen1320
@josephhansen1320 11 ай бұрын
Thanks so much this was really helpful
@ch41ky822
@ch41ky822 3 жыл бұрын
How do I get these blinking/ flashing with music etc please?
@TeCoEd
@TeCoEd 3 жыл бұрын
I had to program the lights to go with he music. I could not find a sounds activated code. kzbin.info/www/bejne/qprOopxsf7KUhdE.
@avachavoshi574
@avachavoshi574 3 жыл бұрын
thank you very much. just one question, how to turn the leds off afterwards?! :D
@TeCoEd
@TeCoEd 3 жыл бұрын
Try pixel.clear() or pixel.off()
@ch41ky822
@ch41ky822 3 жыл бұрын
Great video, Would a 5v 3A usb to dc work instead of a plug ? I'm building a cabinet but limited in socket space although i have usb ports in the wall sockets or even usb port on raspberry pi4 8gb!
@TeCoEd
@TeCoEd 3 жыл бұрын
Yes this would work as long as you have the correct ends. The plug power is great for longer lengths of LEDs as they begin to lose the brightness at the end of the length. Over 100 and they start to fade, so the power plug keeps them bright and the correct colour.
@ch41ky822
@ch41ky822 3 жыл бұрын
@@TeCoEd great thank, u have 50 led bulbs around the screen of on my machine so im hoping this will work, cheers thanks for reply,
@TeCoEd
@TeCoEd 3 жыл бұрын
@@ch41ky822 yes 50 LEDs will be fine. I had chained together 300 LEDs.
@pb9756
@pb9756 3 жыл бұрын
I know this is a bit old, but can you put a parts list that you used?
@TeCoEd
@TeCoEd 3 жыл бұрын
Pi 4 and the any WS2811 LEDs. Also a 12volt power adapter and the adapter. 👍
@someguy650
@someguy650 3 жыл бұрын
Is there a way to chain multiple of these strips together connected to one pi? I can’t find the size I need so is that possible?
@TeCoEd
@TeCoEd 3 жыл бұрын
Yes you can join as many as you want. You just need to use additional power supplies. I had 100 and they were fine. Then 200 news another power supply.
@someguy650
@someguy650 3 жыл бұрын
I did some more research and understand it a bit more now. It depends on the watts the lights use so you might be able to get away with one power supply depending on the lights. This was the first and clearest video that didn’t use some breadboard. Thanks!
@TeCoEd
@TeCoEd 3 жыл бұрын
@@someguy650 you are welcome. I am glad that you found it helpful.
@jannikthyzen1407
@jannikthyzen1407 4 жыл бұрын
can i also connect the red Wire to 5v of Raspi? So there is the same power supply for both
@TeCoEd
@TeCoEd 4 жыл бұрын
Do you mean use the red wire to power the Pi or use the red wire to power the LEDs from the 5v?
@jannikthyzen1407
@jannikthyzen1407 4 жыл бұрын
@@TeCoEd I mean to power the Pi...so i dont need another connection via mini usb to the plug
@TeCoEd
@TeCoEd 4 жыл бұрын
@@jannikthyzen1407 the 5v pin provides 5v output only. If you input 5v you risk damaging the Pi. You can get add on board such as the Pixel Pi that only require 1 power source.
@jannikthyzen1407
@jannikthyzen1407 4 жыл бұрын
@@TeCoEd ok thanks for the answer! :-) I will check for other ways to power the Pi via GPIO
@kenmcmullan9330
@kenmcmullan9330 4 жыл бұрын
What's the red wire for in the triple connector?
@TeCoEd
@TeCoEd 4 жыл бұрын
Red wire is the power wire.
@dswersky
@dswersky 3 жыл бұрын
Thanks for this! Got it working great with a pi Zero with one hitch- the animations work, but there's some glitchy flickering. I've changed the /boot/config.txt, added the recommended hdmi settings. Still some strange random-color flickering. Any ideas? Thanks again!
@TeCoEd
@TeCoEd 3 жыл бұрын
It could be a power issue? Are you powering the LEDs on a separate supply?
@dswersky
@dswersky 3 жыл бұрын
@@TeCoEd Yes, I'm using a 5V/5A external power supply. I read elsewhere that it could be the power/ground/data connections, I'm using some thin prototyping leads. Going to solder some heavier-gauge wire in and use JST connectors, see if that helps.
@TeCoEd
@TeCoEd 3 жыл бұрын
@@dswersky It may be the power supply. I had 300 LEDs chained together and had to use a 12v supply to the colour fading by the end of the chain. Different LEDs also use different voltage.
@dswersky
@dswersky 3 жыл бұрын
@@TeCoEd This strip only has 50 leds, it's identical to the one you have in this video.
@TeCoEd
@TeCoEd 3 жыл бұрын
@@dswersky must be the wire quality then.
@David-zw8xu
@David-zw8xu 3 жыл бұрын
Hello! Whenever I run "sudo pip3 install adafruit-circuitpython-neopixel" I end up with this message: 'Command "python setup.py egg_info" failed with error code 1 in /tmp/pip-build-51ng5rn6/adafruit-circuitpython-neopixel/', and when I run the test .py in the terminal, it reports there is no module named board or neopixel. How can I fix this? Thank you!
@TeCoEd
@TeCoEd 3 жыл бұрын
It may be because you have to specify the type of neopixels. Try, sudo pip3 install rpi_ws281x adafruit-circuitpython-neopixel
@David-zw8xu
@David-zw8xu 3 жыл бұрын
@@TeCoEd Thanks for the speedy reply. I tried what you suggested, and and it didn't work. I am pretty much new to raspberry pi projects, so maybe there could be something flying over my head?
@TeCoEd
@TeCoEd 3 жыл бұрын
@@David-zw8xu are you using the newest version of the Pi OS?
@TeCoEd
@TeCoEd 3 жыл бұрын
@@David-zw8xu you may need to install pip, www.linuxscrew.com/install-pip
@David-zw8xu
@David-zw8xu 3 жыл бұрын
@@TeCoEd Thank you so much for your help, I've done both but to no avail.
@tinkertron
@tinkertron 4 жыл бұрын
how many amps is that power plug?
@TeCoEd
@TeCoEd 4 жыл бұрын
5volts and 4amps.
@crazierpuma_6080
@crazierpuma_6080 2 жыл бұрын
Hi TeCoEd, thanks for your video. I've been following yours steps but when i put "sudo pip3 install adafruit-circuitpython-neopixel" it appears one error. "Python setup.py egg_info" failed with error code 1 in /tmp/pip-build-kqjsi4hc/sysv-ipc/ I've seen that someone had the same problem but no solution
@TeCoEd
@TeCoEd 2 жыл бұрын
Try without pip3 just pip.
@crazierpuma_6080
@crazierpuma_6080 2 жыл бұрын
@@TeCoEd New error "python setup.py egg_info" failed with error code 1 in /tmp/pip-build-xTd60y/adafruit-circuitpython-neopixel/ ( I'm a noob at this :,) )
@TeCoEd
@TeCoEd 2 жыл бұрын
@@crazierpuma_6080 are you running the code in root?
@TeCoEd
@TeCoEd 2 жыл бұрын
@@crazierpuma_6080 also Adafruit have updated their instructions. learn.adafruit.com/neopixels-on-raspberry-pi/python-usage
@crazierpuma_6080
@crazierpuma_6080 2 жыл бұрын
@@TeCoEd ok, ill try it now. I don't know if I'm running out in root
@conceptroot
@conceptroot 4 жыл бұрын
how to run this code with no sudo?
@TeCoEd
@TeCoEd 4 жыл бұрын
You can't, it requires you to run the code with sudo. But, if you open Python in the terminal with 'sudo Python', then you can run the code from Python IDE.
@leesahcage3297
@leesahcage3297 4 жыл бұрын
Excellent video, one of the best I have seen. How many pixels can the Pi control?
@TeCoEd
@TeCoEd 4 жыл бұрын
Thanks. The LEDs are powered by a 5v power supply and you can run about 300 and then they start to fade out. But just add another 5v supply half way and then you can add another 300. So you can run as many as you like to from the Pi.
@leesahcage3297
@leesahcage3297 4 жыл бұрын
@@TeCoEd Really so if I had 3 5v 40A power supplies do you think I can control 1000 pixels with one raspberry pi Zero W or 4B?
@TeCoEd
@TeCoEd 4 жыл бұрын
@@leesahcage3297 yes that is correct. The Pi is simply to provide the code and control the LEDs. so you need the power supplies.
@TeCoEd
@TeCoEd 4 жыл бұрын
@@leesahcage3297 check this out. kzbin.info/www/bejne/pXjXhqVrmdKihs0
@the_wub
@the_wub 2 жыл бұрын
This was so helpful, thank you!
@TeCoEd
@TeCoEd 2 жыл бұрын
You are welcome
@jaws2531
@jaws2531 4 жыл бұрын
Great Video! Question, are you also using a level shifter? From what I have read the Raspberry Pi GPIO pins output @ 3.3v and the NeoPixels need 5v for the data and thats where the level shifter apparently comes in. I have tried your exact setup pretty much and so far I can't get it to power up any of the leds. I am guessing its because I don't have a level shifter and was just verifying if you were using one. Thanks!
@TeCoEd
@TeCoEd 4 жыл бұрын
Hi. No level shifter. The LEDs are powered by a separate 5v power supply. Some LEDs require 12v so you may need a different powder supply. Check the LED model and the recommended power supply.
@TeCoEd
@TeCoEd 4 жыл бұрын
Also check from 2 mins into the video. I talk about how to rig up the power. First time I set them up I was using the wrong power supply.
@jaws2531
@jaws2531 4 жыл бұрын
@@TeCoEd Thanks as this was another idea I had also to what my problem is. I have another power supply arriving tomorrow that is a 5v 60a so it should good. My current was 5v 4a, which I thought was similar to yours but it doesn't seem to light any leds up. Once I get this all figured out my goal is to retro fit a 1981 Nevco Score Board from a local HS gym with Led lights that I can control a bit to just set a fake time and score. Will be just for decoration in the shop =) Thanks for your advice. Have a great 2021!
@TeCoEd
@TeCoEd 4 жыл бұрын
@@jaws2531 that sounds like a great project. Let me know how you get on.
@jaws2531
@jaws2531 4 жыл бұрын
Well good news.... I solved my own issue. Apparently I missed this part: sudo nano /etc/modprobe.d/snd-blacklist.conf blacklist snd_bcm2835 Once I created that file with that line everything works now!
@kayajones9215
@kayajones9215 4 жыл бұрын
Hey, nice video. I have been trying to wire up WS2813 lights however it is not working.
@TeCoEd
@TeCoEd 4 жыл бұрын
What power supply are you using ?
@kayajones9215
@kayajones9215 4 жыл бұрын
@@TeCoEd Hey i figured it out
@willdoyle5380
@willdoyle5380 4 жыл бұрын
@@kayajones9215 what did you do?
@otto.bjorkland
@otto.bjorkland 2 жыл бұрын
@@kayajones9215 How did you do? I cannot figure out how to do it
@andrespalusalu7393
@andrespalusalu7393 4 жыл бұрын
can I also use a battery or a powerbank as an external power supply?
@TeCoEd
@TeCoEd 4 жыл бұрын
Yes, I use the Anker power packs, they provide around 6 - 8 hours of use.
@GhettoArabSage
@GhettoArabSage 3 жыл бұрын
@@TeCoEd is this to power the rpi or the LED? I'm looking for a solution to only have one power supply to light up a few LEDs.
@TeCoEd
@TeCoEd 3 жыл бұрын
@@GhettoArabSage the 5V power supply is for the LEDs. Because there are over 50 and you lose the signal powering it from the Pi.
@GhettoArabSage
@GhettoArabSage 3 жыл бұрын
@@TeCoEd if I'm not mistaken the gpio pin is 5v, no? Why the need for extra energy?
@GhettoArabSage
@GhettoArabSage 3 жыл бұрын
@@TeCoEd thanks for the reply btw. I really appreciate it.
@douglasoshea8064
@douglasoshea8064 3 жыл бұрын
no picap?
@TeCoEd
@TeCoEd 3 жыл бұрын
I have a PiCap but had already started the project. I will make a video on the new year using the PiCap.
@n0b0t19
@n0b0t19 4 жыл бұрын
Great walk-through! Thanks :-)
@TeCoEd
@TeCoEd 4 жыл бұрын
Glad you enjoyed it!
@timleimbach5817
@timleimbach5817 4 жыл бұрын
Why didn't you use any resistors?
@TeCoEd
@TeCoEd 4 жыл бұрын
Not needed as the power is from the supply plug, not the Pi so, as long as you don't put the wires around the wrong way it all works. 👍
@timleimbach5817
@timleimbach5817 4 жыл бұрын
@@TeCoEd Awesome thanks! I'm currently trying to make the same setup.
@TeCoEd
@TeCoEd 4 жыл бұрын
@@timleimbach5817 let me know how you get on. 👍
@timleimbach5817
@timleimbach5817 3 жыл бұрын
@@TeCoEd Life got in the way so I took a break, but just made it work! Thanks
@Wesfelkins
@Wesfelkins 3 жыл бұрын
It compiles but nothing happens.. any advice?
@TeCoEd
@TeCoEd 3 жыл бұрын
Are you using the correct voltage. Some LEDs require 12 some 5.
@Wesfelkins
@Wesfelkins 3 жыл бұрын
@@TeCoEd Yes 5 Volt WS2811. It works on the 5 volt arduino for reference
@Wesfelkins
@Wesfelkins 3 жыл бұрын
@@TeCoEd Yea, it just turns them all off for some reason..
@Wesfelkins
@Wesfelkins 3 жыл бұрын
@@TeCoEd FIXED: I had to use GPIO 10
@TeCoEd
@TeCoEd 3 жыл бұрын
@@Wesfelkins great job. I was going to suggest the GPIO pins next.
@dablet
@dablet 3 жыл бұрын
that was great! thank you mate
@TeCoEd
@TeCoEd 3 жыл бұрын
Adapter plug here www.amazon.co.uk/inShareplus-100-240V-Adapter-Voltage-Transformer/dp/B088WBTNRV/ref=mp_s_a_1_9?dchild=1&keywords=led+adapter+for+lights&qid=1616882800&sprefix=LED+adapter+&sr=8-9
@Tom_Neverwinter
@Tom_Neverwinter 3 жыл бұрын
oh, this is for wirepy or whatever.
@thefonze1985
@thefonze1985 Жыл бұрын
no
Une nouvelle voiture pour Noël 🥹
00:28
Nicocapone
Рет қаралды 9 МЛН
Гениальное изобретение из обычного стаканчика!
00:31
Лютая физика | Олимпиадная физика
Рет қаралды 4,8 МЛН
coco在求救? #小丑 #天使 #shorts
00:29
好人小丑
Рет қаралды 120 МЛН
Connecting an LED To Raspberry Pi
6:19
O'Reilly
Рет қаралды 180 М.
I wired my tree with 500 LED lights and calculated their 3D coordinates.
24:38
How to control WS2811 RGB LED with Arduino
11:04
Creative creator
Рет қаралды 75 М.
I’m Never Buying LEDs Again! EASY DIY WLED!
13:11
TechFlow
Рет қаралды 1,3 МЛН
Tutorial: Control Raspberry Pi GPIO via HTTP Web Server
7:19
Software Sage
Рет қаралды 63 М.
Raspberry Pi Pico Tutorial : NeoPixels / WS2812B LED's
5:17
NerdCave
Рет қаралды 38 М.
WS2811 on Steroids
14:17
Leo's Bag of Tricks
Рет қаралды 16 М.
I Made My Own Computer | Let's See How It Works
7:51
3DSage
Рет қаралды 824 М.
Une nouvelle voiture pour Noël 🥹
00:28
Nicocapone
Рет қаралды 9 МЛН