We have moved at community.getvera.com

Author Topic: AutoVera updates sometimes delayed up to a few minutes  (Read 9784 times)

Offline mikee123

  • Hero Member
  • *****
  • Posts: 1521
  • Karma: +18/-11
Re: turning updates on/off in a scene
« Reply #30 on: July 26, 2014, 12:42:24 pm »
Over the last few days i have done a lot of testing. While i thought my phone updates quicker than the tablet, that was not the case. Testing with various different devices, what happens most of the time the updates in AutoVera are instant, probably about 80% of the time. Other times they can be delayed by up to a few minutes, not depending on which device i monitor, it happens with power switches, virtual switches, motion sensors. So the problem is somehow communication from Vera to AutoVera. I can see the device change on my ipad when i log into UI5, that updates normally, but then my phone as well as the tablet do not get the update. That being all 3 devices next to each other, on the same WiFi. If there is a way to help you find the cause of this (logs or anything else) please let me know. I love the app, and would like to help make it even better if i can.


I tried changing the thread title, as most of it is now about AutoVera delayed updates. Maybe that should be seperated and put in a different thread ?
« Last Edit: July 26, 2014, 12:45:28 pm by mikee123 »

Offline dkc

  • Moderator
  • Jr. Member
  • *****
  • Posts: 97
  • Karma: +6/-0
Re: AutoVera updates sometimes delayed up to a few minutes
« Reply #31 on: July 26, 2014, 12:53:08 pm »
You have access to logs from within the AutoVera app itself, enable system logs for a more detailed view.  You should be able to compare the timestamps for the received update to the time the message was supposed to be sent on Vera.  If the timestamps align, then the issue is related to bringing the device out of a sleep state.  If the timestamps are delayed themselves, then your device is incapable receiving GCM messages at the time they are sent, for one reason or another.  If you can study your logs and relay which of the two scenarios is causing the problem, I can certainly investigate further.  Thanks for your willingness to perfect AutoVera, I'm glad you are still enjoying your muddled experience with AutoVera :)


Offline dkc

  • Moderator
  • Jr. Member
  • *****
  • Posts: 97
  • Karma: +6/-0
Re: AutoVera updates sometimes delayed up to a few minutes
« Reply #32 on: July 26, 2014, 01:06:26 pm »
Doing some research, I've stumbled upon a potential cause for the issue.  You wouldn't happen to be using a Netgear WiFi router provided by your Telco?

Offline mikee123

  • Hero Member
  • *****
  • Posts: 1521
  • Karma: +18/-11
Re: AutoVera updates sometimes delayed up to a few minutes
« Reply #33 on: July 26, 2014, 01:09:43 pm »
I have a Virgin Media Superhub (not sure what that is, they have obviously rebranded this), and i use a Buffalo  WHR-G300N router configured as a access point

Offline dkc

  • Moderator
  • Jr. Member
  • *****
  • Posts: 97
  • Karma: +6/-0
Re: AutoVera updates sometimes delayed up to a few minutes
« Reply #34 on: July 26, 2014, 01:20:55 pm »
That is quite literally the exact model I suspected! This is a known issue with that router in particular, here is some reading: https://groups.google.com/d/msg/android-gcm/Y33c9ib54jY/YxnCkaPRHRQJ

Quote
TL:DR A colleague and I ran some tests using a man-in-the-middle gateway to record packet activity between the Android device and the router and came to the conclusion that the router (a Virgin Media "Super" Hub AKA a Netgear CG3101D) is deliberately forgetting the port mapping after 5 minutes of inactivity.

I'm somewhat relieved that the issue is not with Google or AutoVera, but I am sorry that you have to deal with this particular hardware problem. Sending a GCM message every two to three minutes as a workaround will not harm a powered device. I hope you find a fit resolution.

Offline mikee123

  • Hero Member
  • *****
  • Posts: 1521
  • Karma: +18/-11
Re: AutoVera updates sometimes delayed up to a few minutes
« Reply #35 on: July 27, 2014, 07:58:14 am »
I have been doing a little research on google about GCM. I must admit this is way over my head. I can see i somehow have to ping GCM every 2 mins ideally from my Android tablet as it is always on. But how to achieve this i have no idea. There are solutions (or one solution) but i do not understand it at all.

I think a way round this is using the super hub as a modem, and buy another router... not ideal (expensive) but it should solve my problem. Are other Netgear routers ok, or do you know of any to avoid ?
« Last Edit: July 27, 2014, 11:48:32 am by mikee123 »

Offline dkc

  • Moderator
  • Jr. Member
  • *****
  • Posts: 97
  • Karma: +6/-0
Re: AutoVera updates sometimes delayed up to a few minutes
« Reply #36 on: July 27, 2014, 02:02:27 pm »
I'm not aware of other off the shelf routers with this problem, so you're probably safe with anything relatively new.

That being said, I do have a solution you can try.

  • Create a new virtual switch, name it Staying Alive
  • Refresh AutoVera and enable status updates for the new device
  • Create a new Scene, name it Bee Gees
  • In the Scene, turn the Staying Alive switch On
  • Add a 3 minute delay to the Scene, then turn the Staying Alive switch Off
  • Create a Schedule to run the Bee Gees scene every 5 minutes

This means that every two or three minutes, an AutoVera Status Update will be sent over GCM, ensuring your connection is Staying Alive.

If you do try it, I'd be interested to know if it works :)

Offline mikee123

  • Hero Member
  • *****
  • Posts: 1521
  • Karma: +18/-11
Re: AutoVera updates sometimes delayed up to a few minutes
« Reply #37 on: July 27, 2014, 02:47:48 pm »
Interesting. I am implementing it now, i will keep you updated. If it works i can cancel the new router...

Thanks for your support

Offline mikee123

  • Hero Member
  • *****
  • Posts: 1521
  • Karma: +18/-11
Re: AutoVera updates sometimes delayed up to a few minutes
« Reply #38 on: July 27, 2014, 04:47:55 pm »
I can report back... it did not work unfortunately. There are still delays. I cannot say yet if the delays have been reduced. Also my phone and tablet are now reacting with different delays. I have not enabled the 'bee gees' updates on the phone. I cannot say yet which is quicker or better in updating, as its in the early stages of testing, and i sent quite a few triggers as there was no reaction... So that is just the first initial feedback

Offline mikee123

  • Hero Member
  • *****
  • Posts: 1521
  • Karma: +18/-11
Re: AutoVera updates sometimes delayed up to a few minutes
« Reply #39 on: July 31, 2014, 05:49:32 am »
All problems solved. You were spot on, it was the router. I have replaced the router, and have no delays any more. Even my SQ remote Vera commands seem to be instant again. Vera Alerts occasionally had delays, that seems to be instant now. Unbelievable how much trouble the router caused. Without your suggestion I do not think I would have ever found the cause. I thought that was all unrelated, I asked RTS about Vera alerts delays, and he could not explain it. I don't think he would have suspected a router at fault... It was a expensive solution, but worth it for me.
Many thanks