mirror of
https://github.com/lumapu/ahoy.git
synced 2025-06-28 07:17:00 +02:00
* moved mqtt loop out of checkTicker
as mentioned in #49
* added irritation and efficiency calculations (** EPPROM CHANGE - YOUR SETTINGS MAYBE BECOME CURRUPT! **) * improved style
This commit is contained in:
parent
8238e90903
commit
7844ea2946
11 changed files with 180 additions and 28 deletions
|
@ -27,7 +27,7 @@ class HmSystem {
|
|||
Radio.setup(&BufCtrl);
|
||||
}
|
||||
|
||||
INVERTERTYPE *addInverter(const char *name, uint64_t serial) {
|
||||
INVERTERTYPE *addInverter(const char *name, uint64_t serial, uint16_t chMaxPwr[]) {
|
||||
if(MAX_INVERTER <= mNumInv) {
|
||||
DPRINT("max number of inverters reached!");
|
||||
return NULL;
|
||||
|
@ -35,6 +35,7 @@ class HmSystem {
|
|||
INVERTERTYPE *p = &mInverter[mNumInv];
|
||||
p->id = mNumInv;
|
||||
p->serial.u64 = serial;
|
||||
memcpy(p->chMaxPwr, chMaxPwr, (4*2));
|
||||
DPRINT("SERIAL: " + String(p->serial.b[5], HEX));
|
||||
DPRINTLN(" " + String(p->serial.b[4], HEX));
|
||||
if(p->serial.b[5] == 0x11) {
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue