Sweet, you have all kinds if stuff in your response that I don’t have.
What type of trackr is it?
Not sure what the id field is for.
I also don’t have the lost field and email field and time between updates field or the ownership field. I’ll add those in.
Wonder why your battery reports as -1?
You can ignore that error I removed that function, must have forgot to remove it from the test.py.
cool, it’s on of the bravo’s. what was the setup to integrate it into HA? I’m hoping it’s more accurate to use for presence detection than my phone with nmap.
I made added the changes I mentioned, so if you want you can test again. upgrade to 0.0.5. To implement it into HA, you can try running it as a custom component until it gets added officially.
Okay cool! Did you add a name to your trackr? Your response from above doesn’t have a name set so I would have expected you to get a device with a name of the trackr id.
I got curious and went ahead and setup a trackr for my wife. I through a for loop around the display for the devices and it works well. Looks like it’s just a list of dictionaries.
Custom name: Chips Keys
Location: {'longitude': -99.99999, 'latitude': 99.999999}
Last time seen: Fri Dec 23 13:32:18 UTC 2016
Tracker ID: 00009999-999999999
Type: Bluetooth
Last upadted: Thu Dec 22 22:10:09 UTC 2016
Battery level: None
Custom name: Susan keys
Location: {'longitude': -88.888888, 'latitude': 88.888888}
Last time seen: Fri Dec 23 13:32:42 UTC 2016
Tracker ID: 0000793b-f84e48d2
Type: Bluetooth
Last upadted: Fri Dec 23 12:55:53 UTC 2016
Battery level: None
(hass) hass@hass:~$
Now just how to figure out how to get hass to show them. Haven’t played with that yet.
Ok, I setup an account for my wife when I setup her trackr so she and I are on different email accounts. I then added her to a group called family. Once she confirmed that (and after a restart), I was able to see her tracker information in HA. It integrates well into HA and recognizes the zones I had setup around different locations in HA. For example, I had zones setup for the stores my wife supports back when I was using the iphone integration (which chewed up our batteries). HA is using the lon/lat reported by trackr to report that my wife is in one of her stores right now.
The only negative I see to this is that the trackr’s reported gps location isn’t all that accurate. I had setup the zone around my house to be 100ft, and that was fine for iphone reporting. But trackr isn’t that accurate in it’s gps reporting. I enlarged the zone around my house to be 500 ft and so far so good.
Sweet! That is awesome. I was assuming that it was going to be a list of dictionaries you just never know. Glad to know the group thing works too, that is interesting. Yeah I noticed the same thing on the accuracy going to need to make my zones a little bigger too.
Looks like we should be good to go for the 0.36.0 release as long as there are no complaints on my PR.
One thing I am not sure if you noticed or not, but at the moment I have it throttled in pytrackr to only poll every 5 minutes. I think that is about how often the Android app is doing it so since this isn’t supported by TrackR I thought I could at least not hammer on their API in hopes that they don’t ban us somehow.
5 minutes should be fine. You might want to make that something that could be configured through HA with a minimum value of 5 minutes. I might not care every 5 minutes about my dogs, but for proximity to the house for people, 5 minutes would be about right for me.
I need to play with the proximity sensor some more. So that I can base things not just on home/not home but on distance from home and direction of travel.
It doesn’t seem to be updating in HA every 5 minutes. My wife is 20 minutes away from her last location and it still shows her as being in that zone. How does trackr update their location for her sensor thing. Does she have to have the app running on her phone? Or does someone near her just have to have it running on their phone?
I am not sure, I haven’t been able to test much with that. I believe it will update when anyone with the trackr app is near by. I don’t know how often the trackr app scan though, or how the phones GPS setting effect it.