Posts | Comments

Planet Arduino

Archive for the ‘neopixel’ Category

You might think that making your own electronic games would require some kind of LCD, but lately, [Mirko Pavleski] has been making his using inexpensive 8X8 WS2812B LED panels. This lets even a modest microcontroller easily control a 64-pixel “screen.” In this case, [Mirko] uses an Arduino Nano, 3 switches, and a buzzer along with some 3D printed components to make a good-looking game. You can see it in action in the video below.

The WS2812B panels are easy to use since the devices have a simple protocol where you only talk to the first LED. You send pulses to determine each LED’s color. The first LED changes color and then starts repeating what you send to the next LED, which, of course, does the same thing. When you pause a bit, the array decides you are done, and the next train of pulses will start back at the first LED.

It looks like the project is based on a German project from [Bernd Albrecht], but our German isn’t up to snuff, and machine translation always leaves something to be desired. Another developer added a play against the computer mode. This is a simple program and would be easy to port to the microcontroller of your choice. [Mirko]’s execution of it looks like it could be a commercial product. If you made one as a gift, we bet no one would guess you built it yourself.

Of course, you could play a real robot. You could probably repurpose this hardware for many different games, too.

"The Great Resistor" color code illumination project

With surface-mount components quickly becoming the norm, even for homebrew hardware, the resistor color-code can sometimes feel a bit old-hat. However, anybody who has ever tried to identify a random through-hole resistor from a pile of assorted values will know that it’s still a handy skill to have up your sleeve. With this in mind, [j] decided to super-size the color-code with “The Great Resistor”.

Resistor color code from Wikipedia with white background
How the resistor color-code bands work

At the heart of the project is an Arduino Nano clone and a potential divider that measures the resistance of the test resistor against a known fixed value. Using the 16-bit ADC, the range of measurable values is theoretically 0 Ω to 15 MΩ, but there are some remaining issues with electrical noise that currently limit the practical range to between 100 Ω and 2 MΩ.

[j] is measuring the supply voltage to help counteract the noise, but intends to move to an oversampling/averaging method to improve the results in the next iteration.

The measured value is shown on the OLED display at the front, and in resistor color-code on an enormous symbolic resistor lit by WS2812 RGB LEDs behind.

Inside view of the great resistor showing WS2812 LEDs and baffle plates
Inside The Great Resistor, the LEDs and baffle plates make the magic work

Precision aside, the project looks very impressive and we like the way the giant resistor has been constructed. It would look great at a science show or a demonstration. We’re sure that the noise issues can be ironed out, and we’d encourage any readers with experience in this area to offer [j] some tips in the comments below. There’s a video after the break of The Great Resistor being put through its paces!

If you want to know more about the history of the resistor color code bands, then we have you covered.  Alternatively, how about reading the color code directly with computer vision?

"The Great Resistor" color code illumination project

With surface-mount components quickly becoming the norm, even for homebrew hardware, the resistor color-code can sometimes feel a bit old-hat. However, anybody who has ever tried to identify a random through-hole resistor from a pile of assorted values will know that it’s still a handy skill to have up your sleeve. With this in mind, [j] decided to super-size the color-code with “The Great Resistor”.

Resistor color code from Wikipedia with white background
How the resistor color-code bands work

At the heart of the project is an Arduino Nano clone and a potential divider that measures the resistance of the test resistor against a known fixed value. Using the 16-bit ADC, the range of measurable values is theoretically 0 Ω to 15 MΩ, but there are some remaining issues with electrical noise that currently limit the practical range to between 100 Ω and 2 MΩ.

[j] is measuring the supply voltage to help counteract the noise, but intends to move to an oversampling/averaging method to improve the results in the next iteration.

The measured value is shown on the OLED display at the front, and in resistor color-code on an enormous symbolic resistor lit by WS2812 RGB LEDs behind.

Inside view of the great resistor showing WS2812 LEDs and baffle plates
Inside The Great Resistor, the LEDs and baffle plates make the magic work

Precision aside, the project looks very impressive and we like the way the giant resistor has been constructed. It would look great at a science show or a demonstration. We’re sure that the noise issues can be ironed out, and we’d encourage any readers with experience in this area to offer [j] some tips in the comments below. There’s a video after the break of The Great Resistor being put through its paces!

If you want to know more about the history of the resistor color code bands, then we have you covered.  Alternatively, how about reading the color code directly with computer vision?

