Windows Mobile uptime since boot or battery swap, registry key

I am (at the date of writing) the proud owner of an HD2; given its limited 1200 something mAh battery, and my precaution of always having a spare battery for each of my devices (even if now, with the HD2, I got rid in one swoop of mobile phone, PDA, compact camera and bluetooth gps receiver, and this is pretty much my only device, excluding my DSLR which I rarely bring with me), I went a little overboard and bought three spare batteries, which I charge with a mains charger and then swap out periodically.

Just now I became curious to check the uptime before the battery reaches 10% (at which point I take it out for charging), because I never really remember how long it has been since the last battery swap.

I dug a little, and the registry key that stores the uptime since last boot is

HKLM > System > Uptime > Clock

while the uptime since last battery swap (appears to become 0 when you take out the battery, and is not reset after a simple reboot) is

HKLM > System > Uptime > ClockSession

These keys contain a time interval expressed in seconds. Divide it by 60 twice, and by 24 once, and you get the uptime in days (and fraction of day). They have been verified under WM 6.5.X, yet there is no reason they shouldn’t work in not-so-older builds of  Windows Mobile too.

  This article has been Digiproved

Leave a Reply

Your email address will not be published. Required fields are marked *