Timing - general question
Posted: 28 Feb 2018, 10:12
Hi all,
I am new to this forum.
I have a general question about execution times of rules and other action with ESP_Easy:
What are or should be in general the execution times of rules?
I read in the forum something between 150 and 2500 ms .. And there are many discussions about MQTT slow response etc....
Maybe to my setup first:
Wemos D1 mini with 4 relays and 4 switches (later replaced by motion detectors).
I m running rules to communicate with my broker Mosquitto running on a PI3 and my homebridge on same PI using MQTT.
OpenHAB is on controller 1 without any passwords.
Now, when I press a button, this is published via my broker to the homebridge (works fine and quick).
With node-RED I advised the broker to switch on lamps my sending rule commands by MQTT to the ESP. One command, one rule for one lamp.
In the broke I can define which lamps should be switched on (say Lamp1 and Lamp2).
The Lamp rule publishes a MQTT message back that the Lamp is on or off using JSON format (works).
What I observe is the following:
Press the button : immediately the motion-sensor button in the homekit (via homebridge and Mosquitto) shows the activity (ms ...)
Then it takes about 1 second to switch the first lamp.
After another second the next lamp switches.
Looking into the log:
execution lamp1
...
1300 ms execution time
executing lamp2
...
1350 ms execution time.
My question is this long execution time normal?
Is it related to MQTT messages sent and received?
Can I reduce the reaction time somehow?
It is doing what it should, but I would like to have a quicker response time somehow, because I want to control finally using 2 ESP, 8 lamps, 5 motion sensors (=switches) and one other sensor (=switch).
Thanks in advance for any hint.
I am new to this forum.
I have a general question about execution times of rules and other action with ESP_Easy:
What are or should be in general the execution times of rules?
I read in the forum something between 150 and 2500 ms .. And there are many discussions about MQTT slow response etc....
Maybe to my setup first:
Wemos D1 mini with 4 relays and 4 switches (later replaced by motion detectors).
I m running rules to communicate with my broker Mosquitto running on a PI3 and my homebridge on same PI using MQTT.
OpenHAB is on controller 1 without any passwords.
Now, when I press a button, this is published via my broker to the homebridge (works fine and quick).
With node-RED I advised the broker to switch on lamps my sending rule commands by MQTT to the ESP. One command, one rule for one lamp.
In the broke I can define which lamps should be switched on (say Lamp1 and Lamp2).
The Lamp rule publishes a MQTT message back that the Lamp is on or off using JSON format (works).
What I observe is the following:
Press the button : immediately the motion-sensor button in the homekit (via homebridge and Mosquitto) shows the activity (ms ...)
Then it takes about 1 second to switch the first lamp.
After another second the next lamp switches.
Looking into the log:
execution lamp1
...
1300 ms execution time
executing lamp2
...
1350 ms execution time.
My question is this long execution time normal?
Is it related to MQTT messages sent and received?
Can I reduce the reaction time somehow?
It is doing what it should, but I would like to have a quicker response time somehow, because I want to control finally using 2 ESP, 8 lamps, 5 motion sensors (=switches) and one other sensor (=switch).
Thanks in advance for any hint.