Is there a way to know what time my device has been turned on?
Something like an adb command or something like that?
any idea?
Is there a way to know what time my device has been turned on?
Something like an adb command or something like that?
any idea?
If you want to know what at what time your device was turned on, you can go into Settings > About Phone > Status, and there you have an "Uptime" entry, which tells you how long the device has been on for. Subtract that from the current time, and you have the time the device was turned on.
You can also run the uptime
command from adb or terminal, see this answer here.
If you want to do it in code, you can do something like:
System.currentTimeMillis() - SystemClock.elapsedRealtime();
Check this for more details: How to get Android system boot time