A Python + Node.js music player driven by NFC or RFID tags.
Go to file
2017-04-09 09:41:17 -04:00
bin Move tag-reader into bin and remove extension 2017-04-08 12:39:46 -04:00
init Add systemd init file with hardcoded path 2017-04-08 12:25:23 -04:00
jukebox Move child process handling into its own module 2017-04-09 09:41:17 -04:00
media add media directory 2017-03-26 01:51:32 +00:00
source Replace pug templating with mustache 2017-04-08 23:53:36 -04:00
static Replace pug templating with mustache 2017-04-08 23:53:36 -04:00
.gitignore Add Vagrantfile 2017-04-08 12:12:02 -04:00
config.json.sample Move stop and pause ids into config 2017-04-08 12:46:31 -04:00
config.json.vagrant Rename dummy executables 2017-04-08 12:39:39 -04:00
LICENSE Add MIT License 2017-04-08 13:49:15 -04:00
Makefile Add more make commands 2017-04-08 01:54:49 +00:00
nodemon.json Add nodemon.json config file 2017-04-09 09:41:08 -04:00
package.json Replace pug templating with mustache 2017-04-08 23:53:36 -04:00
player.js Move child process handling into its own module 2017-04-09 09:41:17 -04:00
README.md Add README.md 2017-04-08 13:11:02 -04:00
requirements.txt tag-reader: update to pi-rc522 2.1 2017-04-08 01:55:34 +00:00
Vagrantfile Add Vagrantfile 2017-04-08 12:12:02 -04:00

Rasperry Pi RFID Jukebox

Disclaimer: this is a perpetual work in progress!

This is a personal project of Annika Backstrom for using a Raspberry Pi as an RFID-controlled "jukebox". Given an RPi with attached MFRC522, UIDs from 1K MIFARE tags can be associated with media (MP3 files) and actions (currently, STOP and PAUSE).

Components

  • Jukebox app with web frontend (node.js)
  • RFID tag reader (Python)
  • MP3 player (mpg321, not included)

Setup

This section is incomplete (of course) and parts are tuned to my setup and for my own convenience:

  1. Clone project
  2. Copy config.json.sample to config.json
  3. Edit config.json for your setup
  4. npm install (node.js dependencies)
  5. make all (Python dependencies, mpg321 dependency)

TODO: Can this be streamlined? Maybe move Makefile commands into npm commands.

config.json

The following keys are available:

  • port -- web server port

  • tag_reader -- path to tag reader script. jukebox expects the tag reader to spit out a unique string for each tag (e.g. 10 character hex UID)

  • mpg321 -- path to mpg321 executable. should be run in "remote control" mode (-R), reading commands from stdin.

  • stop_id -- id of the card that stops playback

  • pause_id -- id of card that pauses playback