To bych tam asi musel přidat podmínku moji přítomnosti/nepřítomnosti... Ale přes den by to vydržet mělo, protože tam jde impuls jenom při východu slunce.
Kdyžtak se na to podívej.
Kód: Vybrat vše
[{"id":"11f6ac49.d2cca4","type":"tab","label":"NUKI - zadní vchod","disabled":false,"info":""},{"id":"fe5cf43.9d6f188","type":"api-call-service","z":"11f6ac49.d2cca4","name":"odemkni","server":"c10959a0.9ba6e8","version":1,"debugenabled":false,"service_domain":"lock","service":"unlock","entityId":"lock.zadni_dvere","data":"","dataType":"jsonata","mergecontext":"","output_location":"","output_location_type":"none","mustacheAltTags":false,"x":700,"y":304,"wires":[["b68de301.04668"]]},{"id":"e1933b0d.7309c8","type":"api-current-state","z":"11f6ac49.d2cca4","name":"je zamčeno?","server":"c10959a0.9ba6e8","version":1,"outputs":2,"halt_if":"locked","halt_if_type":"str","halt_if_compare":"is","override_topic":false,"entity_id":"lock.zadni_dvere","state_type":"str","state_location":"payload","override_payload":"msg","entity_location":"data","override_data":"msg","blockInputOverrides":false,"x":566,"y":192,"wires":[["fe5cf43.9d6f188"],[]]},{"id":"1071b333.61bd9d","type":"api-current-state","z":"11f6ac49.d2cca4","name":"je odemčeno?","server":"c10959a0.9ba6e8","version":1,"outputs":2,"halt_if":"unlocked","halt_if_type":"str","halt_if_compare":"is","override_topic":false,"entity_id":"lock.zadni_dvere","state_type":"str","state_location":"payload","override_payload":"msg","entity_location":"data","override_data":"msg","blockInputOverrides":false,"x":608,"y":576,"wires":[["2976c09d.942d"],[]]},{"id":"2976c09d.942d","type":"api-call-service","z":"11f6ac49.d2cca4","name":"zamkni","server":"c10959a0.9ba6e8","version":1,"debugenabled":false,"service_domain":"lock","service":"lock","entityId":"lock.zadni_dvere","data":"","dataType":"jsonata","mergecontext":"","output_location":"","output_location_type":"none","mustacheAltTags":false,"x":722,"y":688,"wires":[["bd650fc7.5d346"]]},{"id":"b68de301.04668","type":"api-call-service","z":"11f6ac49.d2cca4","name":"zpráva \"zadní dveře ODEMČENY\"","server":"c10959a0.9ba6e8","version":1,"debugenabled":false,"service_domain":"telegram_bot","service":"send_message","entityId":"","data":"{\"message\":\"zadní dveře ODEMČENY\"}","dataType":"json","mergecontext":"","output_location":"","output_location_type":"none","mustacheAltTags":false,"x":908,"y":192,"wires":[[]]},{"id":"bd650fc7.5d346","type":"api-call-service","z":"11f6ac49.d2cca4","name":"zpráva \"zadní dveře ZAMČENY\"","server":"c10959a0.9ba6e8","version":1,"debugenabled":false,"service_domain":"telegram_bot","service":"send_message","entityId":"","data":"{\"message\":\"zadní dveře ZAMČENY\"}","dataType":"json","mergecontext":"","output_location":"","output_location_type":"none","mustacheAltTags":false,"x":898,"y":576,"wires":[[]]},{"id":"86b0cc76.864db8","type":"comment","z":"11f6ac49.d2cca4","name":"Odemčení zadních dveří při východu slunce, nejdříve však v 7:00","info":"","x":560,"y":96,"wires":[]},{"id":"cf3d7037.951ee8","type":"comment","z":"11f6ac49.d2cca4","name":"Zamčení zadních dveří při západu slunce, nejpozději však v 21:00","info":"","x":560,"y":480,"wires":[]},{"id":"153fa516.65a9b3","type":"bigtimer","z":"11f6ac49.d2cca4","outtopic":"","outpayload1":"","outpayload2":"","name":"od východu do 9:00","comment":"","lat":"50.7006588","lon":"14.4265413","starttime":"5003","endtime":"540","starttime2":0,"endtime2":0,"startoff":"0","endoff":"0","startoff2":0,"endoff2":0,"offs":0,"outtext1":"","outtext2":"","timeout":"1440","sun":true,"mon":true,"tue":true,"wed":true,"thu":true,"fri":true,"sat":true,"jan":true,"feb":true,"mar":true,"apr":true,"may":true,"jun":true,"jul":true,"aug":true,"sep":true,"oct":true,"nov":true,"dec":true,"day1":0,"month1":0,"day2":0,"month2":0,"day3":0,"month3":0,"day4":0,"month4":0,"day5":0,"month5":0,"day6":0,"month6":0,"day7":0,"month7":0,"day8":0,"month8":0,"day9":0,"month9":0,"day10":0,"month10":0,"day11":0,"month11":0,"day12":0,"month12":0,"d1":0,"w1":0,"d2":0,"w2":0,"d3":0,"w3":0,"d4":0,"w4":0,"d5":0,"w5":0,"d6":0,"w6":0,"xday1":0,"xmonth1":0,"xday2":0,"xmonth2":0,"xday3":0,"xmonth3":0,"xday4":0,"xmonth4":0,"xday5":0,"xmonth5":0,"xday6":0,"xmonth6":0,"xday7":0,"xmonth7":0,"xday8":0,"xmonth8":0,"xday9":0,"xmonth9":0,"xday10":0,"xmonth10":0,"xday11":0,"xmonth11":0,"xday12":0,"xmonth12":0,"xd1":0,"xw1":0,"xd2":0,"xw2":0,"xd3":0,"xw3":0,"xd4":0,"xw4":0,"xd5":0,"xw5":0,"xd6":0,"xw6":0,"suspend":false,"random":false,"randon1":false,"randoff1":false,"randon2":false,"randoff2":false,"repeat":true,"atstart":true,"odd":false,"even":false,"x":164,"y":304,"wires":[[],["e1533561.a46cb8"],[]]},{"id":"e1533561.a46cb8","type":"switch","z":"11f6ac49.d2cca4","name":"jenom \"1\"","property":"payload","propertyType":"msg","rules":[{"t":"eq","v":"1","vt":"str"}],"checkall":"true","repair":false,"outputs":1,"x":332,"y":192,"wires":[["8119170b.2beb58"]]},{"id":"8119170b.2beb58","type":"time-range-switch","z":"11f6ac49.d2cca4","name":"od 7:00 do 9:00","lat":"","lon":"","startTime":"07:00","endTime":"09:00","startOffset":0,"endOffset":0,"x":448,"y":304,"wires":[["e1933b0d.7309c8"],[]]},{"id":"26f68134.bed526","type":"bigtimer","z":"11f6ac49.d2cca4","outtopic":"","outpayload1":"","outpayload2":"","name":"od západu do 21:00","comment":"","lat":"50.7006588","lon":"14.4265413","starttime":"5004","endtime":"1260","starttime2":0,"endtime2":0,"startoff":"0","endoff":"0","startoff2":0,"endoff2":0,"offs":0,"outtext1":"","outtext2":"","timeout":"1440","sun":true,"mon":true,"tue":true,"wed":true,"thu":true,"fri":true,"sat":true,"jan":true,"feb":true,"mar":true,"apr":true,"may":true,"jun":true,"jul":true,"aug":true,"sep":true,"oct":true,"nov":true,"dec":true,"day1":0,"month1":0,"day2":0,"month2":0,"day3":0,"month3":0,"day4":0,"month4":0,"day5":0,"month5":0,"day6":0,"month6":0,"day7":0,"month7":0,"day8":0,"month8":0,"day9":0,"month9":0,"day10":0,"month10":0,"day11":0,"month11":0,"day12":0,"month12":0,"d1":0,"w1":0,"d2":0,"w2":0,"d3":0,"w3":0,"d4":0,"w4":0,"d5":0,"w5":0,"d6":0,"w6":0,"xday1":0,"xmonth1":0,"xday2":0,"xmonth2":0,"xday3":0,"xmonth3":0,"xday4":0,"xmonth4":0,"xday5":0,"xmonth5":0,"xday6":0,"xmonth6":0,"xday7":0,"xmonth7":0,"xday8":0,"xmonth8":0,"xday9":0,"xmonth9":0,"xday10":0,"xmonth10":0,"xday11":0,"xmonth11":0,"xday12":0,"xmonth12":0,"xd1":0,"xw1":0,"xd2":0,"xw2":0,"xd3":0,"xw3":0,"xd4":0,"xw4":0,"xd5":0,"xw5":0,"xd6":0,"xw6":0,"suspend":false,"random":false,"randon1":false,"randoff1":false,"randon2":false,"randoff2":false,"repeat":true,"atstart":true,"odd":false,"even":false,"x":164,"y":688,"wires":[[],["64e869c2.a53298"],[]]},{"id":"64e869c2.a53298","type":"switch","z":"11f6ac49.d2cca4","name":"jenom \"1\"","property":"payload","propertyType":"msg","rules":[{"t":"eq","v":"1","vt":"str"}],"checkall":"true","repair":false,"outputs":1,"x":380,"y":576,"wires":[["97255b8c.88046"]]},{"id":"97255b8c.88046","type":"time-range-switch","z":"11f6ac49.d2cca4","name":"od 16:00 do 21:01","lat":"","lon":"","startTime":"16:00","endTime":"21:01","startOffset":0,"endOffset":0,"x":458,"y":688,"wires":[["1071b333.61bd9d"],[]]},{"id":"74cc95ee.ca322c","type":"inject","z":"11f6ac49.d2cca4","name":"zamkni ve 21:00","props":[{"p":"payload"},{"p":"topic","vt":"str"}],"repeat":"","crontab":"00 21 * * *","once":false,"onceDelay":0.1,"topic":"","payload":"1","payloadType":"num","x":154,"y":576,"wires":[["64e869c2.a53298"]]},{"id":"c10959a0.9ba6e8","type":"server","name":"Home Assistant","legacy":true,"addon":true,"rejectUnauthorizedCerts":true,"ha_boolean":"y|yes|true|on|home|open","connectionDelay":true,"cacheJson":true}]