Announcement

Collapse
No announcement yet.

Geo-location Testing

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

    Geo-location Testing

    I've been doing some testing on the accuracy of the geo-location before I build it into my rules and I'm seeing something odd.

    iPhone 12 Pro Max. Accuracy is set to most accurate and only report significant changes is off.
    Geofence Radius/margin is 0.1 mile

    I have push notifications setup for when I enter/exit the geofence for testing and when exiting, I get the expected notification for exiting but I also get the entering one. HSBuddy is triggering entering/exiting gofence at the same time.

    Any ideas?

    Thanks

    #2
    When you enter, are you also getting two notifications? It may be that your margin is too small, i.e. your enter and exit fences are too close together. Try changing the margin to .15 or .2 to see if that helps.

    Comment


      #3
      Hi! As Kevb said, it is possible that this behavior is caused by readings that make it appear as if the device is jumping back into the geofence. Even at highest accuracy setting, some phones do fallback to cellphone tower to determine location when GPS signal is low, and in some cases the phone connection may jump intermittently between towers causing this behavior.

      I would suggest experimenting with larger Radius/Margin - I've got mine setup at 0.25mi each, and have not noticed this behavior.

      Comment


        #4
        My house is made from concrete, so the GPS signal is degraded. I looked at the log, found the coordinates the iPhone was reporting, pasted them into Google Maps and found that the iPhone was reporting coordinates 1.4 miles away. I used that info to make the “Margin” bigger than the 1.4 miles (2.25 km). Additionally, I found it to be more accurate if the “Accuracy” setting was set to the maximum and disabling “Significant changes only” in HSBuddy.

        Comment


          #5
          I just started using HS Buddy this month and just began testing as well. I have an iPhone 8 while my wife has an iPhone 12. I send push notifications for entering and exiting the GEOFENCE. Using the 0.25 mile margin. The iPhone 12 seems to work very well when entering and exiting the fenced area. The iPhone 8 is very intermittent at best. Settings on the phones are the same - no idea how to troubleshoot this ???

          I began looking at creating occupancy code. Using HS buddy Device - if I use OR IF for each phone, the HS4 command sequence is the same when evaluating phone locations. However, if I use the AND IF statement, I get a slightly different command syntax, see screenshots. When using OR IF - both IF and OR IF use same ENTER action word. If I use AND IF, the if is the typical Leave but the And IF is outside of. I feel I am missing something here?
          Attached Files
          Last edited by Weisel_Abode; December 30, 2021, 07:05 PM. Reason: Updated text to clarify behavior.

          Comment


            #6
            I believe you are misunderstanding AND IF and OR IF- which is pretty common at first. IF is a trigger, ANDIF is a condition, OR IF is another trigger. So your OR IF event is fine. There is an Event Clinic in the HS3 forum which is extremely helpful for me. I use a virtual switch for each of us. My entering the geofence sets the my virtual device to home, exiting sets it to away. I have another setup for my wife's phone. If either of the virtual devices is set to "HOME", another virtual device is set to "House Occupied". If both of us are away, the house is unoccupied. I have found that the virtual devices change status near instantly, but push notifications are sometimes delayed. We are using android phones. Hope this is helpful.

            Comment


              #7
              I only have 2 devices with geofencing enabled so I have been using the group conditions (any device/all devices) to track occupancy. I think this could be improved to allow selecting multiple devices rather than any/all. The alternative would be to use virtual devices like Kevb suggested.

              Click image for larger version  Name:	Screenshot_20211230-171604_Edge.jpg Views:	0 Size:	122.4 KB ID:	1517512

              Comment


                #8
                Thank you - set up the virtual devices - have not been able to real life test this. I have not built any events for a while and forgot about this trigger versus condition issue.

                Losing the battle on determining my phone location. We both left the house for a couple of hours today. Got the push notification that she left the house. Not about my phone however. Turns out during this time away; HS4 log shows my wife's phone location being updated every couple of seconds - swamping the log file. This continued until we arrived back home. Not so for my phone - guessing my phone may have been blocked by all the attention to my wife's phone. I checked the HS Buddy Server and that log has same information - so issue resides with HS Buddy. By the way the locations for wife's phone appear to be all different indicating it is reporting location continuously. My phone is set to Medium accuracy with Significant change only turned off; wife's phone was the same - am changing hers to Significant Changes Only to ON. Changed geo fence outer ring at 0.75 miles (had been 0.25 as well). Inner ring is default 0.25 mile. Shutting off push notifications next.

                Comment


                  #9
                  Originally posted by Weisel_Abode View Post
                  Thank you - set up the virtual devices - have not been able to real life test this. I have not built any events for a while and forgot about this trigger versus condition issue.

                  Losing the battle on determining my phone location. We both left the house for a couple of hours today. Got the push notification that she left the house. Not about my phone however. Turns out during this time away; HS4 log shows my wife's phone location being updated every couple of seconds - swamping the log file. This continued until we arrived back home. Not so for my phone - guessing my phone may have been blocked by all the attention to my wife's phone. I checked the HS Buddy Server and that log has same information - so issue resides with HS Buddy. By the way the locations for wife's phone appear to be all different indicating it is reporting location continuously. My phone is set to Medium accuracy with Significant change only turned off; wife's phone was the same - am changing hers to Significant Changes Only to ON. Changed geo fence outer ring at 0.75 miles (had been 0.25 as well). Inner ring is default 0.25 mile. Shutting off push notifications next.
                  Thank you for the update. If you can send a feedback report from the app in the iPhone 8 I can look into the geolocation logs, in case there's anything that might point to the issue.

                  Comment


                    #10
                    Thank you for the help!!

                    Ran two, 2 mile routes today as a test. First with both phones and the second with just the single iPhone 8. Have sent you two separate feedback reports. When checking the HS4 logs - the system now seems to be working correctly?!?! With both phones I get alternating updates every second or so and when going with the single iPhone 8 it too appears to be working as I think it should; updating every second or so.

                    I had not seen this work before (only began testing in earnest a couple days ago so will go back through logs deeper). I do see an error in log that states something about "Method getunopenednotification count does not exist in this plug-in". However, did not see any behavior difference between this error and phones behavior so not too concerned about this

                    I jumped to the conclusion issue was HS Buddy prematurely - more likely with the iPhone8. I say this as during testing today I saw a parking push notification I had never seen before from Google Maps (especially because the app was closed and I have location services shut off when app is closed - so how did the notification get triggered). My wife and I often use Waze for traffic - any thoughts if location services on iPhone 8 could be an issue?

                    Comment


                      #11
                      Thank you for the update. I'm glad to hear that the issue appears to be resolved!

                      I have location services shut off when app is closed
                      This would certainly be an issue. In order for Geolocation to work in HSBuddy, it needs that Location Services are turned on (overall) and that the app is given permission to acquire precise location information while running in the background (i.e. "Always" as opposed to "While running the app")

                      I do see an error in log that states something about "Method getunopenednotification count does not exist in this plug-in"
                      This would indicate an older version of the plug-in is running in the server. If you upgrade to version 3.28 it should go away.

                      Comment


                        #12
                        An FYI on an unusual find; at least to me... Discovered difference between wife's iPhone 10 and my iPhone 8 with HSBuddy location tracking behavior. Seems to reside with wireless channel used. Noticed her phone had been logged into the NetGear 5G wireless connection and mine was still on the 2.4G. Had no idea it would matter and never felt I needed the higher bandwidth. Only reason I switched was to keep configurations the same. After switching had noticed my location was now being tracked reliably when I left and arrived home. Logic for occupancy is working fine and as such can begin building additional controls!!!

                        Comment


                          #13
                          Originally posted by Weisel_Abode View Post
                          An FYI on an unusual find; at least to me... Discovered difference between wife's iPhone 10 and my iPhone 8 with HSBuddy location tracking behavior. Seems to reside with wireless channel used. Noticed her phone had been logged into the NetGear 5G wireless connection and mine was still on the 2.4G. Had no idea it would matter and never felt I needed the higher bandwidth. Only reason I switched was to keep configurations the same. After switching had noticed my location was now being tracked reliably when I left and arrived home. Logic for occupancy is working fine and as such can begin building additional controls!!!
                          Thanks for the update! I've had phones in the past that showed weird connectivity issues when switching from WiFi to GSM or viceversa. Maybe something similar is going on with your phone but it only happens on the 2.4G WiFi radio?

                          In any case, happy to know it is resolved now.

                          Comment


                            #14
                            Three days and going strong - yes; problem only happens when using the iPhone 8 on the 2.4G WiFi!

                            Comment

                            Working...
                            X