 Anybody hear me? Yes, I think so. We are MoCo and Vax from Germany, and we are here to show you a talk on how to make your own variable color organ dress. And what's a color organ dress? You can see it here, or you can see it here. Please, sound. I'll start the slide again, I guess. What do I have to press? That's a color organ, basically. And we brought you something. Made a simple version, which we were going to give around. So you can have a look at the. You can have a look at the circuit. Well, what's my motivation behind doing this? Basically, basically, I like sewing, and I've always wanted to use variable LEDs in a project. And there's some inspiration to be found on the web. For example, this amputee tie from Adafruit. And I'm a big fan of Spoonflower, where you can buy custom printed fabric, where this design by Kimza named Circuit Nerd is one of my favorites, as you can see. Sadly, I've only limited programming skills, so, well, that's where you come in. Yeah, so I like electronics. And of course, I always wanted to make some project with variable LEDs. And well, there are some microcontrollers on the web. On the left side, you see Adafruit Gamma. On the right side, Adafruit Flower. And well, my issue was that I didn't really have any practical use case. And well, that's kind of where we come together. OK, so what do you need for sewing? You need your standard sewing utensils, like scissors, a pattern, fabric, et cetera. Make sure you choose a fabric that's appropriate for your project. Like if you want to make a dress, you should choose something stretchy. I recommend for sewing with conductive thread, which you need for the LEDs to connect to use embroidery needles. And you want multiple needle threaders because they break easily, because the conductive thread is more like wire and splices easily and is not easily threaded by hand. You'll need cutting pliers for that, too. Not regular scissors, as I said, conductive thread. And you need the electronics like the microcontroller, the LED, the battery. I used a commercial pattern for the dress. It's McCall's pattern M6028. As with all patterns, you have to check the fit and probably make some slight alterations. But all in all, it's a very easy pattern to use. And I can recommend it. On the right side of the slide, you see how the dress looks before assembling. But there's already the front and the side panels sewn together. Yes, I use an overlock for sewing. On this slide, you can see a basic circuit connecting a microcontroller and a Neopixel LED. There are three kinds of connections. Power, ground, and data. Data goes from the data port to the first LED, then from the LED to the next LED, and so on. And it's important that you connect them in the right direction, as indicated by the arrows on the LED. If you are planning to have a more complex LED pattern, I recommend that you use an embroidery frame, as you can see in the slide, in which you mount the fabric. This is especially important because otherwise the tension might skew your garment. When placing the LEDs, be aware of the data direction and avoid crossing the circuits as much as possible. Otherwise, there will be crosstalk. I also recommend that you pin the LEDs in place before sewing them on, for example, with scotch tape, which I used. If you want to make a variable dress, I recommend that you add layers for the different circuits, power, ground, and data. On the left, you can see my first try with variable LEDs, which had a bigger chance for crosstalk, as you can see in the upper left, maybe, where the wires are crossing, resulting in randomly flickering LEDs. On the right, you can see my second version with three different layers, one for data, one in between to segregate the circuits, and one for power ground, which is not optimal yet, but still better than the first. On the left, I used a fabric performance knit, and on the right, you see modern jersey. Last but not least, don't forget you need to power your dress. You need to add a battery pouch. OK. So basically, we had two microcontroller options that I showed earlier. One was the Adafruit Gamma, and the other one was the Adafruit Flua. They are both fairly cheap and both made to be sued onto something where you actually have to sue and not solder. The thing is that they both are very short on flash and power, so if you're trying to do any more advanced projects, it's probably an issue. So just for scale, the sketch that is running on this project right now has been used up like 90% of the flash of the Gamma. So for the LEDs, we chose the Adafruit RGB Smart Neopixels, which is a Neopixel variant that is doable. As with all Neopixels, it's easily addressable with the libraries that are provided. You can power it with 5 to 9 volts. But you can also power it with 3.3 volts, what we are doing actually. They'll be a bit less bright, but still bright enough. And they are, well, somewhat pricey. You can buy a sheet with 20 pieces for around 35 bucks. And you still have to do some work on it, so you have to clip the sides with a wire cutter, then peel them off, so you have the sides off. And then after that, you basically try to break off the LEDs in a diagonal pattern. So and after you have them separated, they still have some left over grating from the PCB, which you want to file off so it doesn't get stuck in your thread. OK, for programming, you use the standard Arduino IDE, which probably by now everybody has seen once or twice, at least. There are standard libraries provided for all the microcontrollers that we have shown in the Neopixels. And if you actually try to address the LEDs, they, of course, have an index position starting with 0, according to how you wire them up. So the first LED that you wire up is always on index 0. And the next one is index 1 and so on. And if you have a complex pattern or something like this, where you want the top to be addressed as a single virtual pixel group, you have to actually do some mapping software. So basically, if you have an arrangement for your LEDs, you can probably address them from the library like this. So it starts at top with 0 and then goes on in the direction they are actually well connected to each other. But what we need for this kind of project is something like that. So what we're actually going to do is we will have an array for the LEDs, where we just assume that every LED group can have up to five LEDs and just enter the real IDs of the LEDs in there. And then we have function to assign a color to a given LED group, which just cycles through those arrays and sets all the single LEDs to a certain color. Having that already as a function is quite nice, because after you got that, you can just use many standard animations that are already out there if you don't have an external trigger. OK, so for our project, we actually have an external trigger, which is the microphone. So we found the Maxim Max 4466 is all the microphone that's easy to integrate and cheap. As I've said before, the Gemma has very limited flash. So doing a real transformation is certainly not possible in the space we had. So we are going with the simple voltage that the output port of the microphone provides. And the only interesting thing there is that the output has a DC bias of half the power you put in. So if you actually connect it to 3.3 volts like we do, and there is no sound at all, you will still have 1.65 volts on the port. So basically, you configure it as an analog grid on your Arduino. And that would be around 512 to 1024, which corresponds directly to the input voltage given from the microphone. And after that, you will remove the input bias by just subtracting 512. And after that, we also check for noise constants, which we set to 10, because we found out that the microphone tends to measure itself if it's totally quiet, so we just subtract 10. And if it's less than 10, we just return zero. So it doesn't flicker too much if it's quiet. Well, and after that, you actually have to figure out how deep the levels should be turned on. So we have some height variable, which we later used to turn off the single LED groups in order. So basically, if you have 10 LED groups and the height variable is 10, all the LEDs will be on. And if you have something like two or three, they will be only the first two or three volts on. So probably this is confusing. So if it's too confusing, I have two quick examples where we just assume a maximum volume. So for a maximum volume, the output voltage of the microphone will be 3.3 volts. So that will convert to 1024. Then we will subtract the 512. So our result will be 512. And then we retract another 10, because it's above the noise threshold. And then we picked an arbitrary number, 42, of course, that results in 12, which is more LED groups than we have here. But as we are never going to hit a maximum volume, that's probably a good size. We can do that again with low volume, which while we're just going with 623. Again, we are subtracting the 512 input bias, which results with 101. 100, whatever you know. And then at the end, we have 101. And so when we do the division, we see that only the first two LED groups would have been activated by this. So this looks like it should work with 42. If you think that the sensitivity is low, because maybe you're in a quiet room and what you want to see more flicking, you can just decrease the sensitivity variable. So you will end up with more color. OK, in the end, we are not just turning the LEDs on and off, but we're putting a pretty standard rainbow color wheel effect on them, which is so standard that I won't go into it, because you get it with the standard examples with the library. And you have to make sure that there's some kind of fading out. So if you just turn off the LEDs that they aren't used anymore, it will look very, very annoying, because they're flashy then. So what we are doing here is we are slowly fading those out that are not needed anymore. OK, and then basically, you're done. Yeah, what were the lessons learned during the second dress of this form already? What's your fabric choice? In my first version, I had runs on the fabric, probably because I used the wrong needles. You need to watch out. If you want to sew jersey, you best use jersey needles, ballpoint needles. Also, that conductive thread is very rough and may harm sensible fabrics. There will be crosstalk if you move or if your hair falls over the circuits. I haven't found a way yet to change that. Conductive thread is more wire than string. Therefore, you'll need to fixate it in other ways than you would do with regular string. We try to solder it that it doesn't work, but you can hot glue it. And if you don't fix it, you'll lose connectivity. The circuits will get loose, and debugging that is really not fun. Yeah, and if you go to a party in a dress like this, then you might get many annoyed drunks, because they obviously don't like really bright LEDs. And as said, multiple times already, maybe try not the gamma for a larger project, but maybe a flora or something similar, because the tiny storage is an annoyment to the programmer. All right, thanks for listening. We were faster than expected. If you want, I think we can take some questions on stage. And otherwise, you will find us next to the stage or later at Camp Holland for questions, and we'll upload the slides and some resources at Zivicki later. All right, thank you. If you have any questions, please stick your hand up, and I'll bring a microphone over. Two and a half questions. How often can you wear that before it needs maintenance and soldering back together again? Presumably, you can barely panwash that. And also, that's why I asked the question, also, granted you can't have real live FFTs in a thing that small, did you think of just getting maybe three or four signals from just passive filters, just loads of gaps and seeing if that would have done any good? OK, I'll start with the first question. Washing the Adafruit website states it's machine washable, but I haven't tried because of the hot glue, actually. I have washed it by hand so far. And it's the, yeah, well, breaking point has been the soldering part on the microphone so far. I've broken that one off once already. I think I've worn it three times so far, this variant. I also added small dots of hot glue on the, how do you say it, ports, on the data and ground and power points on the electrodes as to keep the wire more tight, so to connect it better? I hope that answers the questions. Yeah, the second question was if we tried an FFT with less channels than a standard FFT, like three or four channels. And the answer is actually that I didn't try it because I was kind of lazy. And so somebody wrote an FFT library for Omega, like, I don't know, years ago, and it wasn't touched in sense. And I was just, well, I could be bothered to load that library. But then even without adding any code to it, it wouldn't compile anymore because it would be too large for the 8K flash. So that's kind of where it left off. Well, rather than just FFT and just having just completely passive analog filters, just sort of doing it not with an FFT algorithm at all, but just with having analog filters completely passive and just having three signals coming in, I just wonder if that was doable. Yeah, that should be possible. But well, it kind of doesn't work with the microphone then. OK, any more questions? OK, thank you very much, guys.