One of the problems with a classic Turing machine is the tape must be infinitely long. [Mark’s] Turing Ring still doesn’t have an infinite tape, but it does make it circular to save space. That along with a very clever and capable UI makes this one of the most usable Turing machines we’ve seen. You can see a demo in the video below.

The device uses an Arduino Nano, a Neopixel ring, an encoder, and a laser-cut enclosure that looks great. The minimal UI has several modes and the video below takes you through all of them.

You can even store tapes to EEPROM or the serial port, so that’s even more practical. Of course, you might wonder what practicality is a Turing machine? The honest answer is not much, but on the bright side, this one also has a clock mode so even when you aren’t explaining how a Turing machine works, it will make a good conversation piece.

We were impressed with the lettering on the case in addition to the simplicity of the user interface. [Mark] had won the LED ring in a competition so the total cost of this — to him — was low, but it wouldn’t be too much even if you bought all the pieces.

This one is certainly more compact than the last Turing machine we looked at. If you need a refresher on Turing machines and why they matter, here’s some reading for you.

We suppose it’s a bit early to call it just yet, but we definitely have a solid contender for Father of the Year. [DIY_Maxwell] made a light-up hockey game for his young son that looks like fun for all ages. Whenever the puck is hit with the accompanying DIY hockey stick (or anything else), it lights up and produces different sounds based on its acceleration.

Inside the printed puck is an Arduino Nano running an MPU6050 accelerometer, a 12-NeoPixel ring, and a piezo buzzer. [DIY_Maxell] reused a power bank charging circuit to charge up the small LiPo battery.

The original circuit used a pair of coin cells, but the Arduino was randomly freezing up, probably because of the LEDs’ current draw. Be sure to check out the video after the break, which begins with a little stop motion and features a solder stand in the shape of a 3D printer.

Got a house full of carpet or breakables? You could always build an air hockey table instead.

When we see RGB LEDs used in a project, they’re often used more for aesthetic purposes than as a practical source of light. It’s an easy way to throw some color around, but certainly not the sort of thing you’d try to light up anything larger than a desk with. Apparently nobody explained the rules to [Brian Harms] before he built Light[s]well.

Believe it or not, this supersized light installation doesn’t use any exotic hardware you aren’t already familiar with. Fundamentally, what we’re looking at is a WiFi enabled Arduino MKR1000 driving strips of NeoPixel LEDs. It’s just on a far larger scale than we’re used to, with a massive 4 x 8 aluminum extrusion frame suspended over the living room.

Onto that frame, [Brian] has mounted an undulating diffuser made of 74 pieces of laser-cut cardstock. Invoking ideas of waves or clouds, the light looks like its of natural or even biological origin while at the same time having a distinctively otherworldly quality to it.

The effect is even more pronounced when the RGB LEDs kick in, thanks to the smooth transitions between colors. In the video after the break, you can see Light[s]well work its way from bright white to an animated rainbow. As an added touch, he added Alexa voice control through Arduino’s IoT Cloud service.

While LED home lighting is increasingly becoming the norm, projects like Light[s]well remind us that we aren’t really embracing the possibilities offered by the technology. The industry has tried so hard to make LEDs fit into the traditional role of incandescent bulbs, but perhaps its time to rethink things.

While the Nintendo GameCube stood deep in the shadows of the PS2 in its day, its controller remains a popular target for all sorts of modifications today — many of them involving LEDs, thanks to a translucent bottom and button option. As an avid player of the Super Smash Bros. series, [goomysmash] is of course an owner of the very same controller, which motivated him to write GoomWave, a “versatile and hackable LED library”. In an impressively detailed Instructable, he shows how to modify your own controller in two different ways to make use of the library for yourself.

Initially inspired by the Shinewave mod that lights up RGB LEDs in colors associated to pre-defined moves in Smash Bros, [goomysmash] aimed to improve on it and add more versatility from the very beginning. Its latest iteration comes in a simplified ABXY-buttons-only variety using an ATtiny85, and a full-blown all-button variety using an Arduino Nano. Both of them are powered straight from the controller board, and have different modes where they either react to controller interactions, or are just custom lights. A brief showcasing of all the different modes can be seen in the video after the break, and there a few more details also in an older version’s video, also embedded below.

Mesmerizing LED-blinking aside, we just have to admire the diligence and cleanliness [goomysmash] put into the wiring and fitting everything inside the controller. But in case light mods aren’t your thing or you’re looking for other GameCube controller modifications, how about adding Bluetooth?

