Wisselschakelaar I think indeed not possible. You'll have to fake it but then you have to have a domoticz that is always online..... otherwise... WAF... no go no go. I believe KAKU now has a solution for that ,,, but then again... it is 433 mhz.. So we don't want to go that way. Other idea... Smart bulbs... Leave everything always on .... and control the lights with motion sensors... In case of emergency you use one of the switches to switch on the light. That is how I solved it as well for those specific cases.ropske wrote: ↑Sunday 07 April 2019 21:49Just searched for this device and it seems nice.sincze wrote: ↑Friday 05 April 2019 8:07 Wall switch are NEO Coolcam.(1 or 2 channel) blue brown and black wire required!!!
Around 20 euro I buy them on AliExpress.
Roller shutters are controlled automatically with Domoticz or with simple remote (hardly used) hahaha.
Sent from my ONEPLUS A6003 using Tapatalk
But you can only use it when you have 1 switching point (nederlands: enkel als je een enkelpolige schakelaar hebt)
For example if you need a switching point for 2 places (nederlands: wisselschakelaar)
Is it also possible?
Thanks!
Pass2PHP
Moderator: leecollings
- sincze
- Posts: 1300
- Joined: Monday 02 June 2014 22:46
- Target OS: Raspberry Pi / ODroid
- Domoticz version: 2024.4
- Location: Netherlands / Breda Area
- Contact:
Re: Pass2PHP
Pass2php
LAN: RFLink, P1, OTGW, MySensors
USB: RFXCom, ZWave, Sonoff 3
MQTT: ZIgbee2MQTT,
ZWAVE: Zwave-JS-UI
WIFI: Mi-light, Tasmota, Xiaomi Shelly
Solar: Omnik, PVOutput
Video: Kodi, Harmony HUB, Chromecast
Sensors: You name it I got 1.
LAN: RFLink, P1, OTGW, MySensors
USB: RFXCom, ZWave, Sonoff 3
MQTT: ZIgbee2MQTT,
ZWAVE: Zwave-JS-UI
WIFI: Mi-light, Tasmota, Xiaomi Shelly
Solar: Omnik, PVOutput
Video: Kodi, Harmony HUB, Chromecast
Sensors: You name it I got 1.
- sincze
- Posts: 1300
- Joined: Monday 02 June 2014 22:46
- Target OS: Raspberry Pi / ODroid
- Domoticz version: 2024.4
- Location: Netherlands / Breda Area
- Contact:
Re: Pass2PHP
Goodie goodie. lets find out.Egregius wrote: ↑Monday 08 April 2019 5:19 Published the new version on https://github.com/Egregius/PHP-Floorpl ... r-Domoticz
It's a combined repository for pass2php and php floorplan, because they're very much linked to each other.
From now on the repository is updated automagically
Of course, still lot's of work to do in the wiki. Feel free to be a contributor and help with that
It looks amazing.
Amazing Job.
It seems more DB than CACHE oriented now.
Might scare some of our starting fans.
Did scare me as I am not using the Floorplans. Maybe I should
Pass2php
LAN: RFLink, P1, OTGW, MySensors
USB: RFXCom, ZWave, Sonoff 3
MQTT: ZIgbee2MQTT,
ZWAVE: Zwave-JS-UI
WIFI: Mi-light, Tasmota, Xiaomi Shelly
Solar: Omnik, PVOutput
Video: Kodi, Harmony HUB, Chromecast
Sensors: You name it I got 1.
LAN: RFLink, P1, OTGW, MySensors
USB: RFXCom, ZWave, Sonoff 3
MQTT: ZIgbee2MQTT,
ZWAVE: Zwave-JS-UI
WIFI: Mi-light, Tasmota, Xiaomi Shelly
Solar: Omnik, PVOutput
Video: Kodi, Harmony HUB, Chromecast
Sensors: You name it I got 1.
- Egregius
- Posts: 2582
- Joined: Thursday 09 April 2015 12:19
- Target OS: Linux
- Domoticz version: v2024.7
- Location: Beitem, BE
- Contact:
Re: Pass2PHP
You can use regular push buttons for that. Everywhere I needed 2 or 3 switches I changed them to push buttons with a Qubino/Fibaro relay or dimmer.ropske wrote: ↑Sunday 07 April 2019 21:49 Just searched for this device and it seems nice.
But you can only use it when you have 1 switching point (nederlands: enkel als je een enkelpolige schakelaar hebt)
For example if you need a switching point for 2 places (nederlands: wisselschakelaar)
Is it also possible?
Thanks!
We hardly ever use them because all the lights turn on automatically when there's movement. Basically it's only in the bedrooms that they're used.
- Egregius
- Posts: 2582
- Joined: Thursday 09 April 2015 12:19
- Target OS: Linux
- Domoticz version: v2024.7
- Location: Beitem, BE
- Contact:
Re: Pass2PHP
You definitely should try it. It's a lot easier for daily use than the domoticz gui. I have 126 switches on the switches tab, that's just not usable in the domoticz gui on a smartphone. It also gives you the possibility to integrate a lot of other stuff in the same gui, like Kodi control pages, receiver control,...
It makes it also a lot easier to set secondary modes for switches that then bypasses the automatic stuff.
But indeed, everything is MySQL based now. Might look difficult, on the other hand, the apcu stuff before was also not that easy to get working.
- sincze
- Posts: 1300
- Joined: Monday 02 June 2014 22:46
- Target OS: Raspberry Pi / ODroid
- Domoticz version: 2024.4
- Location: Netherlands / Breda Area
- Contact:
Re: Pass2PHP
Damn I forgot about that one. Robbshop has detailed installation guides available .Egregius wrote: ↑Tuesday 09 April 2019 6:36You can use regular push buttons for that. Everywhere I needed 2 or 3 switches I changed them to push buttons with a Qubino/Fibaro relay or dimmer.ropske wrote: ↑Sunday 07 April 2019 21:49 Just searched for this device and it seems nice.
But you can only use it when you have 1 switching point (nederlands: enkel als je een enkelpolige schakelaar hebt)
For example if you need a switching point for 2 places (nederlands: wisselschakelaar)
Is it also possible?
Thanks!
We hardly ever use them because all the lights turn on automatically when there's movement. Basically it's only in the bedrooms that they're used.
But for my wallet it was a bit to expensive as they are hardly used indeed.
Pass2php
LAN: RFLink, P1, OTGW, MySensors
USB: RFXCom, ZWave, Sonoff 3
MQTT: ZIgbee2MQTT,
ZWAVE: Zwave-JS-UI
WIFI: Mi-light, Tasmota, Xiaomi Shelly
Solar: Omnik, PVOutput
Video: Kodi, Harmony HUB, Chromecast
Sensors: You name it I got 1.
LAN: RFLink, P1, OTGW, MySensors
USB: RFXCom, ZWave, Sonoff 3
MQTT: ZIgbee2MQTT,
ZWAVE: Zwave-JS-UI
WIFI: Mi-light, Tasmota, Xiaomi Shelly
Solar: Omnik, PVOutput
Video: Kodi, Harmony HUB, Chromecast
Sensors: You name it I got 1.
-
- Posts: 483
- Joined: Tuesday 12 August 2014 5:37
- Target OS: Raspberry Pi / ODroid
- Domoticz version: V3_8394
- Location: Rumbeke,Belgium
- Contact:
Re: Pass2PHP
Do you have any idea at what time interval you need to reinstall the battery for the motion sensors?sincze wrote: ↑Tuesday 09 April 2019 9:11Damn I forgot about that one. Robbshop has detailed installation guides available .Egregius wrote: ↑Tuesday 09 April 2019 6:36You can use regular push buttons for that. Everywhere I needed 2 or 3 switches I changed them to push buttons with a Qubino/Fibaro relay or dimmer.ropske wrote: ↑Sunday 07 April 2019 21:49 Just searched for this device and it seems nice.
But you can only use it when you have 1 switching point (nederlands: enkel als je een enkelpolige schakelaar hebt)
For example if you need a switching point for 2 places (nederlands: wisselschakelaar)
Is it also possible?
Thanks!
We hardly ever use them because all the lights turn on automatically when there's movement. Basically it's only in the bedrooms that they're used.
But for my wallet it was a bit to expensive as they are hardly used indeed.
i'm using the fibaro motion sensor and its sending temperature and luminance at 5min interval.
But my battery is getting low fast (3months)
Thanks, and btw, looking awesome to install the new pass2php in my new house
- sincze
- Posts: 1300
- Joined: Monday 02 June 2014 22:46
- Target OS: Raspberry Pi / ODroid
- Domoticz version: 2024.4
- Location: Netherlands / Breda Area
- Contact:
Re: Pass2PHP
A well I use the Zigbee XIAOMI motion sensors and never changed a battery since installation over 1 year ago.ropske wrote: ↑Tuesday 09 April 2019 9:31 Do you have any idea at what time interval you need to reinstall the battery for the motion sensors?
i'm using the fibaro motion sensor and its sending temperature and luminance at 5min interval.
But my battery is getting low fast (3months)
Thanks, and btw, looking awesome to install the new pass2php in my new house
Never changed a NEO Coolcam motion sensor battery as well and they are installed on the stairs and in the Kitchen. so daily used.
Pass2php
LAN: RFLink, P1, OTGW, MySensors
USB: RFXCom, ZWave, Sonoff 3
MQTT: ZIgbee2MQTT,
ZWAVE: Zwave-JS-UI
WIFI: Mi-light, Tasmota, Xiaomi Shelly
Solar: Omnik, PVOutput
Video: Kodi, Harmony HUB, Chromecast
Sensors: You name it I got 1.
LAN: RFLink, P1, OTGW, MySensors
USB: RFXCom, ZWave, Sonoff 3
MQTT: ZIgbee2MQTT,
ZWAVE: Zwave-JS-UI
WIFI: Mi-light, Tasmota, Xiaomi Shelly
Solar: Omnik, PVOutput
Video: Kodi, Harmony HUB, Chromecast
Sensors: You name it I got 1.
-
- Posts: 50
- Joined: Thursday 04 January 2018 8:43
- Target OS: Linux
- Domoticz version: 3.66
- Location: Roeselare, Wvl, BE
- Contact:
Re: Pass2PHP
What is the main diference between the code published here
https://github.com/Egregius/LUA-Pass2PHP-for-Domoticz
and the new code?
i'm upgrading this saturday to a new debian machine with latest domoticz version. Maybe i need to revise the pass2php code also?
https://github.com/Egregius/LUA-Pass2PHP-for-Domoticz
and the new code?
i'm upgrading this saturday to a new debian machine with latest domoticz version. Maybe i need to revise the pass2php code also?
- Egregius
- Posts: 2582
- Joined: Thursday 09 April 2015 12:19
- Target OS: Linux
- Domoticz version: v2024.7
- Location: Beitem, BE
- Contact:
Re: Pass2PHP
Biggest difference is that the cache is now stored in a MySQL database instead of APCu cache from PHP.
At the beginning of functions.php that cache is fetched into one big array wich holds all the devices statusses, modes and timestamps.
Therefor you don't need to worry calling a cache again in a script that it could cause overhead or something similar. And it gives a lot more freedom and possibilities in the scripts. It's quite a luxury to have all that data available everywhere you are.
At the beginning of functions.php that cache is fetched into one big array wich holds all the devices statusses, modes and timestamps.
Therefor you don't need to worry calling a cache again in a script that it could cause overhead or something similar. And it gives a lot more freedom and possibilities in the scripts. It's quite a luxury to have all that data available everywhere you are.
-
- Posts: 50
- Joined: Thursday 04 January 2018 8:43
- Target OS: Linux
- Domoticz version: 3.66
- Location: Roeselare, Wvl, BE
- Contact:
Re: Pass2PHP
Is it as fast as before or do you notice delay? for me speed is imported as all my switches & lights are controlled by it.
so there is no more a php file needed for every device created in domoticz?
do you have a installation procedure?
so there is no more a php file needed for every device created in domoticz?
do you have a installation procedure?
- Egregius
- Posts: 2582
- Joined: Thursday 09 April 2015 12:19
- Target OS: Linux
- Domoticz version: v2024.7
- Location: Beitem, BE
- Contact:
Re: Pass2PHP
My lights switch within 1 msec. Don't think that it can be any faster than that
Before with the apcu option I was at about 18 msecs.
No, not at the moment. The wiki must be filled.
Basically you'll need a php enabled web server like before and a Mysql server. There's a script to create the database.
From there on it should be quite the same as before.
Before with the apcu option I was at about 18 msecs.
No, not at the moment. The wiki must be filled.
Basically you'll need a php enabled web server like before and a Mysql server. There's a script to create the database.
From there on it should be quite the same as before.
-
- Posts: 50
- Joined: Thursday 04 January 2018 8:43
- Target OS: Linux
- Domoticz version: 3.66
- Location: Roeselare, Wvl, BE
- Contact:
Re: Pass2PHP
Ok, il try to make it working tonight.
-
- Posts: 50
- Joined: Thursday 04 January 2018 8:43
- Target OS: Linux
- Domoticz version: 3.66
- Location: Roeselare, Wvl, BE
- Contact:
Re: Pass2PHP
Can you reply to the question:
so there is no more a php file needed for every device created in domoticz?
Every event or action is hanled by the named function in the pass2php.php file?
now i have php code in each 'device php' file to do some action.
Tnx for your help.
so there is no more a php file needed for every device created in domoticz?
Every event or action is hanled by the named function in the pass2php.php file?
now i have php code in each 'device php' file to do some action.
Tnx for your help.
- Egregius
- Posts: 2582
- Joined: Thursday 09 April 2015 12:19
- Target OS: Linux
- Domoticz version: v2024.7
- Location: Beitem, BE
- Contact:
Re: Pass2PHP
Sorry, forgot that one.
In pass2php the include is now done at the end with a @ in front of it (to surpress errors):
@include 'pass2php/'.$device.'.php';
So only for devices that you want something to happen you need to have the files. No more empty files needed.
See https://github.com/Egregius/PHP-Floorpl ... e/pass2php for examples
In pass2php the include is now done at the end with a @ in front of it (to surpress errors):
@include 'pass2php/'.$device.'.php';
So only for devices that you want something to happen you need to have the files. No more empty files needed.
See https://github.com/Egregius/PHP-Floorpl ... e/pass2php for examples
- sincze
- Posts: 1300
- Joined: Monday 02 June 2014 22:46
- Target OS: Raspberry Pi / ODroid
- Domoticz version: 2024.4
- Location: Netherlands / Breda Area
- Contact:
Re: Pass2PHP
I need a POC environment for this. As in production this is not allowed. WAF -> DIS-APPROVES
18msec -> 1msec.... Goodie goodie.
That is amazing.
18msec -> 1msec.... Goodie goodie.
That is amazing.
Pass2php
LAN: RFLink, P1, OTGW, MySensors
USB: RFXCom, ZWave, Sonoff 3
MQTT: ZIgbee2MQTT,
ZWAVE: Zwave-JS-UI
WIFI: Mi-light, Tasmota, Xiaomi Shelly
Solar: Omnik, PVOutput
Video: Kodi, Harmony HUB, Chromecast
Sensors: You name it I got 1.
LAN: RFLink, P1, OTGW, MySensors
USB: RFXCom, ZWave, Sonoff 3
MQTT: ZIgbee2MQTT,
ZWAVE: Zwave-JS-UI
WIFI: Mi-light, Tasmota, Xiaomi Shelly
Solar: Omnik, PVOutput
Video: Kodi, Harmony HUB, Chromecast
Sensors: You name it I got 1.
-
- Posts: 50
- Joined: Thursday 04 January 2018 8:43
- Target OS: Linux
- Domoticz version: 3.66
- Location: Roeselare, Wvl, BE
- Contact:
Re: Pass2PHP
That is why i al doing the upgrade this saturday, wife NOT home
- Egregius
- Posts: 2582
- Joined: Thursday 09 April 2015 12:19
- Target OS: Linux
- Domoticz version: v2024.7
- Location: Beitem, BE
- Contact:
Re: Pass2PHP
During the transition from old to new you can have some strange behaviour of course.
It took me several hours to rewrite all the files with the new way. Replacing every apcu_fetch('device') with $d['device']['s']...
But now I'm done, everything works better than before so I'm happy
And the wife? She used to see strange things here
It took me several hours to rewrite all the files with the new way. Replacing every apcu_fetch('device') with $d['device']['s']...
But now I'm done, everything works better than before so I'm happy
And the wife? She used to see strange things here
-
- Posts: 50
- Joined: Thursday 04 January 2018 8:43
- Target OS: Linux
- Domoticz version: 3.66
- Location: Roeselare, Wvl, BE
- Contact:
Re: Pass2PHP
i'm not using much apcu_fetch('device') i think, only simple stuff sw(device, on/off) so i think the migration will be ok?
only apcu i use is to maintain the last status of the rollershutter. This will be an enhancement for me when writing in db because every day the apache auto restarts at 9h and apcu is empty after that, so status is lost...
only apcu i use is to maintain the last status of the rollershutter. This will be an enhancement for me when writing in db because every day the apache auto restarts at 9h and apcu is empty after that, so status is lost...
- Egregius
- Posts: 2582
- Joined: Thursday 09 April 2015 12:19
- Target OS: Linux
- Domoticz version: v2024.7
- Location: Beitem, BE
- Contact:
Re: Pass2PHP
That's indeed another great thing about storing in MySQL, data is persistant.
Before I used to fetch the statusses from domoticz from time to time, no I don't do that anymore and everything stays in sync anyway.
Before I used to fetch the statusses from domoticz from time to time, no I don't do that anymore and everything stays in sync anyway.
-
- Posts: 50
- Joined: Thursday 04 January 2018 8:43
- Target OS: Linux
- Domoticz version: 3.66
- Location: Roeselare, Wvl, BE
- Contact:
Re: Pass2PHP
What does your config.php file looks like?
PHP Fatal error: require(): Failed opening required '/var/www/config.php'
Tnx
PHP Fatal error: require(): Failed opening required '/var/www/config.php'
Tnx
Who is online
Users browsing this forum: No registered users and 0 guests