mirror of
https://github.com/firewalkwithm3/Sensor-Watch.git
synced 2024-11-22 19:20:30 +08:00
Merge PR #431 - fix wrong number of days in month
July has 31 days and but was set to 30 days in the Sensor Watch. This patch fixes the discrepancy. Reviewed-by: Matheus Afonso Martins Moreira <matheus@matheusmoreira.com> GitHub-Pull-Request: https://github.com/joeycastillo/Sensor-Watch/pull/431
This commit is contained in:
commit
c8ca0d3619
|
@ -47,7 +47,7 @@ void set_time_hackwatch_face_activate(movement_settings_t *settings, void *conte
|
||||||
|
|
||||||
bool set_time_hackwatch_face_loop(movement_event_t event, movement_settings_t *settings, void *context) {
|
bool set_time_hackwatch_face_loop(movement_event_t event, movement_settings_t *settings, void *context) {
|
||||||
uint8_t current_page = *((uint8_t *)context);
|
uint8_t current_page = *((uint8_t *)context);
|
||||||
const uint8_t days_in_month[12] = {31, 28, 31, 30, 31, 30, 30, 31, 30, 31, 30, 31};
|
const uint8_t days_in_month[12] = {31, 28, 31, 30, 31, 30, 31, 31, 30, 31, 30, 31};
|
||||||
|
|
||||||
if (event.subsecond == 15) // Delay displayed time update by ~0.5 seconds, to align phase exactly to main clock at 1Hz
|
if (event.subsecond == 15) // Delay displayed time update by ~0.5 seconds, to align phase exactly to main clock at 1Hz
|
||||||
date_time_settings = watch_rtc_get_date_time();
|
date_time_settings = watch_rtc_get_date_time();
|
||||||
|
|
Loading…
Reference in a new issue