mirror of
https://github.com/dalathegreat/Battery-Emulator.git
synced 2025-10-03 09:49:32 +02:00
Add configurable cell/module/etc settings for Pylonish/Solax inverters to use
This commit is contained in:
parent
9816417b21
commit
2f1ff9950c
5 changed files with 112 additions and 1 deletions
|
@ -414,7 +414,7 @@ void init_webserver() {
|
|||
|
||||
const char* boolSettingNames[] = {
|
||||
"DBLBTR", "CNTCTRL", "CNTCTRLDBL", "PWMCNTCTRL", "PERBMSRESET", "REMBMSRESET",
|
||||
"CANFDASCAN", "WIFIAPENABLED", "MQTTENABLED", "HADISC", "MQTTTOPICS",
|
||||
"CANFDASCAN", "WIFIAPENABLED", "MQTTENABLED", "HADISC", "MQTTTOPICS", "INVICNT",
|
||||
};
|
||||
|
||||
// Handles the form POST from UI to save settings of the common image
|
||||
|
@ -497,6 +497,24 @@ void init_webserver() {
|
|||
} else if (p->name() == "SOFAR_ID") {
|
||||
auto type = atoi(p->value().c_str());
|
||||
settings.saveUInt("SOFAR_ID", type);
|
||||
} else if (p->name() == "INVCELLS") {
|
||||
auto type = atoi(p->value().c_str());
|
||||
settings.saveUInt("INVCELLS", type);
|
||||
} else if (p->name() == "INVMODULES") {
|
||||
auto type = atoi(p->value().c_str());
|
||||
settings.saveUInt("INVMODULES", type);
|
||||
} else if (p->name() == "INVCELLSPER") {
|
||||
auto type = atoi(p->value().c_str());
|
||||
settings.saveUInt("INVCELLSPER", type);
|
||||
} else if (p->name() == "INVVLEVEL") {
|
||||
auto type = atoi(p->value().c_str());
|
||||
settings.saveUInt("INVVLEVEL", type);
|
||||
} else if (p->name() == "INVCAPACITY") {
|
||||
auto type = atoi(p->value().c_str());
|
||||
settings.saveUInt("INVCAPACITY", type);
|
||||
} else if (p->name() == "INVBTYPE") {
|
||||
auto type = atoi(p->value().c_str());
|
||||
settings.saveUInt("INVBTYPE", (int)type);
|
||||
}
|
||||
|
||||
for (auto& boolSetting : boolSettings) {
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue