Compared to the old 8-bit Arduinos, it’s incredible how cheap modern microcontrollers like the ESP32 have become. But there are even cheaper options out there if you don’t need that kind of horsepower, and are willing to do a little work yourself, as [atomic14] demonstrates.
The CH32V003 is a dirt cheap microcontroller—which can reportedly be had for as little as 10 cents if you know where to look. It’s not the most powerful chip by any means, boasting just 16 K flash, and 2 K of SRAM. However, it is a 32-bit RISC V machine, and it does run at 48 MHz—giving it a leg up on many 8-bit parts that are still out there.
Surprisingly there aren’t a whole lot of CH32V003 products for the maker market, so if you want to play with it, you’ll probably need to spin up your own boards. [atomic14] does just that, showing us how the chip can be put to good use by turning it into a little musical trinket. It’s a fun demo, and a great way to get to grips with programming on a new microcontroller platform.
It’s hard to get more chiptune than a 10 cent chip beeping its little head off. How could possibly justify spending tens of dollars modding a Game Boy when this exists, even if it sounds like a caffeinated greeting card?
YTDW. It’s well within the capability of these micros to play RTTL, and there’s loads of music out there in that format.
https://rtttl.skully.tech/rtttl_specification
You guys aren’t going to believe it, but this seems to be BogdanTheGeek week:
https://github.com/BogdanTheGeek/ch32fun-audio
Something that might be of interest to anyone doing a similar project might be an old bit of DOS software called Muzak. It had .muz files that were plain text and stored the menus along with the songs themselves. The format was pretty easy to interpret. I wrote a few myself to extend it many years ago, but by default it came with around 100, if I recall correctly. No doubt it would save people the effort of trying to transcribe midi or wav. There were so many good little utilities back then. Many with clever programming tricks.
The CH570 is a newer similar MCU that costs the same.
The Bond Theme playing in the video gave me instant flashbacks to a very cool program on the Amiga, back in the day, Aegis Sonix, which had the same melody – in a similar-quality rendition! – as one of its demo tunes. This was the very early Amiga days, before the far more sophisticated Tracker programs and OctaMED and so on.