Hey All, for the last couple of weeks I’ve been trying (off and on) to to get openhab to connect to pulseaudio.
My openhab “host” device is a beagleboneblack running ubuntu and installation went quite smooth.
In sitemaps/demo.sitemap I added the following switch to a frame:
Switch item=Sink_FF_Multiroom_Muted label="Mute All Audio"
Followed by adding the following to rules/demo.rules:
/* MUSIC */
rule "mute pulseaudio sink on incoming call"
when
Item Incoming_Call received update
then
if (Incoming_Call.state==ON) {
Sink_FF_Multiroom_Muted.sendCommand(ON)
} else {
Sink_FF_Multiroom_Muted.sendCommand(OFF)
}
end
and adding this to items/demo.items:
Switch Sink_FF_Multiroom_Muted { pulseaudio="Test:combined:MUTED" }
(Test used to be Main, but I changed it along the way for testing purposes)
This all was topped of by the following configuration(s) in openhab.cfg
############################## Pulseaudio Binding #####################################
#
# PulseaudioServer IP address
pulseaudio:Main.host=192.168.7.2
# PulseaudioServer Port (optional, defaults to 4712)
# pulseaudio:Main.port=4713
and
############################## Pulseaudio Binding #####################################
#
# PulseaudioServer IP address
pulseaudio:Main.host=192.168.7.1
pulseaudio:Test.host=192.168.7.1
#pulseaudio:Main.host=192.168.7.2
# PulseaudioServer Port (optional, defaults to 4712)
# pulseaudio:Main.port=4713
pulseaudio:Test.port=4712
The first config shows me trying to connect to the pulseaudio server (running on system level) on the beaglebone black. The second one shows me trying to connect to the pulseaudio system running on my “development” machine running ubuntu. Both devices are loaded with the pulse-tcp-plugin and allowing anonymous connections.
All of them had the same result in the openhab log file:
2015-12-11 09:53:45.357 [WARN ] [b.p.internal.PulseaudioBinding] - connection to pulseaudio server in not available for the given itemName [itemName=Sink_FF_Multiroom_Muted, audio-item-name=combined, serverId=Test, command=MUTED] => querying for values aborted!
Any pointers would be greatly appreciated!