Compare commits
5 Commits
ae29e23812
...
a960e67c7d
Author | SHA1 | Date | |
---|---|---|---|
a960e67c7d | |||
9e1a4d821f | |||
4d0a9918ce | |||
53928a93b0 | |||
6b89ed9a8c |
@ -274,7 +274,7 @@ bool LoRa_E220::begin(){
|
|||||||
|
|
||||||
this->serialDef.stream->setTimeout(100);
|
this->serialDef.stream->setTimeout(100);
|
||||||
Status status = setMode(MODE_0_NORMAL);
|
Status status = setMode(MODE_0_NORMAL);
|
||||||
return status==E220_SUCCESS;
|
return status;
|
||||||
}
|
}
|
||||||
|
|
||||||
/*
|
/*
|
||||||
|
@ -26,13 +26,14 @@ upload_speed = 921600
|
|||||||
|
|
||||||
build_flags=
|
build_flags=
|
||||||
!python git_rev_macro.py
|
!python git_rev_macro.py
|
||||||
;-DSERIAL_DEBUG
|
-DATOMIC_FS_UPDATE
|
||||||
;-DWIFI_CLIENT
|
;-DFEATURE_ENABLE_WIFI_CLIENT
|
||||||
;-DCAPTIVE
|
;-DCAPTIVE
|
||||||
-DWIFI_AP_IP_GW=10,0,1,1
|
-DWIFI_AP_IP_GW=10,0,1,1
|
||||||
-DADMIN_PASSWORD=${wifi_cred.admin_password}
|
-DADMIN_PASSWORD=${wifi_cred.admin_password}
|
||||||
-DWIFI_SSID=${wifi_cred.wifi_ssid}
|
-DWIFI_SSID=${wifi_cred.wifi_ssid}
|
||||||
-DWIFI_PASSWORD=${wifi_cred.wifi_password}
|
-DWIFI_PASSWORD=${wifi_cred.wifi_password}
|
||||||
|
-DWIFI_AP_SSID=${wifi_cred.wifi_ap_ssid}
|
||||||
-DWIFI_AP_PASSWORD=${wifi_cred.wifi_ap_password}
|
-DWIFI_AP_PASSWORD=${wifi_cred.wifi_ap_password}
|
||||||
-DDEVICE_NAME='"Dark Emergency Timer"'
|
-DDEVICE_NAME='"Dark Emergency Timer"'
|
||||||
-DFACTION_1_NAME='"GOF"'
|
-DFACTION_1_NAME='"GOF"'
|
||||||
|
@ -13,6 +13,7 @@
|
|||||||
#define HOST_NAME "AirsoftTimer_%08X"
|
#define HOST_NAME "AirsoftTimer_%08X"
|
||||||
|
|
||||||
#define SHUTDOWN_DELAY_MS 5000
|
#define SHUTDOWN_DELAY_MS 5000
|
||||||
|
#define RESETABLE_AFTER_STARTUP_MS 30000
|
||||||
|
|
||||||
#define GPIO_LORA_TX D3
|
#define GPIO_LORA_TX D3
|
||||||
#define GPIO_LORA_RX D4
|
#define GPIO_LORA_RX D4
|
||||||
@ -39,6 +40,9 @@
|
|||||||
#define I2C_POWER_ADDRESS 0x40
|
#define I2C_POWER_ADDRESS 0x40
|
||||||
#define I2C_EEPROM_ADDRESS 0x50
|
#define I2C_EEPROM_ADDRESS 0x50
|
||||||
|
|
||||||
|
#define SW_VERSION 1.0
|
||||||
|
#define FLASH_FS_VERSION 1.0
|
||||||
|
|
||||||
#ifndef OTA_DELAY
|
#ifndef OTA_DELAY
|
||||||
#define OTA_DELAY 50 // ticks -> 10ms / tick
|
#define OTA_DELAY 50 // ticks -> 10ms / tick
|
||||||
#endif
|
#endif
|
||||||
@ -52,6 +56,10 @@
|
|||||||
#ifndef WIFI_SSID
|
#ifndef WIFI_SSID
|
||||||
#error "You must define an WIFI_SSID for OTA-Update"
|
#error "You must define an WIFI_SSID for OTA-Update"
|
||||||
#endif
|
#endif
|
||||||
|
#ifndef WIFI_AP_SSID
|
||||||
|
#warning "No WIFI_AP_SSID defined. Using DeviceName"
|
||||||
|
#define WIFI_AP_SSID DEVICE_NAME
|
||||||
|
#endif
|
||||||
#ifndef WIFI_AP_PASSWORD
|
#ifndef WIFI_AP_PASSWORD
|
||||||
#error "You must define an WIFI_AP_PASSWORD for Standalone AP-Mode"
|
#error "You must define an WIFI_AP_PASSWORD for Standalone AP-Mode"
|
||||||
#endif
|
#endif
|
||||||
|
@ -15,6 +15,8 @@ typedef enum DTCNums_e
|
|||||||
DTC_FLASHFS_ERROR,
|
DTC_FLASHFS_ERROR,
|
||||||
DTC_FLASHFS_VERSION_ERROR,
|
DTC_FLASHFS_VERSION_ERROR,
|
||||||
DTC_EEPROM_CFG_SANITY,
|
DTC_EEPROM_CFG_SANITY,
|
||||||
|
DTC_NO_LORA_FOUND,
|
||||||
|
DTC_NO_BATMNON_FOUND,
|
||||||
DTC_LAST_DTC
|
DTC_LAST_DTC
|
||||||
} DTCNums_t;
|
} DTCNums_t;
|
||||||
|
|
||||||
|
@ -5,52 +5,62 @@ LoRa_E220 e220ttl(GPIO_LORA_TX, GPIO_LORA_RX, GPIO_LORA_AUX, 3, 4); // Arduino R
|
|||||||
void printParameters(struct Configuration configuration);
|
void printParameters(struct Configuration configuration);
|
||||||
void printModuleInformation(struct ModuleInformation moduleInformation);
|
void printModuleInformation(struct ModuleInformation moduleInformation);
|
||||||
|
|
||||||
void InitLoRa(void (*MPinHelper)(int, int))
|
bool InitLoRa(void (*MPinHelper)(int, int))
|
||||||
{
|
{
|
||||||
|
bool returnval;
|
||||||
|
|
||||||
e220ttl.setMPins = MPinHelper;
|
e220ttl.setMPins = MPinHelper;
|
||||||
e220ttl.begin();
|
returnval = e220ttl.begin();
|
||||||
|
|
||||||
ResponseStructContainer c;
|
if (returnval == true)
|
||||||
c = e220ttl.getConfiguration();
|
{
|
||||||
// It's important get configuration pointer before all other operation
|
ResponseStructContainer c;
|
||||||
Configuration configuration = *(Configuration *)c.data;
|
c = e220ttl.getConfiguration();
|
||||||
Serial.println(c.status.getResponseDescription());
|
// It's important get configuration pointer before all other operation
|
||||||
Serial.println(c.status.code);
|
Configuration configuration = *(Configuration *)c.data;
|
||||||
|
Serial.println(c.status.getResponseDescription());
|
||||||
|
Serial.println(c.status.code);
|
||||||
|
|
||||||
ResponseStructContainer cMi;
|
ResponseStructContainer cMi;
|
||||||
cMi = e220ttl.getModuleInformation();
|
cMi = e220ttl.getModuleInformation();
|
||||||
// It's important get information pointer before all other operation
|
// It's important get information pointer before all other operation
|
||||||
// ModuleInformation mi = *(ModuleInformation *)cMi.data;
|
// ModuleInformation mi = *(ModuleInformation *)cMi.data;
|
||||||
|
|
||||||
Serial.println(cMi.status.getResponseDescription());
|
Serial.println(cMi.status.getResponseDescription());
|
||||||
Serial.println(cMi.status.code);
|
Serial.println(cMi.status.code);
|
||||||
|
|
||||||
// ----------------------- DEFAULT TRANSPARENT WITH RSSI -----------------------
|
// ----------------------- DEFAULT TRANSPARENT WITH RSSI -----------------------
|
||||||
configuration.ADDL = 0x02;
|
configuration.ADDL = 0x02;
|
||||||
configuration.ADDH = 0x00;
|
configuration.ADDH = 0x00;
|
||||||
|
|
||||||
configuration.CHAN = 23;
|
configuration.CHAN = 23;
|
||||||
|
|
||||||
configuration.SPED.uartBaudRate = UART_BPS_9600;
|
configuration.SPED.uartBaudRate = UART_BPS_9600;
|
||||||
configuration.SPED.airDataRate = AIR_DATA_RATE_010_24;
|
configuration.SPED.airDataRate = AIR_DATA_RATE_010_24;
|
||||||
configuration.SPED.uartParity = MODE_00_8N1;
|
configuration.SPED.uartParity = MODE_00_8N1;
|
||||||
|
|
||||||
configuration.OPTION.subPacketSetting = SPS_200_00;
|
configuration.OPTION.subPacketSetting = SPS_200_00;
|
||||||
configuration.OPTION.RSSIAmbientNoise = RSSI_AMBIENT_NOISE_ENABLED;
|
configuration.OPTION.RSSIAmbientNoise = RSSI_AMBIENT_NOISE_ENABLED;
|
||||||
configuration.OPTION.transmissionPower = POWER_22;
|
configuration.OPTION.transmissionPower = POWER_22;
|
||||||
|
|
||||||
configuration.TRANSMISSION_MODE.enableRSSI = RSSI_ENABLED;
|
configuration.TRANSMISSION_MODE.enableRSSI = RSSI_ENABLED;
|
||||||
configuration.TRANSMISSION_MODE.fixedTransmission = FT_FIXED_TRANSMISSION;
|
configuration.TRANSMISSION_MODE.fixedTransmission = FT_FIXED_TRANSMISSION;
|
||||||
configuration.TRANSMISSION_MODE.enableLBT = LBT_ENABLED;
|
configuration.TRANSMISSION_MODE.enableLBT = LBT_ENABLED;
|
||||||
configuration.TRANSMISSION_MODE.WORPeriod = WOR_2000_011;
|
configuration.TRANSMISSION_MODE.WORPeriod = WOR_2000_011;
|
||||||
|
|
||||||
// Set configuration changed and set to not hold the configuration
|
// Set configuration changed and set to not hold the configuration
|
||||||
ResponseStatus rs = e220ttl.setConfiguration(configuration, WRITE_CFG_PWR_DWN_LOSE);
|
ResponseStatus rs = e220ttl.setConfiguration(configuration, WRITE_CFG_PWR_DWN_LOSE);
|
||||||
Serial.println(rs.getResponseDescription());
|
Serial.println(rs.getResponseDescription());
|
||||||
Serial.println(rs.code);
|
Serial.println(rs.code);
|
||||||
c.close();
|
c.close();
|
||||||
|
|
||||||
printParameters(configuration);
|
printParameters(configuration);
|
||||||
|
}
|
||||||
|
else
|
||||||
|
{
|
||||||
|
MaintainDTC(DTC_NO_LORA_FOUND, DTC_WARN, true);
|
||||||
|
}
|
||||||
|
return returnval;
|
||||||
}
|
}
|
||||||
|
|
||||||
void LoRa_Process()
|
void LoRa_Process()
|
||||||
|
@ -14,7 +14,7 @@
|
|||||||
|
|
||||||
#define FREQUENCY_868
|
#define FREQUENCY_868
|
||||||
|
|
||||||
void InitLoRa(void (*MPinHelper)(int, int));
|
bool InitLoRa(void (*MPinHelper)(int, int));
|
||||||
void LoRa_Process();
|
void LoRa_Process();
|
||||||
void sendStatus_LoRa();
|
void sendStatus_LoRa();
|
||||||
|
|
||||||
|
@ -22,11 +22,14 @@
|
|||||||
#ifdef WIFI_CLIENT
|
#ifdef WIFI_CLIENT
|
||||||
#include <WiFiMulti.h>
|
#include <WiFiMulti.h>
|
||||||
|
|
||||||
const char *ssid = QUOTE(WIFI_SSID);
|
#ifdef FEATURE_ENABLE_WIFI_CLIENT
|
||||||
const char *password = QUOTE(WIFI_PASSWORD);
|
#include <ESP8266WiFiMulti.h>
|
||||||
|
|
||||||
|
const char *ssid = QUOTE(WIFI_SSID_CLIENT);
|
||||||
|
const char *password = QUOTE(WIFI_PASSWORD_CLIENT);
|
||||||
const uint32_t connectTimeoutMs = 5000;
|
const uint32_t connectTimeoutMs = 5000;
|
||||||
|
|
||||||
WiFiMulti wifiMulti;
|
ESP8266WiFiMulti wifiMulti;
|
||||||
#endif
|
#endif
|
||||||
|
|
||||||
PCF8574 i2c_io(I2C_IO_ADDRESS);
|
PCF8574 i2c_io(I2C_IO_ADDRESS);
|
||||||
@ -56,7 +59,7 @@ Ticker tmrInputGetter(tmrCallback_InputGetter, 250, 0, MILLIS);
|
|||||||
void tmrCallback_EEPROMCyclicPDS();
|
void tmrCallback_EEPROMCyclicPDS();
|
||||||
Ticker tmrEEPROMCyclicPDS(tmrCallback_EEPROMCyclicPDS, 60000, 0, MILLIS);
|
Ticker tmrEEPROMCyclicPDS(tmrCallback_EEPROMCyclicPDS, 60000, 0, MILLIS);
|
||||||
|
|
||||||
#ifdef WIFI_CLIENT
|
#ifdef FEATURE_ENABLE_WIFI_CLIENT
|
||||||
void tmrCallback_WiFiMaintainConnection();
|
void tmrCallback_WiFiMaintainConnection();
|
||||||
Ticker tmrWiFiMaintainConnection(tmrCallback_WiFiMaintainConnection, 1000, 0, MILLIS);
|
Ticker tmrWiFiMaintainConnection(tmrCallback_WiFiMaintainConnection, 1000, 0, MILLIS);
|
||||||
#endif
|
#endif
|
||||||
@ -117,17 +120,22 @@ void setup()
|
|||||||
Serial.print("INA219 not Initialized\n");
|
Serial.print("INA219 not Initialized\n");
|
||||||
}
|
}
|
||||||
|
|
||||||
InitLoRa(&setMPins_Helper);
|
if (InitLoRa(&setMPins_Helper))
|
||||||
tmrStatusSender.start();
|
{
|
||||||
|
Serial.printf("Initialized LoRa_Transceiver");
|
||||||
|
tmrStatusSender.start();
|
||||||
|
}
|
||||||
|
else
|
||||||
|
{
|
||||||
|
Serial.print("LoRa not Initialized\n");
|
||||||
|
}
|
||||||
|
|
||||||
#ifdef WIFI_CLIENT
|
#ifdef FEATURE_ENABLE_WIFI_CLIENT
|
||||||
WiFi.mode(WIFI_STA);
|
WiFi.mode(WIFI_STA);
|
||||||
WiFi.setHostname(globals.DeviceName_ID);
|
WiFi.setHostname(globals.DeviceName);
|
||||||
wifiMulti.addAP(QUOTE(WIFI_SSID), QUOTE(WIFI_PASSWORD));
|
wifiMulti.addAP(QUOTE(WIFI_SSID_CLIENT), QUOTE(WIFI_PASSWORD_CLIENT));
|
||||||
tmrWiFiMaintainConnection.start();
|
WiFiMaintainConnectionTicker.start();
|
||||||
#else
|
#else
|
||||||
WiFi.mode(WIFI_AP);
|
|
||||||
WiFi.begin(QUOTE(DEVICE_NAME), QUOTE(WIFI_AP_PASSWORD));
|
|
||||||
WiFi.mode(WIFI_OFF);
|
WiFi.mode(WIFI_OFF);
|
||||||
#endif
|
#endif
|
||||||
|
|
||||||
@ -252,13 +260,13 @@ void SevenSeg_Output()
|
|||||||
if (millis() % 3000 < 1500)
|
if (millis() % 3000 < 1500)
|
||||||
snprintf(sevenSegBuff, sizeof(sevenSegBuff), "%4d", globals.battery_level);
|
snprintf(sevenSegBuff, sizeof(sevenSegBuff), "%4d", globals.battery_level);
|
||||||
else
|
else
|
||||||
snprintf(sevenSegBuff, sizeof(sevenSegBuff), "%2d.%1d", (globals.loadvoltage_mV / 1000), ((globals.loadvoltage_mV % 1000) / 100));
|
snprintf(sevenSegBuff, sizeof(sevenSegBuff), "%3d.%1d", (globals.loadvoltage_mV / 1000), ((globals.loadvoltage_mV % 1000) / 100));
|
||||||
|
|
||||||
disp_FAC_1.setBrightness(1);
|
disp_FAC_1.setBrightness(1);
|
||||||
disp_FAC_1.display(" BAT");
|
disp_FAC_1.display(" Bat");
|
||||||
|
|
||||||
disp_FAC_2.setBrightness(1);
|
disp_FAC_2.setBrightness(1);
|
||||||
disp_FAC_2.display("LOW ");
|
disp_FAC_2.display("low ");
|
||||||
|
|
||||||
disp_FAC_3.setBrightness(1);
|
disp_FAC_3.setBrightness(1);
|
||||||
disp_FAC_3.display(String(sevenSegBuff));
|
disp_FAC_3.display(String(sevenSegBuff));
|
||||||
@ -420,29 +428,38 @@ void tmrCallback_WiFiMaintainConnection()
|
|||||||
else
|
else
|
||||||
{
|
{
|
||||||
if (WiFiFailCount < WiFiFailMax)
|
if (WiFiFailCount < WiFiFailMax)
|
||||||
|
{
|
||||||
WiFiFailCount++;
|
WiFiFailCount++;
|
||||||
|
}
|
||||||
else
|
else
|
||||||
toggleWiFiAP(false);
|
{
|
||||||
|
debugV("WiFi not connected! - Start AP");
|
||||||
|
toggleWiFiAP();
|
||||||
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
#endif
|
#endif
|
||||||
|
|
||||||
void toggleWiFiAP(boolean shutdown)
|
void toggleWiFiAP(boolean shutdown)
|
||||||
{
|
{
|
||||||
if (WiFi.getMode() != WIFI_OFF && shutdown == true)
|
if (WiFi.getMode() != WIFI_OFF)
|
||||||
{
|
{
|
||||||
WiFi.mode(WIFI_OFF);
|
WiFi.mode(WIFI_OFF);
|
||||||
#ifdef WIFI_CLIENT
|
debugV("WiFi turned off");
|
||||||
tmrWiFiMaintainConnection.stop();
|
#ifdef FEATURE_ENABLE_WIFI_CLIENT
|
||||||
|
WiFiMaintainConnectionTicker.stop();
|
||||||
#endif
|
#endif
|
||||||
}
|
}
|
||||||
else if (shutdown == false)
|
else
|
||||||
{
|
{
|
||||||
WiFi.mode(WIFI_AP);
|
WiFi.mode(WIFI_AP);
|
||||||
WiFi.softAPConfig(IPAddress(WIFI_AP_IP_GW), IPAddress(WIFI_AP_IP_GW), IPAddress(255, 255, 255, 0));
|
WiFi.softAPConfig(IPAddress(WIFI_AP_IP_GW), IPAddress(WIFI_AP_IP_GW), IPAddress(255, 255, 255, 0));
|
||||||
WiFi.softAP(globals.DeviceName_ID, QUOTE(WIFI_AP_PASSWORD));
|
WiFi.softAP(QUOTE(WIFI_AP_SSID), QUOTE(WIFI_AP_PASSWORD));
|
||||||
#ifdef WIFI_CLIENT
|
#ifdef FEATURE_ENABLE_WIFI_CLIENT
|
||||||
tmrWiFiMaintainConnection.stop();
|
WiFiMaintainConnectionTicker.stop();
|
||||||
|
debugV("WiFi AP started, stopped Maintain-Timer");
|
||||||
|
#else
|
||||||
|
debugV("WiFi AP started");
|
||||||
#endif
|
#endif
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
@ -489,24 +506,14 @@ void ProcessKeyCombos(bool *btnState)
|
|||||||
} keyStatus_t;
|
} keyStatus_t;
|
||||||
|
|
||||||
static keyStatus_t keyStatus_Fac1 = KEY_RELEASED;
|
static keyStatus_t keyStatus_Fac1 = KEY_RELEASED;
|
||||||
static uint8_t keyCount_Fac1 = 0;
|
|
||||||
static keyStatus_t keyStatus_Fac2 = KEY_RELEASED;
|
static keyStatus_t keyStatus_Fac2 = KEY_RELEASED;
|
||||||
static uint8_t keyCount_Fac2 = 0;
|
static uint8_t keyCount_Fac2 = 0;
|
||||||
static keyStatus_t keyStatus_Fac3 = KEY_RELEASED;
|
static keyStatus_t keyStatus_Fac3 = KEY_RELEASED;
|
||||||
|
static uint8_t keyCount_Fac3 = 0;
|
||||||
|
|
||||||
if (btnState[2] == FAC_3_TRG_PRESSED)
|
if (btnState[0] == FAC_1_TRG_PRESSED)
|
||||||
{
|
{
|
||||||
keyStatus_Fac3 = KEY_PRESSED;
|
keyStatus_Fac1 = KEY_PRESSED;
|
||||||
|
|
||||||
// Process FactionKey 1 ComboCounter
|
|
||||||
if (btnState[0] == FAC_1_TRG_PRESSED && keyStatus_Fac1 == KEY_RELEASED)
|
|
||||||
{
|
|
||||||
keyStatus_Fac1 = KEY_PRESSED;
|
|
||||||
keyCount_Fac1++;
|
|
||||||
}
|
|
||||||
|
|
||||||
if (btnState[0] != FAC_1_TRG_PRESSED)
|
|
||||||
keyStatus_Fac1 = KEY_RELEASED;
|
|
||||||
|
|
||||||
// Process FactionKey 2 ComboCounter
|
// Process FactionKey 2 ComboCounter
|
||||||
if (btnState[1] == FAC_2_TRG_PRESSED && keyStatus_Fac2 == KEY_RELEASED)
|
if (btnState[1] == FAC_2_TRG_PRESSED && keyStatus_Fac2 == KEY_RELEASED)
|
||||||
@ -517,22 +524,50 @@ void ProcessKeyCombos(bool *btnState)
|
|||||||
|
|
||||||
if (btnState[1] != FAC_2_TRG_PRESSED)
|
if (btnState[1] != FAC_2_TRG_PRESSED)
|
||||||
keyStatus_Fac2 = KEY_RELEASED;
|
keyStatus_Fac2 = KEY_RELEASED;
|
||||||
|
|
||||||
|
// Process FactionKey 3 ComboCounter
|
||||||
|
if (btnState[2] == FAC_3_TRG_PRESSED && keyStatus_Fac3 == KEY_RELEASED)
|
||||||
|
{
|
||||||
|
keyStatus_Fac3 = KEY_PRESSED;
|
||||||
|
keyCount_Fac3++;
|
||||||
|
}
|
||||||
|
|
||||||
|
if (btnState[2] != FAC_3_TRG_PRESSED)
|
||||||
|
keyStatus_Fac3 = KEY_RELEASED;
|
||||||
}
|
}
|
||||||
|
|
||||||
if (btnState[2] != FAC_3_TRG_PRESSED && keyStatus_Fac3 == KEY_PRESSED)
|
if (btnState[0] != FAC_1_TRG_PRESSED && keyStatus_Fac1 == KEY_PRESSED)
|
||||||
{
|
{
|
||||||
if (keyCount_Fac1 > 0 || keyCount_Fac2 > 0)
|
if (keyCount_Fac2 > 0 || keyCount_Fac3 > 0)
|
||||||
Serial.printf("KeyCombo 1: %d | 2: %d\n", keyCount_Fac1, keyCount_Fac2);
|
Serial.printf("KeyCombo 2: %d | 3: %d\n", keyCount_Fac2, keyCount_Fac3);
|
||||||
|
|
||||||
if (keyCount_Fac1 == 2 && keyCount_Fac2 == 2)
|
if (keyCount_Fac2 == 2 && keyCount_Fac3 == 0)
|
||||||
{
|
{
|
||||||
Serial.println("KeyCombo: WiFi AP ON");
|
Serial.println("KeyCombo: WiFi AP ON");
|
||||||
OverrideDisplay("NET ", 5000);
|
OverrideDisplay("NET ", 5000);
|
||||||
toggleWiFiAP(false);
|
toggleWiFiAP(false);
|
||||||
}
|
}
|
||||||
|
else if (keyCount_Fac2 == 4 && keyCount_Fac3 == 0)
|
||||||
|
{
|
||||||
|
Serial.printf("KeyCombo: Reset Timer\n");
|
||||||
|
if (millis() < RESETABLE_AFTER_STARTUP_MS)
|
||||||
|
{
|
||||||
|
OverrideDisplay("RST ", 5000);
|
||||||
|
PersistenceData.faction_1_timer = 0;
|
||||||
|
PersistenceData.faction_2_timer = 0;
|
||||||
|
PersistenceData.faction_3_timer = 0;
|
||||||
|
PersistenceData.activeFaction = NONE;
|
||||||
|
globals.requestEEAction = EE_PDS_SAVE;
|
||||||
|
}
|
||||||
|
else
|
||||||
|
{
|
||||||
|
OverrideDisplay("ERR ", 5000);
|
||||||
|
Serial.printf("ERROR: only %d seconds after Startup!\n", RESETABLE_AFTER_STARTUP_MS / 1000);
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
keyCount_Fac1 = 0;
|
|
||||||
keyCount_Fac2 = 0;
|
keyCount_Fac2 = 0;
|
||||||
|
keyCount_Fac3 = 0;
|
||||||
keyStatus_Fac1 = KEY_RELEASED;
|
keyStatus_Fac1 = KEY_RELEASED;
|
||||||
keyStatus_Fac2 = KEY_RELEASED;
|
keyStatus_Fac2 = KEY_RELEASED;
|
||||||
keyStatus_Fac3 = KEY_RELEASED;
|
keyStatus_Fac3 = KEY_RELEASED;
|
||||||
|
@ -1,4 +1,5 @@
|
|||||||
[wifi_cred]
|
[wifi_cred]
|
||||||
|
wifi_ap_ssid = wifi-ap-ssid
|
||||||
wifi_ap_password = wifiappass
|
wifi_ap_password = wifiappass
|
||||||
wifi_ssid = wifi-ssid
|
wifi_ssid = wifi-ssid
|
||||||
wifi_password = wifi-pass
|
wifi_password = wifi-pass
|
||||||
|
Loading…
x
Reference in New Issue
Block a user