Why I'm asking for this: I look for phone app for automatic sleep tracking. Easiest way is to define sleep as longest time of screen turned off.
Existing sleep trackers usually require manual start/stop and are overbloated for such a simple purpose. Same for phone activity trackers - they usually include apps usage analytics, time warnings, blocking of overusage, etc.
So you app is very close to a perfect match. Anyone can easily implement any analyzing logic, charts and statistics in a spreadsheet table basing on data from Screen Time.
CSV seems to be an optimal export format, containing just event and its timestamp. The latter might be Unixtime, easiest to do computations with it. So it might be like following:
"on"; "1655323662";
"off"; "1655323667";
Additional dependency is to save history log for a long time, it is not preserved for now, as far as I see.
I believe all of that should add small overhead to code and UI (just one "export" button).
Couple of unrelated things, I can create separate issues for them if necessary:
- As far as I see, there is no option to disable notification from Screen Time. I did it in Android system settings, but some people might miss this way.
- I have "Screen Time is running in background" system notification on Android 8. Not sure why it appears since a lot of apps are working in background without this notification.
Paid version with that features is also an option, especially taking into account it's opensource 👍