create config structs
This commit is contained in:
parent
a3fef36ecb
commit
ac10feccf7
2 changed files with 45 additions and 2 deletions
|
@ -4,8 +4,8 @@
|
||||||
test -z $TTY && TTY="/dev/ttyUSB0"
|
test -z $TTY && TTY="/dev/ttyUSB0"
|
||||||
test -z $IP && IP="192.168.4.20"
|
test -z $IP && IP="192.168.4.20"
|
||||||
test -z $VER && VER="0.2-dev"
|
test -z $VER && VER="0.2-dev"
|
||||||
#test -z $BOARD && BOARD="esp8266:esp8266:d1_mini_clone"
|
test -z $BOARD && BOARD="esp8266:esp8266:d1_mini_clone"
|
||||||
test -z $BOARD && BOARD="esp32:esp32:d1_mini32"
|
#test -z $BOARD && BOARD="esp32:esp32:d1_mini32"
|
||||||
|
|
||||||
BUILD="$(git rev-parse --short HEAD)-$(echo $BOARD | cut -d : -f1)-$(date '+%Y%m%d%H%M%S')"
|
BUILD="$(git rev-parse --short HEAD)-$(echo $BOARD | cut -d : -f1)-$(date '+%Y%m%d%H%M%S')"
|
||||||
|
|
||||||
|
|
|
@ -29,6 +29,49 @@
|
||||||
|
|
||||||
#include "CanGrow_Version.h"
|
#include "CanGrow_Version.h"
|
||||||
|
|
||||||
|
struct Config_WiFi {
|
||||||
|
char ssid[32];
|
||||||
|
char password[64];
|
||||||
|
char ip[16];
|
||||||
|
char netmask[16];
|
||||||
|
char gateway[16];
|
||||||
|
char dns[16];
|
||||||
|
bool dhcp;
|
||||||
|
};
|
||||||
|
|
||||||
|
Config_WiFi configWifi;
|
||||||
|
|
||||||
|
struct Config_System {
|
||||||
|
byte ntpOffset;
|
||||||
|
unsigned short maintenanceDuration;
|
||||||
|
char esp32camIp[16];
|
||||||
|
};
|
||||||
|
|
||||||
|
Config_System configSystem;
|
||||||
|
|
||||||
|
struct Config_Grow {
|
||||||
|
char GrowName[64];
|
||||||
|
unsigned short DoG;
|
||||||
|
byte daysVeg;
|
||||||
|
byte daysBloom;
|
||||||
|
byte lightHoursVeg;
|
||||||
|
byte lightHoursBloom;
|
||||||
|
byte sunriseHour;
|
||||||
|
byte sunriseMinute;
|
||||||
|
bool sunFade;
|
||||||
|
byte sunFadeDuration;
|
||||||
|
|
||||||
|
};
|
||||||
|
|
||||||
|
Config_Grow configGrow;
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
struct Config {
|
struct Config {
|
||||||
char GrowName[64];
|
char GrowName[64];
|
||||||
int DoG;
|
int DoG;
|
||||||
|
|
Loading…
Reference in a new issue