Announcement

Collapse
No announcement yet.

wifi connectivity changes affect parent device status

Collapse
X
 
  • Filter
  • Time
  • Show
Clear All
new posts

    wifi connectivity changes affect parent device status

    Heya AK,

    I'm hoping this is a plugin issue rather than a Remootio quirk....everytime the Remootio device loses wifi connectivity, the values of both the main and the .output devices get changed to -1. That in itself isn't a problem but when the remootio comes back online, both those values change again...the main device changes to the appropriate value for either open or closed, based on the current status of the gate, and the .output status changes back to 0, for ok. This change from -1 to the real current status of the main device causes on-open or on-close events to be triggered erroneously.

    Wifi comes back online...
    Nov-07 15:28:15 AK Remootio [2626]: Device: Gate 207 Set to 6
    Nov-07 15:28:14 AK Remootio [2627]: Device: Gate 207.Output Set to 0
    Nov-07 15:28:14 AK Remootio Warning [2626]: WebSocket Connected
    Nov-07 15:28:13 AK Remootio ERROR [2626]: Sending {"type":"PING"} - but websocket is 'Closed', trying to open
    Wifi goes offline...
    Nov-07 15:27:58 AK Remootio [2626]: Device: Gate 207 Set to -1
    Nov-07 15:27:58 AK Remootio [2627]: Device: Gate 207.Output Set to -1
    Nov-07 15:27:58 AK Remootio Warning [2626]: WebSocket Closed code: 1006, reason 'An exception has occurred while receiving.'
    You can replicate this simply by putting an on-open and on-close speak event on your remootio device and then rebooting your router. As it loses and regains connectivity you'll hear your speak events triggered. Would it be possible to *not* have the main device values changed based on wifi connectivity? If the .output device value changes based on connectivity but the main device does not, it then gives the user the option to both monitor wifi connectivity and gate status change without having to worry about erroneous reports on the gate status due to changes in wifi connectivity.

    As it is now, one cannot reliably trigger events based on gate status because a wifi connection change will trigger gate-open and gate-close events erroneously. For me, I have whole-house speak events on gate-open and on gate-close and this issue causes random gate announcements near dusk and dawn when the rapid temperature change effects wifi connectivity to a remootio that is at the edge of my wifi coverage.

    #2
    Sure, I can have a look. I was thinking that it makes sense to show that connection is lost...

    Comment


      #3
      agreed. It's def nice to have the wifi connectivity status info, just not at the detriment of the gate status info. My thought is that if the main device only tracked the status of the gate but the .output device tracked *everything*, including the wifi connectivity status, then one can have it all... reliable monitoring of gate status plus the ability to include wifi connectivity status in event conditions or trigger events explicitly off of wifi connectivity changes.

      Comment


        #4
        Yeah, that's what I do now in my plugins - I don't set all devices to "Unknown" when connection is lost. I'll fix it. Feel free to remind me if I forget.

        Comment


          #5
          Awesome. Thanks!

          Comment


            #6
            Ver 3.0.0.4 (BETA) - Don't set child devices state on error
            Not tested, so please test and report back

            Comment


              #7
              Hi AK, still testing...based on the log it looks like the .output device was changed to no longer get set to -1 on disconnection. Was this by design? In this new version, a wifi disconnect causes the main device to change to -1 and the .output device to remain unchanged. The .output device, however, when reconnected gets changed to the open/close status value and then immediately to 0 for ok. Wouldn't it be better to instead continue to have the .output device get the -1 on disconnect and to instead prevent the main device from getting the -1 on disconnection? If the main device only maintained the latest known status of the device (and no wifi disconnect -1 status) then one can trigger on-open and on-close events on it as well as trigger "has been/for at least" events. With this new update, one can trigger on-open and on-close events on the .output device without worrying about the -1, but one cannot trigger "has been/for at least" events on it because of the immediate update to 0/OK. I suppose one could use the .output device to perform *only* on-open and on-close triggered events and then use the main device to perform *only* "has been/for at least" triggered events, but it would be nice not to have to remember which device to use for what type of trigger.
              One more thing...below is a section of the log when from when i stopped/started the plugin which interrupts connectivity in a different way... you'll see that both the main and the .output device get immediately set to -1 when the plugin starts and then they both get updated (to 0 or open or closed depending on status of the sensor) when the connection is established. You may want to consider preventing this -1 initialization setting here as well, if possible as this causes the startup of the plugin (or restart of the plugin) to always trigger on-open and on-close events.
              Code:
                [TABLE="class: log_table_row"]
              [TR]
              [TD="class: LogDateShort LogDateTime1, align: left"][COLOR=#FF0000]Nov-08 08:28:55 [/COLOR][/TD]
               			[TD="class: LogPri1, align: left"] [/TD]
               			[TD="class: LogType1, colspan: 3, align: left"][COLOR=#FF0000]AK Remootio ERROR [/COLOR][/TD]
               			[TD="class: LogEntry1, colspan: 8, align: left"][COLOR=#FF0000][2626]: Sending {"type":"PING"} - but websocket is 'Closed', trying to open [/COLOR][/TD]
               		[/TR]
              [/TABLE]
              [TABLE="class: log_table_row"]
              [TR]
              [TD="class: LogDateShort LogDateTime0, align: left"][COLOR=#000000]Nov-08 08:28:42 [/COLOR][/TD]
               			[TD="class: LogPri0, align: left"] [/TD]
               			[TD="class: LogType0, colspan: 3, align: left"][COLOR=#000000]AK Remootio [/COLOR][/TD]
               			[TD="class: LogEntry0, colspan: 8, align: left"][COLOR=#000000][2668]: Device: [COLOR=#000080]Gate 215[/COLOR] Set to [COLOR=#008000]0[/COLOR] [/COLOR][/TD]
               		[/TR]
              [/TABLE]
              [TABLE="class: log_table_row"]
              [TR]
              [TD="class: LogDateShort LogDateTime1, align: left"][COLOR=#000000]Nov-08 08:28:42 [/COLOR][/TD]
               			[TD="class: LogPri1, align: left"] [/TD]
               			[TD="class: LogType1, colspan: 3, align: left"][COLOR=#000000]AK Remootio [/COLOR][/TD]
               			[TD="class: LogEntry1, colspan: 8, align: left"][COLOR=#000000][2669]: Device: [COLOR=#000080]Gate 215.Output[/COLOR] Set to [COLOR=#008000]0[/COLOR] [/COLOR][/TD]
               		[/TR]
              [/TABLE]
              [TABLE="class: log_table_row"]
              [TR]
              [TD="class: LogDateShort LogDateTime1, align: left"][COLOR=#000000]Nov-08 08:28:42 [/COLOR][/TD]
               			[TD="class: LogPri1, align: left"] [/TD]
               			[TD="class: LogType1, colspan: 3, align: left"][COLOR=#000000]AK Remootio [/COLOR][/TD]
               			[TD="class: LogEntry1, colspan: 8, align: left"][COLOR=#000000][2672]: Device: [COLOR=#000080]Garage[/COLOR] Set to [COLOR=#008000]5[/COLOR] [/COLOR][/TD]
               		[/TR]
              [/TABLE]
              [TABLE="class: log_table_row"]
              [TR]
              [TD="class: LogDateShort LogDateTime0, align: left"][COLOR=#000000]Nov-08 08:28:42 [/COLOR][/TD]
               			[TD="class: LogPri0, align: left"] [/TD]
               			[TD="class: LogType0, colspan: 3, align: left"][COLOR=#000000]AK Remootio [/COLOR][/TD]
               			[TD="class: LogEntry0, colspan: 8, align: left"][COLOR=#000000][2673]: Device: [COLOR=#000080]Garage.Output[/COLOR] Set to [COLOR=#008000]0[/COLOR] [/COLOR][/TD]
               		[/TR]
              [/TABLE]
              [TABLE="class: log_table_row"]
              [TR]
              [TD="class: LogDateShort LogDateTime1, align: left"][COLOR=#D58000]Nov-08 08:28:41 [/COLOR][/TD]
               			[TD="class: LogPri1, align: left"] [/TD]
               			[TD="class: LogType1, colspan: 3, align: left"][COLOR=#D58000]AK Remootio Warning [/COLOR][/TD]
               			[TD="class: LogEntry1, colspan: 8, align: left"][COLOR=#D58000][2672]: WebSocket Connected [/COLOR][/TD]
               		[/TR]
              [/TABLE]
              [TABLE="class: log_table_row"]
              [TR]
              [TD="class: LogDateShort LogDateTime0, align: left"][COLOR=#000000]Nov-08 08:28:41 [/COLOR][/TD]
               			[TD="class: LogPri0, align: left"] [/TD]
               			[TD="class: LogType0, colspan: 3, align: left"][COLOR=#000000]AK Remootio [/COLOR][/TD]
               			[TD="class: LogEntry0, colspan: 8, align: left"][COLOR=#000000][2673]: Device: [COLOR=#000080]Garage.Output[/COLOR] Set to [COLOR=#008000]-1[/COLOR] [/COLOR][/TD]
               		[/TR]
              [/TABLE]
              [TABLE="class: log_table_row"]
              [TR]
              [TD="class: LogDateShort LogDateTime1, align: left"][COLOR=#000000]Nov-08 08:28:41 [/COLOR][/TD]
               			[TD="class: LogPri1, align: left"] [/TD]
               			[TD="class: LogType1, colspan: 3, align: left"][COLOR=#000000]AK Remootio [/COLOR][/TD]
               			[TD="class: LogEntry1, colspan: 8, align: left"][COLOR=#000000][2672]: Device: [COLOR=#000080]Garage[/COLOR] Set to [COLOR=#008000]-1[/COLOR] [/COLOR][/TD]
               		[/TR]
              [/TABLE]
              [TABLE="class: log_table_row"]
              [TR]
              [TD="class: LogDateShort LogDateTime0, align: left"][COLOR=#000000]Nov-08 08:28:40 [/COLOR][/TD]
               			[TD="class: LogPri0, align: left"] [/TD]
               			[TD="class: LogType0, colspan: 3, align: left"][COLOR=#000000]AK Remootio [/COLOR][/TD]
               			[TD="class: LogEntry0, colspan: 8, align: left"][COLOR=#000000][0]: * Set Remootio ws://192.168.0.72:8080/ (HSPI_AKRemootio.DeviceRemootioDevice) [/COLOR][/TD]
               		[/TR]
              [/TABLE]
              [TABLE="class: log_table_row"]
              [TR]
              [TD="class: LogDateShort LogDateTime1, align: left"] [/TD]
               			[TD="class: LogPri1, align: left"] [/TD]
               			[TD="class: LogType1, colspan: 3, align: left"] [/TD]
               			[TD="class: LogEntry1, colspan: 8, align: left"] [/TD]
               		[/TR]
              [/TABLE]
              [TABLE="class: log_table_row"]
              [TR]
              [TD="class: LogDateShort LogDateTime0, align: left"][COLOR=#D58000]Nov-08 08:28:40 [/COLOR][/TD]
               			[TD="class: LogPri0, align: left"] [/TD]
               			[TD="class: LogType0, colspan: 3, align: left"][COLOR=#D58000]AK Remootio Warning [/COLOR][/TD]
               			[TD="class: LogEntry0, colspan: 8, align: left"][COLOR=#D58000][2668]: WebSocket Connected [/COLOR][/TD]
               		[/TR]
              [/TABLE]
              [TABLE="class: log_table_row"]
              [TR]
              [TD="class: LogDateShort LogDateTime1, align: left"][COLOR=#000000]Nov-08 08:28:40 [/COLOR][/TD]
               			[TD="class: LogPri1, align: left"] [/TD]
               			[TD="class: LogType1, colspan: 3, align: left"][COLOR=#000000]AK Remootio [/COLOR][/TD]
               			[TD="class: LogEntry1, colspan: 8, align: left"][COLOR=#000000][2669]: Device: [COLOR=#000080]Gate 215.Output[/COLOR] Set to [COLOR=#008000]-1[/COLOR] [/COLOR][/TD]
               		[/TR]
              [/TABLE]
              [TABLE="class: log_table_row"]
              [TR]
              [TD="class: LogDateShort LogDateTime0, align: left"][COLOR=#000000]Nov-08 08:28:40 [/COLOR][/TD]
               			[TD="class: LogPri0, align: left"] [/TD]
               			[TD="class: LogType0, colspan: 3, align: left"][COLOR=#000000]AK Remootio [/COLOR][/TD]
               			[TD="class: LogEntry0, colspan: 8, align: left"][COLOR=#000000][2668]: Device: [COLOR=#000080]Gate 215[/COLOR] Set to [COLOR=#008000]-1[/COLOR] [/COLOR][/TD]
               		[/TR]
              [/TABLE]
              [TABLE="class: log_table_row"]
              [TR]
              [TD="class: LogDateShort LogDateTime1, align: left"][COLOR=#000000]Nov-08 08:28:40 [/COLOR][/TD]
               			[TD="class: LogPri1, align: left"] [/TD]
               			[TD="class: LogType1, colspan: 3, align: left"][COLOR=#000000]AK Remootio [/COLOR][/TD]
               			[TD="class: LogEntry1, colspan: 8, align: left"][COLOR=#000000][0]: * Set Remootio ws://192.168.0.71:8080/ (HSPI_AKRemootio.DeviceRemootioDevice) [/COLOR][/TD]
               		[/TR]
              [/TABLE]
              [TABLE="class: log_table_row"]
              [TR]
              [TD="class: LogDateShort LogDateTime0, align: left"] [/TD]
               			[TD="class: LogPri0, align: left"] [/TD]
               			[TD="class: LogType0, colspan: 3, align: left"] [/TD]
               			[TD="class: LogEntry0, colspan: 8, align: left"] [/TD]
               		[/TR]
              [/TABLE]
              [TABLE="class: log_table_row"]
              [TR]
              [TD="class: LogDateShort LogDateTime1, align: left"][COLOR=#D58000]Nov-08 08:28:40 [/COLOR][/TD]
               			[TD="class: LogPri1, align: left"] [/TD]
               			[TD="class: LogType1, colspan: 3, align: left"][COLOR=#D58000]AK Remootio Warning [/COLOR][/TD]
               			[TD="class: LogEntry1, colspan: 8, align: left"][COLOR=#D58000][2626]: WebSocket Closed code: 1006, reason 'An exception has occurred while connecting.' [/COLOR][/TD]
               		[/TR]
              [/TABLE]
              [TABLE="class: log_table_row"]
              [TR]
              [TD="class: LogDateShort LogDateTime1, align: left"][COLOR=#000000]Nov-08 08:28:19 [/COLOR][/TD]
               			[TD="class: LogPri1, align: left"] [/TD]
               			[TD="class: LogType1, colspan: 3, align: left"][COLOR=#000000]AK Remootio [/COLOR][/TD]
               			[TD="class: LogEntry1, colspan: 8, align: left"][COLOR=#000000][2627]: Device: [COLOR=#000080]Gate 207.Output[/COLOR] Set to [COLOR=#008000]-1[/COLOR] [/COLOR][/TD]
               		[/TR]
              [/TABLE]
              [TABLE="class: log_table_row"]
              [TR]
              [TD="class: LogDateShort LogDateTime0, align: left"][COLOR=#000000]Nov-08 08:28:19 [/COLOR][/TD]
               			[TD="class: LogPri0, align: left"] [/TD]
               			[TD="class: LogType0, colspan: 3, align: left"][COLOR=#000000]AK Remootio [/COLOR][/TD]
               			[TD="class: LogEntry0, colspan: 8, align: left"][COLOR=#000000][2626]: Device: [COLOR=#000080]Gate 207[/COLOR] Set to [COLOR=#008000]-1[/COLOR] [/COLOR][/TD]
               		[/TR]
              [/TABLE]
              [TABLE="class: log_table_row"]
              [TR]
              [TD="class: LogDateShort LogDateTime1, align: left"][COLOR=#000000]Nov-08 08:28:19 [/COLOR][/TD]
               			[TD="class: LogPri1, align: left"] [/TD]
               			[TD="class: LogType1, colspan: 3, align: left"][COLOR=#000000]AK Remootio [/COLOR][/TD]
               			[TD="class: LogEntry1, colspan: 8, align: left"][COLOR=#000000][0]: * Set Remootio ws://192.168.0.70:8080/ (HSPI_AKRemootio.DeviceRemootioDevice) [/COLOR][/TD]
               		[/TR]
              [/TABLE]

              Comment


                #8
                Ok, I'll check again

                Comment


                  #9
                  Hmm, since I tried to minimise the number of HS devices - the main root device is used for both connection status and open/close status.

                  So I can't see what's the option? Either not show disconnect status, or better create separate input device?

                  Comment


                    #10
                    Originally posted by alexbk66 View Post
                    Hmm, since I tried to minimise the number of HS devices - the main root device is used for both connection status and open/close status.

                    So I can't see what's the option? Either not show disconnect status, or better create separate input device?
                    Personally, I always prefer to have too much information rather than not enough....so I think moving the connection status to a new separate child device would be better than simply removing the connection status from the main root device.

                    Comment


                      #11
                      Heya AK, I just noticed that there's now a 3.0.0.5 beta out there...The release notes indicate that this is the mDNS update... does it include any updates to the connection status issue as well? Let me know...I can test both.

                      Comment


                        #12
                        Originally posted by IKUS View Post
                        Heya AK, I just noticed that there's now a 3.0.0.5 beta out there...The release notes indicate that this is the mDNS update... does it include any updates to the connection status issue as well? Let me know...I can test both.
                        Hey IKUS no, I haven't worked on your issue, it's a major change to separate the devices (since I'm not home - I can't test). I'll try to do it, but it will require your testing.

                        If you could test mDNS in the mean time - would be great. But you will probably have to delete your devices to test if they are re-created using the discovery.

                        Appreciate your patience.
                        -Alex

                        Comment


                          #13
                          The best option I think is to separate 'output' device from 'root' - this way you get separate device for connection status. I guess I have to do that, but it's a bit of work, since I'm not home - difficult to test...

                          Comment


                            #14
                            alexbk66 I'll be happy to test it out. Just let me know.

                            Comment


                              #15
                              Originally posted by IKUS View Post
                              alexbk66 I'll be happy to test it out. Just let me know.
                              https://forums.homeseer.com/forum/se...66-version-hs4

                              Comment

                              Working...
                              X