IFTTT Applet skipped, Unable to make web request: Error: ETIMEDOUT

I’ve been using IFTTT for quite a while now. Until now I only used it to store the data of the Withings body scale in a MySQL database. Now that’s gonna change since Bosch released their IFTTT integration for the Easycontrol CT200 room thermostat. Of course that has to get integrated into Domoticz and Pass2PHP …
View

Pass2PHP and Floorplan v3 for Domoticz

It’s been a while since I posted something here. For the urbex photo fans, I’m sorry but I don’t get out exploring that often anymore. Busy renovating the home.Anyway, here’s an update of my Pass2PHP advanced automation for Domoticz. The Github repository is now combined with the Floorplan files so you’ll get everything in one …
View

LUA Pass2PHP v2.2 minimal script

<?php error_reporting(E_ALL); ini_set(“display_errors”,”on”); date_default_timezone_set(‘Europe/Brussels’); define(‘time’,$_SERVER[‘REQUEST_TIME’]); $c=json_decode(base64_decode($_REQUEST[‘c’]),true); $s=json_decode(base64_decode($_REQUEST[‘s’]),true); $i=json_decode(base64_decode($_REQUEST[‘i’]),true); $t=json_decode(base64_decode($_REQUEST[‘t’]),true); $r=str_replace(” “,”_”,key($c)); if(function_exists(key($c))) key($c)(); elseif(function_exists($r)) $r(); //START USER FUNCTIONS function pirhall() { global $s,$i,$t; if($s[‘pirhall’==”On”]) { if($s[‘lighthall’]==’Off’) sw($i[‘hall’],’On’,’hall by pir’,1000); } } //END USERFUNCTIONS. Only change IP:PORT and ios,sms account details below function sw($idx,$action=””,$info=””,$Usleep=600000) { lg(“SWITCH “.$action.” “.$info); if(empty($action)) curl(“http://127.0.0.1:8084/json.htm?type=command&param=switchlight&idx=”.$idx.”&switchcmd=Toggle”); else curl(“http://127.0.0.1:8084/json.htm?type=command&param=switchlight&idx=”.$idx.”&switchcmd=”.$action); usleep($Usleep); } function sl($idx,$level,$info=””,$Usleep=600000) …
View

LUA Pass2PHP v2.2 complete script

Another update for my Pass2PHP script. This time a great difference in setup. The $events array isn’t used anymore. Instead each update instantly executes the function with his name, if the function exists of course. Spaces can’t be used in function names, therefor they need to be replaced by underscores. In the $s, $i and …
View

LUA Pass2PHP v2.1 minimal script

Please read the information on LUA Pass2PHP v2.1 complete script for information about new stuff in 2.1 This script only contains the minimal stuff to get you started. In this example a PIR with idx 123 will switch a light on. <?php $c=json_decode(base64_decode($_REQUEST[‘c’]),true); $s=json_decode(base64_decode($_REQUEST[‘s’]),true); $i=json_decode(base64_decode($_REQUEST[‘i’]),true); $t=json_decode(base64_decode($_REQUEST[‘t’]),true); $a=$s[key($c)];$devidx=$i[key($c)]; $events=array( 123=>’pirhall’ ); if(isset($events[$devidx]))$events[$devidx](); //START USERFUNCTIONS function pirhall(){ global $a,$s,$i,$t; …
View

LUA Pass2PHP v2.1 complete script

Make sure you also read the other posts about pass2php on https://egregius.be/tag/domoticz/ as they contain more information on how to implement this. the script_device_pass2php.lua script has basically stayd the same: JSON=loadfile(‘/volume1/@appstore/domoticz/var/scripts/JSON.lua’)() base64=loadfile(‘/volume1/@appstore/domoticz/var/scripts/base64.lua’)() c=base64.encode(JSON:encode(devicechanged)) s=base64.encode(JSON:encode(otherdevices)) i=base64.encode(JSON:encode(otherdevices_idx)) t=base64.encode(JSON:encode(otherdevices_lastupdate)) os.execute(‘curl -s –data “c=’..c..’&s=’..s..’&i=’..i..’&t=’..t..'” http://127.0.0.1/secure/pass2php.php &’) commandArray={} return commandArray In the PHP file some changes are made in my own function. …
View

LUA Pass2PHP v2.0 Small example and explanation

Based on the script LUA Pass2PHP v2.0 a small example: 2 pirs in this script. They have idx 123 and idx 234. In the $events array we define wich function is called when this $idx is the changed device. Have a look at LUA Pass2PHP v2.0 for many more examples and conditional switching. Some explanation …
View

LUA Pass2PHP v2.0

Vervolg op LUA Pass2php In grote lijnen dezelfde werkwijze als de vorige versie, vooral de functies zijn een groot stuk eenvoudiger geworden waardoor de code wat overzichtelijker en makkelijker te gebruiken is. Download deze 2 bestanden en plaats ze in de Domoticz scripts folder: JSON.lua ee5_base64.lua Maak in Domoticz Events een device lua script, pas eventueel …
View

PHP Floorplan for Domoticz Extra screenshots

De ontwikkeling van mijn floorplan, vooral dan het cron gedeelte is onverminderd verder gegaan. Het systeem werd uitgebreid met koppelingen naar de Synology Nas, een camera met bewegingsdetectie werd toegevoegd en de interface kreeg hier en daar wel wat aanpassingen. De code is te vinden op Github: https://github.com/Egregius/PHP-Custom-Floorplan-for-Domoticz Enkele screenshots: