salon: kontrola zasilania głośników
Póki nie działa audio przez HDMI z amdgpu i są podłączone zewnętrze głośniki, niech będą wyłączone gdy nie gra ani Kodi, ani QuodLibet
This commit is contained in:
@@ -4,7 +4,7 @@ Group temperatury
|
|||||||
Switch sOWFS01 "Światełka [%s]" { onewire="deviceId=12.0C7045000000;propertyName=PIO.A" }
|
Switch sOWFS01 "Światełka [%s]" { onewire="deviceId=12.0C7045000000;propertyName=PIO.A" }
|
||||||
Switch sOWFS01_expected "Światełka wg automatyki"
|
Switch sOWFS01_expected "Światełka wg automatyki"
|
||||||
Switch sOWFS02 "Lampka nocna [%s]" { onewire="deviceId=12.C56E45000000;propertyName=PIO.A" }
|
Switch sOWFS02 "Lampka nocna [%s]" { onewire="deviceId=12.C56E45000000;propertyName=PIO.A" }
|
||||||
/*Switch sOWFS03 "OneWire włącznik 03 [%s]" { onewire="deviceId=12.7B6845000000;propertyName=PIO.A" } */
|
Switch sOWFS03 "Głośniki salon [%s]" { onewire="deviceId=12.7B6845000000;propertyName=PIO.A" }
|
||||||
|
|
||||||
Number t_spizarnia "Spiżarnia [%.1f °C]" <temperature> (spizarnia, temperatury) { onewire="deviceId=28.807A2A060000;propertyName=latesttemp" }
|
Number t_spizarnia "Spiżarnia [%.1f °C]" <temperature> (spizarnia, temperatury) { onewire="deviceId=28.807A2A060000;propertyName=latesttemp" }
|
||||||
Number t_schowek "Schowek [%.1f °C]" <temperature> (schowek, temperatury) { onewire="deviceId=28.6B4925030000;propertyName=latesttemp" }
|
Number t_schowek "Schowek [%.1f °C]" <temperature> (schowek, temperatury) { onewire="deviceId=28.6B4925030000;propertyName=latesttemp" }
|
||||||
|
|||||||
15
rules/salon.głośniki.rules
Normal file
15
rules/salon.głośniki.rules
Normal file
@@ -0,0 +1,15 @@
|
|||||||
|
|
||||||
|
rule "Zasilanie głośników"
|
||||||
|
when
|
||||||
|
Item Kodi_State received update or
|
||||||
|
Item Mpd_quodlibet_StartStop received update
|
||||||
|
then
|
||||||
|
|
||||||
|
if (Kodi_State.state == "Play" || Mpd_quodlibet_StartStop.state == ON) {
|
||||||
|
sOWFS03.sendCommand(ON)
|
||||||
|
|
||||||
|
} else if (Kodi_State.state == "Stop" && Mpd_quodlibet_StartStop.state == OFF) {
|
||||||
|
sOWFS03.sendCommand(OFF)
|
||||||
|
}
|
||||||
|
end
|
||||||
|
|
||||||
@@ -23,6 +23,7 @@ sitemap pbrk label="Domek"
|
|||||||
|
|
||||||
Frame label="Media" {
|
Frame label="Media" {
|
||||||
Switch item=samsungtv
|
Switch item=samsungtv
|
||||||
|
Switch item=sOWFS03
|
||||||
Switch item=Mpd_quodlibet_StartStop icon="audio" mappings=[OFF="Pause", ON="Play"]
|
Switch item=Mpd_quodlibet_StartStop icon="audio" mappings=[OFF="Pause", ON="Play"]
|
||||||
|
|
||||||
/*Switch item=Mpd_quodlibet_StartStop label="Kontrola" icon="play" mappings=[ON="Play"] visibility=[Mpd_quodlibet_StartStop==OFF]
|
/*Switch item=Mpd_quodlibet_StartStop label="Kontrola" icon="play" mappings=[ON="Play"] visibility=[Mpd_quodlibet_StartStop==OFF]
|
||||||
|
|||||||
Reference in New Issue
Block a user