Move alarm and time types into dedicated headers
This commit is contained in:
@@ -6,17 +6,11 @@
|
||||
#ifndef ALARM_STORE_H
|
||||
#define ALARM_STORE_H
|
||||
|
||||
#include "time_manager.h"
|
||||
#include "alarm_types.h"
|
||||
|
||||
#include "sdkconfig.h"
|
||||
#include <stdbool.h>
|
||||
|
||||
typedef struct {
|
||||
bool set;
|
||||
Time time;
|
||||
bool days[WEEK_DAY_COUNT];
|
||||
} Alarm;
|
||||
|
||||
extern Alarm alarms[CONFIG_MAX_ALARMS];
|
||||
|
||||
/**
|
||||
|
||||
19
components/alarms/alarm_types.h
Normal file
19
components/alarms/alarm_types.h
Normal file
@@ -0,0 +1,19 @@
|
||||
/*
|
||||
* SPDX-License-Identifier: AGPL-3.0-only
|
||||
* Copyright (c) Camden Dixie O'Brien
|
||||
*/
|
||||
|
||||
#ifndef ALARM_TYPE_H
|
||||
#define ALARM_TYPE_H
|
||||
|
||||
#include "time_types.h"
|
||||
|
||||
#include <stdbool.h>
|
||||
|
||||
typedef struct {
|
||||
bool set;
|
||||
Time time;
|
||||
bool days[WEEK_DAY_COUNT];
|
||||
} Alarm;
|
||||
|
||||
#endif
|
||||
@@ -8,6 +8,7 @@
|
||||
#include "alarm_store.h"
|
||||
#include "console.h"
|
||||
#include "sound.h"
|
||||
#include "time_manager.h"
|
||||
|
||||
#include "esp_log.h"
|
||||
#include "freertos/FreeRTOS.h"
|
||||
|
||||
Reference in New Issue
Block a user