mirror of
https://github.com/lumapu/ahoy.git
synced 2025-04-29 18:26:21 +02:00
* added erase application settings
* HM1500 as selectable in setup * Added new commands to statistic (0x82, 0x83)
This commit is contained in:
parent
a00ab4e48d
commit
df9f050313
11 changed files with 71 additions and 35 deletions
|
@ -13,8 +13,8 @@ app::app() : Main() {
|
||||||
mMqttTicker = NULL;
|
mMqttTicker = NULL;
|
||||||
mMqttEvt = false;
|
mMqttEvt = false;
|
||||||
|
|
||||||
memset(mCmds, 0, sizeof(uint32_t));
|
memset(mCmds, 0, sizeof(uint32_t)*DBG_CMD_LIST_LEN);
|
||||||
memset(mChannelStat, 0, sizeof(uint32_t));
|
//memset(mChannelStat, 0, sizeof(uint32_t) * 4);
|
||||||
|
|
||||||
mSys = new HmSystemType();
|
mSys = new HmSystemType();
|
||||||
}
|
}
|
||||||
|
@ -30,13 +30,14 @@ app::~app(void) {
|
||||||
void app::setup(const char *ssid, const char *pwd, uint32_t timeout) {
|
void app::setup(const char *ssid, const char *pwd, uint32_t timeout) {
|
||||||
Main::setup(ssid, pwd, timeout);
|
Main::setup(ssid, pwd, timeout);
|
||||||
|
|
||||||
mWeb->on("/", std::bind(&app::showIndex, this));
|
mWeb->on("/", std::bind(&app::showIndex, this));
|
||||||
mWeb->on("/setup", std::bind(&app::showSetup, this));
|
mWeb->on("/setup", std::bind(&app::showSetup, this));
|
||||||
mWeb->on("/save", std::bind(&app::showSave, this));
|
mWeb->on("/save", std::bind(&app::showSave, this));
|
||||||
mWeb->on("/cmdstat", std::bind(&app::showCmdStatistics, this));
|
mWeb->on("/erase", std::bind(&app::showErase, this));
|
||||||
mWeb->on("/hoymiles", std::bind(&app::showHoymiles, this));
|
mWeb->on("/cmdstat", std::bind(&app::showStatistics, this));
|
||||||
mWeb->on("/livedata", std::bind(&app::showLiveData, this));
|
mWeb->on("/hoymiles", std::bind(&app::showHoymiles, this));
|
||||||
mWeb->on("/mqttstate", std::bind(&app::showMqtt, this));
|
mWeb->on("/livedata", std::bind(&app::showLiveData, this));
|
||||||
|
mWeb->on("/mqttstate", std::bind(&app::showMqtt, this));
|
||||||
|
|
||||||
if(mSettingsValid) {
|
if(mSettingsValid) {
|
||||||
uint16_t interval;
|
uint16_t interval;
|
||||||
|
@ -125,13 +126,15 @@ void app::loop(void) {
|
||||||
else if(*cmd == 0x02) mCmds[1]++;
|
else if(*cmd == 0x02) mCmds[1]++;
|
||||||
else if(*cmd == 0x03) mCmds[2]++;
|
else if(*cmd == 0x03) mCmds[2]++;
|
||||||
else if(*cmd == 0x81) mCmds[3]++;
|
else if(*cmd == 0x81) mCmds[3]++;
|
||||||
else if(*cmd == 0x84) mCmds[4]++;
|
else if(*cmd == 0x82) mCmds[4]++;
|
||||||
else mCmds[5]++;
|
else if(*cmd == 0x83) mCmds[5]++;
|
||||||
|
else if(*cmd == 0x84) mCmds[6]++;
|
||||||
|
else mCmds[7]++;
|
||||||
|
|
||||||
if(p->sendCh == 23) mChannelStat[0]++;
|
/*if(p->sendCh == 23) mChannelStat[0]++;
|
||||||
else if(p->sendCh == 40) mChannelStat[1]++;
|
else if(p->sendCh == 40) mChannelStat[1]++;
|
||||||
else if(p->sendCh == 61) mChannelStat[2]++;
|
else if(p->sendCh == 61) mChannelStat[2]++;
|
||||||
else mChannelStat[3]++;
|
else mChannelStat[3]++;*/
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
mSys->BufCtrl.popBack();
|
mSys->BufCtrl.popBack();
|
||||||
|
@ -319,20 +322,26 @@ void app::showSave(void) {
|
||||||
|
|
||||||
|
|
||||||
//-----------------------------------------------------------------------------
|
//-----------------------------------------------------------------------------
|
||||||
void app::showCmdStatistics(void) {
|
void app::showErase() {
|
||||||
String content = "CMDs:\n";
|
eraseSettings();
|
||||||
content += String("0x01: ") + String(mCmds[0]) + String("\n");
|
showReboot();
|
||||||
content += String("0x02: ") + String(mCmds[1]) + String("\n");
|
}
|
||||||
content += String("0x03: ") + String(mCmds[2]) + String("\n");
|
|
||||||
content += String("0x81: ") + String(mCmds[3]) + String("\n");
|
|
||||||
content += String("0x84: ") + String(mCmds[4]) + String("\n");
|
|
||||||
content += String("other: ") + String(mCmds[5]) + String("\n");
|
|
||||||
|
|
||||||
content += "\nCHANNELs:\n";
|
|
||||||
|
//-----------------------------------------------------------------------------
|
||||||
|
void app::showStatistics(void) {
|
||||||
|
String content = "CMDs:\n";
|
||||||
|
for(uint8_t i = 0; i < DBG_CMD_LIST_LEN; i ++) {
|
||||||
|
content += String("0x") + String(dbgCmds[i], HEX) + String(": ") + String(mCmds[i]) + String("\n");
|
||||||
|
}
|
||||||
|
content += String("other: ") + String(mCmds[DBG_CMD_LIST_LEN]) + String("\n\n");
|
||||||
|
|
||||||
|
/*content += "\nCHANNELs:\n";
|
||||||
content += String("23: ") + String(mChannelStat[0]) + String("\n");
|
content += String("23: ") + String(mChannelStat[0]) + String("\n");
|
||||||
content += String("40: ") + String(mChannelStat[1]) + String("\n");
|
content += String("40: ") + String(mChannelStat[1]) + String("\n");
|
||||||
content += String("61: ") + String(mChannelStat[2]) + String("\n");
|
content += String("61: ") + String(mChannelStat[2]) + String("\n");
|
||||||
content += String("75: ") + String(mChannelStat[3]) + String("\n");
|
content += String("75: ") + String(mChannelStat[3]) + String("\n");*/
|
||||||
|
|
||||||
mWeb->send(200, "text/plain", content);
|
mWeb->send(200, "text/plain", content);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
|
@ -22,6 +22,9 @@ const char* const wemosPins[] = {"D3 (GPIO0)", "TX (GPIO1)", "D4 (GPIO2)", "RX (
|
||||||
const char* const pinNames[] = {"CS", "CE", "IRQ"};
|
const char* const pinNames[] = {"CS", "CE", "IRQ"};
|
||||||
const char* const pinArgNames[] = {"pinCs", "pinCe", "pinIrq"};
|
const char* const pinArgNames[] = {"pinCs", "pinCe", "pinIrq"};
|
||||||
|
|
||||||
|
const uint8_t dbgCmds[] = {0x01, 0x02, 0x03, 0x81, 0x82, 0x83, 0x84};
|
||||||
|
#define DBG_CMD_LIST_LEN 7
|
||||||
|
|
||||||
class app : public Main {
|
class app : public Main {
|
||||||
public:
|
public:
|
||||||
app();
|
app();
|
||||||
|
@ -42,7 +45,8 @@ class app : public Main {
|
||||||
void showIndex(void);
|
void showIndex(void);
|
||||||
void showSetup(void);
|
void showSetup(void);
|
||||||
void showSave(void);
|
void showSave(void);
|
||||||
void showCmdStatistics(void);
|
void showErase(void);
|
||||||
|
void showStatistics(void);
|
||||||
void showHoymiles(void);
|
void showHoymiles(void);
|
||||||
void showLiveData(void);
|
void showLiveData(void);
|
||||||
void showMqtt(void);
|
void showMqtt(void);
|
||||||
|
@ -65,6 +69,7 @@ class app : public Main {
|
||||||
return ret;
|
return ret;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
uint8_t mState;
|
uint8_t mState;
|
||||||
bool mKeyPressed;
|
bool mKeyPressed;
|
||||||
|
|
||||||
|
@ -73,8 +78,8 @@ class app : public Main {
|
||||||
Ticker *mSendTicker;
|
Ticker *mSendTicker;
|
||||||
bool mFlagSend;
|
bool mFlagSend;
|
||||||
|
|
||||||
uint32_t mCmds[6];
|
uint32_t mCmds[DBG_CMD_LIST_LEN+1];
|
||||||
uint32_t mChannelStat[4];
|
//uint32_t mChannelStat[4];
|
||||||
uint32_t mRecCnt;
|
uint32_t mRecCnt;
|
||||||
|
|
||||||
// mqtt
|
// mqtt
|
||||||
|
|
|
@ -25,7 +25,7 @@
|
||||||
//-------------------------------------
|
//-------------------------------------
|
||||||
#define VERSION_MAJOR 0
|
#define VERSION_MAJOR 0
|
||||||
#define VERSION_MINOR 2
|
#define VERSION_MINOR 2
|
||||||
#define VERSION_PATCH 5
|
#define VERSION_PATCH 6
|
||||||
|
|
||||||
|
|
||||||
//-------------------------------------
|
//-------------------------------------
|
||||||
|
|
|
@ -21,7 +21,7 @@ enum {CH0 = 0, CH1, CH2, CH3, CH4};
|
||||||
enum {CMD01 = 0x01, CMD02, CMD03, CMD82 = 0x82, CMD83, CMD84};
|
enum {CMD01 = 0x01, CMD02, CMD03, CMD82 = 0x82, CMD83, CMD84};
|
||||||
|
|
||||||
enum {INV_TYPE_HM600 = 0, INV_TYPE_HM1200, INV_TYPE_HM400};
|
enum {INV_TYPE_HM600 = 0, INV_TYPE_HM1200, INV_TYPE_HM400};
|
||||||
const char* const invTypes[] = {"HM600", "HM1200", "HM400"};
|
const char* const invTypes[] = {"HM600", "HM1200 / HM1500", "HM400"};
|
||||||
#define NUM_INVERTER_TYPES 3
|
#define NUM_INVERTER_TYPES 3
|
||||||
|
|
||||||
typedef struct {
|
typedef struct {
|
||||||
|
@ -97,7 +97,7 @@ const byteAssign_t hm600assignment[] = {
|
||||||
|
|
||||||
|
|
||||||
//-------------------------------------
|
//-------------------------------------
|
||||||
// HM1200, HM1500?
|
// HM1200, HM1500
|
||||||
//-------------------------------------
|
//-------------------------------------
|
||||||
const byteAssign_t hm1200assignment[] = {
|
const byteAssign_t hm1200assignment[] = {
|
||||||
{ FLD_UDC, UNIT_V, CH1, CMD01, 3, 2, 10 },
|
{ FLD_UDC, UNIT_V, CH1, CMD01, 3, 2, 10 },
|
||||||
|
|
|
@ -79,7 +79,6 @@ class HmRadio {
|
||||||
// enable only receiving interrupts
|
// enable only receiving interrupts
|
||||||
mNrf24.maskIRQ(true, true, false);
|
mNrf24.maskIRQ(true, true, false);
|
||||||
|
|
||||||
// Use lo PA level, as a higher level will disturb CH340 serial usb adapter
|
|
||||||
mNrf24.setPALevel(RF24_PA_MAX);
|
mNrf24.setPALevel(RF24_PA_MAX);
|
||||||
mNrf24.startListening();
|
mNrf24.startListening();
|
||||||
|
|
||||||
|
|
|
@ -1,4 +1,4 @@
|
||||||
#ifndef __SETUP_H__
|
#ifndef __SETUP_H__
|
||||||
#define __SETUP_H__
|
#define __SETUP_H__
|
||||||
const char setup_html[] PROGMEM = "<!doctype html><html><head><title>Setup - {DEVICE}</title><link rel=\"stylesheet\" type=\"text/css\" href=\"style.css\"/><meta name=\"viewport\" content=\"width=device-width, initial-scale=1\"></head><body><h1>Setup</h1><div id=\"setup\" class=\"content\"><div id=\"content\"><p>Enter the credentials to your prefered WiFi station. After rebooting the device tries to connect with this information. </p><form method=\"post\" action=\"/save\"><p class=\"des\">WiFi</p><label for=\"ssid\">SSID</label><input type=\"text\" class=\"text\" name=\"ssid\" value=\"{SSID}\"/><label for=\"pwd\">Password</label><input type=\"password\" class=\"text\" name=\"pwd\" value=\"{PWD}\"/><p class=\"des\">Device Host Name</p><label for=\"device\">Device Name</label><input type=\"text\" class=\"text\" name=\"device\" value=\"{DEVICE}\"/><p class=\"des\">Inverter</p>{INVERTERS}<br/><p class=\"subdes\">General</p><label for=\"invInterval\">Interval (ms)</label><input type=\"text\" class=\"text\" name=\"invInterval\" value=\"{INV_INTERVAL}\"/><p class=\"des\">Pinout (Wemos)</p>{PINOUT}<p class=\"des\">MQTT</p><label for=\"mqttAddr\">Broker / Server IP</label><input type=\"text\" class=\"text\" name=\"mqttAddr\" value=\"{MQTT_ADDR}\"/><label for=\"mqttUser\">Username (optional)</label><input type=\"text\" class=\"text\" name=\"mqttUser\" value=\"{MQTT_USER}\"/><label for=\"mqttPwd\">Password (optional)</label><input type=\"text\" class=\"text\" name=\"mqttPwd\" value=\"{MQTT_PWD}\"/><label for=\"mqttTopic\">Topic</label><input type=\"text\" class=\"text\" name=\"mqttTopic\" value=\"{MQTT_TOPIC}\"/><label for=\"mqttInterval\">Interval (seconds)</label><input type=\"text\" class=\"text\" name=\"mqttInterval\" value=\"{MQTT_INTERVAL}\"/><p class=\"des\"> </p><input type=\"checkbox\" class=\"cb\" name=\"reboot\"/><label for=\"reboot\">Reboot device after successful save</label><input type=\"submit\" value=\"save\" class=\"btn\" /></form></div></div><div id=\"footer\"><p class=\"left\"><a href=\"/\">Home</a></p><p class=\"left\"><a href=\"/update\">Update Firmware</a></p><p class=\"right\">AHOY - {VERSION}</p></div></body></html>";
|
const char setup_html[] PROGMEM = "<!doctype html><html><head><title>Setup - {DEVICE}</title><link rel=\"stylesheet\" type=\"text/css\" href=\"style.css\"/><meta name=\"viewport\" content=\"width=device-width, initial-scale=1\"></head><body><h1>Setup</h1><div id=\"setup\" class=\"content\"><div id=\"content\"><p>Enter the credentials to your prefered WiFi station. After rebooting the device tries to connect with this information. </p><form method=\"post\" action=\"/save\"><p class=\"des\">WiFi</p><label for=\"ssid\">SSID</label><input type=\"text\" class=\"text\" name=\"ssid\" value=\"{SSID}\"/><label for=\"pwd\">Password</label><input type=\"password\" class=\"text\" name=\"pwd\" value=\"{PWD}\"/><p class=\"des\">Device Host Name</p><label for=\"device\">Device Name</label><input type=\"text\" class=\"text\" name=\"device\" value=\"{DEVICE}\"/><a class=\"erase\" href=\"/erase\">ERASE SETTINGS (not WiFi)</a><p class=\"des\">Inverter</p>{INVERTERS}<br/><p class=\"subdes\">General</p><label for=\"invInterval\">Interval (ms)</label><input type=\"text\" class=\"text\" name=\"invInterval\" value=\"{INV_INTERVAL}\"/><p class=\"des\">Pinout (Wemos)</p>{PINOUT}<p class=\"des\">MQTT</p><label for=\"mqttAddr\">Broker / Server IP</label><input type=\"text\" class=\"text\" name=\"mqttAddr\" value=\"{MQTT_ADDR}\"/><label for=\"mqttUser\">Username (optional)</label><input type=\"text\" class=\"text\" name=\"mqttUser\" value=\"{MQTT_USER}\"/><label for=\"mqttPwd\">Password (optional)</label><input type=\"text\" class=\"text\" name=\"mqttPwd\" value=\"{MQTT_PWD}\"/><label for=\"mqttTopic\">Topic</label><input type=\"text\" class=\"text\" name=\"mqttTopic\" value=\"{MQTT_TOPIC}\"/><label for=\"mqttInterval\">Interval (seconds)</label><input type=\"text\" class=\"text\" name=\"mqttInterval\" value=\"{MQTT_INTERVAL}\"/><p class=\"des\"> </p><input type=\"checkbox\" class=\"cb\" name=\"reboot\"/><label for=\"reboot\">Reboot device after successful save</label><input type=\"submit\" value=\"save\" class=\"btn\" /></form></div></div><div id=\"footer\"><p class=\"left\"><a href=\"/\">Home</a></p><p class=\"left\"><a href=\"/update\">Update Firmware</a></p><p class=\"right\">AHOY - {VERSION}</p></div></body></html>";
|
||||||
#endif /*__SETUP_H__*/
|
#endif /*__SETUP_H__*/
|
||||||
|
|
|
@ -1,4 +1,4 @@
|
||||||
#ifndef __STYLE_H__
|
#ifndef __STYLE_H__
|
||||||
#define __STYLE_H__
|
#define __STYLE_H__
|
||||||
const char style_css[] PROGMEM = "h1 {margin:0;padding:20pt;font-size:22pt;color:#fff;background-color:#006ec0;display:block;text-transform:uppercase;}html, body {font-family:Arial;margin:0;padding:0;}p {text-align:justify;font-size:13pt;}.des {margin-top:35px;font-size:14pt;color:#006ec0;}.subdes {font-size:13pt;color:#006ec0;margin-left:7px;}.fw {width:60px;display:block;float:left;}.color {width:50px;height:50px;border:1px solid #ccc;}.range {width:300px;}a:link, a:visited {text-decoration:none;font-size:13pt;color:#006ec0;}a:hover, a:focus {color:#f00;}#content {padding:15px 15px 60px 15px;}#footer {position:fixed;bottom:0px;height:45px;background-color:#006ec0;width:100%;}#footer p {color:#fff;padding-left:20px;padding-right:20px;font-size:10pt !important;}#footer a {color:#fff;}div.content {background-color:#fff;padding-bottom:65px;overflow:hidden;}input, select {padding:7px;font-size:13pt;}input.text, select {width:70%;box-sizing:border-box;margin-bottom:10px;border:1px solid #ccc;}input.btn {background-color:#006ec0;color:#fff;border:0px;float:right;text-transform:uppercase;}input.cb {margin-bottom:20px;}label {width:20%;display:inline-block;font-size:12pt;padding-right:10px;margin-left:10px;}.left {float:left;}.right {float:right;}div.ch {width:250px;height:410px;background-color:#006ec0;display:inline-block;margin-right:20px;margin-bottom:20px;}div.ch .value, div.ch .info, div.ch .head {color:#fff;display:block;width:100%;text-align:center;}div.ch .unit {font-size:19px;margin-left:10px;}div.ch .value {margin-top:20px;font-size:30px;}div.ch .info {margin-top:3px;font-size:10px;}div.ch .head {background-color:#003c80;padding:10px 0 10px 0;}";
|
const char style_css[] PROGMEM = "h1 {margin:0;padding:20pt;font-size:22pt;color:#fff;background-color:#006ec0;display:block;text-transform:uppercase;}html, body {font-family:Arial;margin:0;padding:0;}p {text-align:justify;font-size:13pt;}.des {margin-top:35px;font-size:14pt;color:#006ec0;}.subdes {font-size:13pt;color:#006ec0;margin-left:7px;}.fw {width:60px;display:block;float:left;}.color {width:50px;height:50px;border:1px solid #ccc;}.range {width:300px;}a:link, a:visited {text-decoration:none;font-size:13pt;color:#006ec0;}a:hover, a:focus {color:#f00;}a.erase {background-color:#006ec0;color:#fff;padding:7px;display:inline-block;margin-top:30px;float:right;}#content {padding:15px 15px 60px 15px;}#footer {position:fixed;bottom:0px;height:45px;background-color:#006ec0;width:100%;}#footer p {color:#fff;padding-left:20px;padding-right:20px;font-size:10pt !important;}#footer a {color:#fff;}div.content {background-color:#fff;padding-bottom:65px;overflow:hidden;}input, select {padding:7px;font-size:13pt;}input.text, select {width:70%;box-sizing:border-box;margin-bottom:10px;border:1px solid #ccc;}input.btn {background-color:#006ec0;color:#fff;border:0px;float:right;margin:10px 0 30px;text-transform:uppercase;}input.cb {margin-bottom:20px;}label {width:20%;display:inline-block;font-size:12pt;padding-right:10px;margin-left:10px;}.left {float:left;}.right {float:right;}div.ch {width:250px;height:410px;background-color:#006ec0;display:inline-block;margin-right:20px;margin-bottom:20px;}div.ch .value, div.ch .info, div.ch .head {color:#fff;display:block;width:100%;text-align:center;}div.ch .unit {font-size:19px;margin-left:10px;}div.ch .value {margin-top:20px;font-size:30px;}div.ch .info {margin-top:3px;font-size:10px;}div.ch .head {background-color:#003c80;padding:10px 0 10px 0;}";
|
||||||
#endif /*__STYLE_H__*/
|
#endif /*__STYLE_H__*/
|
||||||
|
|
|
@ -22,6 +22,9 @@
|
||||||
<label for="device">Device Name</label>
|
<label for="device">Device Name</label>
|
||||||
<input type="text" class="text" name="device" value="{DEVICE}"/>
|
<input type="text" class="text" name="device" value="{DEVICE}"/>
|
||||||
|
|
||||||
|
|
||||||
|
<a class="erase" href="/erase">ERASE SETTINGS (not WiFi)</a>
|
||||||
|
|
||||||
<p class="des">Inverter</p>
|
<p class="des">Inverter</p>
|
||||||
{INVERTERS}<br/>
|
{INVERTERS}<br/>
|
||||||
<p class="subdes">General</p>
|
<p class="subdes">General</p>
|
||||||
|
|
|
@ -57,6 +57,15 @@ a:hover, a:focus {
|
||||||
color: #f00;
|
color: #f00;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
a.erase {
|
||||||
|
background-color: #006ec0;
|
||||||
|
color: #fff;
|
||||||
|
padding: 7px;
|
||||||
|
display: inline-block;
|
||||||
|
margin-top: 30px;
|
||||||
|
float: right;
|
||||||
|
}
|
||||||
|
|
||||||
#content {
|
#content {
|
||||||
padding: 15px 15px 60px 15px;
|
padding: 15px 15px 60px 15px;
|
||||||
}
|
}
|
||||||
|
@ -103,6 +112,7 @@ input.btn {
|
||||||
color: #fff;
|
color: #fff;
|
||||||
border: 0px;
|
border: 0px;
|
||||||
float: right;
|
float: right;
|
||||||
|
margin: 10px 0 30px;
|
||||||
text-transform: uppercase;
|
text-transform: uppercase;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
|
@ -90,9 +90,8 @@ bool Main::getConfig(void) {
|
||||||
memset(mStationPwd, 0, PWD_LEN);
|
memset(mStationPwd, 0, PWD_LEN);
|
||||||
memset(mDeviceName, 0, DEVNAME_LEN);
|
memset(mDeviceName, 0, DEVNAME_LEN);
|
||||||
|
|
||||||
// erase eeprom
|
// erase application settings except wifi settings
|
||||||
uint8_t buf[ADDR_NEXT-ADDR_START_SETTINGS] = {0};
|
eraseSettings();
|
||||||
mEep->write(ADDR_START_SETTINGS, buf, (ADDR_NEXT-ADDR_START_SETTINGS));
|
|
||||||
}
|
}
|
||||||
|
|
||||||
return mApActive;
|
return mApActive;
|
||||||
|
|
|
@ -53,6 +53,17 @@ class Main {
|
||||||
return (crcCheck == crcRd);
|
return (crcCheck == crcRd);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
void eraseSettings(void) {
|
||||||
|
uint8_t buf[64] = {0};
|
||||||
|
uint16_t addr = ADDR_START_SETTINGS, end;
|
||||||
|
do {
|
||||||
|
end = addr += 64;
|
||||||
|
if(end > (ADDR_SETTINGS_CRC + 2))
|
||||||
|
end = (ADDR_SETTINGS_CRC + 2 - addr);
|
||||||
|
mEep->write(ADDR_START_SETTINGS, buf, (ADDR_NEXT-ADDR_START_SETTINGS));
|
||||||
|
} while(addr < ADDR_START_SETTINGS);
|
||||||
|
}
|
||||||
|
|
||||||
char mStationSsid[SSID_LEN];
|
char mStationSsid[SSID_LEN];
|
||||||
char mStationPwd[PWD_LEN];
|
char mStationPwd[PWD_LEN];
|
||||||
bool mWifiSettingsValid;
|
bool mWifiSettingsValid;
|
||||||
|
|
Loading…
Add table
Reference in a new issue