A floppy-disk Walkman - using a Raspberry Pi


I have built the most inconvenient way of playing music! It is lo-fi awfulness and cyberpunk grungy.

Thanks! I hate it!

Ingredients

WHY?!?!

As I discussed yesterday, it's possible to fit half an hour of speech on a single floppy disk. The best band in the world are The Beatles, and their shortest album is A Hard Day's Night - at 30 minutes, 45 seconds. Beatles audio was designed to be played over crappy AM radio in mono, so is well suited to being compressed using the latest audio codecs.

OK, I also got sent a USB floppy drive to review and wanted to do something interesting with it!

Compress your audio

A floppy disk can hold a maximum of 1,457,664 Bytes.

Using the Opus Audio Codec, you can squish audio to miniscule file sizes.

I got a single WAV of the album, and ran this command - which is about the best quality within the target filesize:

opusenc hdn.wav --downmix-mono --bitrate 6.7 --framesize 60 --discard-comments --discard-pictures --cvbr hdn.opus

That got it down to a trim 1,429,105 bytes. Enough space left over for some low-resolution cover art!

A very tiny copy of the Hard Day's Night album cover.

You can shrink the audio by a few more bytes by using removing the default metadata from .opus files.

How does it sound?

The copyright for Hard Day's Night should have expired in 2014. Sadly, the law was changed in the UK in 2013. So it doesn't expire for another 14 years. Here are some samples which I am using for non-commercial research purposes. This, I hope, falls under the fair dealing exception.

🔊

Not much worse than fading medium-wave station, right? RIGHT!?

