-
Notifications
You must be signed in to change notification settings - Fork 266
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Leading-Zero 24hr Bugs #476
Comments
|
Well, just don't go down too much of a rabbit hole on that one. As I said, it's changing a 1 to a 0, so I'm not sure it's simply a matter of it not updating that digit. (Because it is indeed updating it.) I'm not sure how the leading-zero bit works, but maybe one of the display conditions just isn't quite right? Thanks for looking into it! |
The The relevant display logic in the Sensor-Watch/movement/watch_faces/clock/simple_clock_face.c Lines 140 to 141 in c9cbb82
I believe the problem happens because it does not unset the Simply adding an if (set_leading_zero) {
watch_display_string("0", 4);
} else {
watch_display_string(" ", 4);
} In the refactored Sensor-Watch/movement/watch_faces/clock/clock_face.c Lines 127 to 142 in c9cbb82
A problem remains though: the above lines will only run when a full screen update is done, which occurs only when the current hour changes. Sensor-Watch/movement/watch_faces/clock/simple_clock_face.c Lines 102 to 129 in c9cbb82
Sensor-Watch/movement/watch_faces/clock/clock_face.c Lines 144 to 174 in c9cbb82
In order to fully resolve this issue, I will decompose those hours/minutes checks into actual bits of information in the clock's state structure: Compared to all this I expect the |
The watch was not indicating to the user that it was in 24h mode when set to the leading zero 024h time format. This could lead to ambiguity and confusion, so make sure to indicate 24h mode. Closes #476. Reported-by: CarpeNoctem <[email protected]> GitHub-Issue: #476
Ensure that the segments of the leading hour digit are cleared prior to displaying the time when the watch is not in 024h mode. This prevents a previous configuration from putting the display in an inconsistent state where the watch is configured to show the time in 12h or 24h modes but the leading zero is still shown. Reported-by: CarpeNoctem <[email protected]> GitHub-Issue: #476
Ensure that the segments of the leading hour digit are cleared prior to displaying the time when the watch is not in 024h mode. This prevents a previous configuration from putting the display in an inconsistent state where the watch is configured to show the time in 12h or 24h modes but the leading zero is still shown. Reported-by: CarpeNoctem <[email protected]> GitHub-Issue: #476
This ensures that the display is always in a consistent state. Reported-by: CarpeNoctem <[email protected]> GitHub-Issue: #476
Ensure that the segments of the leading hour digit are cleared prior to displaying the time when the watch is not in 024h mode. This prevents a previous configuration from putting the display in an inconsistent state where the watch is configured to show the time in 12h or 24h modes but the leading zero is still shown. Reported-by: CarpeNoctem <[email protected]> GitHub-Issue: #476
There was an issue where the simple clock's display would remain in 024h mode even after switching back to 12h/24h mode because it only took into account the leading zero bit, whose value is meaningless unless the 24h mode bit is also set. The issue is fixed by taking both bits into account. Closes #476. Reported-by: CarpeNoctem <[email protected]> GitHub-Issue: #476
There was an issue where the clock's display would remain in 024h mode even after switching back to 12h/24h mode because it only took into account the leading zero bit, whose value is meaningless unless the 24h mode bit is also set. The issue is fixed by taking both bits into account. Closes #476. Reported-by: CarpeNoctem <[email protected]> GitHub-Issue: #476
OK issue should be fixed. Turned out to be much simpler than I initially thought it would be. When I read the code again, I realized there was no way to change the display mode from inside the face, the user must go to preferences screen. That causes a face activation when the user returns to the clock face. Activating the clock face resets the previous time value's bits to all ones which ensures a full repainting. That means the bug actually had nothing to do with what I described above. The real problem turned out to be the fact that there's a I have also added the 24h indicator back to the alarm face. All issues should be resolved. Would appreciate further testing for confirmation. |
There was an issue where the simple clock's display would remain in 024h mode even after switching back to 12h/24h mode because it only took into account the leading zero bit, whose value is meaningless unless the 24h mode bit is also set. The issue is fixed by taking both bits into account. Closes #476. Reported-by: CarpeNoctem <[email protected]> GitHub-Issue: #476
There was an issue where the clock's display would remain in 024h mode even after switching back to 12h/24h mode because it only took into account the leading zero bit, whose value is meaningless unless the 24h mode bit is also set. The issue is fixed by taking both bits into account. Closes #476. Reported-by: CarpeNoctem <[email protected]> GitHub-Issue: #476
I've just run through all my testing again, and can confirm that these two issues are fixed. Good job and thanks!
Doh. This is exactly what I meant when I said "but maybe one of the display conditions just isn't quite right?" in my comment above. Sorry for not being clearer; it was very late at night here. >__< Thanks again! |
Branch: next
Most recent revision tested & present: c9cbb82
Board color: GREEN
Issue 1: When switching from 024hr mode to 12hr mode, there is a leftover leading zero in front of the hour. This goes away if the user goes back to the usual 24hr mode, then back to 12hr mode. Seems like it could be a stuck "pixel" due to the way simple_clock_face conserves power, except that this happens in both am/pm and an example of this happening includes going from 16:xx to 04:xx PM. (note that the first digit is 1, not 0.) This only appears to be happening in simple_time_face, and not in others such as set_time_face, alarm_face
Issue 2: 24hr Indicator missing from
alarm_face
when in 024h mode.The text was updated successfully, but these errors were encountered: