Rocket Roll Control, The Old Fashioned Way

The vast majority of model rockets go vaguely up and float vaguely downwards without a lot of control. However, [newaysfactory] built a few rockets that were altogether more precise in their flight, thanks to his efforts to master active roll control.

[newaysfactory] started this work a long time ago, well before Arduinos, ESP32s, and other highly capable microcontroller platforms were on the market. In an era when you had to very much roll your own gear from the ground up, he whipped up a rocket control system based around a Microchip PIC18F2553. He paired it with a L3G4200D gyro, an MPXH6115A barometer, and an MMA2202KEG accelerometer, chosen for its ability to provide useful readings under high G acceleration. He then explains how these sensor outputs were knitted together to keep a rocket flying straight and true under active control.

[newaysfactory] didn’t just master roll control for small rockets; he ended up leveraging this work into a real career working on fully-fledged autopilot systems. Sometimes your personal projects can take your career in interesting directions.

Continue reading “Rocket Roll Control, The Old Fashioned Way”

2025 Component Abuse Challenge: An Input Is Now An Output

Part of setting up a microcontroller when writing a piece of firmware usually involves configuring its connections to the outside world. You define a mapping of physical pins to intenral peripherals to decide which is an input, output, analogue, or whatever other are available. In some cases though that choice isn’t available, and when you’ve used all the available output pins you’re done. But wait – can you use an input as an output? With [SCART VADER]’s lateral thinking, you can.

The whole thing takes advantage of the internal pull-up resistor that a microcontroller has among its internal kit of parts. Driving a transistor from an output pin usually requires a base resistor, so would it be possible to use the pullup as a base resistor? If the microcontroller can enable or disable the resistor on an input pin then yes it can, a transistor can be turned off and on with nary an output to be seen. In this case the chip is from ATmega parts bin so we’re not sure if the trick is possible on other manufacturers’ devices.

As part of our 2025 Component Abuse Challenge, this one embodies the finest principles of using a part in a way it was never intended to be used, and we love it. You’ve still got a few days to make an entry yourself at the time of writing this, so bring out your own hacks!

Speech Synthesis On A 10 Cent Microcontroller

Speech synthesis has been around since roughly the middle of the 20th century. Once upon a time, it took remarkably advanced hardware just to even choke out a few words. But as [atomic14] shows with this project, these days it only takes some open source software and 10-cent microcontroller

The speech synth is implemented on a CH32V003 microcontroller, known for its remarkably low unit cost when ordered in quantity. It’s a speedy little RISC-V chip running at 48 MHz, albeit with the limitation of just 16 KB of Flash and 2 KB of SRAM on board.

The microcontroller is hooked up to a speaker via a simple single-transistor circuit, which allows for audio output. [atomic14] first demonstrates this by having the chip play back six seconds of low quality audio with some nifty space-saving techniques to squeeze it into the limited flash available. Then, [atomic14] shows how he implemented the Talkie library on the chip, which is a softwarehttps://www.youtube.com/watch?v=RZvX95aXSdM implementation of Texas Instruments’ LPC speech synthesis architecture—which you probably know from the famous Speak & Spell toys. It’s got a ton of built in vocabulary out of the box, and you can even encode your own words with some freely available tools.

We’ve seen [atomic14] tinker with these chips before, too.

Continue reading “Speech Synthesis On A 10 Cent Microcontroller”

10 Cent Microcontroller Makes Tracker Music

We are absurdly spoiled these days by our microcontrollers. Take the CH32V00X family– they’ve been immortalized by meme as “the ten cent micro” but with a clock speed of 48MHz and 32-bit registers to work with, they’re astoundingly capable machines even by the standards of home computers of yore. That’s what motivated [Tim] to see if he could use one to play MOD files, with only minimal extra parts– and quite specifically no DAC.

Well, that’s part of what motivated him. The other part was seeing Hackaday feature someone use a CH32V003 making chiptune-like beeps. [Tim] apparently saw that post as a gauntlet thrown down, and he picked it up with an even smaller chip: the CH32V002, which he proceeded to turn into a MOD player. For those of you who slept through 80s and early 90s (or for those precocious infants reading this who hadn’t then yet been born), MOD files are an  electronic music format, pioneered on the Amiga home computers. Like MIDI, the file specifies when to play specific voices rather than encoding the sound directly. Unlike MIDI, MOD files are self-contained, with the samples/voices used being stored inside the file. The original version targeted four-channel sound, and that’s what [Tim] is using here.