(I've re-encoded it to MP3 in order for it to play in the browser.)

Building It

Sadly, the Pi Zero doesn't have an an audio out jack. But the USB floppy drive is pretty big, so we don't lose much space by going for a full-sized Pi. The Pi has a weird combined video / audio jack. I powered it using a USB Battery.
A floppy disk with an album conver printed on it. It is about to be plugged in to a mishmash of electronics.

All held together with rubber-bands. Classy!

Here's a high tech block diagram:


🔋---→💻---→ 🎧 
      ↑
      |
      💾

Run these magic commands

I used Raspberry Pi OS Lite which doesn't have a desktop manager, and fits on a 4GB microSD card.

Set the audio output to go via the headphone jack:

sudo raspi-config

Then choose: Option 7 (Advanced Options), then A4 (Audio), then 1 (Headphones).

Set the headphone volume to 100% (or whatever you fancy):

amixer sset "Headphone" 100%

Make sure you have the Opus tools and codecs installed:

sudo apt install opus-tools

Make sure that the floppy disk has been detected:

dmesg

It will probably show us as sda - mount it with

sudo mount /dev/sda /mnt

Go to the directory with your audio in it:

cd /mnt

Decode the file and pass it through to aplay - this should start playing music straight through your headphones.

opusdec --force-wav --quiet hdn.opus - | aplay

ENJOY!

Notes

Depending on the speed of your drive, and the framesize of your audio, you may experience buffer-underruns. This will cause the audio to skip. Just like jogging with a CD Walkman!

I printed the album cover on a Bluetooth Thermal Printer.

A floppy disk with a low fidelity label of A Hard Day's Night.

ToDo

  • Build a circuit to let me press buttons to play, pause, and skip tracks.
  • Make it auto-play when the disk is inserted.
  • Use the Rockband Moggs to make acapella / vocal only disks. Should be better quality without the backing music.
  • 3D print a case so I can go jogging with it while wearing a shell suit.
  • Register a patent on the blockchain so people have to pay me a trillionth of a EdentCoin every time they play music using my brilliant invention.

Put your ideas in the comment box.

Thanks

Huge thanks to Alistair for sending me a bunch of old floppies to play with.

Enjoyed this post?

If you like the silly things I do, you can say thanks by:

Or, just leave a supportive comment.


Share this post on…

32 thoughts on “A floppy-disk Walkman - using a Raspberry Pi”

    1. says:

      I did think about using some of those non-standard formats, but I wasn't sure if I could get the Pi to read them.

      Reply
      1. David Sheldon says:

        Last time I looked at USB floppy drives, you couldn't use those formats as it was done in the USB controller, and want exposed to the system.

        Reply
    1. John Wood says:

      I used to love Mavica floppy cameras. I worked on a very fun pilot of selling rare books online from Oxfam shops using them. At the time we found it the easiest way for less technical shop volunteers to transfer the files they needed to put onto online auctions - the transfer software tools for most digital cameras at the time were horrid & needed installing on people's computers, and transfer leads of the time were much less standard or ubiquitous than floppy drives. But that was a rather niche need - it is indeed an awful idea for anything else 🙂

      Reply
  1. Andi Archer says:

    Talking of floppies did you ever see that Windows 95 on a floppy that was produced, it did sort of work visually but was really a linux derivative with a windows shell.

    Reply
    1. Erik Tomlinson says:

      I mean, Windows 95 did come on floppies... thirteen of them, formatted in that Microsoft Advanced Format or whatever it was called.

      One CD was much more convenient... and it had a Weezer music video on it!

      Reply
  2. Stuart Hall says:

    I especially like the red rubber bands, most commonly used by the Royal Mail because the degrade over time and therefore don't contaminate the ground when dropped. This means that they will unquestionably fail at some point (presumably when most inconvenient?) and make the whole thing just that little bit more annoying.

    Superb!

    Reply
  3. Amigiac says:

    Weirdly I did this on the Amstrad CPC6128 in the early 90's. And rediscovered my CPC at the weekend. The disk marked Music didn't survive the plastic box in the shed unfortunately. Ni ether did the CPC but I can and will rebuild it.

    Reply
  4. Karl says:

    So I built something like this using NodeJS, look at UDev rules for the ability to "autoplay"

    Reply
  5. said on www.recantha.co.uk:


    Terence Eden has created a device which will allow you to play music in what he calls the most inconvenient way possible. Labelled as “lo-fi awfulness and cyberpunk grungy”, this portable music player is a Raspberry Pi hooked up to a USB floppy drive and powered by a battery. Some command line operations allow him to squeeze a full album onto a 1.44MB floppy. Further commands allow him to read the floppy drive and pipe the music into his headphones. The audio quality is similar to a MW radio station and the audio will skip if the floppy drive buffers! It’s all very 1980s!
    You can read more over on his blog including his list of ideas of how to improve it, including taking it “on the road”. There are also some videos of the walkman in action!

    var bdfd = document.getElementsByClassName("bdfd");
    for (dfdb = 0; dfdb < bdfd.length; dfdb++) {
    bdfd[dfdb].style.display = "none";
    }
    Share this:FacebookTwitterRedditPinterestLinkedInTumblr

    <em>Related</em>

    Reply | Reply to original comment on www.recantha.co.uk
  6. said on blog.adafruit.com:

    via Terence Eden

    As I discussed yesterday, it’s possible to fit half an hour of speech on a single floppy disk. The best band in the world are The Beatles, and their shortest album is A Hard Day’s Night – at 30 minutes, 45 seconds. Beatles audio was designed to be played over crappy AM radio in mono, so is well suited to being compressed using the latest audio codecs.
    OK, I also got sent a USB floppy drive to review and wanted to do something interesting with it!

    Read more.Each Friday is PiDay here at Adafruit! Be sure to check out our posts, tutorials and new Raspberry Pi related products. Adafruit has the largest and best selection of Raspberry Pi accessories and all the code & tutorials to get you up and running in no time!

    Reply | Reply to original comment on blog.adafruit.com

Trackbacks and Pingbacks

  1. Der har været mange tvivlsomme bærbare musikafspillerformater gennem årene (kan nogen huske Iomega HipZip?), men Terence Edens hjemmebryggede Walkman, der afspiller hele album fra old-school 3,5-tommers disketter er et uklart mesterværk. Hvis du betragter dig selv som en lydfil, skal du straks se væk.
    Opbygning af Walkman selv var relativt let. Efter at have modtaget en grundlæggende TEAC USB diskettedrev til gennemgang, Eden besluttede at gøre noget andet end at smide det i skuffen til afdøde lagerformater. Han sluttede det til en Raspberry Pi i fuld størrelse, for hvad skal du ellers med et 3,5-tommers diskettedrev i år 2020? De mindre versioner af den miniature-pc mangler et hovedtelefonstik. Derefter tilsluttede han al hardware til et tykt bærbart batteri til strøm. Et par elastikker senere, den grimeste Walkman, du nogensinde har set, var fuldt funktionel og klar til at rocke.
    Den største udfordring ved dette hack var at montere et helt album på en diskettens dårlige 1,4 MB lagerplads. Til sammenligning kræver cd-kvalitetslyd ca. 10 MB lagring pr. Minut lyd, mens en MP3 i høj kvalitet kræver omkring 2 MB for det samme beløb. Det er grunden til, at Eden valgte The Beatles album En hård dags nat, der kun er 30 minutter og 45 sekunder lange. Startende med en enkelt WAV-fil af hele albummet brugte Eden Opus Interactive Audio Codec at komprimere alle 13 numre til kun 1.429.105 byte, hvilket efterlader en lille smule plads til albumcover.

    G / O Media kan få en kommission

    Hvis du nogensinde har lyttet til en station, der spiller musik på en AM-radio, der bare er lidt for langt væk fra udsendelsestårnet til perfekt at indstille signalet, så har du en grov idé om, hvordan The Beatles lyder som at spille gennem Edens diskettedisk Walkman. Komprimering og lydkvalitet er omtrent så dårlig som den kan blive (du kan høre eksempler på Edens websted), og i den nuværende form har afspilleren ingen dedikerede knapper til at springe spor over, hurtigt fremad eller endda pause i musikken. Der er meget plads til at forbedre dets fysiske æstetik og funktionalitet, men så længe disketter er det foretrukne medium her, er Edens trommehinder i en hård tur.

    .

  2. Im letzten Monat las ich folgende Texte und fand diese gut:
    The companies that help people vanish (bbc.com): Jedes Jahr entscheiden sich Menschen dafür, zu verschwinden und ihr Leben, ihre Arbeit, ihr Zuhause und ihre Familien aufzugeben. In Japan gibt es Unternehmen, die helfen, wenn sich jemand in Lufa auflösen will.
    Ned Batchelder: How to be helpful online (nedbatchelder.com): Jemandem online helfen zu wollen, ist gar nicht so einfach. Hier ein paar Tipps.
    100 Jahre altes Huhn: Der Zeit entzogen (taz.de): Die Autorin hat schon als Kind von einem vor 100 Jahren eingemachten Huhn in ihrer Familie gehört. Sie beschließt, der Geschichte nachzugehen. Hat nicht jede Familie so ein Ding im Keller, auch wenn’s kein Huhn ist.
    A floppy-disk Walkman – using a Raspberry Pi (shkspr.mobi): Wahrscheinlich die unpraktischst mögliche Möglichkeit unterwegs Musik zu hören. Aber so cool.
    taz-Recherche zu Drohmails: Wer steckt hinter „NSU 2.0“? (taz.de): Seit Jahren bekommen Menschen, die sich gegen rechts stellen, Morddrohungen vom „NSU 2.0“. Wer verschickt sie? Die Spur führt vor die Haustür eines Polizisten.
    Synchronized editing: the future of collaborative writing) (nature.com): Die Wissenschaft ins 21. Jahrhundert zerren. Bei zwei meiner letzten Publikationen (dazu später mehr) versuchen wir’s per Authorea und mit Manuscripts.io. Ich würde ja gerne mit manubot, aber das bleibt glaub’ ein Traum.
    The Wildest Insurance Fraud Scheme Texas Has Ever Seen (texasmonthly.com): Letzthin mit Gymerkollege Miklos darüber gesprochen. Flugunfälle machen um Versicherungsgeld abzuzügeln. Kann mensch machen.
    Why Did YouTubers Myka and James Stauffer Give Up Huxley? (thecut.com): Die YouTuber Myka und James Stauffer adoptierten ein Kind und teilten jeden Schritt des Prozesses auf YouTube. Nur den Schritt wie sie die Adoption auflösten nicht. Krass.
    Im Netz der Corona-Gegner (correctiv.org): Ungültige Atteste gegen die Maskenpflicht und ein vertrauliches Treffen mit Sachsens Ministerpräsident Kretschmer: Eine Recherche von CORRECTIV zeigt, wie ein bundesweites Netzwerk von Wissenschaftlern, Meinungsmachern und Anwälten versucht, die Corona-Maßnahmen zu untergraben.
    Sturm auf den Reichstag – Rotes Tuch vor der Herzkammer der Demokratie (derbund.ch): Was hat es mit den Reichsflaggen an den Corona-Demonstrationen auf sich? Und warum ist der Reichstag in Berlin ein derart aufgeladenes Symbol der deutschen Demokratie?
    The surreal art of ‘unnatural lighting’ (nationalgeographic.com): Eine fette Lampe auf ein Fluggerät binden und unglaubliche Fotos machen. So geht das.
    FedEx Bandwidth (what-if.xkcd.com): In anderem Zusammenhang (über den ‘Transport’ von mehreren TeraBytes von Tomographiedaten, dazu später mehr) mal wider darüber gesprochen. Unterschätze nie die Bandbreite eines Kombis voller Festplatten (oder so).
    They Told You Not To Reply (voices.washingtonpost.com): Was passiert eigentlich mit all den Emails die an ‘somethinghere@donotreply.com’ gehen? Sie landen bei Chet Faliszek.
    Rechtsextremer Techno: Raven für Deutschland (belltower.news): Immer wieder eignen sich Nazis Subkulturen an, um ihre faschistische Ideologie zu verbreiten. Auch die Technoszene ist dagegen nicht immun. Besonders anfällig dafür scheint das Subgenre „Dark Techno“ zu sein. Durch Codes und Symbole in der Ästhetik und Aufbereitung werden rechtsextreme Ideen normalisiert und der Nationalsozialismus verharmlost – verpackt als vermeintlich rebellische Provokation.
    Attila Hildmann und die Satire: Verstehen Sie Spaß? (faz.net): Wird Attila Hildmann von Angela Merkel bezahlt? Nach einem „Postillon“-Artikel muss der Vegankoch und Verschwörungstheoretiker seinen Fans erklären, was eine Satireseite ist. Einfach nur geil!
    Im letzten Monat sah ich folgende Videos und fand diese gut:
    [youtube https://www.youtube.com/watch?v=kHpXle4NqWI?version=3&rel=1&fs=1&autohide=2&showsearch=0&showinfo=1&iv_load_policy=1&wmode=transparent&w=700&h=394%5D
    Flashback zu Samstagmorgen-Trickfilmschauen
    [youtube https://www.youtube.com/watch?v=BkvEpoqFx6c?version=3&rel=1&fs=1&autohide=2&showsearch=0&showinfo=1&iv_load_policy=1&wmode=transparent&w=700&h=394%5DHenry Rollins über die wichtigste Entscheidung in seinem Leben.
    [youtube https://www.youtube.com/watch?v=IHW9ByMtfpI?version=3&rel=1&fs=1&autohide=2&showsearch=0&showinfo=1&iv_load_policy=1&wmode=transparent&w=700&h=394%5D
    Der Trailer zu The Climb.
    Der Film ist sehr sehenswert und war ein Grund mal wieder physisch in ein Kino zu gehen.
    Im letzten Monat hörte ich folgenden Podcast und fand diesen gut:
    Hunting Warhead (cbc.ca): Hunting Warhead ist ein unglaublich packender Podcast, der über 6 ca. stündige Episoden erzählt, wie ein Team aus Journalisten, Polizisten und ‘White Hat‘ Hacker einen Pädophilenring überführt haben und den Hauptakteur zur Verurteilung gebracht haben.
    Share this:Click to share on Twitter (Opens in new window)Click to share on Facebook (Opens in new window)

    <em>Related</em>

What links here from around this blog?

What are your reckons?

All comments are moderated and may not be published immediately. Your email address will not be published.Allowed HTML: <a href="" title=""> <abbr title=""> <acronym title=""> <b> <blockquote cite=""> <cite> <code> <del datetime=""> <em> <i> <q cite=""> <s> <strike> <strong> <p> <pre> <br> <img src="" alt="" title="" srcset="">