-
-
Notifications
You must be signed in to change notification settings - Fork 3.6k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
[MPD] doesn't work with external mpd player #10142
Comments
Looks like you get a value that can‘t be converted to PercentType. Increase Binding loglevel and see if you get more information. |
I found to change the loglevel. |
I can reproduce the original issue (and that is a bug), but controlling a mpd instance works fine (from a remote computer). Did you configure mpd to listen on the IP address? The dault is listen to localhost only. |
My mpd listen on my network, not localhost. I can control the mpd from my pc with gmpc and from my tablet and so on
|
Please try if the first fix also fixes your other problems:
I doubt it helps, but it's worth a try. |
IT HELPS!!!!!!! I can control the extern MPD!! Danke, thanks,. You can close this bug
One question: How can I change or list playlists/albums and so on? Is this possible?
|
One question again, because I'm interesting of that. I've looking your changing code. I'm not a programer in java/C++, but I can understand a little bit. Now my question: Why do you set the volume to undef and not to the min or max value? |
Playlist/album: no idea, I don‘t even use mpd From my understanding a value of -1 means „not set/unknown“, so UNDEF seems to be the closest equivalent. |
You can thinking about using playlist and so on, to complete the binding. ;-) My understanding is that values can be +/- and greater than 100 :-) Must I close this issue? |
I think volume is usually 0-100%, what would a value of -10 mean in this context (ok, it could be dB or something like that, but that is not what mpd is reporting)? No, please don’t close this issue until someone fixes it on openHAB. |
Fixes openhab#10142. Signed-off-by: Stefan Roellin <stefan@roellin-baumann.ch>
Which version of mpd are you using? According to the protocol specification a volume -1 is deprecated and should not occur in never versions. I have nevertheless submitted a fix. |
Fixes openhab#10142. Signed-off-by: Stefan Roellin <stefan@roellin-baumann.ch> Also-by: Jan N. Klug <jan.n.klug@rub.de>
Both mpd version are 0.19.21 Debian stretch for changing the playlist/album, it's better to know which playlist/album exist. In the example, I saw some possible actions, but I don't know what is also possible. My next handicap is the english language, that is not so well. What I missed are more functions like gmpc, I know that's a dream :-) |
This is a really old version! If you encounter other problems with the mpd binding I suggest you update to a more recent version. With actions you can do almost everything you can do with gmpc. Have you tried the example? Define a switch named
Now, if the switch changes to ON, the queue is cleared, the playlist "MorningMusic" is loaded and shuffled and then played. If you don't want to hard-code the name of the playlist you can define a string item and use the state of the item for the playlist. For a list of commands see https://www.musicpd.org/doc/html/protocol.html |
Dear Stefan, |
Fixes #10142. Signed-off-by: Stefan Roellin <stefan@roellin-baumann.ch> Also-by: Jan N. Klug <jan.n.klug@rub.de>
Fixes openhab#10142. Signed-off-by: Stefan Roellin <stefan@roellin-baumann.ch> Also-by: Jan N. Klug <jan.n.klug@rub.de> Signed-off-by: John Marshall <john.marshall.au@gmail.com>
Fixes openhab#10142. Signed-off-by: Stefan Roellin <stefan@roellin-baumann.ch> Also-by: Jan N. Klug <jan.n.klug@rub.de>
Fixes openhab#10142. Signed-off-by: Stefan Roellin <stefan@roellin-baumann.ch> Also-by: Jan N. Klug <jan.n.klug@rub.de>
MPD Binding doesn't work with external MPD-Player. I've openhab on an raspberry installed and on two raspberries I installed MPD as musicplayer. Both player worked fine and I can control this with Gnome Music Player Client.
Now I'will try this with openhab. The version on OH 2.5.latest and 3,x gives the same result. it will not work completly. OH Binding goes online and that all. I can't control anything.
My OH Installation run on IP xx.xx.xx.10 my MPD's on xx.xx.xx.13 an .20 .
The only thing what I've found is an error in the Syslog on my OH3 Raspi (after the latest update, there is nothing in the syslog):
Feb 8 20:27:57 raspiOHTest karaf[32614]: Exception in thread "OH-binding-mpd:mpd:Musik" java.lang.IllegalArgumentException: Value must be between 0 and 100 Feb 8 20:27:57 raspiOHTest karaf[32614]: #011at org.openhab.core.library.types.PercentType.validateValue(PercentType.java:57) Feb 8 20:27:57 raspiOHTest karaf[32614]: #011at org.openhab.core.library.types.PercentType.<init>(PercentType.java:42) Feb 8 20:27:57 raspiOHTest karaf[32614]: #011at org.openhab.binding.mpd.internal.handler.MPDHandler.updateMPDStatus(MPDHandler.java:257) Feb 8 20:27:57 raspiOHTest karaf[32614]: #011at org.openhab.binding.mpd.internal.protocol.MPDConnection.handleResponseStatus(MPDConnection.java:218) Feb 8 20:27:57 raspiOHTest karaf[32614]: #011at org.openhab.binding.mpd.internal.protocol.MPDConnection.onResponse(MPDConnection.java:172) Feb 8 20:27:57 raspiOHTest karaf[32614]: #011at org.openhab.binding.mpd.internal.protocol.MPDConnectionThread.processPendingCommands(MPDConnectionThread.jav Feb 8 20:27:57 raspiOHTest karaf[32614]: #011at org.openhab.binding.mpd.internal.protocol.MPDConnectionThread.run(MPDConnectionThread.java:81)
Thats all, no errors more, not in the openhab.log and so on. The events.log shows me the sending commands, but nothing works.
There are no firewalls inside my internal network. People, how brings the binding up to work are using MPD and OH on the same IP adrress, on the same raspi. That's not the way for me.
The text was updated successfully, but these errors were encountered: