add: commands

fix: timezone problem
This commit is contained in:
Tobias Reisinger 2020-05-07 01:38:13 +02:00
parent 0edb16a2d5
commit 10e41ca166
11 changed files with 209 additions and 21 deletions

16
include/command.h Normal file
View file

@ -0,0 +1,16 @@
#ifndef CORE_COMMAND_H
#define CORE_COMMAND_H
#include <models/controller.h>
#include <models/relay.h>
int
command_set_relay_schedule(relay_t *relay);
int
command_set_controller_name(controller_t *controller);
int
command_send(controller_t *controller, int command_code, char *payload, uint32_t payload_size);
#endif /* CORE_COMMAND_H */

View file

@ -1,6 +1,7 @@
#ifndef CORE_HELPERS_H
#define CORE_HELPERS_H
#include <time.h>
#include <config.h>
#include <confini.h>
@ -29,6 +30,6 @@ void
helper_parse_cli(int argc, const char **argv, config_t *config);
int
helper_get_weekday(const time_t timestamp_now);
helper_get_weekday(const struct tm *time_struct);
#endif /* CORE_HELPERS_H */