As you can see from the demo video, it sounds great. He pulled it off by using the chip’s built-in PWM timer. Since the timer’s duty cycle is determined by a variable that can be changed by DMA, the CPU doesn’t end up with very much to do here. In the worst case, with everything in flash memory instead of SRAM, the CPU is only taxed at 24%, so there’s plenty of power to say, add graphics for a proper demo. Using the existing MODPlay Library, [Tim]’s player fits into 4kB of memory, leaving a perfectly-usable 12kB for the MOD file. As far as external components needed, it’s just an RC filter to get rid of PWM noise.

[Tim] has put his code up on GitHub for anyone interested, and has perhaps inadvertently cast down another gauntlet for anyone who wants to use these little RISC V microprocessors for musical tasks. If you can do better, please do, let us know.

Continue reading “10 Cent Microcontroller Makes Tracker Music”

There's an ATMega88 in that handsome case.

Give ATMega88 The Boot With This Retro Front Panel

It’s a truism that a computer must boot before it begins to operate. Nowadays that bootstrapping process is automatic, but in the case of the very first home computers, it was very much a hands-on affair. That’s what all those switches and blinkenlights are for on the front panel of the Altair 8800 — laboriously flicking each bit into memory as required to get your program going.

[Linus Åkesson] missed those very early days, and wanted to see what it was like, and clicking virtual switches on an emulator wasn’t going to cut it. He realized that he could set up an ATmega88 for front-panel booting, and proceeded to do just that.

The article linked above goes into good detail; for those of you who prefer video, we’ve embedded his presentation below.  They say the book is always better, but to get the full story, you’ll really want both in this case. The video contains a lot more context and build details, but neglects to mention some issues he had with programming that are detailed in the text. In short, the Write Page bit needs to be written to the Command register to use the page buffer. Which does make sense, but tripped [Linus] up at first.

Then again, this use case isn’t exactly detailed in the datasheet. ATmega88 is an old chip, but not Intel 8008 old, so that’s no surprise. Which is exactly what makes this a good hack! The only thing lacking is blinkenlights to allow one to see the contents of the registers. [Linus] discusses the idea of putting them in, but is apparently happy with this more minimalist approach.

We’ve seen the doughty Atmel chip hacked into everything from web-servers to washing machines, and even things that don’t start with “W”. As for the redoubtable [Linus], he’s most famous around these parts for his musical inventions and adventures with the Commodore 64Continue reading “Give ATMega88 The Boot With This Retro Front Panel”

10 Cent Microcontroller Makes Music

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?

Continue reading “10 Cent Microcontroller Makes Music”

Making A Clock With A Retooled Unihiker K10

The Unihiker K10 is intended to be a small single-board solution for light AI and machine learning tasks. However, you don’t have to use it in that way if you don’t want to. [mircemk] figured out how to repurpose the device, and whipped up a simple Internet clock build to demonstrate how it’s done. 

While the Unihiker K10 is based on the common ESP32 microcontroller, out of the box, it isn’t compatible with standard Arduino libraries. However, [mircemk] had previously figured out how to get the K10 to play nice with the Arduino environment, building a simple light meter as a proof of concept. It just took a little tinkering to get everything playing nicely together, but soon enough, the TFT LCD and a light sensor were playing nicely with the K10 platform.

Moving forward, [mircemk] wanted to unlock more capability, so set about figuring out how to get WiFi and the onboard buttons working within the Arduino environment. A great way to test this was building a clock—the screen would show an analog clock face, the buttons would be used for control, and the WiFi would be used to query an NTP time server to keep it synced up and accurate.

It took a little work, particularly as the buttons are accessed through an external I/O expansion chip, but [mircemk] got there in the end. The clock may not be a particularly advanced project, but the write-up demonstrates how the K10 can readily be used with Arduino libraries for when you’re not interested in leveraging its fancier AI/ML capabilities.

We’ve seen a few good builds from [mircemk] before, too, like this neat proximity sensor. Continue reading “Making A Clock With A Retooled Unihiker K10”