core-legacy/include/constants.h

33 lines
814 B
C
Raw Normal View History

2020-05-05 09:42:02 +00:00
#ifndef CORE_CONTANTS_H
#define CORE_CONTANTS_H
#define SECONDS_PER_DAY 86400 // 60 * 60 * 24
2020-11-13 01:06:48 +00:00
#define DAYS_PER_WEEK 7
2020-05-05 09:42:02 +00:00
#define SECONDS_PER_MINUTE 60
#define POLL_FDS_COUNT 2
/**
* @brief Limit the maximum length of a controller/relay/etc name
*
* The NULL terminator is not included. Arrays of length #MAX_NAME_LENGTH + 1 are required.
*/
#define MAX_NAME_LENGTH 128
/**
* @brief How many milli seconds to wait until poll timeout in main loop
*/
#define ACCEPT_TIMEOUT_MSECONDS 1000
#define PIFACE_GPIO_BASE 200
2020-11-18 23:59:26 +00:00
#define DEFAULT_CONFIG_PATH "emgauwa-core.conf"
#define DEFAULT_GLOBAL_CONFIG_PATH "/etc/emgauwa/core.conf"
2020-11-19 17:36:03 +00:00
#define DEFAULT_DATABASE_PATH "emgauwa-core.sqlite"
2020-11-13 01:06:48 +00:00
#define DEFAULT_DISCOVERY_PORT 4421
#define DEFAULT_MQTT_PORT 1885
#define DEFAULT_SERVER_PORT 5000
2020-11-12 20:58:01 +00:00
2020-05-05 09:42:02 +00:00
#endif /* CORE_CONTANTS_H */