How to stop a reactor from tripping when going from disabled to enabled?

Hello @rigpapa,

Thanks once again for making a great tool for the vera platform. Still using it all these years later!

I decided to tackle the TTS problem we have with sonos where the music stops when a TTS announcement is made, by disabling TTS while music is playing.

I have done this by creating a reactor sensor which disables all my TTS related reactor sensors while music is playing.

A side effect of this has been that one of my sensors trips when being enabled and I can’t think of a way to stop it from doing so. The conditions of which are:

Print Finished (within 60 seconds after octoprint printing tripped equals 1).

  1. Octoprint Printing tripped equals 0 (Current value is 0)
  2. Time between 9am and 11pm.

This particular sensor announces changes in state of my 3D-Printer by monitoring the printer with SiteSensor. Since the majority of the time the printer is offline, the “Print Finished” remains tripped, even though it is specified to only be true if following “Print Started”. I suppose this variable remains true, regardless of the reactor sensor going disabled…

Can you suggest how to have the reactor sensor remain untripped when re-enabled?

*************************************************** REACTOR LOGIC SUMMARY REPORT ***************************************************
   Version: 3.8-20262 config 20190 cdata 20045 ui 20190 pluginDevice 8 LuaXP not loaded
    System: Vera version 1.7.5185 (7.31) on Sercomm NA301 ID 35 (Vera Edge); loadtime 1717983461/1717983477; systemReady 1717983486
       Env: Lua 5.1; JSON dkjson 1.2; UnsafeLua=1/true
Local time: 2024-06-09T22:32:33-0400; DST=1; Oakville, Ontario Canada; formats %Y-%m-%d %H:%M:%S
House mode: plugin 1; system 1; tracking on
  Sun data: { "source": "int", "civdawn": 1717923749, "nautdawn": 1717920980, "sunset": 1717981103, "nautdusk": 1717986002, "stamp": 2024161, "latitude": 43.4501, "astrodusk": 1717989438, "longitude": -79.6829, "civdusk": 1717983233, "astrodawn": 1717917544, "sunrise": 1717925879 }
  Geofence: not running
        RS: 1717470828,1717470850,1717471920,1717473407,1717553468,1717668181,1717911052,1717955507,1717966187,1717983477
        NS: 1690687140:D,1690687560:U,1692246451:D,1692247440:U,946685130:D,946685160:U,946685130:D,1707149460:U,946685100:D,1714618440:U
