SayoriOS  0.3.3
Файл cmos.c

Драйвер CMOS. Подробнее...

#include "common.h"
#include "io/ports.h"
#include "drv/cmos.h"

См. исходные тексты.

Макросы

#define CURRENT_YEAR   2022
 

Перечисления

enum  { cmos_address = 0x70 , cmos_data = 0x71 }
 

Функции

int32_t get_update_in_progress_flag ()
 Проверяет CMOS на обновление Подробнее...
 
unsigned char get_RTC_register (int32_t reg)
 Получает регистр CMOS.
 
void read_rtc ()
 Считывает время с CMOS.
 
int isleap (int year)
 Это високосный год? Подробнее...
 
sayori_time_t get_time ()
 Считывает время и передает в удобной структуре
 

Переменные

int32_t century_register = 0x00
 
unsigned char cmos_second
 
unsigned char cmos_minute
 
unsigned char cmos_hour
 
unsigned char cmos_day
 
unsigned char cmos_month
 
unsigned short cmos_year
 
unsigned char cmos_century
 
unsigned char last_second
 
unsigned char last_minute
 
unsigned char last_hour
 
unsigned char last_day
 
unsigned char last_month
 
unsigned char last_year
 
unsigned char last_century
 
unsigned char registerB
 

Подробное описание

Драйвер CMOS.

Автор
NDRAEY >_ (pikac.nosp@m.hu_a.nosp@m.ndrey.nosp@m.@vk..nosp@m.com)
Версия
0.3.5
Дата
2022-11-01

См. определение в файле cmos.c

Функции

◆ get_update_in_progress_flag()

int32_t get_update_in_progress_flag ( )

Проверяет CMOS на обновление

Возвращает
Если значение не равно нулю, значит CMOS обновляется

См. определение в файле cmos.c строка 46

◆ isleap()

int isleap ( int  year)

Это високосный год?

Аргументы
yearГод в формате YYYY

См. определение в файле cmos.c строка 137