Infotainment system playing back from USB. (Folkert van Heusden)

Create Virtual USB Sticks With A Raspberry Pi Zero

Playing back music files from USB sticks is a common feature these days, and is built-into the infotainment system in [Folkert van Heusden]’s Opel Astra. Unfortunately such USB playback features often come with a range of limitations on things like audio codecs, and in the case of [Folkert]’s car, a 1000 file limit. This had him looking at an alternative to lugging a lot of USB sticks around to avoid the horror of hearing the same songs within a week while commuting. The solution? Make a Raspberry Pi Zero into a virtual USB mass storage device using the Mass Storage Gadget (MSG) driver in the Linux kernel.

Picking USB storage as the ideal option here comes mostly from the age of the infotainment system, which lacks Bluetooth, and the audio input jack is rather crackly. Of course, having the Raspberry Pi Zero pretend to be a storage device via the MSG driver wouldn’t solve the file limit, but to get around this two Python scripts were written: one which creates images from a folder of music files, and another which randomly picks one of the available images from the Zero’s SD card and configures the MSG driver to use it.

As for the list of future improvements, there is mounting the RPi Zero’s SD card as read-only to deal with the power-off when the car is shut down, and the creating of images requires to be run as root due to the use of loopback devices. As a Proof-of-Concept it does seem to be on the right track.

It’s not just the older infotainment systems that get to have all the fun. If you’re lucky enough to have Linux running in the dashboard, you might be little more than a Bash script away from bending the system to your will.

FLOSS Weekly Episode 772: Raspberry Pi From The Man Himself

This week, Jonathan Bennett and Elliot Williams talk with Eben Upton about the Raspberry Pi! The conversation covers the new Pi 5, the upcoming CM5, the possible Pi500, and the Initial Public Offering (IPO) that may happen before too long. There’s also the PCIe port, the RP1, and the unexpected effects of using Broadcom chips. And then we ask the Billion Dollar question: What’s the money from an IPO going to fund? New hardware, software upgrades, better documentation? Nope, and the answer surprised us, too.

Continue reading “FLOSS Weekly Episode 772: Raspberry Pi From The Man Himself”

DietPi Version 9.1: Now With Raspberry Pi 5 Support And More

DietPi recently released version 9.1, which among other changes includes new images for the Raspberry Pi 5, Radxa Rock 4 SE and NanoPi R5S/R5C & 6. The Radxa Rock 4 SE image was necessary because the Rock 4’s RK3399 SoC is subtly different from the RK3399-T’s SoC in terms of memory support, which prevents a Rock 4 image from booting on the Rock 4 SE. Meanwhile the Raspberry Pi 5 image is all new and still a bit rough around the edges, with features like the changing of the resolution and camera module support not working yet. These new images are all available for testing.

We covered DietPi previously with their 8.12 release, along with the reasons why you might want to use DietPi over Armbian and Raspberry Pi OS. Essentially DietPi’s main focus is on performance combined with a small installed size, with the included configuration tools and the setup allowing for many more features to be tweaked than you usually find. If the performance improvements, lower RAM usage and faster boot times seen with the Raspberry Pi 4 holds up, then DietPi can just give the Raspberry Pi 5 a nice little boost, while saving power in the process.

Thanks to [StephanStS] for the tip.

Sonolithography With The Raspberry Pi Pico

You can do some wild things with sound waves, such as annoy your neighbours or convince other road users to move out of your way. Or, if you get into sonolithography like [Oliver Child] has, you can make some wild patterns with ultrasound.

Sonolithography is a method of patterning materials on to a surface using finely-controlled sound waves. To achieve this, [Oliver] created a circular array of sixteen ultrasonic transducers controlled via shift registers and gate driver ICs, under the command of a Raspberry Pi Pico. He then created an app for controlling the transducer array via an attached computer with a GUI interface. It allows the phase and amplitude of each element of the array to be controlled to create different patterns.

Creating a pattern is then a simple matter of placing the array on a surface, firing it up in a given drive mode, and then atomising some kind of dye or other material to visualize the pattern of the acoustic waves.