************************************************************************************************************************************
3DPrint Announcement (#190)
    Version 20045.33 06/09/24 22:17:02
    Message/status: Not tripped
    Condition group "Prusa 3d Printer Status" (NUL)  false as of n/a <root>
      Z-F-group "Print Started" (AND)  false as of 22:17:45 <grp1l17y76w>
      |     &-F-service Octoprint Printing (185) urn:micasaverde-com:serviceId:SecuritySensor1/Tripped = 1 [0 at 22:17:45; F/F as of 22:17:45/22:17:45] <cond1l17ysyw>
      Z-T-group "Print Finished" (AND)  within 60s after cond1l17ysyw TRUE as of 22:17:45 <grp1l17y83o>
      |     &-T-service Octoprint Printing (185) urn:micasaverde-com:serviceId:SecuritySensor1/Tripped = 0 [0 at 22:17:45; T/T as of 22:17:45/22:17:45] <cond1l17z8lm>
      |     &-T-trange bet ,,,9,0,,,,23,0 [1717986731 => 1717986734 at 22:32:14; T/T as of 22:17:45/22:17:45] <cond1vsfsv7k>
      Z-F-group "Print Error" (AND)  after grp1l17y76w false as of 22:17:45 <grp1l17ykyj>
      |     &-F-service Octoprint Error (186) urn:micasaverde-com:serviceId:SecuritySensor1/Tripped = 1 [0 at 22:17:45; F/F as of 22:17:45/22:17:45] <cond1l17zvfg>
    Activity grp1l17ykyj.true
        Device Sonos - Robin Office (100) action urn:micasaverde-com:serviceId:Sonos1/Say( Text="Alert! The 3D printer encountered an error.", Volume="30", SameVolumeForAll="1", GroupDevices="100,44,104,101,102,103", UnMute="1" )
    Activity grp1l17y76w.true
        Device Sonos - Robin Office (100) action urn:micasaverde-com:serviceId:Sonos1/Say( Text="3D Print Started.", Volume="15", Chime="0", UnMute="1" )
    Activity grp1l17y83o.true
        Device Sonos - Robin Office (100) action urn:micasaverde-com:serviceId:Sonos1/Say( Text="The 3D print has finished.", Volume="20", UnMute="1" )
    Events
        2024-06-09 22:28:14: Sensor update completed; 0.026s
        2024-06-09 22:28:14: Device SiteSnsr-Prusa3dprnt (#183) urn:toggledbits-com:serviceId:SiteSensor1/Message changed from "Retrieving last response..." to "Last query failed, HTTP status 500"
        2024-06-09 22:28:14: Sensor update starting
        2024-06-09 22:28:14: Sensor update completed; 0.013s
        2024-06-09 22:28:41: Device SiteSnsr-Prusa3dprnt (#183) urn:toggledbits-com:serviceId:SiteSensor1/LastQuery changed from "1717986491" to "1717986521"
        2024-06-09 22:28:41: Sensor update starting
        2024-06-09 22:28:41: Sensor update completed; 0.030s
        2024-06-09 22:28:41: Device SiteSnsr-Prusa3dprnt (#183) urn:toggledbits-com:serviceId:SiteSensor1/Message changed from "Last query failed, HTTP status 500" to "Requesting JSON..."
        2024-06-09 22:28:41: Sensor update starting
        2024-06-09 22:28:41: Sensor update completed; 0.013s
        2024-06-09 22:28:44: Device SiteSnsr-Prusa3dprnt (#183) urn:toggledbits-com:serviceId:SiteSensor1/Message changed from "Requesting JSON..." to "Retrieving last response..."
        2024-06-09 22:28:44: Sensor update starting
        2024-06-09 22:28:44: Sensor update completed; 0.039s
        2024-06-09 22:28:44: Device SiteSnsr-Prusa3dprnt (#183) urn:toggledbits-com:serviceId:SiteSensor1/Message changed from "Retrieving last response..." to "Last query failed, HTTP status 500"
        2024-06-09 22:28:44: Sensor update starting
        2024-06-09 22:28:44: Sensor update completed; 0.013s
        2024-06-09 22:29:11: Device SiteSnsr-Prusa3dprnt (#183) urn:toggledbits-com:serviceId:SiteSensor1/LastQuery changed from "1717986521" to "1717986551"
        2024-06-09 22:29:11: Sensor update starting
        2024-06-09 22:29:11: Sensor update completed; 0.064s
        2024-06-09 22:29:11: Device SiteSnsr-Prusa3dprnt (#183) urn:toggledbits-com:serviceId:SiteSensor1/Message changed from "Last query failed, HTTP status 500" to "Requesting JSON..."
        2024-06-09 22:29:11: Sensor update starting
        2024-06-09 22:29:11: Sensor update completed; 0.017s
        2024-06-09 22:29:14: Device SiteSnsr-Prusa3dprnt (#183) urn:toggledbits-com:serviceId:SiteSensor1/Message changed from "Requesting JSON..." to "Retrieving last response..."
        2024-06-09 22:29:14: Sensor update starting
        2024-06-09 22:29:14: Sensor update completed; 0.032s
        2024-06-09 22:29:14: Device SiteSnsr-Prusa3dprnt (#183) urn:toggledbits-com:serviceId:SiteSensor1/Message changed from "Retrieving last response..." to "Last query failed, HTTP status 500"
        2024-06-09 22:29:14: Sensor update starting
        2024-06-09 22:29:14: Sensor update completed; 0.013s
        2024-06-09 22:29:41: Device SiteSnsr-Prusa3dprnt (#183) urn:toggledbits-com:serviceId:SiteSensor1/LastQuery changed from "1717986551" to "1717986581"
        2024-06-09 22:29:41: Sensor update starting
        2024-06-09 22:29:41: Sensor update completed; 0.022s
        2024-06-09 22:29:41: Device SiteSnsr-Prusa3dprnt (#183) urn:toggledbits-com:serviceId:SiteSensor1/Message changed from "Last query failed, HTTP status 500" to "Requesting JSON..."
        2024-06-09 22:29:41: Sensor update starting
        2024-06-09 22:29:41: Sensor update completed; 0.012s
        2024-06-09 22:29:44: Device SiteSnsr-Prusa3dprnt (#183) urn:toggledbits-com:serviceId:SiteSensor1/Message changed from "Requesting JSON..." to "Retrieving last response..."
        2024-06-09 22:29:44: Sensor update starting
        2024-06-09 22:29:44: Sensor update completed; 0.036s
        2024-06-09 22:29:44: Device SiteSnsr-Prusa3dprnt (#183) urn:toggledbits-com:serviceId:SiteSensor1/Message changed from "Retrieving last response..." to "Last query failed, HTTP status 500"
        2024-06-09 22:29:44: Sensor update starting
        2024-06-09 22:29:44: Sensor update completed; 0.024s
        2024-06-09 22:30:11: Device SiteSnsr-Prusa3dprnt (#183) urn:toggledbits-com:serviceId:SiteSensor1/LastQuery changed from "1717986581" to "1717986611"
        2024-06-09 22:30:11: Sensor update starting
        2024-06-09 22:30:11: Sensor update completed; 0.028s
        2024-06-09 22:30:11: Device SiteSnsr-Prusa3dprnt (#183) urn:toggledbits-com:serviceId:SiteSensor1/Message changed from "Last query failed, HTTP status 500" to "Requesting JSON..."
        2024-06-09 22:30:11: Sensor update starting
        2024-06-09 22:30:11: Sensor update completed; 0.014s
        2024-06-09 22:30:14: Device SiteSnsr-Prusa3dprnt (#183) urn:toggledbits-com:serviceId:SiteSensor1/Message changed from "Requesting JSON..." to "Retrieving last response..."
        2024-06-09 22:30:14: Sensor update starting
        2024-06-09 22:30:14: Sensor update completed; 0.031s
        2024-06-09 22:30:14: Device SiteSnsr-Prusa3dprnt (#183) urn:toggledbits-com:serviceId:SiteSensor1/Message changed from "Retrieving last response..." to "Last query failed, HTTP status 500"
        2024-06-09 22:30:14: Sensor update starting
        2024-06-09 22:30:14: Sensor update completed; 0.013s
        2024-06-09 22:30:41: Device SiteSnsr-Prusa3dprnt (#183) urn:toggledbits-com:serviceId:SiteSensor1/LastQuery changed from "1717986611" to "1717986641"
        2024-06-09 22:30:41: Sensor update starting
        2024-06-09 22:30:41: Sensor update completed; 0.027s
        2024-06-09 22:30:41: Device SiteSnsr-Prusa3dprnt (#183) urn:toggledbits-com:serviceId:SiteSensor1/Message changed from "Last query failed, HTTP status 500" to "Requesting JSON..."
        2024-06-09 22:30:41: Sensor update starting
        2024-06-09 22:30:41: Sensor update completed; 0.015s
        2024-06-09 22:30:44: Device SiteSnsr-Prusa3dprnt (#183) urn:toggledbits-com:serviceId:SiteSensor1/Message changed from "Requesting JSON..." to "Retrieving last response..."
        2024-06-09 22:30:44: Sensor update starting
        2024-06-09 22:30:44: Sensor update completed; 0.033s
        2024-06-09 22:30:44: Device SiteSnsr-Prusa3dprnt (#183) urn:toggledbits-com:serviceId:SiteSensor1/Message changed from "Retrieving last response..." to "Last query failed, HTTP status 500"
        2024-06-09 22:30:44: Sensor update starting
        2024-06-09 22:30:44: Sensor update completed; 0.015s
        2024-06-09 22:31:11: Device SiteSnsr-Prusa3dprnt (#183) urn:toggledbits-com:serviceId:SiteSensor1/LastQuery changed from "1717986641" to "1717986671"
        2024-06-09 22:31:11: Sensor update starting
        2024-06-09 22:31:11: Sensor update completed; 0.027s
        2024-06-09 22:31:11: Device SiteSnsr-Prusa3dprnt (#183) urn:toggledbits-com:serviceId:SiteSensor1/Message changed from "Last query failed, HTTP status 500" to "Requesting JSON..."
        2024-06-09 22:31:11: Sensor update starting
        2024-06-09 22:31:11: Sensor update completed; 0.016s
        2024-06-09 22:31:14: Device SiteSnsr-Prusa3dprnt (#183) urn:toggledbits-com:serviceId:SiteSensor1/Message changed from "Requesting JSON..." to "Retrieving last response..."
        2024-06-09 22:31:14: Sensor update starting
        2024-06-09 22:31:14: Sensor update completed; 0.032s
        2024-06-09 22:31:14: Device SiteSnsr-Prusa3dprnt (#183) urn:toggledbits-com:serviceId:SiteSensor1/Message changed from "Retrieving last response..." to "Last query failed, HTTP status 500"
        2024-06-09 22:31:14: Sensor update starting
        2024-06-09 22:31:14: Sensor update completed; 0.013s
        2024-06-09 22:31:41: Device SiteSnsr-Prusa3dprnt (#183) urn:toggledbits-com:serviceId:SiteSensor1/LastQuery changed from "1717986671" to "1717986701"
        2024-06-09 22:31:41: Sensor update starting
        2024-06-09 22:31:41: Sensor update completed; 0.038s
        2024-06-09 22:31:41: Device SiteSnsr-Prusa3dprnt (#183) urn:toggledbits-com:serviceId:SiteSensor1/Message changed from "Last query failed, HTTP status 500" to "Requesting JSON..."
        2024-06-09 22:31:41: Sensor update starting
        2024-06-09 22:31:41: Sensor update completed; 0.013s
        2024-06-09 22:31:44: Device SiteSnsr-Prusa3dprnt (#183) urn:toggledbits-com:serviceId:SiteSensor1/Message changed from "Requesting JSON..." to "Retrieving last response..."
        2024-06-09 22:31:44: Sensor update starting
        2024-06-09 22:31:44: Sensor update completed; 0.045s
        2024-06-09 22:31:44: Device SiteSnsr-Prusa3dprnt (#183) urn:toggledbits-com:serviceId:SiteSensor1/Message changed from "Retrieving last response..." to "Last query failed, HTTP status 500"
        2024-06-09 22:31:44: Sensor update starting
        2024-06-09 22:31:44: Sensor update completed; 0.017s
        2024-06-09 22:32:11: Device SiteSnsr-Prusa3dprnt (#183) urn:toggledbits-com:serviceId:SiteSensor1/LastQuery changed from "1717986701" to "1717986731"
        2024-06-09 22:32:11: Sensor update starting
        2024-06-09 22:32:11: Sensor update completed; 0.027s
        2024-06-09 22:32:11: Device SiteSnsr-Prusa3dprnt (#183) urn:toggledbits-com:serviceId:SiteSensor1/Message changed from "Last query failed, HTTP status 500" to "Requesting JSON..."
        2024-06-09 22:32:11: Sensor update starting
        2024-06-09 22:32:11: Sensor update completed; 0.015s
        2024-06-09 22:32:14: Device SiteSnsr-Prusa3dprnt (#183) urn:toggledbits-com:serviceId:SiteSensor1/Message changed from "Requesting JSON..." to "Retrieving last response..."
        2024-06-09 22:32:14: Sensor update starting
        2024-06-09 22:32:14: Sensor update completed; 0.031s
        2024-06-09 22:32:14: Device SiteSnsr-Prusa3dprnt (#183) urn:toggledbits-com:serviceId:SiteSensor1/Message changed from "Retrieving last response..." to "Last query failed, HTTP status 500"
        2024-06-09 22:32:14: Sensor update starting
        2024-06-09 22:32:14: Sensor update completed; 0.013s
    Devices
        Octoprint Printing (185) urn:schemas-micasaverde-com:device:MotionSensor:1 (4/3); parent 183; plugin -; mfg  model ; dev D_MotionSensor1.xml impl 
        Octoprint Error (186) urn:schemas-micasaverde-com:device:MotionSensor:1 (4/3); parent 183; plugin -; mfg  model ; dev D_MotionSensor1.xml impl 
        Sonos System (99) urn:schemas-toggledbits-com:device:SonosSystem:1 (1/-1); parent 0; plugin 4226; mfg  model ; dev D_SonosSystem1.xml impl I_SonosSystem1.xml
        Sonos - Robin Office (100) urn:schemas-micasaverde-com:device:Sonos:1 (15/-1); parent 99; plugin -; mfg  model ; dev D_Sonos1.xml impl 
        SiteSnsr-Prusa3dprnt (183) urn:schemas-toggledbits-com:device:SiteSensor:1 (4/0); parent 0; plugin 8942; mfg  model ; dev D_SiteSensor1.xml impl I_SiteSensor1.xml
    Watches
        Device #190 3DPrint Announcement service urn:toggledbits-com:serviceId:ReactorSensor variable TestTime
        Device #186 Octoprint Error service urn:micasaverde-com:serviceId:SecuritySensor1 variable Tripped
        Device #185 Octoprint Printing service urn:micasaverde-com:serviceId:SecuritySensor1 variable Tripped
        Device #183 SiteSnsr-Prusa3dprnt service urn:toggledbits-com:serviceId:SiteSensor1 variable LastQuery
        Device #183 SiteSnsr-Prusa3dprnt service urn:toggledbits-com:serviceId:SiteSensor1 variable Message
        Device #190 3DPrint Announcement service urn:toggledbits-com:serviceId:ReactorSensor variable TestHouseMode
        Device #190 3DPrint Announcement service urn:toggledbits-com:serviceId:ReactorSensor variable cdata