Just In Time For Christmas! A DIY Desktop LED Tree

Okay, we haven’t even hit Halloween yet, but if you’re planning some kind of holiday project, now’s a good time to start ordering your parts, especially if you’re designing your own PCB. While there’s no PCB involved, [designer2k2] built a desktop “hollow” Christmas tree using some WS2812 RGB LEDs controlled by a microcontroller and powered by USB.

The board running [designer2k2]’s project is a Digispark, a USB powered board by Digistump which contains an ATtiny85. The LEDs, four different sized NeoPixel rings, plus a single pixel for the top, are connected together using some solid wire which makes for a very cool look. The code that runs on the ATtiny is the part that really makes this tree. The code cycles through colors and some light chaser effects, as well as a mode that shows a green tree with some white lights. The whole project is topped off by a routine that spells “XMAS” as you look at the tree from the top down.

We’ve seen some other Christmas tree hacks over the years controlled by various things, but this one is a fairly simple, cool design. [Designer2k2] also released the code for the tree and I’m sure a lot of us could come up with some more light designs.

Check out the video after the break:

Continue reading “Just In Time For Christmas! A DIY Desktop LED Tree”

Minimal Computer And Operating System: One Button, One LED

DUO BINARY is a very, very small computer system in every possible sense. It runs on an ATtiny84, which has even got “tiny” in its name. The user interface is a single button for data entry and a single LED for feedback, making this binary keyboard look frivolously over-complicated. It uses a devilish chimera of Morse code and a truncated ASCII to enter data, and the LED blinks the same back at you.

We’re guessing that [Jack Eisenmann] is the only person in the world who can control this thing, and you can watch him doing so in the video embedded below. Continue reading “Minimal Computer And Operating System: One Button, One LED”

A Real Turn Off

[Newbrain] had a small problem. He’d turn off the TV, but would leave the sound system turned on. Admittedly, not a big problem, but an annoyance, none the less. He realized the TV had a USB port that went off when it did, so he decided to build something that would sense when the USB port died and fake a button press into the amplifier.

He posted a few ideas online and, honestly, the discussion was at least as interesting as the final project. The common thread was to use an optoisolator to sense the 5 V from the USB port. After that, everyone considered a variety of ICs and discretes and even did some Spice modeling.

In the end, though, [Newbrain] took the easy way out. An ATtiny 84 is probably overkill, but it easy enough to press into service. With only three other components, he built the whole thing into a narrow 24-pin socket and taped it to the back of the audio unit’s wired remote control.

Continue reading “A Real Turn Off”

Raspberry Pi Plays All That Jazz

[James Bellafaire] wanted a good looking old radio with a modern sound. Granted, you could hollow the case out and replace it with an iPod. Or you could convert the thing to an Internet radio. But where’s the fun in that?

[James] took a different approach. Part woodworking project, part Raspberry Pi project, and part microcontroller project, he wound up with a hard drive-based music player in a 1930’s case with knobs that control the playback.

Continue reading “Raspberry Pi Plays All That Jazz”

How I²C EEPROM Talks To The Bus

You will probably be familiar with I²C, a serial bus typically used for not-very-fast communication with microcontroller peripherals. It’s likely though that unless you are an I²C wizard you won’t be intimately familiar with the intricacies of its operation, and each new device will bring a lengthy spell of studying data sheets and head-scratching.

If the previous paragraph describes you, read on. [Clint Stevenson] wrote a library for interfacing I²C EEPROMs to Arduino platforms, and when a user found a bug when using it on an ATtiny85, he wrote up his solution. The resulting piece is a clear explanation of how I²C EEPROMs talk to the bus, the various operations you can perform on them, and the overhead each places on the bus. He then goes on to explain EEPROM timing, and how since it takes the device a while to perform each task, the microcontroller must be sure it has completed before moving to the next one.

In the case of [Clint]’s library, the problem turned out to be a minor incompatibility with the Arduino Wire library over handling I²C start conditions. I²C has a clock and a data line, both of which are high when no tasks are being performed. A start condition indicates to the devices on the bus that something is about to happen, and is indicated by the data line going low while the clock line stays high for a while before the clock line starts up and the data line carries the I²C command. He’s posted samples of code on the page linked above, and you can find his library in his GitHub repository.

If you want to know more about I²C, take a look at Hackaday Editor [Elliot Williams’] masterclasses on the subject: What could go wrong, I²C edition, and Embed With Elliot, I²C bus scanning.

Serial EEPROM die picture, By Epop (Own work) [CC0], via Wikimedia Commons.

Bluetooth HID Gamepad And HC-05 Serial Hack

“Which came first, the chicken or the egg?” Don’t bother us with stupid questions, they both co-evolved into the forms that we now serve up in tasty sandwiches or omelets, respectively. “Which came first, the HC-05 serial-flash-hack, or the wireless Bluetooth Gamepad?” Our guess is that [mitxela] wanted to play around with the dirt-cheap Bluetooth modules, and that building the wireless controller was an afterthought. But for that, it’s a well-done afterthought! (Video below the break.)

It all starts with the HC-05 Bluetooth module, which is meant to transfer serial data, but which can be converted into a general-purpose device costing ten times as much with a simple Flash ROM replacement. The usual way around this requires bit-banging over a parallel port, but hackers have worked out a way to do the same thing in bit-bang mode using a normal USB/Serial adapter. The first part of [mitxela]’s post describes this odyssey.

Continue reading “Bluetooth HID Gamepad And HC-05 Serial Hack”

New Part Day: ATtiny102 And 104

Atmel put out some new, small microcontroller chips early this year, and we’re just now starting to think about how we’d use them. The ATtiny102 and ATtiny104 (datasheet) sell for about a buck (US) and come in manageable SOIC packages with eight and fourteen pins respectively. It’s a strange chip though, with capabilities that fit somewhere between the grain-of-rice-sized ATtiny10 and the hacker-staple ATtiny25-45-85 series.

The ATtiny104 has a bunch of pins for not much money. It’s got a real hardware USART, which none of the other low-end AVRs do, and it’s capable of SPI in master mode. It has only one counter, but it’s a 16-bit counter, and it’s got the full AVR 10-bit ADC instead of the ATtiny10’s limited 8-bit ADC. The biggest limitation, that it shares with the ATtiny10, is that it has only 1 KB of program flash memory and 32 bytes (!) of RAM. You’re probably going to want to program this beast in assembler.

Read on for more reviews, and check out [kodera2t]’s video review at the end.

Continue reading “New Part Day: ATtiny102 And 104”