velociraptor icon indicating copy to clipboard operation
velociraptor copied to clipboard

[Feature Request] Use App Usage Stats instead of Accessibility Service

Open yochananmarqos opened this issue 7 years ago • 7 comments
trafficstars

App Usage Stats can be used to detect when Maps is open. I don't believe it would be able to detect when Maps is in Navigation mode vs. other activities, however. Perhaps add it as an option for those who do not want to use the Accessibility Service.

yochananmarqos avatar Feb 04 '18 16:02 yochananmarqos

AFAIK app usage stats would require polling the foreground app every couple of seconds. The accessibility service emits events when the activity changes. I haven't tested it, but I imagine it would use more battery. Do you know other apps that use the app usage stats method?

pluscubed avatar Feb 04 '18 18:02 pluscubed

Tasker now does with v5.1.

yochananmarqos avatar Feb 04 '18 18:02 yochananmarqos

I downloaded Tasker, and it looks like it checks the foreground app every 1.5 seconds (when the display is on). What's the battery impact like on your device?

pluscubed avatar Feb 04 '18 18:02 pluscubed

I haven't noticed any impact on battery. I use it to enable auto rotate when using Maps or YouTube.

yochananmarqos avatar Feb 04 '18 18:02 yochananmarqos

I haven't noticed any impact on battery. I use it to enable auto rotate when using Maps or YouTube.

yochananmarqos avatar Feb 04 '18 18:02 yochananmarqos

I see. I'll look into testing it. I'm a full-time high school student, and this isn't high priority (as it's only an alternative method), so it might be a while before I can do so.

pluscubed avatar Feb 04 '18 18:02 pluscubed

Some anecdotal evidence: During 1 day / 3 screen-on hours, Tasker with an app check trigger used 20mAh. During the same time period, Velociraptor with the accessibility service used 3mAh.

pluscubed avatar Feb 05 '18 04:02 pluscubed