A smart NFC-based music player for toddlers. Place a toy on the pedestal, and the matching Spotify song plays automatically.
Inspired by Tonie Box. Built for Jamie.
- NFC tags are embedded in small toys
- A Raspberry Pi with an NFC reader detects which toy is placed on the pedestal
- The Pi looks up the tag-to-song mapping and triggers Spotify playback
- Parents manage mappings through a web app
| Component | Tech |
|---|---|
| Brain | Raspberry Pi 4 |
| NFC Reader | PN532 (I2C) |
| Backend | Python / FastAPI |
| Frontend | Next.js / Tailwind |
| Database | SQLite |
| Music | Spotify Premium + Raspotify |
See Hardware Guide for shopping list and wiring.
# Backend
cd backend
python3 -m venv .venv && source .venv/bin/activate
pip install -e ".[dev]"
cp .env.example .env # Fill in Spotify credentials
uvicorn app.main:app --reload
# Frontend
cd frontend
npm install
npm run devgit clone <repo> ~/music-box
cd ~/music-box
./scripts/pi-setup.sh- Go to https://developer.spotify.com/dashboard
- Create an app, get Client ID and Secret
- Add
http://<pi-ip>:8000/callbackas a Redirect URI - Copy credentials to
backend/.env - Visit
http://<pi-ip>:8000/auth/loginto authenticate