MiczFlor / RPi-Jukebox-RFID

A Raspberry Pi jukebox, playing local music, podcasts, web radio and streams triggered by RFID cards, web app or home automation. All plug and play via USB. GPIO scripts available.
http://phoniebox.de
MIT License
1.33k stars 395 forks source link

button/action for assigning latest added to new RFID-tag #439

Open Wallnusskaese opened 5 years ago

Wallnusskaese commented 5 years ago

Hey there, is there a nice way to manually assign an RFID-tag to the latest added Folder within audiofolders?

Background: I've got my old and unused Superdrive hooked up to my Phoniebox to Rip some CD's directly to it. Using abcde it's as simple as hooking up the Superdrive via USB and pressing a button to start ripping.

All I'm missing is a neat way to just throw a new RFID chip onto my kid's first beloved gadget and get it linked to the newly added folder.

Any ideas?

lg Marco

gizmo21 commented 5 years ago

hhm nice request, as I'm also using abcde to rip directly to the box and also created a own RFID trigger to start autorip or use a userscript (https://github.com/MiczFlor/RPi-Jukebox-RFID/tree/master/scripts/userscripts) to call abcde with tracknumbers array to rip.

Perhaps a solution could be:

But this 'non visual interface' approach is quite tricky as it has to be in excat order or wrong IDs are attached to the new folder.

Wallnusskaese commented 5 years ago

Hi there,

"attach Latest_RFID to latest foldername"

That's exactly what I want, and what I'm sadly don't know how to achieve :(

"But this 'non visual interface' approach is quite tricky as it has to be in excat order or wrong IDs are attached to the new folder."

Yes that's true, even though this feature is arguably more of an 'admin' then an 'enduser' case it should be as easy as possible.

So, preferably, I would suggest the other way around:

  1. Attach unknown Chip. (2. If USB Cd-Drive is connected start ripping)
  2. Press and hold Play-Button to assign RFID to last added folder.

I put 2 in brackets as it is optional. Even if you copy over an audiofolder off of your nas, it would be awesome to just throw a chip at it, press a button, and done.

MiczFlor commented 5 years ago

Hi @Wallnusskaese @gizmo21 I want to do this in the webui first. And my thoughts are similar to @gizmo21 but in a different order. I want to add a section in the RFID assign page which says „add RFID to latest folder created“ and then the process would be:

1 open WebUi

2 rip Cd

3 Swipe card

4 select „add to latest folder“

5 rip next and go to 3

The GPIO button would then come later :)

Sent with GitHawk

Wallnusskaese commented 5 years ago

Hi @MiczFlor,

I understand that the webUI is the way to go. It'd be great if the function would be accessible by script too.

Technically speaking, would it be enough to write the (new) foldername into shared/shortcuts/$CARDID ?