Two technologies that have taken the DIY world by storm are the Raspberry Pi and LED lights. Anyone can buy ready-to-use strips or panels and achieve a great number of effects, but the person behind the YouTube channel there oughta be decided to add an extra twist, or rather, a dimension: his LED cube not only presents an excellent 3D pattern, but also reports the processor load of a computer, with the help of a Raspberry Pi 2 and a bit of Python code.

Build an LED Cube That Monitors CPU Load
LED cube

The Panels and the Idea

A quick visit to online stores like eBay and AliExpress will reveal a range of LED panels that have basically exploded in popularity, thanks to the ability to connect them to a Raspberry Pi using a compatible HAT. With the right code, these panels (in 64x64 or 64x128 configurations) are capable of generating very attractive patterns while delivering relevant information to the user. But the best part is that you are not limited to a single panel. There are models with daisy chain support, and that raises an interesting question: What can we build with two or more panels?

Sebastian's Proposal

Sebastian from the there oughta be YouTube channel has a fabulous proposal: An LED cube that measures the CPU load of a computer. After participating in the Chaos Communication Congress 36 and seeing these panels in action as a cube, he decided to create a stationary variant. That enables two advantages: he can use three panels instead of six (reducing the final cost of the project) and it eliminates all the battery and charging circuitry.

Build an LED Cube That Monitors CPU Load
The panels are daisy-chained, but they need a very good power supply

Power and Raspberry Pi Choices

Another good decision is using a Raspberry Pi 2. Sebastian explains he already had one gathering dust, but it also offers the exact balance. Faster models generate extra heat inside the cube, and options like the Raspberry Pi Zero are too weak in terms of processing. The power supply is quite a challenge: Sebastian uses a 5V 10A unit, but under certain conditions (e.g., white LEDs at maximum brightness) it is not enough. His recommendation is to adopt a more powerful supply or to separate the Raspberry Pi's power.

Build an LED Cube That Monitors CPU Load
The cube, before its frame is printed

The Software Behind the Cube

However, the most complex element is the software, which transforms the cube into a CPU usage indicator. The computer loads a Python script as a systemd service, which sends the information to the Raspberry Pi configured with rpi-rgb-led-matrix and OpenGL enabled. Unfortunately, the solution is not exactly universal, and the code is likely to need modifications depending on the type of LED panels.

https://old.neoteo.com/un-bullet-time-de-bajo-costo-con-15-raspberry-pi/

The Final Display

The final result is a ring that occupies the three surfaces, and it changes both color and thickness. Blue means idle, green and yellow represent intermediate loads, and red shows the chip at 100 percent. As if that were not enough, the ring is divided into twelve sections, one for each thread, which modify their intensity according to usage.

Cost and More Information

In total, Sebastian invested less than 150 euros to build the cube, originally intended to be a lamp in his living room, but his wife exercised her veto power (!). That number does not include the filament used in 3D printing the frame or the cost of the Raspberry Pi 2. If you want to know more, check the link below.

More details can be found on the official project page.

https://old.neoteo.com/como-construir-un-controlador-midi-con-arduino/