balkon: zamiana sterowania lampkami z sonoffa na shelly
This commit is contained in:
@@ -15,7 +15,7 @@ sonoff01
|
|||||||
sonoff02 - lampka stół
|
sonoff02 - lampka stół
|
||||||
sonoff03 - łazienka wiatrak
|
sonoff03 - łazienka wiatrak
|
||||||
sonoff04 -
|
sonoff04 -
|
||||||
sonoff05 - lampki balkonowe
|
sonoff05 -
|
||||||
sonoff06 - przedpokój touch przy drzwiach
|
sonoff06 - przedpokój touch przy drzwiach
|
||||||
sonoff07 - wc wiatrak
|
sonoff07 - wc wiatrak
|
||||||
d1mini01 - okap
|
d1mini01 - okap
|
||||||
@@ -24,6 +24,7 @@ d1mini03 - prototyp / pilot na kanapie
|
|||||||
d1mini04 - odświeżacz
|
d1mini04 - odświeżacz
|
||||||
d1mini05 - wskazówka interneu
|
d1mini05 - wskazówka interneu
|
||||||
d1mini06 - schodowy przy salonie
|
d1mini06 - schodowy przy salonie
|
||||||
|
shelly01 - oświetlenie balkonu
|
||||||
*/
|
*/
|
||||||
|
|
||||||
/* moc sygnalu */
|
/* moc sygnalu */
|
||||||
@@ -50,9 +51,8 @@ Number wSONOFF03 "Wifi s03 wiatrak [%d dB]" <wifi> (wifi) { mqtt="<[motherqtt:/s
|
|||||||
Switch rSONOFF03 "Conn s03 [%s]" { mqtt="<[motherqtt:/sonoff03/status:state:MAP(espeasy_lwt.map)]" }
|
Switch rSONOFF03 "Conn s03 [%s]" { mqtt="<[motherqtt:/sonoff03/status:state:MAP(espeasy_lwt.map)]" }
|
||||||
|
|
||||||
|
|
||||||
/* lampki balkonowe */
|
Switch sSONOFF05 "sonoff5" <whites> { mqtt=">[motherqtt:/sonoff05/gpio/12:command:ON:1],>[motherqtt:/sonoff05/gpio/12:command:OFF:0]" }
|
||||||
Switch sSONOFF05 "Lampki balkonowe" <whites> { mqtt=">[motherqtt:/sonoff05/gpio/12:command:ON:1],>[motherqtt:/sonoff05/gpio/12:command:OFF:0]" }
|
Number wSONOFF05 "Wifi s05 [%d dB]" <wifi> (wifi) { mqtt="<[motherqtt:/sonoff05/sysinfo/wifi:state:default]" }
|
||||||
Number wSONOFF05 "Wifi s05 balkon [%d dB]" <wifi> (wifi) { mqtt="<[motherqtt:/sonoff05/sysinfo/wifi:state:default]" }
|
|
||||||
Switch rSONOFF05 "Conn s05 [%s]" { mqtt="<[motherqtt:/sonoff05/lwt:state:MAP(espeasy_lwt.map)]" }
|
Switch rSONOFF05 "Conn s05 [%s]" { mqtt="<[motherqtt:/sonoff05/lwt:state:MAP(espeasy_lwt.map)]" }
|
||||||
|
|
||||||
/* przedpokój - sonoff przy drzwiach wejściowych */
|
/* przedpokój - sonoff przy drzwiach wejściowych */
|
||||||
@@ -79,7 +79,7 @@ Switch rSONOFF07 "Conn s07 [%s]" { mqtt="<[motherqtt:/sonoff07/lwt:state:MAP(esp
|
|||||||
relay 2 gpio5
|
relay 2 gpio5
|
||||||
*/
|
*/
|
||||||
Switch sSONOFF08a "Sypialnia cottonballs" <whites> { mqtt=">[motherqtt:/sonoff08/gpio/12:command:ON:1],>[motherqtt:/sonoff08/gpio/12:command:OFF:0]" }
|
Switch sSONOFF08a "Sypialnia cottonballs" <whites> { mqtt=">[motherqtt:/sonoff08/gpio/12:command:ON:1],>[motherqtt:/sonoff08/gpio/12:command:OFF:0]" }
|
||||||
Switch sSONOFF08b "Sypialnia lampeczki" <whites> { mqtt=">[motherqtt:/sonoff08/gpio/5:command:ON:1],>[motherqtt:/sonoff08/gpio/5:command:OFF:0]" }
|
Switch sSONOFF08b "Sypialnia nawilżacz" <whites> { mqtt=">[motherqtt:/sonoff08/gpio/5:command:ON:1],>[motherqtt:/sonoff08/gpio/5:command:OFF:0]" }
|
||||||
Switch sSONOFF08_ext "Sypialnia przycisk" { mqtt="<[motherqtt:/sonoff08/button/ext:state:MAP(espeasy_onoff.map)]" }
|
Switch sSONOFF08_ext "Sypialnia przycisk" { mqtt="<[motherqtt:/sonoff08/button/ext:state:MAP(espeasy_onoff.map)]" }
|
||||||
Number wSONOFF08 "Wifi s08 dual [%d dB]" <wifi> (wifi) { mqtt="<[motherqtt:/sonoff08/sysinfo/wifi:state:default]" }
|
Number wSONOFF08 "Wifi s08 dual [%d dB]" <wifi> (wifi) { mqtt="<[motherqtt:/sonoff08/sysinfo/wifi:state:default]" }
|
||||||
Switch rSONOFF08 "Conn s08 [%s]" { mqtt="<[motherqtt:/sonoff08/lwt:state:MAP(espeasy_lwt.map)]" }
|
Switch rSONOFF08 "Conn s08 [%s]" { mqtt="<[motherqtt:/sonoff08/lwt:state:MAP(espeasy_lwt.map)]" }
|
||||||
@@ -146,3 +146,12 @@ Switch sD1MINI06LED "Przedpokój LED" <whites> { mqtt=">[motherqtt:/d1mini06/gpi
|
|||||||
Switch sD1MINI06KEY "Włącznik hall przy salonie [%s]" { mqtt="<[motherqtt:/d1mini06/salon/switch:state:MAP(espeasy_onoff.map)]" } /* GPIO14 */
|
Switch sD1MINI06KEY "Włącznik hall przy salonie [%s]" { mqtt="<[motherqtt:/d1mini06/salon/switch:state:MAP(espeasy_onoff.map)]" } /* GPIO14 */
|
||||||
Number wD1MINI06 "Wifi d1m06 przedpokój [%d dB]" <wifi> (wifi) { mqtt="<[motherqtt:/d1mini06/wifi/:state:default]" }
|
Number wD1MINI06 "Wifi d1m06 przedpokój [%d dB]" <wifi> (wifi) { mqtt="<[motherqtt:/d1mini06/wifi/:state:default]" }
|
||||||
Switch rD1MINI06 "Conn d1m06 [%s]" { mqtt="<[motherqtt:/d1mini06/lwt:state:MAP(espeasy_lwt.map)]" }
|
Switch rD1MINI06 "Conn d1m06 [%s]" { mqtt="<[motherqtt:/d1mini06/lwt:state:MAP(espeasy_lwt.map)]" }
|
||||||
|
|
||||||
|
|
||||||
|
/* lampki balkonowe */
|
||||||
|
Switch sSHELLY01 "Lampki balkonowe" <whites> { mqtt=">[motherqtt:/shelly01/gpio/4:command:ON:1],>[motherqtt:/shelly01/gpio/4:command:OFF:0]" }
|
||||||
|
/*Switch sSHELLY01KEY "Włącznik hall przy drzwiach wejściowych [%s]" { mqtt="<[motherqtt:/shelly01/gpio/5:state:MAP(espeasy_onoff.map)]" }*/
|
||||||
|
Number wSHELLY01 "Wifi sh01 balkon [%d dB]" <wifi> (wifi) { mqtt="<[motherqtt:/shelly01/wifi/:state:default]" }
|
||||||
|
Switch rSHELLY01 "Conn sh01 [%s]" { mqtt="<[motherqtt:/shelly01/lwt:state:MAP(espeasy_lwt.map)]" }
|
||||||
|
|
||||||
|
|
||||||
|
|||||||
@@ -7,7 +7,7 @@ then
|
|||||||
sSONOFF02.sendCommand(ON)
|
sSONOFF02.sendCommand(ON)
|
||||||
|
|
||||||
/* balkon */
|
/* balkon */
|
||||||
sSONOFF05.sendCommand(OFF)
|
sSHELLY01.sendCommand(ON)
|
||||||
end
|
end
|
||||||
|
|
||||||
|
|
||||||
@@ -19,7 +19,7 @@ then
|
|||||||
sSONOFF02.sendCommand(OFF)
|
sSONOFF02.sendCommand(OFF)
|
||||||
|
|
||||||
/* balkon */
|
/* balkon */
|
||||||
sSONOFF05.sendCommand(OFF)
|
sSHELLY01.sendCommand(OFF)
|
||||||
end
|
end
|
||||||
|
|
||||||
|
|
||||||
@@ -33,7 +33,7 @@ then
|
|||||||
sD1MINI01_lampki_sufitowe.sendCommand(ON)
|
sD1MINI01_lampki_sufitowe.sendCommand(ON)
|
||||||
|
|
||||||
/* balkon */
|
/* balkon */
|
||||||
sSONOFF05.sendCommand(ON)
|
sSHELLY01.sendCommand(ON)
|
||||||
end
|
end
|
||||||
|
|
||||||
/* HOLIDAY */
|
/* HOLIDAY */
|
||||||
@@ -100,6 +100,7 @@ then
|
|||||||
dSONOFF02LED.sendCommand(0)
|
dSONOFF02LED.sendCommand(0)
|
||||||
end
|
end
|
||||||
|
|
||||||
|
|
||||||
rule "Zgaś stółlampkę, sufitowe i nablatowe wieczorem"
|
rule "Zgaś stółlampkę, sufitowe i nablatowe wieczorem"
|
||||||
when
|
when
|
||||||
Time cron "0 15 22 * * ?"
|
Time cron "0 15 22 * * ?"
|
||||||
@@ -113,7 +114,19 @@ then
|
|||||||
sD1MINI02MOS.sendCommand(OFF)
|
sD1MINI02MOS.sendCommand(OFF)
|
||||||
|
|
||||||
/* balkon */
|
/* balkon */
|
||||||
sSONOFF05.sendCommand(OFF)
|
sSHELLY01.sendCommand(OFF)
|
||||||
|
end
|
||||||
|
|
||||||
|
|
||||||
|
/* na wypadek rebootów sonoffa */
|
||||||
|
rule "Synchronizuj balkon & lampka po restarcie"
|
||||||
|
when
|
||||||
|
Item rSHELLY01 changed to ON or
|
||||||
|
Item rSONOFF02 changed to ON
|
||||||
|
then
|
||||||
|
logInfo("S02,SH01", "Reappeared, applying state balkon {}, lampka {}", sSHELLY01.state, sSONOFF02.state)
|
||||||
|
sSONOFF02.sendCommand(sSONOFF02.state.toString)
|
||||||
|
sSHELLY01.sendCommand(sSHELLY01.state.toString)
|
||||||
end
|
end
|
||||||
|
|
||||||
/*
|
/*
|
||||||
|
|||||||
@@ -20,7 +20,7 @@ sitemap pbrk label="Domek"
|
|||||||
Switch item=sD1MINI01_lampki_sufitowe
|
Switch item=sD1MINI01_lampki_sufitowe
|
||||||
Switch item=sSONOFF01
|
Switch item=sSONOFF01
|
||||||
Switch item=sSONOFF06
|
Switch item=sSONOFF06
|
||||||
Switch item=sSONOFF05
|
Switch item=sSHELLY01
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
|
|||||||
Reference in New Issue
Block a user