I have tablet that is used as Medical device where is running software that I am developing. I need have always actual time in my application.
Tablet do not contain CMOS battery so RTC time will restarted when batery is empty.
Tablet is aslo not connect to the internet so time synchronization via internet is not possible.
I need some notification from Windows to know that RTC time in BIOS was restarted. So I can ask user in me application to enter new time/date.
I suppoused that when RTC reset happened there will be default time and this default time will be used aslo in Windows but as I read for Windows 10 it does not work .
(https://learn.microsoft.com/en-us/troubleshoot/windows-client/shell-experience/changes-calendar-date-in-bios-not-reflected)
- Is there some background solution in Windows 10 how to know that RTC time was restarted ? ( some value in registry, some logs in windows,... )
- Is there some way how to use restarted RTC time in Windows 10 ?
During normal behaviour during Windows 10 startup:
if (RTC time > Windows system time) => RTC time us used in Windows
if (RTC time < Windows system time) => Windows keep system time and aslo set RTC time
- Is there some way how to block Windows 10 to set RTC time when RTC time was restarted ( or is older that Windows time) ? I tried to block service "Windows Time" but RTC time is still updated.
In this point I am thinking to disable time synchronization between RTC and Windows time and check directli this time to evaluate if RTC time was restarted (RTC time is older than Windows time)
- I found on internet that Windows use function "clock_systohc" to set RTC clock
(https://learn.microsoft.com/en-us/azure-sphere/reference/applibs-reference/applibs-rtc/function-clock-systohc)
Is there any way to know that this fuction was called ?
Thanks