NewTron-Radio: Auflösungsunabhängiges Tron-Radio
- veloci
- Thread is Unresolved
Mach mit und werde Teil unserer Community!
-
-
Danke für den Hinweis auf Peppy.
Dachte aber gerade an das Newtron Radio.
Habe Einige, mit Gehäuse, Touchdisplays, Taster, FB also warum nicht ein Sprachassi.
Habe keine Resourcenanalyse was z.B. Snips braucht durchgeführt, aber mpd/mpc ließ sich damit steuern.
Ein kleines USB Mikro reichte schon, man braucht also nicht unbedingt ein Mikroarray.
Auch habe ich Googles AIY auf einem Raspberry laufen. Auch hier keine Resourcenmessung.
-
Hallo
Ich habe mir heute auf dem Pi4 Dein Newtron-Radio-v3 über das bash-script installiert.
Anfangs lief alles bestens. Als ich jedoch meine Playlists aus der alten Version in "/var/lib/mpd/playlists" reimportiert habe, startet nur noch kurz der Splash-Screen und verschwindet wieder. MDP läuft aber und spielt den zuletzt gewählten Sender ab.
Kannst Du mir sagen, wie ich das fixen kann, um wieder ins GUI zu kommen?
Grüße
Mark
...nach anfänglichen Schwierigkeiten läuft es mittlerweile mit Raspbian Buster und dem Pi4 richtig rund! Nochmals vielen Dank
Grüße
Mark
-
-
Touchdisplays im Konsolenmodus (Teil 2)
Wer wie ich eines der universelleren HDMI-Touchdisplays mit USB-Touch von Waveshare (oder auch von anderen Herstellern) besitzt, wünscht sich vielleicht, dass er den Touch auch im Konsolenmodus (ohne Desktopumgebung) benutzen kann. Dies ist bisher nur recht umständlich möglich. Waveshare unterstützt bei solchen Displays den Touch leider nur im Desktop-Modus...
Daher habe ich ein kleines Skript geschrieben (vor allem für mich selbst...) das für alle(?) USB-Touchdisplays mit der USB-ID
0eef:0005 die Touchfunktion im Konsolenmodus ermöglichen sollte. Diese Touchdisplays haben einen resistiven Touch - für Displays mit kapazitivem Touch ist das Skript nicht geeignet.
Welche USB-ID das eigene Touchdisplay hat, kann man mit lsusb ermitteln.
Ich selbst habe das Waveshare 5inch HDMI LCD (B) mit einer Auflösung von 800x480 Pixeln. Das Skript sollte aber auch mit dem einen oder anderen 7inch-Display mit 1024x600 Pixeln funktionieren - wenn die USB-ID übereinstimmt.
Wie schon in Beitrag #1778 (Touchdisplays im Konsolenmodus) erläutert, reicht es, das Skript als user 'pi' auszuführen und den Anweisungen des Skriptes zu folgen.
Danach sollte der Touchscreen für alle Anwendungen funktionieren die libts benutzen (z.B. Newtron-Radio, peppy-player, (kodi z. Zt. nur unter stretch) usw.)
Download: waveshare-usb-touch-setup.sh
Das Touchdisplay sollte vor dem Start des Skriptes bereits als Display funktionieren und mindestens die Bootmeldungen von Raspbian anzeigen können.
Installation als user 'pi' mit sh waveshare-usb-touch-setup.sh
Getestet unter Raspbian Buster Lite und Stretch Lite.
Ob das Skript tatsächlich mit anderen Displays mit der USB-ID 0eef:0005 funktioniert kann ich nicht sagen, da ich nur dieses eine Display mit USB-Touch habe. Wenn jedoch jemand das Skript an seinem Display erfolgreich getestet hat, könnte ich ja eine Liste der Displays erstellen mit denen es funktioniert.
Gruß,
veloci
-
Hallo veloci,
Model: RPi 3B
Display: -
Sound: Bluetooth-Lautsprecher
interfaces: ssh active, vnc active
Internet: LAN-Kabel
OS: 2019-07-10-raspbian-buster.img
ich habe ein newtron-radio-setup-v3.1.sh vom 22.08.2019
die Bluetooth-Lautsprecher Konfiguration funktioniert nicht mit mpd und Buster, siehe MPD and bluetooth speaker issue in Raspbian Buster (used to work with Stretch)
deshalb habe ich den Workaround von dort (ohne "HCI=hci0,") übernommen in einen zweiten audio_output für Bluetooth-Lautsprecher:
Code
Display More#1: 3.5mm Klinkenstecker audio_output { type "alsa" name "My ALSA Device" mixer_type "software" } #2: Bluetooth-Lautsprecher (workaround for raspbian-buster) audio_output { type "pipe" name "pipe to JBL GO" mixer_type "software" # Edit #command "aplay -D bluealsa:HCI=hci0,DEV=xx:xx:xx:xx:xx:78,PROFILE=a2dp -f cd 2>/dev/null" command "aplay -D bluealsa:DEV=xx:xx:xx:xx:xx:78,PROFILE=a2dp -f cd 2>/dev/null" format "44100:16:2" }
ich habe eine Unschönheit gefunden:
- Meldung "no playlistentries ...", obwohl welcher vorhanden sind.
Traceback: mit Bluetooth-Lautsprecher, KeyError: 'volume'
Zu 1.) Deine Playlist 'Radio BOB!.m3u' habe ich nicht. Vor dem ersten Start des NewTron-Radio kopiere ich meine Playlists ins Verzeichnis /var/lib/mpd/playlists. Beim Start findet er 'Radio BOB!.m3u' nicht und lügt: "no playlistentries ...".
Zu 2.) dieser Fehler tritt nur auf, wenn nur der 2. Output aktiv ist. NewTron-Radio stürzt ab, wenn man in der Oberflache den Output abwählt. Es wird nicht gestartet, wenn nur Output 2 aktiv ist.Edit: im 2. Ouput hatte ich mixer_type "software" vergessen.Schönen Gruß, kle
-
Hallo,
das Problem mit den fehlenden Playlist kann ich hier auf meinem Raspi4-4GB mit dem aktuellsten Debian Buster nicht reproduzieren. Ich habe in "/var/lib/mpd/playlists" insgesamt 22 Playlists, davon 7 selbst angelegte. Alle werden gefunden und lassen sich abspielen.
Gruß
Mark
-
-
Hallo Mark,
offensichtlich habe ich mich mißverständlich ausgedrückt.
Wichtig: wir reden von newtron-radio-setup-v3.1.sh nach dem 19.08.2019 (Test in Beitrag #1825) bzw. für diesen Beitrag habe ich den Installer neu runtergeladen (1.10.2019 12:00 Uhr)
Wie funktioniert NewTron-Radio:
- wenn keine Playlists*1 in /var/lib/mpd/playlists vorhanden sind, dann werden (z.Z. 14) Default-Playlists aus /usr/local/lib/newtron-v3/playlists/ dorthin kopiert.
*1 eine leere Datei readme wird nicht für eine Playlist gehalten. - ( veloci ) NewTron-Radio erkennt (und das ist die Unschönheit) am Vorhandensein einer Playlist 'Radio BOB!'
(siehe Zeile 122: DEFAULTPLAYLIST = 'Radio BOB!' # eine Playlist aus dem 'playlist_directory')
ob Playlisten im Verzeichnis enthalten sind. Sauber müßte geschaut werden, ob m3u-Dateien (Frage: gehen auch pls-Dateien?) im Verzeichnis stehen.
Codesudo /usr/local/lib/newtron-v3/newtron_radio.py & [1] 1020 pi@raspberrypi:~ $ pygame 1.9.4.post1 Hello from the pygame community. https://www.pygame.org/contribute.html No ConfigFile found, using defaults using fbcon from SDL_VIDEODRIVER env var. Display area size: 320 x 240 connected using unix socket... copying some playlists to /var/lib/mpd/playlists
Aus Deinem Satz:
Ich habe in "/var/lib/mpd/playlists" insgesamt 22 Playlists, davon 7 selbst angelegte. Alle werden gefunden und lassen sich abspielen.
sehe ich, daß Du NewTron-Radio ohne Playlists gestartet hast. NewTron-Radio hat deshalb die Default-Playlists nach /usr/lib/mpd/playlists kopiert. Später hast Du noch Playlists hinzugefügt.
(Erbsenzählen: entweder hast Du nur 21 Playlists, oder Du hast 8 eigene hinzugefügt.)
ich habe
mit dem heute heruntergeladenen Installer newtron-radio-setup-v3.1.sh NewTron-Radio installiert,
das Display mit waveshare-spi-console-setup.sh konfiguriert,
in Datei /boot/config.txt die Display-Orientierung korrigiert dtoverlay=waveshare32b:rotate=270
dann meine Playlists nach /usr/lib/mpd/playlists kopiert (Info1: keine heißt Radio BOB!, Info2: Playlist-Namen sind Dateinamen ohne Extention, Beispiel: Playlist heißt Radio BOB! und Datei heißt Radio BOB!.m3u)
NewTron-Radio gestartet:
Codepi@raspberrypi:~ $ sudo /usr/local/lib/newtron-v3/newtron_radio.py & [1] 935 pi@raspberrypi:~ $ pygame 1.9.4.post1 Hello from the pygame community. https://www.pygame.org/contribute.html No ConfigFile found, using defaults using fbcon from SDL_VIDEODRIVER env var. Display area size: 320 x 240 connected using unix socket... Playlist 'Radio BOB!' not found Starting with empty list.
mark-aus-51 das hat mir jetzt sehr viel Zeit gekostet. Versuche bitte zu verstehen worum es dem Schreiber geht, Du hast eine Playlist Radio BOB!, ich nicht.
Schönen Gruß, kle
- wenn keine Playlists*1 in /var/lib/mpd/playlists vorhanden sind, dann werden (z.Z. 14) Default-Playlists aus /usr/local/lib/newtron-v3/playlists/ dorthin kopiert.
-
In der bereits vorhandenen aber noch nicht veröffentlichten Version 3.2 ist das schon korrigiert.Das passiert übrigens, wenn im state-file von mpd noch nichts drin ist (also wenn mpd noch nie ein stück gespielt hat) aber eigene Playlisten bereits vorhanden sind - ein Fall, den ich bisher nie berücksichtigt hatte...
Gruß,
veloci
-
Das passiert übrigens, wenn im state-file von mpd noch nichts drin ist (also wenn mpd noch nie ein stück gespielt hat) aber eigene Playlisten bereits vorhanden sind - ein Fall, den ich bisher nie berücksichtigt hatte...
Hallo veloci,
Jetzt hatte ich gerade den umgekehrten Fall, daß in Datei state Radio BOB! stand (von den Default-Playlists), und ich meine Playlists nach /var/lib/mpd/playlists kopiert habe. MPD-Restart (auch update Database) hat nichts genützt. Erst mpc clear und mpc load <playlist> auf der Kommandozeile haben geholfen.
Schönen Gruß, kle
-
-
Nochmal zum Ursprünglichen Fall:
Eigentlich ist das kein Fehler. Wenn er "Radio BOB!" nicht findet startet das Radio mit einer leeren Playliste.
Dann muß man halt in der Playlistenauswahl erst eine auswählen (der rechte Pfeil nach oben). Das Radio weiß ja beim (erst)Start nicht, welche deiner Playlisten du hören willst wenn die Defaultliste oder das state-file von mpd nicht existieren.
Die Meldung "no playlistentries ..." (könnte man noch umbenennen zu "no entries in playlist...") heisst nur, dass in der aktuellen Playliste vom mpd keine Einträge vorhanden sind und das ist ja nicht gelogen. Wenn das Radio keine Playlisten oder Dateien findet meldet es "no playlists or files found..."
Deinen zweiten Fehler konnte ich bisher allerdings noch nicht nachvollziehen bzw. ich konnte bisher immer eine neue Playliste auswählen.
Übrigens, autostart via systemd funktioniert mit v3.2 auch schon (newtron-radio wird als user pi gestartet, Fehlerabfrage über journalctl -u newtron-radio, usw.)...
Gruß,
veloci
-
Dann muß man halt in der Playlistenauswahl erst eine auswählen (der rechte Pfeil nach oben). Das Radio weiß ja beim (erst)Start nicht, welche deiner Playlisten du hören willst wenn die Defaultliste oder das state-file von mpd nicht existieren.
Du mußt zugeben, daß der Pfeil nach oben nicht selbsterklärend ist.
Du hast ja in Version 3.0 die Playlisten-Wahl aufgebohrt in:
- Playlistenwahl und
- Titel-Wahl
So sehe ich die Logik:
Die zuletzt geladene Playliste ist im state-File des mpd gespeichert.
Sind keine Titel im state-File vorhanden, wird verzweigt:- NewTron-Radio Startup
- Normalbetrieb
Zu 1: Die default-Playliste ersetzt die Playlistenwahl beim Start des NewTron-Radio. Gibt es keine oder wird sie nicht gefunden, muß eine Playliste gewählt werden.
Zu 2: z.B. nach Papierkorb-Symbol (= Playliste löschen) muß eine Playliste gewählt werden.
Damit wird die Meldung "no playlistentries ..." und der (meiner Ansicht nach überflüssige) Bedienschritt Pfeil nach oben vermieden.
Schönen Gruß, kle
-
Darüber hatte ich mir auch schon Gedanken gemacht.
Wie soll sowas dann im "consume"-Modus von mpd aussehen, wo jeder gespielte Titel aus der Playliste gelöscht wird. Irgendwann ist die leer. Oder mit einer tatsächlich leeren Playlist (z.B. durch fehlerhaftes kopieren entstanden - Dateilänge 0)? Oder du löschst über das Radio nach und nach einzelne Einträge aus der aktuellen Playliste - auch die kann irgendwann leer sein.
In allen Fällen wird z.Zt. die leere Playliste mit entsprechender Meldung "no playlist entries.." angezeigt. Also Immer dann, wenn die Playliste leer ist.
Gruß,
veloci
-
-
So, rev. 00 von Newtron-Radio v3.2 ist soweit fertig. Und wieder einmal hat sich jede Menge gegenüber der Vorversion geändert. Der größte Teil davon intern - ich bin endlich die 'global'-Deklarationen in den Funktionen und Klassen los. Zwar bin ich mit der Umstellung noch lange nicht soweit wie ich eigentlich wollte, aber in letzter Zeit hab ich einfach mal wieder zu wenig Zeit...
Die nach außen sichtbaren Änderungen hier nun im einzelnen.
- Die von kle vorgeschlagenen Änderungen bezüglich der Playlistenauswahl wurden implementiert.
- Der Autostart im Konsolenmodus kann jetzt via systemd-Unit realisiert werden (mehr dazu weiter unten)
- Ort und Name der Radio-Konfigurationsdatei wurde geändert. Diese befindet sich jetzt im Homeverzeichnis des jeweiligen Benutzers und heißt jetzt .newtron-radio.conf. Hier kann nun auch der Openweathermap API-Key und der Ort für die Wetteranzeige eingetragen werden (diese Änderung war nötig, damit der Autostart via systemd - als user pi - funktioniert).
- Die Backlightsteuerung wurde vorerst entfernt, da RPi.gpio root-Rechte benötigte, was dem Autostart via systemd im Weg stand. Ein Umstieg auf gpiozero ist aber in Planung.
- Die Skin-Konfig-Dateien akzeptieren keine symbolischen Farbnamen mehr sondern nur noch RGB-Tupel. Änderungen der Fontgröße können nur noch im Skript selbst vorgenommen werden.
- Es gibt ein paar neue Button-Symbole. Damit sollen die Symbole eindeutiger und verständlicher werden.
- Beim Clock-Screensaver wird nun auch der Name der Radiostation angezeigt.
- ...
Wie immer muß mindestens Raspbian Lite installiert sein. Netzwerk und Touchdisplay müssen vollständig funktionieren (vor allem der Touch). Bei Raspbian Lite letzteres auch auf der Konsole.
Wer Probleme hat sein Touchdisplay für die Konsole einzurichten kann sich Beitrag #1778 (für Waveshare SPI LCD Touchdisplays) oder Beitrag #1824 (USB-Touchdisplays mit der USB-ID 0eef:0005 (D-Wav) u.A. für das Waveshare 5inch HDMI LCD (B) Display mal ansehen.
Installer: newtron-radio-setup-v3.2.sh (rev. 01 vom 25.10.19)
Installiert NewTron-Radio und alle nötigen weiteren Pakete
Installation mit sh newtron-radio-setup-v3.2.sh
Danach kann das Radio mit der Eingabe von newtron-radio direkt an der Touchscreen-Konsole (bzw. via ssh mit X11-Forwarding) oder mit sudo newtron-radio an der Kommandozeile (via putty/ssh ohne X11-Forwarding) gestartet werden.
Autostart ist nun via systemd möglich.
Hierzu wird eine entsprechende Unit vom Installationsskript nach /etc/systemd/system/ kopiert.
Um zu überprüfen, ob der Autostart über systemd funktionieren würde gibt man als user pi an der (putty/ssh-)Kommandozeile einfach sudo systemctl start newtron-radio ein. Wenn alles Korrekt eingerichtet wurde sollte das Radio nun auf dem Touchdisplay zu sehen und zu bedienen sein. Sollte das nicht der Fall sein, kann man sich mit journalctl -u newtron-radio die Fehlermeldungen anzeigen lassen.
Sollte alles wie erwartet funktionieren, kann man den Autostart mittels sudo systemctl enable newtron-radio aktivieren.
Entsprechend kann man den Autostart mit sudo systemctl disable newtron-radio wieder deaktivieren oder das Radio mit sudo systemctl stop newtron-radio beenden. Ist der Autostart aktiv läuft die 'newtron-radio'-Instanz immer als User 'pi' und benutzt dessen Konfiguration.
Sollte der Autostart nicht funktionieren, kann das vor allem an fehlenden oder falschen Umgebungsvariablen (SDL_FBDEV, SDL_MOUSEDEV usw.) liegen, da systemd die Umgebung vom User 'pi' nicht berücksichtigt. Diese Variablen können daher direkt im Radio-Skript (newtron_radio.py) angepasst werden oder als eigene config-Unit z.B. in /etc/systemd/system.conf.d/10-SDL-TSLIB-env.conf eingetragen werden:
Code: /etc/systemd/system.conf.d/10-SDL-TSLIB-env.conf[Manager] DefaultEnvironment="SDL_VIDEODRIVER=fbcon" "SDL_FBDEV=/dev/fb1" "SDL_MOUSEDRV=TSLIB" "SDL_MOUSEDEV=/dev/input/touchscreen" "TSLIB_TSDEVICE=/dev/input/touchscreen" "TSLIB_FBDEVICE=/dev/fb1"
Hat man die Datei neu erstellt, muss sie von systemd noch eingelesen werden. Dies erfolgt mit sudo systemctl daemon-reload
Das passende usbmount-Skript (Automatisches einhängen von USB-Datenträgern in den Zugriffsbereich von mpd) gibts in Beitrag #1760.
Falls etwas nicht funktioniert, bitte ich darum, das Problem hier zu posten. Aber bitte nur mit möglichst genauen Fehlermeldungen und einer Beschreibung dessen was zum Fehler geführt hat.
Gruß,
veloci
PS: Wie immer wurden einige Fehler beseitigt und wahrscheinlich einige neu eingefügt...
Achtung!
Bitte beachtet auch folgende ergänzende Hinweise, die kle hier NewTron-Radio Korrekturen freundlicherweise schrieb!
(Editiert von hyle)
-
Hallo zusammen.
Habe das Newtronradio seit etlichen Jahren am laufen, soweit nie Probleme gehabt.
Nun habe ich heute entdeckt dass es eine neue Version gibt.
Habe eine Raspberry Pi 3 b+ mit frisch aufgesetztem Buster Image und einem Waveshare Display.
Habe die Installation nach Anleitung durchgeführt, soweit hat auch alles geklappt.
Nun Habe ich aber 2 Probleme.
- Die .config Datei .newtron-radio.config wird bei mir im Home Folder nicht erstellt.
Habe deshalb mal etwas im newtron_radio.py Code rumgerührt und einfach mal den Speicherort/Dateinamen geändert.
Danach habe ich auch die Daten für das wetter eingeben können, damit dies funktioniert.
-Problem 2:
Wenn ich manuell die Seite mit der Wetteranzeige öffne, wird auch das Wetter angezeigt.
Nur im Screensaver Betrieb wo das Wetter angezeigt werden sollte, wird dies nicht angezeigt.
Es wird nur der Sender Angezeigt.
Deshalb habe ich mal alles komplett neu aufgesetzt, inkl. Raspian Image, aber leider brachte dies keine Besserung.
Wenn ich die Newtron Version 3.1 installiere funktioniert alles tadellos.
Lass es einfach jetzt mit der Version 3.1 laufen.
Trotzdem vielen vielen Dank für dieses coole Internetradio.
Grüße
Mommi
-
Die .config Datei .newtron-radio.config wird bei mir im Home Folder nicht erstellt.
die Datei .newtron-radio.conf wird im Home-Verzeichnis erstellt.
Aber...
NewTron-Radio wird bisher nicht von Benutzer pi gestartet, sondern in /etc/rc.local oder mit sudo, also mit Benutzer root.
Deshalb findest Du .newtron-radio.conf im Home-Verzeichnis von Benutzer root also in Verzeichnis /root.
veloci den Fehler mit der Wetter-Anzeige im Screensaver kann ich bestätigen
Schönen Gruß, kle
Edit (12:13 Uhr):
ohne, daß ich etwas getan habe, ist als ich um 12:13 Uhr nachgeschaut habe, der Wetter-Screensave korrekt dargestellt.
-
-
Danke erstmal für die Info.
Beim Wetterscreensaver muß ich noch nachbessern (da fehlt die initiale Wetterabfrage/-anzeige - spätestens 10 min nach Start des Screensavers ist das Wetter aber da...).
Die Korrektur kommt dann in Beitrag #1833 als rev. 01 -
also ab und zu mal nachschauen (heute aber nicht mehr)...Die Konfigurationsdatei '.newtron-radio.conf' wird immer im Verzeichnis des aufrufenden Benutzers erzeugt:
Wenn ich das Radio über rc.local oder direkt via sudo newtron-radio starte (beides nicht empfohlen), dann wird sie unter /root/ erzeugt.
Wenn das Radio dagegen direkt an der Touchscreen-Kommandozeile (als user pi), vom Desktop aus (als user pi) oder via systemd-service gestartet wird, dann wird sie unter /home/pi/ erzeugt.
Gruß,
veloci
EDIT: Die korrigierte Version v3.2 Rev. 01 ist ab sofort in Beitrag #1833 zu finden.
-
Hallo nochmals,
bislang lief auf meinem Raspberry Pi 4 - 4GB das NewTron-Radio mit einer USB-Soundkarte einwandfrei. Nun habe ich allerdings einen JustBoom-Dac Hat installiert, der mit allen anderen Anwendungen einwandfrei funktioniert (VLC, Clementine, Kodi, Chromium, ...). Nur beim NewTron-Radio habe ich jetzt keinen Ton mehr
Frage: Wie muss ich das NewTron-Radio bzw. mpd konfigurieren, dass ich wieder eine Tonausgabe erhalte?
Grüße
Mark
-
Hallo mark-aus-51,
vielleicht hilft Dir das weiter: https://www.justboom.co/softwa…figure-justboom-with-mpd/
//Edit: Ab Step 3.
-
-
Hallo,
poste doch mal die Dateien
- ~/.asoundrc und
- /etc/asound.conf und
- den/die audio_output-Definitionen der Datei /etc/mpd.conf.
in jeweils einem Codeblock (es müssen nicht beide Dateien vorhanden sein).
Schönen Gruß, kle
-
hyle : Hab ich auch schon gelesen hat leider nichts gebracht...
kle :
~/.asoundrc:
Code
Display Morepcm.!default { type asym playback.pcm { type plug slave.pcm "output" } capture.pcm { type plug slave.pcm "input" } } pcm.output { type hw card 0 } ctl.!default { type hw card 0 } pcm.input { type hw card 1 }
/etc/asound.conf:
aplay -l:
Code**** Liste der Hardware-Geräte (PLAYBACK) **** Karte 0: sndrpijustboomd [snd_rpi_justboom_dac], Gerät 0: JustBoom DAC HiFi pcm512x-hifi-0 [] Sub-Geräte: 1/1 Sub-Gerät #0: subdevice #0
/etc/mpd.conf:
Code
Display More# An example configuration file for MPD. # Read the user manual for documentation: http://www.musicpd.org/doc/user/ # or /usr/share/doc/mpd/html/user.html # Files and directories ####################################################### # # This setting controls the top directory which MPD will search to discover the # available audio files and add them to the daemon's online database. This # setting defaults to the XDG directory, otherwise the music directory will be # be disabled and audio files will only be accepted over ipc socket (using # file:// protocol) or streaming files over an accepted protocol. # music_directory "/var/lib/mpd/music" # # This setting sets the MPD internal playlist directory. The purpose of this # directory is storage for playlists created by MPD. The server will use # playlist files not created by the server but only if they are in the MPD # format. This setting defaults to playlist saving being disabled. # playlist_directory "/var/lib/mpd/playlists" # # This setting sets the location of the MPD database. This file is used to # load the database at server start up and store the database while the # server is not up. This setting defaults to disabled which will allow # MPD to accept files over ipc socket (using file:// protocol) or streaming # files over an accepted protocol. # db_file "/var/lib/mpd/tag_cache" # # These settings are the locations for the daemon log files for the daemon. # These logs are great for troubleshooting, depending on your log_level # settings. # # The special value "syslog" makes MPD use the local syslog daemon. This # setting defaults to logging to syslog, or to journal if mpd was started as # a systemd service. # log_file "/var/log/mpd/mpd.log" # # This setting sets the location of the file which stores the process ID # for use of mpd --kill and some init scripts. This setting is disabled by # default and the pid file will not be stored. # pid_file "/run/mpd/pid" # # This setting sets the location of the file which contains information about # most variables to get MPD back into the same general shape it was in before # it was brought down. This setting is disabled by default and the server # state will be reset on server start up. # state_file "/var/lib/mpd/state" # # The location of the sticker database. This is a database which # manages dynamic information attached to songs. # sticker_file "/var/lib/mpd/sticker.sql" # ############################################################################### # General music daemon options ################################################ # # This setting specifies the user that MPD will run as. MPD should never run as # root and you may use this setting to make MPD change its user ID after # initialization. This setting is disabled by default and MPD is run as the # current user. # user "mpd" # # This setting specifies the group that MPD will run as. If not specified # primary group of user specified with "user" setting will be used (if set). # This is useful if MPD needs to be a member of group such as "audio" to # have permission to use sound card. # #group "nogroup" # # This setting sets the address for the daemon to listen on. Careful attention # should be paid if this is assigned to anything other then the default, any. # This setting can deny access to control of the daemon. Choose any if you want # to have mpd listen on every address. Not effective if systemd socket # activation is in use. # # For network bind_to_address "localhost" # # And for Unix Socket #bind_to_address "/run/mpd/socket" # # This setting is the TCP port that is desired for the daemon to get assigned # to. # #port "6600" # # This setting controls the type of information which is logged. Available # setting arguments are "default", "secure" or "verbose". The "verbose" setting # argument is recommended for troubleshooting, though can quickly stretch # available resources on limited hardware storage. # #log_level "default" # # Setting "restore_paused" to "yes" puts MPD into pause mode instead # of starting playback after startup. # #restore_paused "no" # # This setting enables MPD to create playlists in a format usable by other # music players. # #save_absolute_paths_in_playlists "no" # # This setting defines a list of tag types that will be extracted during the # audio file discovery process. The complete list of possible values can be # found in the user manual. #metadata_to_use "artist,album,title,track,name,genre,date,composer,performer,disc" # # This example just enables the "comment" tag without disabling all # the other supported tags: #metadata_to_use "+comment" # # This setting enables automatic update of MPD's database when files in # music_directory are changed. # #auto_update "yes" # # Limit the depth of the directories being watched, 0 means only watch # the music directory itself. There is no limit by default. # #auto_update_depth "3" # ############################################################################### # Symbolic link behavior ###################################################### # # If this setting is set to "yes", MPD will discover audio files by following # symbolic links outside of the configured music_directory. # #follow_outside_symlinks "yes" # # If this setting is set to "yes", MPD will discover audio files by following # symbolic links inside of the configured music_directory. # #follow_inside_symlinks "yes" # ############################################################################### # Zeroconf / Avahi Service Discovery ########################################## # # If this setting is set to "yes", service information will be published with # Zeroconf / Avahi. # #zeroconf_enabled "yes" # # The argument to this setting will be the Zeroconf / Avahi unique name for # this MPD server on the network. %h will be replaced with the hostname. # #zeroconf_name "Music Player @ %h" # ############################################################################### # Permissions ################################################################# # # If this setting is set, MPD will require password authorization. The password # setting can be specified multiple times for different password profiles. # #password "password@read,add,control,admin" # # This setting specifies the permissions a user has who has not yet logged in. # #default_permissions "read,add,control,admin" # ############################################################################### # Database ####################################################################### # #database { # plugin "proxy" # host "other.mpd.host" # port "6600" #} # Input ####################################################################### # input { plugin "curl" # proxy "proxy.isp.com:8080" # proxy_user "user" # proxy_password "password" } # QOBUZ input plugin input { enabled "no" plugin "qobuz" # app_id "ID" # app_secret "SECRET" # username "USERNAME" # password "PASSWORD" # format_id "N" } # TIDAL input plugin input { enabled "no" plugin "tidal" # token "TOKEN" # username "USERNAME" # password "PASSWORD" # audioquality "Q" } # Decoder ##################################################################### # decoder { plugin "hybrid_dsd" enabled "no" # gapless "no" } # ############################################################################### # Audio Output ################################################################ # # MPD supports various audio output types, as well as playing through multiple # audio outputs at the same time, through multiple audio_output settings # blocks. Setting this block is optional, though the server will only attempt # autodetection for one sound card. # # An example of an ALSA output: # audio_output { type "alsa" name "My ALSA Device" # device "hw:0,0" # optional mixer_type "software" # optional # mixer_device "default" # optional # mixer_control "PCM" # optional # mixer_index "0" # optional } # # An example of an OSS output: # #audio_output { # type "oss" # name "My OSS Device" # device "/dev/dsp" # optional # mixer_type "hardware" # optional # mixer_device "/dev/mixer" # optional # mixer_control "PCM" # optional #} # # An example of a shout output (for streaming to Icecast): # #audio_output { # type "shout" # encoder "vorbis" # optional # name "My Shout Stream" # host "localhost" # port "8000" # mount "/mpd.ogg" # password "hackme" # quality "5.0" # bitrate "128" # format "44100:16:1" # protocol "icecast2" # optional # user "source" # optional # description "My Stream Description" # optional # url "http://example.com" # optional # genre "jazz" # optional # public "no" # optional # timeout "2" # optional # mixer_type "software" # optional #} # # An example of a recorder output: # #audio_output { # type "recorder" # name "My recorder" # encoder "vorbis" # optional, vorbis or lame # path "/var/lib/mpd/recorder/mpd.ogg" ## quality "5.0" # do not define if bitrate is defined # bitrate "128" # do not define if quality is defined # format "44100:16:1" #} # # An example of a httpd output (built-in HTTP streaming server): # #audio_output { # type "httpd" # name "My HTTP Stream" # encoder "vorbis" # optional, vorbis or lame # port "8000" # bind_to_address "0.0.0.0" # optional, IPv4 or IPv6 # quality "5.0" # do not define if bitrate is defined # bitrate "128" # do not define if quality is defined # format "44100:16:1" # max_clients "0" # optional 0=no limit #} # # An example of a pulseaudio output (streaming to a remote pulseaudio server) # Please see README.Debian if you want mpd to play through the pulseaudio # daemon started as part of your graphical desktop session! # #audio_output { # type "pulse" # name "My Pulse Output" # server "remote_server" # optional # sink "remote_server_sink" # optional #} # # An example of a winmm output (Windows multimedia API). # #audio_output { # type "winmm" # name "My WinMM output" # device "Digital Audio (S/PDIF) (High Definition Audio Device)" # optional # or # device "0" # optional # mixer_type "hardware" # optional #} # # An example of an openal output. # #audio_output { # type "openal" # name "My OpenAL output" # device "Digital Audio (S/PDIF) (High Definition Audio Device)" # optional #} # ## Example "pipe" output: # #audio_output { # type "pipe" # name "my pipe" # command "aplay -f cd 2>/dev/null" ## Or if you're want to use AudioCompress # command "AudioCompress -m | aplay -f cd 2>/dev/null" ## Or to send raw PCM stream through PCM: # command "nc example.org 8765" # format "44100:16:2" #} # ## An example of a null output (for no audio output): # #audio_output { # type "null" # name "My Null Output" # mixer_type "none" # optional #} # ############################################################################### # Normalization automatic volume adjustments ################################## # # This setting specifies the type of ReplayGain to use. This setting can have # the argument "off", "album", "track" or "auto". "auto" is a special mode that # chooses between "track" and "album" depending on the current state of # random playback. If random playback is enabled then "track" mode is used. # See <http://www.replaygain.org> for more details about ReplayGain. # This setting is off by default. # #replaygain "album" # # This setting sets the pre-amp used for files that have ReplayGain tags. By # default this setting is disabled. # #replaygain_preamp "0" # # This setting sets the pre-amp used for files that do NOT have ReplayGain tags. # By default this setting is disabled. # #replaygain_missing_preamp "0" # # This setting enables or disables ReplayGain limiting. # MPD calculates actual amplification based on the ReplayGain tags # and replaygain_preamp / replaygain_missing_preamp setting. # If replaygain_limit is enabled MPD will never amplify audio signal # above its original level. If replaygain_limit is disabled such amplification # might occur. By default this setting is enabled. # #replaygain_limit "yes" # # This setting enables on-the-fly normalization volume adjustment. This will # result in the volume of all playing audio to be adjusted so the output has # equal "loudness". This setting is disabled by default. # #volume_normalization "no" # ############################################################################### # Character Encoding ########################################################## # # If file or directory names do not display correctly for your locale then you # may need to modify this setting. # filesystem_charset "UTF-8" # ###############################################################################