https://bugs.kde.org/show_bug.cgi?id=392525

--- Comment #1 from Mark <[email protected]> ---
To add a little to this.

It's not as easy as just adding a method that writes to wakealarm. The datetime
you get as input needs to be translated to whatever the RTC clock timezone is.
You cannot use QDateTime::currentDateTime(); as that returns the localtime
according to /etc/localtime (i think). So for example, in my case my localtime
is set to Europe/Amsterdam but my RTC is set to UTC (at this very moment, that
is a 2 hour difference). So you need to have the clock time without the UTC
offset applied and you need to know which UTC offset would have been applied
(for translating input time to RTC time).

There are a few ways to get that information (that i know of).
1. timedatectl
2. hwclock --debug
3. cat /proc/driver/rtc tells you the RTC time, but not the UTC offset (1 and 2
do tell you that)

-- 
You are receiving this mail because:
You are watching all bug changes.

Reply via email to