This repository was archived by the owner on May 17, 2024. It is now read-only.
-
Notifications
You must be signed in to change notification settings - Fork 1
How does it work
metskem edited this page Dec 9, 2012
·
3 revisions
Before you can send files to your MPD server you have to set up your preferences properly.
- hostname - This can be a hostname or an IP address. This is where we try to scp (secure copy program) to mp3 file to.
- port - This is the port where the MPD is listening on, the default is 6600.
- username - This is the username we use when doing the scp.
- password - This is the password for the above userid.
- destdir - This is the directory on the MPD server where we will scp the mp3 file to, the default is /var/lib/mpd/music. The above userid should have write access to this directory.
- mpdpassword - This is the password that has been configured on the MPD server. This password should at least allow for a server update.
You fire up your favourite Music Player or File Explorer app. The app should support the option to share the mp3 file, when doing this, Send2MPD should show up as one of the selectable apps. When you select Send2MPD, the main screen will show with prefilled fields coming from the ID3 tags of the mp3 file. You can then modify artist, title or album. When modifying artist and title, the destination file name will also change according to the name pattern <artist> - <title>.mp3 When you click the "Save and Send" button, we will :
- save the file (with the modified ID3 tags), and yes the original file will be overwritten
- send a broadcast intent ACTION_MEDIA_SCANNER_SCAN_FILE for the modified file, so that your music app(s) will pick up the changes
- scp the file to the MPD server
- ssh into the server and issue a "chmod 664" for the file, to make sure it is readable by the userid that runs the MPD server.
- open a connection to the MPD port (6600 default) and issue 3 MPD commands: ** password <password> ** update (so MPD will reread the data) ** close