Converting a hexdump to binary, SoundPlay on BeOSby Ben
I recently inherited an old machine with a 150 MHz AMD K6-2 CPU and 32 MB RAM. That’s a really meager machine, even for the time it was built (circa 1999).
I was planning to just donate it to Goodwill Reboot… but before I did, I wondered what I could possibly do with it. My first computer was a 133 MHz Pentium with maybe 32 or 64 MB of RAM, so there was a certain sentimentality for a machine like it. It had Windows 98 installed, which was interesting but only in passing. (I sold the install CD on Amazon for $20 surprisingly). Win98 was depressingly slow. I tried a semi-modern, lightweight Linux (a 2005 release of Damn Small Linux), and it wasn’t much better.
As I’ve mentioned before, I was a fan of the BeOS back in the day. It had a great ability to squeeze an amazing amount of power out of meager hardware. Scot Hacker definitely nailed it when he wrote that “anyone who has spent time with BeOS is forever spoiled, their expectations for OS technology permanently affected.” (Although I mostly use Ubuntu now, I also landed on Mac OS X after BeOS like Scot. In comparison to BeOS, OSX is incredibly resource hungry, albeit providing plenty of charm.)
So I had to try BeOS on the machine too. It was surprisingly easy to get the free version of BeOS R5 installed. That was especially meaningful to me, since I’ve never gotten BeOS working in VirtualBox; apparently there are some rarely used features of the x86 architecture that BeOS depends on. After getting the OS installed, it really wasn’t much more work to get SoundPlay — an MP3/Vorbis player — up and running. It runs incredibly fast for 150MHz/32MB. I could play music and even write a little Ruby in Vim at the same time.
So for now, the box is reborn as a BeOS-powered jukebox down in the basement. An appropriate use, given the place that music and this particular OS have had in my life. Is it woefully outdated? Yes. But this was really more of a sentimental journey than anything, and it can actually do something useful.
I was pretty happy until I realized that SoundPlay would stop working in 30 days.
I figured it must have been given away for free by this point. And my intuition was correct:
I’m no longer accepting SoundPlay registrations, but you can download a free keyfile here. Copy to /boot/home/config/settings, then restart SoundPlay.
…but the keyfile mentioned on SoundPlay’s website (currently down, but available on the Wayback Machine) wasn’t there.
I’d gotten this far, so I figured I’d see if I could find it elsewhere.
Within the first page of Google results, I found someone who posted their keyfile (which also gave a 404). Thankfully, a kind soul had the insight to post a hexdump of that file.
So close, I could almost touch it! I did a little more research and found a command to reconstitute it as a binary file.
# xxd v1.10 was already installed on my Ubuntu 12.04 machine xxd --revert keyfile.soundplay.hexdump keyfile.soundplay
For whatever reason, I had to do a little adjustment by hand before I was able to run the command. Basically this:
00000000 2b 9b 18 5f 0e 51 23 4e c2 44 16 b8 aa 6c 7e e0 |+.._.Q#N.D...l~.|
00000000: 2b9b 185f 0e51 234e c244 16b8 aa6c 7ee0
(I’ve posted the reformatted file below.)
At the end of this adventure, I now have a simple jukebox built out of SoundPlay and BeOS R5. Since others were nice enough to share and get me to this point, I figured I should do the same.
So here you go, Internet:
- SoundPlay 4.9.3 (Intel) (only tested on BeOS R5)
- keyfile.soundplay (goes in
- keyfile.soundplay.hexdump (reformatted hexdump)
(Note, I’m not claiming copyright; I’m just archiving what the author had already made available as shareware, and then freeware. Please notify me if you own this and would like it to be taken down.)
I know I’m not the only one who still has a soft spot for BeOS, so I’d be happy to know this helped someone else. (Please leave a comment!)
Charming story of hardware revival and software nostalgia by @benjaminoakes: http://t.co/iNrJYfOGmp
— Dan Bernier (@danbernier) March 11, 2014