A RISC-y Undertaking

Creative engineer bitluni built a 256-core supercluster of dirt-cheap CH32V003 RISC-V microcontrollers with lots of LEDs, because why not.

Nick Bild
24 days agoUpcycling
Now that's what I call blinkenlights! (📷: bitluni)

Computing power is being squeezed into smaller and less expensive packages all the time. Not long ago, hardware hackers were drooling over moderately powerful microcontrollers that could be had in single unit quantities for around a dollar. Now similar chips are available for just a few cents. At that price, one can order hundreds of them for a few tens of dollars. That temptation is just too great to pass up, leading many hobbyists to fill their spare parts bins with trays of these microcontrollers, because surely they will be sorely needed at some unknown point in the future, just like all of those other unused parts … right?

Engineer and electronics hobbyist bitluni found a use for large quantities of the CH32V003 RISC-V microcontroller that is very popular these days, in large part because they can be purchased for a few pennies. Previously, bitluni built a supercluster consisting of 16 CH32V003 chips, connected by an 8-bit data bus, and a carrier board to break out the GPIOs to headers. Sure, that is pretty cool, but only 16? Is that the best you can do?

Many of us are familiar with bitluni’s past work, and of course the answer to that question is “no.” That initial work was expanded upon to create a 256-core RISC-V supercluster. You heard that right ― 256 CH32V003 chips clustered together. The basic idea was to take the existing 16-chip supercluster board and tile it. By connecting 16 of these boards together, a total of 256 chips would be available for compute jobs.

Scaling up can be a funny thing, however. 16 processors might be able to share a common bus without issue, but when you put 256 processors on the bus, things get real busy real fast. So to avoid constant collisions and likely electrical issues, bitluni designed some secondary boards to break the data bus into segments.

The individual superclusters were hooked into boards called cluster blades to keep their buses separate. This cluster blade had its own microcontrollers to manage these individual buses and move the traffic to a second 8-bit bus. The cluster blade buses were then all hooked up to another board called the mega cluster blade. All of the buses, under the control of another microcontroller, were then made accessible via USB so that external systems could access the chips.

But after firing the system up for the first time, it quickly became clear that it was not working as designed. As it turns out, bitluni forgot to add a command line to one of the buses, which is the mechanism through which a processor requests access to the bus. Making new PCBs and assembling everything again would have been a huge pain, but bitluni noticed that the clock signal was only used when a chip was accessing the bus, so this signal was repurposed to also serve as the command line.

That did the trick, and the massive cluster of cheap chips was up and running. In total, the cluster consisted of 256 RISC-V 48MHz compute chips, 17 additional RISC-V chips running at 144MHz for support functions, and 640 GPIO pins. What can such a cluster be used for? Well, that is still up in the air. So far, bitluni has used it to blink a whole lot of LEDs. Sometimes it is more about the journey than the destination.

Nick Bild
R&D, creativity, and building the next big thing you never knew you wanted are my specialties.
Latest articles
Sponsored articles
Related articles
Latest articles
Read more
Related articles