Тёмный

DIY NeoPixel Matrix - WS2812B Strip - ESP32 Project 2 

Clayton Darwin
Подписаться 11 тыс.
Просмотров 46 тыс.
50% 1

This is a break down of the matrix I have been using in my other videos. I'm taking strips of neopixels and making matrices so I can print using XY coordinates. See the original clock video for some code examples.

Наука

Опубликовано:

 

27 янв 2018

Поделиться:

Ссылка:

Скачать:

Готовим ссылку...

Добавить в:

Мой плейлист
Посмотреть позже
Комментарии : 84   
@gideonmugo1465
@gideonmugo1465 2 года назад
Thank you for the video. I was intending to recreate this same circuit, and here you have it. Great job, much appreciated.
@ClaytonDarwin
@ClaytonDarwin 2 года назад
Thanks for saying so. 👍
@imdbtruth
@imdbtruth 5 лет назад
Great video! I'm trying to learn more about LEDs and microcontrollers. SUBSCRIBED!
@ClaytonDarwin
@ClaytonDarwin 5 лет назад
Cool. The ESP32 using MicroPython is a great place to start. You can learn Python using your desktop, and it will all translate directly to MicroPython. Everything you need is free and online.
@kamilz.2044
@kamilz.2044 5 лет назад
Super pomysł i realizacja
@ClaytonDarwin
@ClaytonDarwin 5 лет назад
Dzięki stary.
@davebeckham5429
@davebeckham5429 6 лет назад
Excellent. Looking forward to see other videos as well. Is there any specific reason for coding in micropython. - Thanks.
@ClaytonDarwin
@ClaytonDarwin 6 лет назад
Thanks. I have been using Python almost daily since about 2001, so it is the language in which I'm most fluent. MicroPython is just a natural and easy choice. However, I think I'd really rather be using Lua RTOS from the folks at WhiteCat: github.com/whitecatboard/Lua-RTOS-ESP32 . I just haven't had the time to get started. Lua just seems small and elegant, perfect for embedded systems. I just have to get better at it.
@davebeckham5429
@davebeckham5429 6 лет назад
Many thanks Clayton.
@RETRODISTORT
@RETRODISTORT 5 лет назад
Great video! How did you level shift the signal for the leds? The esp32 gpio hadles 3.3v but the led requires 3.5v data signal. How did u get it to work?
@ClaytonDarwin
@ClaytonDarwin 5 лет назад
Good question. You're right. At 5V as VDD for the WS2812b, and with 0.7xVDD as the minimum input high, then 3.5V is required. But... the WS2812b can run at 3.5V too, and that lowers VIH to 2.45V. I'm guessing the real specs are 0.7x of the lowest VDD value allowed. At any rate, it works with 3.3V from the GPIO. I've never had any problem. You don't have to add anything, but I always insert a 470 ohm resistor to protect the ESP32 port in the event of a short to ground.
@bubbathemaster
@bubbathemaster 5 лет назад
A SN74LVC1T45 on the data pin would handle this for you
@inakiinchaurregui4848
@inakiinchaurregui4848 5 лет назад
Hi! Do you know if you can change the name of the bluetooth so that it appears as we want, when looking for it with another device?
@ClaytonDarwin
@ClaytonDarwin 5 лет назад
I have not experimented with Bluetooth on this device.
@BES23110
@BES23110 5 месяцев назад
Hey! I'm trying have uniform illumination inside a hood, and was thinking of making 10x50 LED array. Not sure how the brightness would work. If at full brightness, given it draws 60mA per pixel (for white), I'm looking at about 30A. As a starting point, I would try with 10A by limiting the brightness values. The way how I want to control is by hooking it up with ESP8266 and controlling via WLED software. So my questions is, can the ESP8266 handle it? or may be I need to have a different PSU for ESP.
@ClaytonDarwin
@ClaytonDarwin 5 месяцев назад
Yes. With neopixels amperage quickly becomes a problem. However, you may not need full power. You can run a single pixel with 3ma on a low value. You get 256 values per color (red green blue), so 768 different levels. I have an array with 1200+ pixels, but I can run it indoors with about 750ma. Just limit the brightness.
@ClaytonDarwin
@ClaytonDarwin 5 месяцев назад
Also, the command/signal is independent from the current lines. An esp32 or similar can definitely handle it.
@gregclare
@gregclare 6 лет назад
Nice project. Just curious why you have run double power buses across the LED strips, when they come back to a single wire into the ESP32 power pins? I note the onboard AM1117 regulator is rated 1A, so that will be your max current (less what the ESP32 is already drawing). Cheers.
@gregclare
@gregclare 6 лет назад
Sorry, ignore my AM1117 regulator comment, as presumably you're hooking up to the VIN pin, so direct from the USB provided 5V power. But still curious about the 1 wire leading into double wired buses.
@ClaytonDarwin
@ClaytonDarwin 6 лет назад
When I made the board I wasn't sure what brightness I would need and consequently what the amperage would be, so I doubled up. Turns out I never go over 32/255 on any color, so the max amperage is under 400ma and it can be run from the USB power in this application. However, if you run all neopixels with all colors at 255/255, it would use 8 amps, and this setup would melt. Well, the ESP32 dev board would. The matrix would be fine. But next time, for a similar size matrix, I would use a single bus of wire that can handle 8 amps.
@gregclare
@gregclare 6 лет назад
Makes sense. Thanks. Good to know your running around max 400ma with those settings. I'm thinking of a 32 x 8 matrix.
@ClaytonDarwin
@ClaytonDarwin 6 лет назад
Cool. If you don't need to make it 8x32 specifically, you may want to try 9x33 instead. Odd numbers give you a center pixel. This allows you to center a font easier. Most simple fonts have an odd number height, like 7x5, which can't center on 8.
@gregclare
@gregclare 6 лет назад
Good point! If focussing on character display then 9 pixels high does make sense when thinking 7x9 dot matrix font (with descenders). So I understand odd numbered height suggestion (for a single character row display). But for width, a multiple of 8 appears to still makes sense. eg. 7x9 font with a 1 pixel character gap would use 8 horizontal pixels per character. So perhaps I should go for a 32x9 pixel panel. Alternatively, if only needing uppercase (and digits), perhaps a 5x7 font on a 30x7 pixel panel. Hmmm
@TMS5100
@TMS5100 6 лет назад
put a smoked acrylic filter over the display. it will improve contrast.
@ClaytonDarwin
@ClaytonDarwin 6 лет назад
Yeah, I was thinking about a white acrylic, but smoked would be good.
@raymundomendez4221
@raymundomendez4221 5 лет назад
I have a question, I am trying to figure out how was it possible to reduce the current and voltage so much, so you can just use the usb port? thank you.
@ClaytonDarwin
@ClaytonDarwin 5 лет назад
If I set all pixels on this board too full brightness white, RGB values (255,255,255), then it draws over 7 amps. That's the maximum amperage it will ever use, but this is way too bright for indoors. I limit the color values in software to comfortable levels. I think here the maximum brightness for white is RGB values (16,16,16). If all the pixels are set to these values, it uses less than 900 milliamps, so that is good for USB3. However, I never use all white, and other colors use even less amperage. Remember that the total amperage of the board is the sum of the amperage of each pixel, and the color values are pulse width modulation values. At a max of 16, at most any pixel is on only 16/256 of the time, 6.25 % of the time. And when one is on (a high pulse) most others are off. Consequently the actual load at any given time, averaged across all pixels, is only a fraction of the 7 amp it could draw. I think the wave clock (same board, another video) averages less than 300 milliamps. Just run some experiments and see what amp loads you get. You don't want to burn anything up.
@raymundomendez4221
@raymundomendez4221 5 лет назад
@@ClaytonDarwin thanks a lot, I havent thougt on not using white to decrease the current neither on using just some leds at the same time and yes, I'll try to use it with a usb3.0, you got a new subscriber.
@ClaytonDarwin
@ClaytonDarwin 5 лет назад
Cool. Be sure to check everything with a meter first so you don't burn up your USB port. Also scale all your color values. Values (255,0,0) is red, but very bright and high current. Values (16,0,0) is the same color red, but dimmer and much lower current. Just divide all color values by the same number, and you get a dimmer, lower current version. Check out the kid computer video. I scale all colors on that by dividing by 8. Really low power.
@wchen2340
@wchen2340 2 года назад
I did shy away from using python for my build (which is a little bigger) cause i was worried about achievable framerates/latency for (interactive) animations, especially if they need a bunch of compute in the background. and learning c was quite painful. can u tell me something about performance/fps in comparison to controlling by c-compiled vs micropython code? thx in advance.
@ClaytonDarwin
@ClaytonDarwin 2 года назад
I haven't compared them. However, even C functions to manipulate frames will be relatively slow on the ESP32.
@ClaytonDarwin
@ClaytonDarwin 2 года назад
That's not helpful, I know.
@mertcapkin7263
@mertcapkin7263 6 лет назад
hey man, great video! At the moment I am doing something similar with these strips. I saw that you used so called "bus(s)es". Could you make a video where you tell how you wired that and why like this? Purpose, advantages, Why two power power lines etc. ? I would really appreciate it! :)
@ClaytonDarwin
@ClaytonDarwin 6 лет назад
Hey Mert, thanks. I ran two power lines because I wasn't sure what the power consumption would be when I was building it. One would be fine now that I know it will only pull 8A max, and especially since it normally runs under 500ma for most applications. I ran the power lines straight across the strips because 1) it's the shortest distance to the pixels for least loss, and 2) it's way easier than doing it at the ends like you have to do with the signal line. But it really doesn't matter when you're under 300 pixels. Do whatever is easier for you. Over 300 pixels, you won't want to run all the power down the strip because of the voltage drop and heat it might cause.
@mertcapkin7263
@mertcapkin7263 6 лет назад
hey, thanks for the reply (sorry little late). The way you connected the power lines makes this circuit a series circuit, right? So the current is the same and the voltage is split? Or do I understand in incorrectly? Thanks! :)
@ClaytonDarwin
@ClaytonDarwin 6 лет назад
Well, hmmm. It's not that complex. Just make sure you have 5 to 7 volts connected to each strip. I guess you could call it parallel. Also make sure your wires are big enough to carry about 45ma per neopixel on the strip. It doesn't matter how you do it. I ran it per strip, but I could have run it along all the strips, as if they weren't cut into smaller strips. The + and - run down the strip and all the neopixels connect to them in parallel. Only the command signal runs in series down the strip.
@mertcapkin7263
@mertcapkin7263 6 лет назад
I bought a 5V, 10A power supply to power my project, consisting of 100 LEDs. I was going to use a bit more LED, but my plans changed. So if I just do the same as you did, except for 1 + and 1 - wire going across the strips would be enough, right? Thanks for the quick answer!
@ClaytonDarwin
@ClaytonDarwin 6 лет назад
Yeah, 100 neopixels should use less than 4.5 amps at full bright, i.e. the RGB values at 255,255,255 for all neopixels. I would do your initial testing with them all as a single strip. Once you have it running, then cut the strips and arrange them back and forth like i did. Run your signal down the strips following the arrows. Run your power across the strips. Be careful with the polarity. Make sure everything is insulated because10 amps can melt metal.
@robincrosscarpenter1
@robincrosscarpenter1 2 года назад
Could this be done using the microbit board?
@ClaytonDarwin
@ClaytonDarwin 2 года назад
I have not used a microbit, but you should be able to adapt to any board that has a library for the WS2812b.
@vhicho2011conejita
@vhicho2011conejita 5 лет назад
Esta muy buena tu explicación pero hay modismos que no entiendo ingles Alguna pagina donde tengas el diagrama de comecciones
@ClaytonDarwin
@ClaytonDarwin 5 лет назад
Lo siento. No tengo diagrama, pero es mas o menos normal por la WS2812B. Hay mas informacion aqui (en ingles): claytondarwin.com/projects/ESP32/MicroPython/
@sub-arts128
@sub-arts128 3 года назад
nice project. i m thinking of esp32 for my next led-matrix, cause arduino is not enough memory. i could not find the project docs on your website. could you please give me a link?
@ClaytonDarwin
@ClaytonDarwin 3 года назад
Cool. I'm moving all my stuff to here : gitlab.com/duder1966/youtube-projects
@ClaytonDarwin
@ClaytonDarwin 3 года назад
Also, I have some tutorials that might help you get started.
@sub-arts128
@sub-arts128 3 года назад
@@ClaytonDarwin thanks. in some other 2812 matrix projects with arduino i saw people using a capacitor with the power supply to protext from peaks and a resistor in front of the first led. you did not use this. so it seem to work without?
@ClaytonDarwin
@ClaytonDarwin 3 года назад
@@sub-arts128 The caps probably protect the arduino. The pixels have their own caps. Most ESP32 dev boards have caps on the input power as well. So I don't add additional caps. You don't have to use a resistor on the input line to the pixels as long as there is no chance the ESP32 pin will accidentally go to ground. However a 470 or 1000 ohm resistor will protect the ESP32 pin and seems to help with spurious signals on the input. I'm using a 1000 in my most recent design (the FunBoard V2). I recently tested my micropixel board and was able to get a reliable signal using up to 8700 ohms in the input from an ESP32.
@wixurechina6794
@wixurechina6794 6 лет назад
mokungit ws2812b strip www.amazon.com/WS2812B-Addressable-Non-waterproof-IP20-Programmable/dp/B01H04YAIQ/ref=sr_1_1?ie=UTF8&qid=1530708385&sr=8-1&keywords=mokungit+ws2812b
@SystemsPlanet
@SystemsPlanet 5 лет назад
launch at night with your propane launcher to simulate a UFO
@andredutoit5340
@andredutoit5340 2 года назад
How come you don't have to use a shift register?
@ClaytonDarwin
@ClaytonDarwin 2 года назад
The WS2812b connects serially. Each one has a microcontroller in it. It reads it's instructions and passes the rest down the line. Each controller handles it's own PWM for color generating. So it isn't in a traditional matrix controlled by shift registers. Just a long string of microcontrollers. The matrix is in the software running it. You send out a whole new set of instructions about 30 times a second.
@Mrle1021
@Mrle1021 2 года назад
It was beautiful. Do you mind if you can share the code? Thanks
@ClaytonDarwin
@ClaytonDarwin 2 года назад
See the original wave clock video.
@Mrle1021
@Mrle1021 2 года назад
@@ClaytonDarwin Great, thanks a lot.
@rocketgamer2404
@rocketgamer2404 5 лет назад
Ben Ben BEN I GO TO HIS SCHOOL AND IM IN HIS CLASS. BEN DARWIN. sHOw hIm THiS CoMMenT!!! Ben it's me!!! Joe!
@ClaytonDarwin
@ClaytonDarwin 5 лет назад
Okay. I will show him.
@sub-arts128
@sub-arts128 2 года назад
so i finally build a 20x20 matrix with esp32. you can see it here: ru-vid.com/video/%D0%B2%D0%B8%D0%B4%D0%B5%D0%BE-cRI8Sehf6do.html . it works nice, but its limited resolution. do you know, what limitations there are for the number of neopixel, you can drive with a esp32? of course there is the amp problem. but i heared of some timing problem all these led-stripes have, cause they are daisy-chained.
@ClaytonDarwin
@ClaytonDarwin 2 года назад
To start, the ESP32 only "drives" the first neopixel. Then each neopixel drives the next. So there is no theoretical limit to the number of pixels. However update speed is an issue (frame rate) since all data has to be passed down the line pixel to pixel. The ws2812b is fast enough at 800mhz (says the datasheet) that it can run 1024 pixels on a single line at 30 frames per second. However, the ESP32 may have a problem keeping up with that if it has to build the data matrix each time before it sends it out. For example, when I play the video using the ESP32 on the 128x64 display, I'm just reading blocks of data from the SD card and sending it. I'm not manipulating the matrix directly. When I actually draw the matrix and move objects or text (like scrolling) it is way slower. My scrolling displays don't generally have any added delay, and they run at probably 12 fps. You might have to use a raspberry pi or something (faster) to have a big responsive display.
@MarcMERLIN
@MarcMERLIN 6 лет назад
I like the diffuser, looks nice. If you'd like a library with a bunch of example demos you can use, see: marc.merlins.org/perso/arduino/post_2018-04-23_FastLED_NeoMatrix-library.html and marc.merlins.org/perso/arduino/post_2018-05-29_EDM-Party-Shirt-powered-with-FastLED_NeoMatrix-and-Adafruit_GFX_-plus-160Wh-_10Ah-4S_-worth-of-lipos.html
@ClaytonDarwin
@ClaytonDarwin 6 лет назад
Thanks bro. Will check it out.
@MarcMERLIN
@MarcMERLIN 6 лет назад
no problem. Also, as you may know, you can now buy premade 8x32 matrices. I spent way too long making my 24x24 by hand like you did, and I'm so happy I can just connect some 8x32 or 16x16 together now, saves loads of time :)
@ClaytonDarwin
@ClaytonDarwin 6 лет назад
Yep. However, what I really want to do is make a big display, so this was my test platform. Maybe by Christmas I'll have the time to do it. I just have too many things I want to try.
@MarcMERLIN
@MarcMERLIN 6 лет назад
Yeah, I saw you wanted to do a bigger one, but how much bigger and how many pixels? Given that time is precious, depending on the size you need, premade panels may still make sense. For instance 1 meter wide is about 3 panels of 32 x 8, which cost about $100. If you want to make a clock, that's one meter square, I agree that it would be too many panels and cost too much ($1200 and 36 panels), but if half that size is good enough, you could use 9x 16x16 panels which would give you 48cmx48cm and 2304 pixels ;) and the panels would cost $300 or so, not _that_ much more than buying the neopixels and laying out 48 strips plus all the soldering.
@ClaytonDarwin
@ClaytonDarwin 6 лет назад
I'm thinking about a 11x27 or 9x33 grid (300 pixels), but 6 inches or a foot between pixels. Bigger, but not many more pixels.
@the3mperor1
@the3mperor1 4 года назад
i want you to make one for me and i will pay for that do you have an email to make a deal ?
@ClaytonDarwin
@ClaytonDarwin 4 года назад
In the "About" tab.
@pavelquispe6483
@pavelquispe6483 5 лет назад
Socio en español pe no se entiende ni michi
@ngoprekmania112
@ngoprekmania112 3 года назад
please coding
@ClaytonDarwin
@ClaytonDarwin 3 года назад
See the wave clock video.
@fekril
@fekril 5 лет назад
Belle realisation mais aucun interet de faire autant de pontage et de soudure, surtout aussi pret l'un de l'autre, une bonne perte de temps pour rien
@ClaytonDarwin
@ClaytonDarwin 5 лет назад
Ce furent les 20 dernières minutes de ma vie.
Далее
How To Make AMAZING ANIMATIONS With LED Matrix
8:17
Просмотров 36 тыс.
Модные мальчишки
00:36
Просмотров 17 тыс.
ESP32 powered WS2812B LED Matrix [Part 1]
8:05
Просмотров 83 тыс.
2 Retro Clocks with an ESP32 (Couldn't be simpler!)
5:37
espArtNetNode v2 ws2812 Pixel Mapping
5:49
Просмотров 44 тыс.
Driving 410 RGB LEDs (WS2812b) with ESP32 & ESP8266
6:45
How to Easily create Animations for your LED Matrix
3:37
Drive 12288 ws2812b with one esp32
3:05
Просмотров 14 тыс.
Getting Started WS2812B RGB Led 32x8 with Esp32
7:52
Просмотров 4,7 тыс.
SSD с кулером и скоростью 1 ГБ/с
0:47