• 10 dec 2017: forum version update. In case of issues use this topic.
  • 30 nov 2017: pilight moved servers. In case of issues use this topic.
Hello There, Guest! Login Register

Thread Rating:
  • 0 Vote(s) - 0 Average
  • 1
  • 2
  • 3
  • 4
  • 5
[Solved] Rules switching state based on another device state not working
After update to rewrite backports my rule for state-connected devices do not work anymore.
I have the following rule switching a device based on the state of another:

"group-decolight": {
            "rule": "IF light_deco_mirror_livingroom.state == on OR light_deco_mirror_livingroom.state == off THEN switch DEVICE light_deco_window_diningroom TO light_deco_mirror_livingroom.state",
            "active": 1

The webgui does reflect this rule.
If I switch light_deco_mirror_livingroom the button state for light_deco_window_diningroom corresponds and change correctly.
But the reciever does nothing meaning it's not responding to the code.
If I switch the devices manually on after another without the rule then it's working (meaning first I switch light_deco_window_diningroom and after that light_deco_mirror_livingroom to overcome the rule in the first place).

I have the same issue switching these devices based on a sunset and sunrise rule. The light does not react anymore on these rules.

Any idea what could cause this?

My config is attached..

Attached Files
.txt   config.txt (Size: 5.79 KB / Downloads: 8)
What pilight version?
This should probably be solved in the new nightlies, but i have to fix a segfault first as i've read.
Issue still present in latest nightly 7.0-230 and probably related to this thread
So what you describe is just working, because the webGUI does reflect the correct state of light_deco_window_diningroom based on light_deco_mirror_livingroom? The only thing that doesn't work is that not both lights are switching off or on?

I do actively check for this functionality in the rewrite code:

Anyway, the workaround described in this Thread seems to be a possible solution

Possibly Related Threads...
Thread Author Replies Views Last Post
  [SOLVED] Triggering generic_switch leads to segfault Ulrich.Arnold 19 4,843 10-23-2019, 09:03 AM
Last Post: Ulrich.Arnold
  [Fixed] Fast sending codes in a row not working apartmedia 12 5,913 08-19-2019, 04:58 PM
Last Post: curlymo
  regex mask for protocol options not working Niek 2 2,124 01-06-2019, 12:20 AM
Last Post: Niek
  duplicate device names causing seqgfault in lua.c Niek 1 1,632 12-10-2018, 10:40 PM
Last Post: curlymo
  ][solved]Segfault when retrieving big chunked http message Niek 21 8,468 11-29-2018, 03:17 PM
Last Post: curlymo
  [Solved] config.json not updated Niek 6 2,318 12-31-2017, 03:19 PM
Last Post: curlymo
  Switching between tab and list-view stops gui Ulrich.Arnold 4 1,602 11-05-2017, 02:43 PM
Last Post: Ulrich.Arnold
  [Solved] callback not executing when dns lookup fails Niek 1 1,168 10-08-2017, 11:44 AM
Last Post: curlymo
  [Solved] connection to main pilight daemon lost TopdRob 20 6,853 09-17-2017, 04:30 PM
Last Post: curlymo
  [Solved] dimmer protocol kaku_dimmer does not react on dimmervalue apartmedia 25 6,656 09-16-2017, 10:29 PM
Last Post: apartmedia

Forum Jump:

Browsing: 1 Guest(s)