Announcement

Collapse
No announcement yet.

PHLocation V2 Discussion

Collapse
This is a sticky topic.
X
X
  • Filter
  • Time
  • Show
Clear All
new posts

  • MNB
    replied
    Steve, thanxs for the update, like I said in my previous post I did not realize that PHL Direction device wasn't a near instantaneous updatable device, it wasn't until I was troubleshooting why my event did not executing when I thought it should and then as I looked at my iPhone devices time stamp was when my eureka realization occurred. I've since updated my events to use my Geo Fences (my previous methodology) as they update real time and I can determine if I'm approaching or depart. Mike

    Leave a comment:


  • MNB
    replied
    John, GeoFency is one of the many (11 total) apps that V2 is supporting. Look under "Users / Devices" if you look under "Choose user type to add" drop down you will see Geofency. As to automatic Polling, Thanxs to Randy, I have a few events that change my polling from every minute to 15 minutes to 1 hour and they seem to be working when I look at my iCloud polling interval it is set to what ever my event set it too the time stamp is at the time the polling was set if you look at your Account Status device the time should update accordantly. If this isn't happening then you might want to "reset account" your iCloud under >Service Accounts>PHLocation2 Tab for iCloud. Mike

    Leave a comment:


  • Timon
    replied
    For some reason automatic polling to my iCloud is not working. I can start a manual poll and that works just fine. I've tried setting the polling interval to everything from a minute to ten minutes and it never automatically poles. The dates never change unless I manually poll.

    I've looked for any setting I might have missed but have yet to find one.

    ----------------------

    Is Geofency no longer supported? I was using it on V1 but don't see it as an option in V2. Now to figure out which of the other two to use.

    Leave a comment:


  • slbuck
    replied
    Originally posted by MNB View Post
    Thanxs Steve this was what I was looking for.. I assume that you did not change your HomeLocDirTimeOut value which is set for 5 minutes? I found that some of the events that were using Home Location Direction took too long (5 minutes) and would not necessary trigger the event reliability especially when there were several that would trigger near real time such as Approaching Home which had Time to Home=6 min, Time at Location=0 and Home Direction=Approaching (which changed 5 minutes later) I would expect that your experiencing the similar outcomes (your Time to Home=10 min)? Mike

    If I understand the Paul's write up your adjustment suggest that you would have to travel 900 meters with HomeLocDirCount=3 vs. 600 meters if HomeLocDirBuff=300?
    UPDATE: I chose 128 meters as the HomeLocDirBuff since that is what my minimum distance to move is set for my users. (.08 miles).

    Here are my settings:

    HomeLocDirTimeOut=5
    HomeLocDirCount=3
    HomeLocDirBuff=128

    I would need to travel a minimum of 384 meters in this case before the Home direction would change. I haven't seen any issues with using Approaching and firing events. Typically what I do is put something like "If time to home < 15 minutes and home direction is approaching" then fire the event and don't fire again for 5 minutes. This way, as long as I'm heading toward home with at least 3 successively closer points, then the home direction will flip to approaching and will allow the event to fire. If I run up the street for a quick errand and I'm less than 5 minutes from the house, then you're right, I would not get an alert that I'm on the way home because the direction timeout is 5 minutes. I may play with that and change it to 3 minutes, but you have to be careful since if you are stuck in traffic and you don't move more than the direction buffer value (128 meters in my case), then the direction could switch to stopped and then require 3 more points before switching back to approaching.

    Leave a comment:


  • MNB
    replied
    Paul, your "PHLocation V2 Release Notes" needs to be updated to reflect your latest release version .63

    Leave a comment:


  • MNB
    replied
    Thanxs Steve this was what I was looking for.. I assume that you did not change your HomeLocDirTimeOut value which is set for 5 minutes? I found that some of the events that were using Home Location Direction took too long (5 minutes) and would not necessary trigger the event reliability especially when there were several that would trigger near real time such as Approaching Home which had Time to Home=6 min, Time at Location=0 and Home Direction=Approaching (which changed 5 minutes later) I would expect that your experiencing the similar outcomes (your Time to Home=10 min)? Mike

    If I understand the Paul's write up your adjustment suggest that you would have to travel 900 meters with HomeLocDirCount=3 vs. 600 meters if HomeLocDirBuff=300?

    Leave a comment:


  • slbuck
    replied
    Originally posted by MNB View Post
    Paul, I've noticed that my "Home Direction" device takes ~ 5 Mins to change state from approaching to Stopped which obviously affect ones event timing (I believe you made mention in an earlier post about 5 minutes) is there any way of getting a quicker response like <1 minute? Mike
    Got this from Paul the other day. I updated the HomeLocDirCount to 3 points since 2 would sometimes show approaching when I was leaving.

    Originally posted by Sooty
    You can adjust that now with ini settings but it's a global setting and not per user.


    If you're comfortable manually editing the PHLocation2.ini file then the settings go in the [Startup] section and won't be there by default.
    The defaults which are used if no settings are present are:

    HomeLocDirTimeOut=5
    This is the time elapsed (in minutes) without any updates before setting the device to "Stopped".
    Allowed values are 2 to 60 inclusive

    HomeLocDirCount=2
    This is the number of same direction updates to cause a change of state to Approaching or Leaving.
    Allowed values are 2 to 10 inclusive

    HomeLocDirBuff=300
    This is the distance (in metres) that a location must have moved since the last received location to be considered in the above count.
    Allowed values are anything >= 100

    If you change the settings in the ini file then you will need to re-start the plug-in for them to take effect.

    Leave a comment:


  • MNB
    replied
    Originally posted by sooty View Post

    I don't use actual device location here any more (have no real use for it), but when I did I would use geofencing to control the polling. When I entered the home geofence for example I would have it:

    1. Stop polling.
    2. Wait 5 minutes.
    3. Single poll for current location.

    Polling was then resumed when exiting the geofence.

    Paul..
    Paul, based on your previous post "(have no real use for it "actual device location" ), then what are you doing then if your not using actual device location? Mike

    Leave a comment:


  • mwaite
    replied
    Originally posted by sooty View Post

    There may well be something that I missed. If it's broken I will endeavour to fix it once I know what the cause is.

    It's getting late here now so I'll look at it in more detail tomorrow but from memory, the only times it would generate a new location trigger and reset the time at location are:
    1. You have (or it thinks you have) moved more than the min dist.
    2. The "Force update of position devices" option in config>other is ON.
    3. It detects a "User has Stopped" event.

    If you've not moved for a few hours and it's only holding the time at location for 15 minutes, then something isn't right.
    Assuming you're not going to be moving for the next hour or so, go to the plug-in general config page and set debug to file ON. Leave it on until you observe a couple of resets of the time at location device (with no actual device movement) then switch OFF the debugging and email me the log file.

    paul dot huddlestone at gmail dot com

    I'll look over it in the morning.

    Paul..
    email sent.

    Leave a comment:


  • MNB
    replied
    Paul, I've noticed that my "Home Direction" device takes ~ 5 Mins to change state from approaching to Stopped which obviously affect ones event timing (I believe you made mention in an earlier post about 5 minutes) is there any way of getting a quicker response like <1 minute? Mike

    Leave a comment:


  • MNB
    replied
    Paul, I noticed when I downloaded v.61 I got v.63, was I faster than you updating your text description? Mike

    Leave a comment:


  • sooty
    replied
    Originally posted by mwaite View Post

    Very interesting. I can see how this can get convoluted fast. I understand the thresholds you described, but I'm not sure that's what is happening. I have min. distance to move set to 0.2 miles, the phone has not moved more than 50 feet or so for the past 8 hours. Best 'not moving' time has been only about 15 minutes (all day long I've been monitoring). Some logic is definitely different than PHLocation(V1), as I didn't have this issue, it seemed like the min. distance would really have to be exceeded to trigger a new location event. In my case I've lost some functionality. It's a fantastic program though, and my donation is on the way.
    There may well be something that I missed. If it's broken I will endeavour to fix it once I know what the cause is.

    It's getting late here now so I'll look at it in more detail tomorrow but from memory, the only times it would generate a new location trigger and reset the time at location are:
    1. You have (or it thinks you have) moved more than the min dist.
    2. The "Force update of position devices" option in config>other is ON.
    3. It detects a "User has Stopped" event.

    If you've not moved for a few hours and it's only holding the time at location for 15 minutes, then something isn't right.
    Assuming you're not going to be moving for the next hour or so, go to the plug-in general config page and set debug to file ON. Leave it on until you observe a couple of resets of the time at location device (with no actual device movement) then switch OFF the debugging and email me the log file.

    paul dot huddlestone at gmail dot com

    I'll look over it in the morning.

    Paul..

    Leave a comment:


  • mwaite
    replied
    Originally posted by sooty View Post

    Things should work more or less as you describe in that the time at location should only be reset when a new location trigger occurs.

    I'll look over the code now but I think I know what may cause the extra triggers without a corresponding history entry.

    I'll try and explain.....
    The numbers are irrelevant but as an example, consider a min dist to move setting of 0.5 miles and you're travelling home with a 5 minute iCloud polling interval.
    The plug-in polls iCloud and gets the location of your device which at that time happens to be 0.4 miles from home and is also more than 0.5 miles since the last recorded location so a new location is recorded to history and the time at location device is reset.
    5 minutes later iCloud is polled again and this time you are at home and have stopped moving for the day.
    This presents a problem because you have not moved more than 0.5 miles since that last update, so the plug-in won't update your location and will show you still at the previous location of 0.4 miles away.

    To try and overcome this issue, the plug-in has a mechanism to detect if the user has stopped. I'll not try to explain how this is done here as it will take forever but what it does if it detects that the user has stopped is replace the last stored history record with the current location rather than adding a new record. This will also cause a new location trigger and reset the time at location device.

    Does that sound like it would cause the behaviour you're seeing?

    I can't just remember why it was done this way as opposed to just adding another history record but there must have been some method in my madness at the time
    Either way it would still generate a new location trigger / time at location reset.

    Another situation (discussed here recently) that could cause a new location trigger is that if the max accuracy setting > min dist to move. If this were the case, then you would see it in the history records.

    I don't use actual device location here any more (have no real use for it), but when I did I would use geofencing to control the polling. When I entered the home geofence for example I would have it:

    1. Stop polling.
    2. Wait 5 minutes.
    3. Single poll for current location.

    Polling was then resumed when exiting the geofence.

    Paul..
    Very interesting. I can see how this can get convoluted fast. I understand the thresholds you described, but I'm not sure that's what is happening. I have min. distance to move set to 0.2 miles, the phone has not moved more than 50 feet or so for the past 8 hours. Best 'not moving' time has been only about 15 minutes (all day long I've been monitoring). Some logic is definitely different than PHLocation(V1), as I didn't have this issue, it seemed like the min. distance would really have to be exceeded to trigger a new location event. In my case I've lost some functionality. It's a fantastic program though, and my donation is on the way.

    Leave a comment:


  • MattL0
    replied
    works great thanks

    Leave a comment:


  • sooty
    replied
    Originally posted by MattL0 View Post
    I am getting theses error when i try v.61. And avery time i restart the plugin

    no error on .60
    Feb-18 16:45:01 PHLocation2 (Startup) Finished at 16:45:01.353
    Feb-18 16:45:01 PHLocation2 Error (Startup) Error count is 1 Plug-In functions disabled.
    Feb-18 16:45:01 PHLocation2 (Startup) Plug-In is registered.
    Feb-18 16:45:01 PHLocation2 (Startup) 0 known locations loaded.
    Feb-18 16:45:01 PHLocation2 (InitHomeLocation) Home Location set. Lat:45.43977 Lon:-73.48173 Rad:0.5 Msg:False
    Feb-18 16:45:01 PHLocation2 (LoadConfigSettings) Distance data provider is set to Pri:None Alt:None
    Feb-18 16:45:01 PHLocation2 (LoadConfigSettings) Static map provider is set to None
    Feb-18 16:45:01 PHLocation2 (LoadConfigSettings) Dynamic map provider is set to None
    Feb-18 16:45:01 PHLocation2 (LoadConfigSettings) Links map provider is set to None
    Feb-18 16:45:01 PHLocation2 (LoadConfigSettings) Elevation Data provider is set to Pri:None Alt:None
    Feb-18 16:45:01 PHLocation2 (LoadConfigSettings) Reverse Geocode provider is set to Pri:OSM Alt:None
    Feb-18 16:45:01 PHLocation2 (LoadConfigSettings) plug-in is working in Metric units.
    Feb-18 16:45:01 PHLocation2 Error (UpgradeDb) Error! No of updates Req doesn't match No of updates done. Not updating DB version.
    Feb-18 16:45:01 PHLocation2 (UpgradeDb) Version 8 update initiated.
    Feb-18 16:45:01 PHLocation2 (BackupDb) Database backed up to BK_20190218164501.db3
    Feb-18 16:45:01 PHLocation2 (UpgradeDb) Called. From v7 To v8
    Feb-18 16:45:01 PHLocation2 Warning (Startup) Database version update required
    Sorry. Should be fixed in .62 just uploaded.

    Paul..

    Leave a comment:

Working...
X