It could be a useful tool for studying the interactions of ultrasonic waves, or it could just be a way to make neat patterns in ink and dye if that’s what you’re into. [Oliver] notes the techniques of sonolithography could also have implications in biology or fabrication in future, as well. If you found this interesting, you might like to study up on ultrasonic levitation, too!

Your Surface RT Can Become Useful Again, With Raspberry Pi OS

Over the years there have been so many times when Microsoft came up with a product that so nearly got it right, but which tanked in the market because the folks at Redmond had more of an eye to what fitted their strategy than what the customer wanted. The Surface RT was one of these: while the hardware was at least as good if not better than Apple’s iPad, its ARM CPU and an ill-advised signed-apps-only policy meant the tablet couldn’t access the huge existing library of Windows software.

Consumers didn’t want a tablet with next-to-no apps, so it failed miserably. Never mind though, because [Michael MJD] has a video showing how an RT can be given a new life from an unlikely source, with the installation of Raspberry Pi OS.

The video pretty closely follows this guide, and involves creating a Raspberry Pi OS install medium modified with RT-specific kernel modules and device tree. It’s possible because the 32-bit ARM architecture is one of those which Raspberry Pi OS targets, and while a few things such as graphics acceleration don’t work, it’s still successful (if a little slow).

Oddly this is a technique not unlike one from the earliest days of the Raspberry Pi, when we remember people in Raspberry Pi Jams showing off the ancestor of the modern OS running on cheap ARM-based netbooks. In those cases the hack relied on transplanting the Pi userland over the device’s existing kernel, we’d be interested in an explanation of how the RT can use the Pi kernel without the famous Broadcom BLOB intended for the Pi.

We have a soft spot for the RT, as we said a good product held back by a very bad software decision. Seeing it take a new life years later is thus pleasing to us.

Continue reading “Your Surface RT Can Become Useful Again, With Raspberry Pi OS”

Impressively Responsive Air Drums Built Using The Raspberry Pi Pico

Drum kits are excellent fun and a terrific way to learn a sense of rhythm. They’re also huge and unwieldy. In contrast, air drums can be altogether more compact, if lacking the same impact as the real thing. In any case, students [Ang], [Devin] and [Kaiyuan] decided to build a set of air drums themselves for their ECE 4760 microcontroller class at Cornell.

As per the current crop of ECE4760 projects, the build relies on the Raspberry Pi Pico microcontroller as the brains of the operation. The Pico is charged with reading the output of MPU6050 inertial measurement units mounted to a pair of drum sticks. The kick pedal itself simply uses a button instead.

Where the project gets really interesting, though, is in the sound synthesis. The build doesn’t simply play different pre-recorded samples for different drums. Instead, it uses the Karplus-Strong Drum Synthesis function combined with a wavetable to generate different sounds.

In the demo video, we get to hear the air drums in action, complete with a Stylophone playing melody. Unlike some toy versions that trigger seemingly at random with no rhythm, these air drums are remarkably responsive and sound great. They could be a great performance instrument if designed for the purpose.

We’ve seen similar builds before, too.

Continue reading “Impressively Responsive Air Drums Built Using The Raspberry Pi Pico”

Wii-Inspired Controller Built Using Raspberry Pi Pico

We all thought Nintendo was going to change the world of gaming when it released the Wii all those years ago. In the end, it was interesting but not really fundamentally life-changing for most of us. In any case, [Sebastian] and [Gabriel] decided to build a Wii-like controller for their microcontroller class at Cornell.

The build uses a pair of Raspberry Pi Pico microcontrollers, communicating over HC-05 Bluetooth modules. One Pico acts as a controller akin to a Wiimote, while the other runs a basic game and displays it on a screen via VGA output. The controller senses motion thanks to a MPU6050 inertial measurement unit, combining both gyros and accelerometers in all three axes.

The duo demonstrate the hardware by using it as a pointer to play a simple Tic-Tac-Toe game. It’s in no way going to light up the Steam charts, but the project page does go into plenty of useful detail on how everything was implemented. If you want to create your own motion gaming controller, you could do worse than reading up on their work.

We’ve seen some other great examples of motion controls put to good use, like this VR bowling game. Video after the break.

Continue reading “Wii-Inspired Controller Built Using Raspberry Pi Pico”