Refactor code

This commit is contained in:
2020-11-20 08:14:46 +01:00
parent 53bacf016a
commit ffdd2beb35
8 changed files with 41 additions and 45 deletions

View File

@@ -19,12 +19,12 @@
#define DEC_2_BCD(dec) ((((dec) / 10) << 4) | ((dec) % 10))
#define BCD_2_DEC(bcd) (((((bcd) >> 4) & 0x0F) * 10) + ((bcd) & 0x0F))
extern volatile struct TIME_HMS time;
extern volatile struct TIME_HMS clock;
void rtc_int0_init(void);
void rtc_int1_init(void);
void rtc_set_time(struct TIME_HMS* time);
void rtc_set_time_part(uint8_t part, uint8_t value);
uint8_t rtc_handle_timer(void);
void rtc_set_clock(struct TIME_HMS* time);
void rtc_set_clock_part(uint8_t part, uint8_t value);
uint8_t rtc_handle_clock(void);
#endif