Skip to content

SaiIyer1/Walkman

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

10 Commits
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

🏴‍☠️ Walkman - Portable Music Player

A Raspberry Pi Zero 2W based portable music player with Pirate Audio HAT, featuring local playback, Spotify Connect, and a beautiful color display.

Walkman Walkman

✨ Features

  • 🎵 Local Music Playback - FLAC, MP3, WAV, M4A, OGG support via MPD
  • 🎧 Spotify Connect - Stream from any device (appears as "Walkman")
  • 📱 Web Interface - Upload and manage music at http://walkman.local:8000
  • 🎮 Physical Controls - 4 tactile buttons for playback control
  • 🖥️ 240×240 Color Display - Shows track info, artist, album, progress bar
  • 💤 Auto Sleep Mode - Saves battery after 10 minutes of inactivity
  • 🔋 Battery Powered - PiSugar 2 support (1200mAh)
  • 🔀 Auto Shuffle - Music loads and shuffles on boot
  • 📦 3D Printable Case - Custom designed enclosure included

🎯 Quick Start

One-Line Install

git clone https://github.com/SaiIyer1/walkman.git
cd walkman
chmod +x install.sh
./install.sh

The installer takes ~15 minutes and handles everything automatically!

🛠️ Hardware Required

Component Notes
Raspberry Pi Zero 2W Required (Zero W too slow)
Pirate Audio Headphone Amp From Pimoroni - includes display, DAC, buttons
PiSugar 2 1200mAh battery with pogo pins
MicroSD Card 16GB+ recommended
Standoffs M2.5 standoffs to protect SD card

Total Cost: ~£60-80

Where to Buy

📋 What Gets Installed

  • MPD - Music Player Daemon for local playback
  • Raspotify - Spotify Connect integration
  • Display Player - Shows track info with progress bar
  • Web Interface - Flask-based music manager
  • Auto-loader - Automatically loads music on boot
  • Systemd Services - Everything starts automatically

🎮 Controls

Physical Buttons

  • Button A (▶): Play / Pause
  • Button B (→): Next track
  • Button X (←): Previous track
  • Button Y (♪): Volume +5%

Web Interface

Access at http://walkman.local:8000

  • Upload music files (drag & drop)
  • Delete tracks
  • View library stats
  • Organize by folder (MP3, FLAC)

Spotify

  1. Open Spotify on your phone/computer
  2. Start playing music
  3. Tap the device icon
  4. Select "Walkman"
  5. Control from anywhere!

🔋 Battery Life

  • Active playback: ~6-8 hours (depends on volume)
  • Sleep mode: Display dims after 10 min inactivity
  • PiSugar LED: Shows battery level (press button for blinks)

📱 Adding Music

Via Web Interface (Easiest)

  1. Visit http://walkman.local:8000
  2. Drag and drop files
  3. Music auto-loads and plays!

Via SCP

# From your computer
scp -r /path/to/music/* walkman@walkman.local:~/music/

# On the Pi
ssh walkman@walkman.local
mpc update

Via USB Drive

# On the Pi
sudo mkdir /mnt/usb
sudo mount /dev/sda1 /mnt/usb
cp /mnt/usb/music/* ~/music/
sudo umount /mnt/usb
mpc update

🏗️ Assembly

Step 1: Flash SD Card

Use Raspberry Pi Imager:

  • OS: Raspberry Pi OS Lite (64-bit)
  • Configure: Hostname, SSH, WiFi, username

Step 2: Run Installer

git clone https://github.com/SaiIyer1/walkman.git
cd walkman
./install.sh

Step 3: Stack Hardware

Assembly order (bottom to top):
1. PiSugar 2 (battery board)
2. Raspberry Pi Zero 2W (pogo pins connect)
3. Pirate Audio HAT (use standoffs!)

⚠️ IMPORTANT: Use standoffs between Pi and Pirate Audio to prevent bending the SD card!

Step 4: Install in Case

See case/README.md for 3D printing instructions.

📦 3D Printable Case

Included in the case/ directory!

  • Material: PLA or PETG
  • Print Time: ~3 hours
  • Supports: None needed
  • Features: Embossed logo, full button access, port cutouts

See case/README.md for details.

🔧 Troubleshooting

Display Not Working

# Check SPI
ls /dev/spi*

# Re-enable if needed
sudo raspi-config nonint do_spi 0
sudo reboot

No Audio

# Check audio device
aplay -l
# Should show: card 1: sndrpihifiberry

# Check config
grep hifiberry /boot/firmware/config.txt

# Restart services
sudo systemctl restart mpd raspotify

Buttons Not Working

# Check display player service
sudo systemctl status walkman

# View logs
sudo journalctl -u walkman -f

Web Interface Not Loading

# Check web service
sudo systemctl status walkman-web

# Restart it
sudo systemctl restart walkman-web

Music Doesn't Auto-Load

# Check auto-loader service
sudo systemctl status mpd-autoload

# Manually run it
~/walkman/mpd-autoload.sh

🎨 Customization

Change Device Name

Edit /etc/raspotify/conf:

LIBRESPOT_NAME="Your Name Here"

Adjust Sleep Timeout

Edit src/walkman_player.py:

SLEEP_TIMEOUT = 600  # Change to desired seconds

Change Volume Increment

Edit src/walkman_player.py, find Button Y handler:

new_vol = min(100, info['volume'] + 10)  # Change +5 to +10

📁 Repository Structure

walkman/
├── install.sh              # Automated installer
├── mpd-autoload.sh        # Auto-loads music on boot
│
├── src/
│   ├── walkman_player.py  # Display player with sleep mode
│   └── web_manager.py     # Web interface (Flask)
│
├── templates/
│   └── index.html         # Web UI template
│
├── case/
│   ├── README.md
│   └── Walkman_Case_no_lid_v1.3mf
│
└── README.md              # This file

🤝 Contributing

Contributions welcome! Feel free to:

  • 🐛 Report bugs
  • 💡 Suggest features
  • 🔧 Submit pull requests
  • 📷 Share your builds!

📜 License

MIT License - See LICENSE

🙏 Credits

🏴‍☠️ Show Off Your Build!

Built your own Walkman? Share it!

  • Tag #WalkmanPi on social media
  • Open an issue with photos
  • Submit a PR with your customizations

Made with ❤️ for music lovers and makers everywhere 🎵

Happy listening! 🏴‍☠️

About

Portable music player with Raspberry Pi Zero 2W

Topics

Resources

License

Stars

Watchers

Forks

Releases

No releases published

Packages

 
 
 

Contributors