You are stuck at home quarantined and you want to do some Arduino projects. The problem is you don’t have all the cool devices you want to use. Sure, you can order them, but the stores are slow shipping things that aren’t essential these days. If you want to get a headstart while you are waiting for the postman, check out Wokwi’s Playground. For example, you can write code to drive a virtual NeoPixel 16×16 matrix. There’s even example code to get you started.

There are quite a few other choices in the playground including Charlieplexed LEDs, a keypad, and an LCD. There are also challenges. For example, in the traffic light challenge, you are given code that uses a task scheduler library to implement a traffic light. You have to add a turn signal to the code.

In addition to LEDs in various configurations, the site has some serial bus components, an LCD, a keypad, and a NeoPixel strip. There are also a few tools including an EasyEDA to KiCad converter and a way to share sourcecode similar to Pastebin.

Of course, simulations only get you so far, but the site is a fun way to play with some different I/O devices. It would be very nice if you could compose for the different components together, but you could work your code in sections, if necessary. You can do similar things with TinkerCad circuits. If you want to install software, there’s a simulator for you, too.

Like pretty much all of us, [Andy Schwarz] loves RGB LEDs. Specifically he likes to put them on RC vehicles, such as navigation lights on airplanes or flashers and headlights on cars. He found himself often rewriting very similar Arduino code for each one of these installations, and eventually decided he could save himself (and all the other hackers in the world) some time by creating a customizable Arduino firmware specifically for driving RGB LEDs.

The software side of this project, which he’s calling BitsyLED, actually comes in two parts. The first is the firmware itself, which is designed to control common RGB LEDs such as the WS2812 or members of the NeoPixel family. It can run on an Arduino Pro Mini with no problems, but [Andy] has also designed his own open hardware control board based on the ATtiny84 that you can build yourself. Currently you need a USBASP to program it, but he’s working on a second version which will add USB support.

With your controller of choice running the BitsyLED firmware, you need something to configure it. For that, [Andy] has developed a Chrome extension which offers a very slick user interface for setting up colors and patterns. The tool even allows you to create a visual representation of your LEDs so you can get an idea of what it’s going to look like when all the hardware is powered up.

RGB LEDs such as the WS2812 are some of the most common components we see in projects today, mainly because they’re so easy to physically interface with a microcontroller. But even though it only takes a couple of wires to control a large number of LEDs, you still need to write the code for it all. BitsyLED takes a lot of the hassle out of that last part, and we’re very interested to see what the hacker community makes of it.

The view from America has long seen French women as synonymous with thin and/or beautiful. France is well-known for culinary skill and delights, and yet many of its female inhabitants seem to view eating heartily as passé. At a recent workshop devoted to creating DIY amusements, [Niklas Roy] and [Kati Hyyppä] built an electro-mechanical sushi-eating game starring Barbie, American icon of the feminine ideal. The goal of the game is to feed her well and inspire a happy relationship with food.

Built in just three days, J’ai faim! (translation: I’m hungry!) lets the player satiate Barbie one randomly lit piece of sushi at a time. Each piece has a companion LED mounted beneath the surface that’s connected in series to the one on the game board. Qualifying sushi are determined by a photocell strapped to the underside of Barbie’s tongue, which detects light from the hidden LED. Players must race against the clock to eat each piece, taking Barbie up the satisfaction meter from ‘starving’ to ‘well-fed’. Gobble an unlit piece, and the score goes down.

The game is controlled with a lovely pink lollipop of a joystick, which was the main inspiration for the game. Players move her head with left and right, and pull down to engage the solenoid that pushes her comically long tongue out of her button-nosed face. Barbie’s brain is an Arduino Uno, which also controls the stepper motor that moves her head.

[Niklas] and [Kati] wound up using cardboard end stops inside the box instead of trying to count the rapidly changing steps as she swivels around. The first motor they used was too weak to move her head. The second one worked, but the game’s popularity combined with the end stops did a number on the gears after a day or so. Click past the break to sink your teeth into the demo video.

Barbie can do more than teach young girls healthy eating habits. She can also teach them about cryptography.



  • Newsletter

    Sign up for the PlanetArduino Newsletter, which delivers the most popular articles via e-mail to your inbox every week. Just fill in the information below and submit.

  • Like Us on Facebook