Различия
Показаны различия между двумя версиями страницы.
sw:openhab:examples:light:ecma-v2 [2023/12/19 21:08] – создано lazygatto | sw:openhab:examples:light:ecma-v2 [2023/12/19 21:09] (текущий) – lazygatto | ||
---|---|---|---|
Строка 4: | Строка 4: | ||
<sxh> | <sxh> | ||
+ | |||
configuration: | configuration: | ||
triggers: | triggers: | ||
Строка 16: | Строка 17: | ||
- inputs: {} | - inputs: {} | ||
id: " | id: " | ||
- | configuration: | ||
- | type: application/ | ||
- | script: > | ||
- | // котельная | ||
- | |||
- | //if (BoilerRoom_SW_S_1_2.state == CLOSED || BoilerRoom_SW_E_1_2.state == CLOSED) { | ||
- | |||
- | // if (m1p08out.state == OFF) { | ||
- | |||
- | // sendCommand(m1p08out, | ||
- | |||
- | // postUpdate(m1p08out, | ||
- | |||
- | // } else { | ||
- | |||
- | // sendCommand(m1p08out, | ||
- | |||
- | // postUpdate(m1p08out, | ||
- | |||
- | // } | ||
- | |||
- | //} | ||
- | |||
- | |||
- | // подсветка лестницы | ||
- | |||
- | //if (Hall_1F_SW_S_1_1.state == CLOSED || Hall_2F_SW_S_1_1.state == CLOSED) { | ||
- | |||
- | // if (m4p10out.state == OFF) { | ||
- | |||
- | // sendCommand(m4p10out, | ||
- | |||
- | // postUpdate(m4p10out, | ||
- | |||
- | // } else { | ||
- | |||
- | // sendCommand(m4p10out, | ||
- | |||
- | // postUpdate(m4p10out, | ||
- | |||
- | // } | ||
- | |||
- | //} | ||
- | |||
- | |||
- | // нижний свет холл 2 этаж | ||
- | |||
- | //if (Hall_2F_SW_S_1_2.state == CLOSED) { | ||
- | |||
- | // if (m5p10out.state == OFF) { | ||
- | |||
- | // sendCommand(m5p10out, | ||
- | |||
- | // postUpdate(m5p10out, | ||
- | |||
- | // } else { | ||
- | |||
- | // sendCommand(m5p10out, | ||
- | |||
- | // postUpdate(m5p10out, | ||
- | |||
- | // } | ||
- | |||
- | //} | ||
- | |||
- | |||
- | // гараж из прихожей | ||
- | |||
- | if (Entry_SW_N_1_1.state == CLOSED) { | ||
- | if (m7p11out.state == OFF) { | ||
- | sendCommand(m7p11out, | ||
- | postUpdate(m7p11out, | ||
- | sendCommand(m7p22out, | ||
- | postUpdate(m7p22out, | ||
- | } else { | ||
- | sendCommand(m7p11out, | ||
- | postUpdate(m7p11out, | ||
- | sendCommand(m7p22out, | ||
- | postUpdate(m7p22out, | ||
- | } | ||
- | } | ||
- | |||
- | |||
- | // ванная | ||
- | |||
- | //if (Hall_2F_SW_S_2_2.state == CLOSED) { | ||
- | |||
- | // if (m1p11out.state == OFF) { | ||
- | |||
- | // sendCommand(m1p11out, | ||
- | |||
- | // postUpdate(m1p11out, | ||
- | |||
- | // } else { | ||
- | |||
- | // sendCommand(m1p11out, | ||
- | |||
- | // postUpdate(m1p11out, | ||
- | |||
- | // } | ||
- | |||
- | //} | ||
- | |||
- | |||
- | // | ||
- | |||
- | |||
- | |||
- | //else { | ||
- | |||
- | // logInfo(" | ||
- | // | ||
- | // sendCommand(m1p8_Out, | ||
- | // postUpdate(m1p8_Out, | ||
- | //} | ||
- | |||
- | // | ||
- | |||
- | |||
- | |||
- | |||
- | // if (g1F_DiningRoom_N_1_2.state == CLOSED) { | ||
- | | ||
- | // // | ||
- | | ||
- | // // улица котельная | ||
- | |||
- | // if (m7p7out.state == OFF) { | ||
- | |||
- | // | ||
- | |||
- | // | ||
- | |||
- | // } else { | ||
- | |||
- | // | ||
- | |||
- | // | ||
- | |||
- | // } | ||
- | |||
- | |||
- | // } | ||
- | |||
- | |||
- | // // столовая | ||
- | |||
- | // if (g1F_DiningRoom_N_2_2.state == CLOSED) { | ||
- | | ||
- | // // | ||
- | |||
- | |||
- | // if (m1p12out.state == OFF) { | ||
- | |||
- | // | ||
- | |||
- | // | ||
- | |||
- | // } else { | ||
- | |||
- | // | ||
- | |||
- | // | ||
- | |||
- | // } | ||
- | |||
- | |||
- | // } | ||
- | |||
- | |||
- | // // кухня рабочая зона | ||
- | |||
- | // if (m7p40_In.state == CLOSED OR m7p41_In.state == CLOSED OR ) { | ||
- | |||
- | |||
- | // // | ||
- | | ||
- | // if (m1p42_16pwm_p15.state == 0) { | ||
- | |||
- | // | ||
- | |||
- | // | ||
- | |||
- | // } else if (m1p42_16pwm_p15.state == 30) { | ||
- | |||
- | // | ||
- | |||
- | // | ||
- | |||
- | // } else if (m1p42_16pwm_p15.state == 60) { | ||
- | |||
- | // | ||
- | |||
- | // | ||
- | |||
- | // } else if (m1p42_16pwm_p15.state == 100) { | ||
- | |||
- | // | ||
- | |||
- | // | ||
- | |||
- | // | ||
- | |||
- | |||
- | // } | ||
- | |||
- | |||
- | // // | ||
- | |||
- | |||
- | |||
- | // //else { | ||
- | |||
- | // // logInfo(" | ||
- | |||
- | // // | ||
- | |||
- | // // sendCommand(m1p8_Out, | ||
- | |||
- | // // postUpdate(m1p8_Out, | ||
- | |||
- | // //} | ||
- | |||
- | // // | ||
- | type: script.ScriptAction | ||
- | - inputs: {} | ||
- | id: " | ||
configuration: | configuration: | ||
type: application/ | type: application/ |