Fix all days in a month

This commit is contained in:
Christian Buschau
2024-08-03 12:22:15 +02:00
parent e732afbec6
commit db165bec30
4 changed files with 4 additions and 4 deletions

View File

@@ -27,7 +27,7 @@
#include "day_one_face.h"
#include "watch.h"
static const uint8_t days_in_month[12] = {31, 29, 31, 30, 31, 30, 30, 31, 30, 31, 30, 31};
static const uint8_t days_in_month[12] = {31, 29, 31, 30, 31, 30, 31, 31, 30, 31, 30, 31};
static uint32_t _day_one_face_juliandaynum(uint16_t year, uint16_t month, uint16_t day) {
// from here: https://en.wikipedia.org/wiki/Julian_day#Julian_day_number_calculation

View File

@@ -158,7 +158,7 @@ static void _draw(time_left_state_t *state, uint8_t subsecond) {
/// @brief handle short or long pressing the alarm button
static void _handle_alarm_button(time_left_state_t *state) {
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, 29, 31, 30, 31, 30, 31, 31, 30, 31, 30, 31};
uint32_t tmp_day;
switch (state->current_page) {
case TIME_LEFT_FACE_SETTINGS_STATE: // birth year