There is more than a casual link between computer people and musicians. Computers have created music since 1961 when an IBM7094 sang the song Daisy Bell (later inspiring another computer, the HAL 9000, to do the same).
[Vinod.S] wanted to create music on an STM32F407 Discovery board, but he also wanted it to play on his FM radio. He did it, and his technique was surprising and straightforward. The key is that the ARM processor on the Discovery board uses an 8MHz crystal, but internally (using a phase-locked loop, or PLL) it produces a 100MHz system clock. This happens to be right in the middle of the FM radio band. Bringing that signal back out of the chip on a spare output pin gives you the FM carrier.
That’s simple, but a carrier all by itself isn’t sufficient. You need to FM modulate the carrier. [Vinod.S] did the music playback in the usual way and fed the analog signal via a resistor to the crystal. With some experimentation, he found a value that would pull the crystal frequency enough that when multiplied up to 100MHz, it would produce the desired amount of FM deviation. You can see a video of the whole thing in action, below.
Surprisingly, even this isn’t a new idea. Back in the early days of computers, it was well known that AM radios would pick up noise from an operating computer and that the right program could produce music. There’s an article about doing just that on an old Altair (although the technique predates that) and even a video of the same. Speaking of videos, there is a video of the IBM computer that would go on to inspire HAL to sing from 1961.
We cover a lot of music-oriented projects, including ones that make music humans can’t. There are plenty of regular projects, too. One word of caution: spewing out 100 MHz signals from your microcontroller might not put you on the good side of your country’s radio regulatory agency. We’d be careful designing something like this into a real product unless you were sure you knew you could pass the legal test.