VinylPi is a Raspberry Pi project that listens to audio from a turntable, identifies the currently playing song using ShazamIO, fetches album metadata and artwork, generates a 64×64 pixel frame, and displays it on a Divoom Pixoo. It also features a webapp with a dashboard and settings.
Important: Hardware-specific implementation
I built this project specifically for my own hardware setup:
If you use different hardware, you will most likely have to modify parts of the code, like:
- turntable without USB: you will need a soundcard or USB microphone on your pi
- other pixel display: you need to modify the Divoom API calls
- Auto-detects USB audio device
- USB audio capture from turntable
- Automatic music recognition using ShazamIO
- Album cover retrieval
- Custom 64×64 pixel renderer
- centered album cover
- custom pixel font
- dynamic/manual background and text font
- marquee text for long titles/bands
- fallback image
- Send results to pixel diplay
- local WebApp:
- dashboard with current song, lyrics and switch (on/off)
- settings: configure vinylpi
- pixoo: configure your divoom pixoo
- statistics: keeps track of your listened minutes, songs, artists and albums
- about: support me :)
- I recommend using Raspberry Pi OS Lite (64-bit) for best performance (again I am using the Raspberry PI zero 2 w).
- Flash it using the official Raspberry Pi Imager.
- Enable SSH during flashing.
- Boot the Pi and connect via SSH:
ssh user@hostnamegit clone https://github.com/simontrost/VinylPi64.git
cd VinylPi64hint: you might need to sudo apt install git first
python3 -m venv venv
source venv/bin/activatehint: you might need to sudo apt install -y python3-venv python3-devfirst
pip install -r requirements.txthint: you might need to pip install --upgrade pip first
arecord -l
eg: 0 USB AUDIO CODEC: Audio (hw:0,0), ALSA (2 in, 2 out)
hint: you might also want to get ffmpeg sudo apt install ffmpeg
If you don't want to use the web interface, you will have toi edit the config manually
nano config.jsonwith active env:
python vinylpi/dashboard.pyhint: you can start the actual music detection from the webapp: http://vinylpi.local:8080/or via python vinylpi/main.py
create a file:
sudo nano /etc/systemd/system/vinylpi.servicewith the following content and adjust the username and paths
[Unit]
Description=VinylPi Dashboard
After=network-online.target
Wants=network-online.target
[Service]
User=pi
WorkingDirectory=/home/pi/VinylPi64
#ExecStart=/home/pi/VinylPi64/venv/bin/gunicorn --bind 0.0.0.0:5000 vinylpi.dashboard:app
ExecStart=/home/simon/VinylPi64/venv/bin/python3 -m vinylpi.web.dashboard
Restart=on-failure
[Install]
WantedBy=multi-user.targetSave and exit. You can decide if you really nead a gunicorn server, for my purpose it's not really needed.
If you do want to use gunicorn, make sure you install it via pip install gunicorn
sudo systemctl daemon-reload
sudo systemctl enable vinylpi.service
sudo systemctl start vinylpi.servicehint: check with sudo systemctl status vinylpi.service (should be "active (running)")
if something is not working check
journalctl -u vinylpi.service -fCreative Commons Attribution–NonCommercial 4.0
Full license text: https://creativecommons.org/licenses/by-nc/4.0/legalcode.txt




