icloud3 icon indicating copy to clipboard operation
icloud3 copied to clipboard

Sensor dropouts

Open GitHubGoody opened this issue 2 years ago • 6 comments

The battery level (and presumably other sensors) seem to drop their state values fairly regularly even if using both iOS and iCloud, but it's definitely worse on devices set to only use iCloud as shown in this screenshot:

image

Is there a setting I need to tweak or does iCloud3 need more permanence with some state values? #notacoder

GitHubGoody avatar Jun 05 '22 13:06 GitHubGoody

The battery gets picked up when a locate is done. The time between locates varies based on the distance from the tracked zone (home) so that might have something to do with it. You might compare it to the iosapp battery sensor or the iosapp device tracker battery attribute.

gcobb321 avatar Jun 05 '22 13:06 gcobb321

Thanks, I have done that. I'll post a comparison graph later today. It will show zero dropouts from the straight iOS app data and some dropouts from the iCloud3 iOS app/iCloud "hybrid" data. I think I can live with that based on the reason you stated (should be short lived) unless I decide to create an automation off an iCloud3 sensor or attribute that is flakey (a delay could work, but not ideal).

The flip side is that the straight iCloud data seems to be updated more frequently resulting in better fidelity than the iOS app...when it's not dropping out completely.

Could iCloud3 handle the dropouts for iCloud only data (pictured above) differently by somehow buffering and smoothing out the final data presented?

GitHubGoody avatar Jun 05 '22 15:06 GitHubGoody

@gcobb321 Sorry, I just remembered this.

Here are the graphs I mentioned. The bold lines are from the Home Assistant iOS app while the thinner lines are from iCloud3 set to use hybrid data from the Home Assistant iOS app and Family Sharing. I have not installed the iOS app on my wife's phone yet, so you can see there's not a bold line and that Family Sharing only data is the most erratic, but all of them have dropouts. All of these devices have mostly been in the Home zone during this time period except for the cyan iCloud3 graph for a brief period in the morning and toward the end of the chart (but not that ~4 hr dropout period).

image

GitHubGoody avatar Jun 14 '22 21:06 GitHubGoody

@gcobb321

Any other thoughts as to what might be causing these dropouts?

GitHubGoody avatar Sep 08 '22 23:09 GitHubGoody

No. I haven’t given it any thought.

iCloud3 v3 monitors the iOS app battery sensor, in addition to the Icloud account battery data, and updates the battery sensor for tracked and monitored devices. You might want to look at monitoring the iOS app battery sensor instead of the iCloud3 battery sensor until it is released.

gcobb321 avatar Sep 08 '22 23:09 gcobb321

Except you can't monitor the Apple Watch battery with the iOS Home Assistant app. Just the internal iPhone battery.

amaisan0 avatar Sep 09 '22 01:09 amaisan0

v3 will monitor and report battery changed by both the iOS App and the iCloud FamShr tracking methods (there is no battery info from FmF).

gcobb321 avatar Oct 17 '22 14:10 gcobb321

I have the same problem, which is stopping me from using this integration, I need it for battery level based automations. The same situation is when restarting iCloud3 - all battery sensors are dropping to 0%. This is looking like there is no support for "unknown" state, when battery info is missing, "unknown" state is not displayed in graphs and history in ha, and also not counted in statistics.

Is there any way to debug this issue? is the "0" being read from iCloud or battery level is missing?

kamkilt avatar Oct 27 '22 20:10 kamkilt

I've used a Node-RED flow to smooth out / discard false positives (or negatives, in this case) for the ic3 watch battery sensor. LMK if you're interested, since it doesn't look like this is getting fixed (or can be fixed, thanks to Apple).

amaisan0 avatar Oct 27 '22 20:10 amaisan0

iCloud3 v3 has fixed this issue. It uses data from the iCloud acct and polls the iOS app every 5 minutes or so. The values are restored on a Home Assistant or ic3 restart.

———————— Gary Cobb On Oct 27, 2022 at 3:36 PM -0500, Adamo Maisano @.***>, wrote:

I've used a Node-RED flow to smooth out / discard false positives (or negatives, in this case) for the ic3 watch battery sensor. LMK if you're interested, since it doesn't look like this is getting fixed (or can be fixed, thanks to Apple). — Reply to this email directly, view it on GitHub, or unsubscribe. You are receiving this because you modified the open/close state.Message ID: @.***>

gcobb321 avatar Oct 28 '22 01:10 gcobb321

iCloud3 v3 has fixed this issue. It uses data from the iCloud acct and polls the iOS app every 5 minutes or so. The values are restored on a Home Assistant or ic3 restart. ———————— Gary Cobb

Any tips or guide how to update to iCloud3 v3 ? I have removed iCloud3 v2.4.7, manually uploaded v3, added iCloud3 Device tracker integration, logged into iCloud, device are visible but not updating any values? iCloud3 Event Log is also not working (device.tracker/icloud3_update service not found error)

kamkilt avatar Oct 28 '22 06:10 kamkilt

I don’t know where you got v3 from but it has not been released yet. If you found it on one of my GitHub repos, it is very old and was there so I could do some code review while away. V2.4.7 is the latest version.

gcobb321 avatar Oct 28 '22 09:10 gcobb321

I don’t know where you got v3 from but it has not been released yet. If you found it on one of my GitHub repos, it is very old and was there so I could do some code review while away. V2.4.7 is the latest version.

Yes, I took it from your another repo: https://github.com/gcobb321/icloud3_v3

Is there any roadmap when v3 will be released?

kamkilt avatar Oct 28 '22 10:10 kamkilt

Probably, hopefully, thumbs crossed soon. I was hoping for a really late November beta. But I have a lot going on.

Anyway, thanks for trying it out and living on the ‘bleeding edge’.  It’s looking pretty good but I found a few things that need to be fixed after traveling to Houston. I’m hoping to wrap up the docs next week.

Gary On Oct 28, 2022 at 5:27 AM -0500, kamkilt @.***>, wrote:

I don’t know where you got v3 from but it has not been released yet. If you found it on one of my GitHub repos, it is very old and was there so I could do some code review while away. V2.4.7 is the latest version. Yes, I took it from your another repo: https://github.com/gcobb321/icloud3_v3 Is there any roadmap when v3 will be released? — Reply to this email directly, view it on GitHub, or unsubscribe. You are receiving this because you modified the open/close state.Message ID: @.***>

gcobb321 avatar Oct 28 '22 19:10 gcobb321