mikebrady / shairport-sync

AirPlay and AirPlay 2 audio player
Other
7.2k stars 571 forks source link

Metadata and config file #104

Closed tatoosh closed 9 years ago

tatoosh commented 9 years ago

How can i use metadata? My version: shairport-sync -V v2.3.7-openssl-Avahi-ALSA-configfile

In config file i did: metadata = { enabled = "yes"; include_cover_art = "yes"; pipe_name = "/tmp/shairport-sync-metadata"; };

but the file isn't there.

By running the service the config file will not be loaded only by stopping the service and running with: shairport-sync --configfile=/etc/shairport-sync.conf

Can you please help?

mikebrady commented 9 years ago

Hi there. Thanks for trying Shairport Sync. You must compile Shairport Sync with the --with-metadata configuration option – please see the development branch version of the README.md document.

tatoosh commented 9 years ago

okay thanks for the advice. and how to use the service with the correct conf file in etc? Am 29.07.2015 20:33 schrieb "Mike Brady" notifications@github.com:

Hi there. Thanks for trying Shairport Sync. You must compile Shairport Sync with the --with-metadata configuration option – please see the development branch version of the README.md document.

— Reply to this email directly or view it on GitHub https://github.com/mikebrady/shairport-sync/issues/104#issuecomment-126051551 .

mikebrady commented 9 years ago

The settings you specify are okay. Have a look at the shairport-sync-metadata-player code for an example of using the metadata. Or simply cat the metadata file.

tatoosh commented 9 years ago

Okay i did a "make install" with "--with-metadata" and have now the /tmp/shairport-sync-metadata file !! I will try it out more on the weekend. Thx

mikebrady commented 9 years ago

Sounds good! BTW, the shairport-sync-metadata-player is at https://github.com/mikebrady/shairport-sync-metadata-reader.

tatoosh commented 9 years ago

i tested it now, the file /tmp/shairport-sync-metadata is always 0 byte. with the sync-metadata-reader or cat i won't get a result. I tried to change user, group and file permissions - no change. By deleting the file it will created empty again. I tried to run shairport-sync as root, service or pi user on my raspberry pi2.

mikebrady commented 9 years ago

You should not have to do anything to permissions, etc. The file is a pipe. If you cat the pipe and then play something to Shairport Sync with metadata enabled, you will get metadata being fed through the pipe. Make sure Shairport Sync is running and has metadata enabled in the configuration file. If you run it from the I it script, it will run in root mode.

tatoosh commented 9 years ago

Okay, so the filesize will always be 0byte? I tried to get an output with cat or yout shairport-sync-metadata-reader.

mikebrady commented 9 years ago

Yes, and information will be piped through it as it is created and will then disappear. If you want to store it in a real file you could cat it to the file, e.g. cat /tmp/shairport-sync-metadata > sample.txt.

Il giorno 31/lug/2015, alle ore 08:26, tatoosh notifications@github.com ha scritto:

Okay, so the filesize will always be 0byte? I tried to get an output with cat or yout shairport-sync-metadata-reader.

— Reply to this email directly or view it on GitHub.

tatoosh commented 9 years ago

ok i understand, it is working now - thx a lot

mikebrady commented 9 years ago

Great.