Files
Lamps/Core/Clock/clock_manager.h

26 lines
688 B
C
Raw Blame History

This file contains ambiguous Unicode characters
This file contains Unicode characters that might be confused with other characters. If you think that this is intentional, you can safely ignore this warning. Use the Escape button to reveal them.
#ifndef CLOCK_MANAGER_H
#define CLOCK_MANAGER_H
#include <stdint.h>
#include <stdbool.h>
#include "main.h" // где определен time_t
// Инициализация
void ClockManager_Init(void);
// Получить текущее время из RTC
time_t ClockManager_GetTime(int blink);
// Установить время в RTC
void ClockManager_SetTime(uint8_t hour, uint8_t min, uint8_t sec);
// Получить яркость (0-10)
uint8_t ClockManager_GetDuty(void);
// Установить яркость (0-10) и сохранить
void ClockManager_SetDuty(uint8_t value);
// Сброс времени на 00:00:00
void ClockManager_ResetTime(void);
#endif