Hi,
thanks for your reply. I've tried compiling the code from
https://github.com/ayasystems/PowerMaxEsp8266. I've added all the libraries etc.
However I get this error message.
/Users/svenbreynaert/Downloads/ESP8266mqtt/PowerMaxEsp8266/PowerMaxEsp8266/PowerMaxEsp8266.ino: In member function 'virtual void MyPowerMax::OnStatusChange(const PlinkBuffer*)':
/Users/svenbreynaert/Downloads/ESP8266mqtt/PowerMaxEsp8266/PowerMaxEsp8266/PowerMaxEsp8266.ino:191:34: error: cannot bind non-const lvalue reference of type 'String&' to an rvalue of type 'String'
191 | addLog("Default case"+String(Buff->buffer[4]));
| ~~~~~~~~~~~~~~^~~~~~~~~~~~~~~~~~~~~~~~
/Users/svenbreynaert/Downloads/ESP8266mqtt/PowerMaxEsp8266/PowerMaxEsp8266/PowerMaxEsp8266.ino:118:21: note: initializing argument 1 of 'void addLog(String&)'
118 | void addLog(String& string)
| ~~~~~~~~^~~~~~
/Users/svenbreynaert/Downloads/ESP8266mqtt/PowerMaxEsp8266/PowerMaxEsp8266/PowerMaxEsp8266.ino: In member function 'virtual void MyPowerMax::OnSytemArmed(unsigned char, const char*, unsigned char, const char*)':
/Users/svenbreynaert/Downloads/ESP8266mqtt/PowerMaxEsp8266/PowerMaxEsp8266/PowerMaxEsp8266.ino:199:27: error: cannot bind non-const lvalue reference of type 'String&' to an rvalue of type 'String'
199 | addLog("Armed by : "+(String)whoArmedStr);
| ~~~~~~~~~~~~~^~~~~~~~~~~~~~~~~~~~
/Users/svenbreynaert/Downloads/ESP8266mqtt/PowerMaxEsp8266/PowerMaxEsp8266/PowerMaxEsp8266.ino:118:21: note: initializing argument 1 of 'void addLog(String&)'
118 | void addLog(String& string)
| ~~~~~~~~^~~~~~
/Users/svenbreynaert/Downloads/ESP8266mqtt/PowerMaxEsp8266/PowerMaxEsp8266/PowerMaxEsp8266.ino: In member function 'virtual void MyPowerMax::OnSytemDisarmed(unsigned char, const char*)':
/Users/svenbreynaert/Downloads/ESP8266mqtt/PowerMaxEsp8266/PowerMaxEsp8266/PowerMaxEsp8266.ino:204:30: error: cannot bind non-const lvalue reference of type 'String&' to an rvalue of type 'String'
204 | addLog("Disarmed by : "+(String)whoDisarmedStr);
| ~~~~~~~~~~~~~~~~^~~~~~~~~~~~~~~~~~~~~~~
/Users/svenbreynaert/Downloads/ESP8266mqtt/PowerMaxEsp8266/PowerMaxEsp8266/PowerMaxEsp8266.ino:118:21: note: initializing argument 1 of 'void addLog(String&)'
118 | void addLog(String& string)
| ~~~~~~~~^~~~~~
/Users/svenbreynaert/Downloads/ESP8266mqtt/PowerMaxEsp8266/PowerMaxEsp8266/PowerMaxEsp8266.ino: In member function 'virtual void MyPowerMax::OnAlarmStarted(unsigned char, const char*, unsigned char, const char*)':
/Users/svenbreynaert/Downloads/ESP8266mqtt/PowerMaxEsp8266/PowerMaxEsp8266/PowerMaxEsp8266.ino:209:41: error: cannot bind non-const lvalue reference of type 'String&' to an rvalue of type 'String'
209 | addLog("System ALARM raised by : "+(String)zoneTrippedStr);
| ~~~~~~~~~~~~~~~~~~~~~~~~~~~^~~~~~~~~~~~~~~~~~~~~~~
/Users/svenbreynaert/Downloads/ESP8266mqtt/PowerMaxEsp8266/PowerMaxEsp8266/PowerMaxEsp8266.ino:118:21: note: initializing argument 1 of 'void addLog(String&)'
118 | void addLog(String& string)
| ~~~~~~~~^~~~~~
/Users/svenbreynaert/Downloads/ESP8266mqtt/PowerMaxEsp8266/PowerMaxEsp8266/PowerMaxEsp8266.ino: In member function 'virtual void MyPowerMax::OnAlarmCancelled(unsigned char, const char*)':
/Users/svenbreynaert/Downloads/ESP8266mqtt/PowerMaxEsp8266/PowerMaxEsp8266/PowerMaxEsp8266.ino:214:34: error: cannot bind non-const lvalue reference of type 'String&' to an rvalue of type 'String'
214 | addLog("Alarm called by : "+(String)whoDisarmedStr);
| ~~~~~~~~~~~~~~~~~~~~^~~~~~~~~~~~~~~~~~~~~~~
/Users/svenbreynaert/Downloads/ESP8266mqtt/PowerMaxEsp8266/PowerMaxEsp8266/PowerMaxEsp8266.ino:118:21: note: initializing argument 1 of 'void addLog(String&)'
118 | void addLog(String& string)
| ~~~~~~~~^~~~~~
/Users/svenbreynaert/Downloads/ESP8266mqtt/PowerMaxEsp8266/PowerMaxEsp8266/PowerMaxEsp8266.ino: In member function 'virtual void MyPowerMax::OnStatusUpdatePanel(const PlinkBuffer*)':
/Users/svenbreynaert/Downloads/ESP8266mqtt/PowerMaxEsp8266/PowerMaxEsp8266/PowerMaxEsp8266.ino:226:52: error: cannot bind non-const lvalue reference of type 'String&' to an rvalue of type 'String'
226 | addLog("Zone: "+(String)zoneId+" Name: "+this->getZoneName(zoneId));
| ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~^~~~~~~~~~~~~~~~~~~~~~~~~~
/Users/svenbreynaert/Downloads/ESP8266mqtt/PowerMaxEsp8266/PowerMaxEsp8266/PowerMaxEsp8266.ino:118:21: note: initializing argument 1 of 'void addLog(String&)'
118 | void addLog(String& string)
| ~~~~~~~~^~~~~~
/Users/svenbreynaert/Downloads/ESP8266mqtt/PowerMaxEsp8266/PowerMaxEsp8266/PowerMaxEsp8266.ino: In function 'void setTime()':
/Users/svenbreynaert/Downloads/ESP8266mqtt/PowerMaxEsp8266/PowerMaxEsp8266/PowerMaxEsp8266.ino

74: warning: ISO C++ forbids converting a string constant to 'char*' [-Wwrite-strings]
1149 | year = (unsigned char) getEpochStringByParams(CE.toLocal(now()),"%y").toInt();
| ^~~~
/Users/svenbreynaert/Downloads/ESP8266mqtt/PowerMaxEsp8266/PowerMaxEsp8266/PowerMaxEsp8266.ino

74: warning: ISO C++ forbids converting a string constant to 'char*' [-Wwrite-strings]
1150 | month = (unsigned char) getEpochStringByParams(CE.toLocal(now()),"%m").toInt();
| ^~~~
/Users/svenbreynaert/Downloads/ESP8266mqtt/PowerMaxEsp8266/PowerMaxEsp8266/PowerMaxEsp8266.ino

74: warning: ISO C++ forbids converting a string constant to 'char*' [-Wwrite-strings]
1151 | day = (unsigned char) getEpochStringByParams(CE.toLocal(now()),"%d").toInt();
| ^~~~
/Users/svenbreynaert/Downloads/ESP8266mqtt/PowerMaxEsp8266/PowerMaxEsp8266/PowerMaxEsp8266.ino

74: warning: ISO C++ forbids converting a string constant to 'char*' [-Wwrite-strings]
1152 | hour = (unsigned char) getEpochStringByParams(CE.toLocal(now()),"%H").toInt();
| ^~~~
/Users/svenbreynaert/Downloads/ESP8266mqtt/PowerMaxEsp8266/PowerMaxEsp8266/PowerMaxEsp8266.ino

74: warning: ISO C++ forbids converting a string constant to 'char*' [-Wwrite-strings]
1153 | minutes = (unsigned char) getEpochStringByParams(CE.toLocal(now()),"%M").toInt();
| ^~~~
/Users/svenbreynaert/Downloads/ESP8266mqtt/PowerMaxEsp8266/PowerMaxEsp8266/PowerMaxEsp8266.ino

74: warning: ISO C++ forbids converting a string constant to 'char*' [-Wwrite-strings]
1154 | seconds = (unsigned char) getEpochStringByParams(CE.toLocal(now()),"%S").toInt();
| ^~~~
/Users/svenbreynaert/Downloads/ESP8266mqtt/PowerMaxEsp8266/PowerMaxEsp8266/PowerMaxEsp8266.ino: In function 'boolean loopMQTT()':
/Users/svenbreynaert/Downloads/ESP8266mqtt/PowerMaxEsp8266/PowerMaxEsp8266/PowerMaxEsp8266.ino

43: error: cannot bind non-const lvalue reference of type 'String&' to an rvalue of type 'String'
1189 | addLog("Mqtt failed connection "+(String)clientMqtt.state());
| ~~~~~~~~~~~~~~~~~~~~~~~~~^~~~~~~~~~~~~~~~~~~~~~~~~~~
/Users/svenbreynaert/Downloads/ESP8266mqtt/PowerMaxEsp8266/PowerMaxEsp8266/PowerMaxEsp8266.ino:118:21: note: initializing argument 1 of 'void addLog(String&)'
118 | void addLog(String& string)
| ~~~~~~~~^~~~~~
/Users/svenbreynaert/Downloads/ESP8266mqtt/PowerMaxEsp8266/PowerMaxEsp8266/fs.ino: In function 'void wifiManagerSetup()':
/Users/svenbreynaert/Downloads/ESP8266mqtt/PowerMaxEsp8266/PowerMaxEsp8266/fs.ino:96:20: error: cannot bind non-const lvalue reference of type 'String&' to an rvalue of type 'String'
96 | addLog("SAVE: "+String(jsonLog));
| ~~~~~~~~^~~~~~~~~~~~~~~~
/Users/svenbreynaert/Downloads/ESP8266mqtt/PowerMaxEsp8266/PowerMaxEsp8266/PowerMaxEsp8266.ino:118:21: note: initializing argument 1 of 'void addLog(String&)'
118 | void addLog(String& string)
| ~~~~~~~~^~~~~~
/Users/svenbreynaert/Downloads/ESP8266mqtt/PowerMaxEsp8266/PowerMaxEsp8266/fs.ino: In function 'void createFS()':
/Users/svenbreynaert/Downloads/ESP8266mqtt/PowerMaxEsp8266/PowerMaxEsp8266/fs.ino:144:30: error: cannot bind non-const lvalue reference of type 'String&' to an rvalue of type 'String'
144 | addLog("LOAD: "+String(jsonLog));
| ~~~~~~~~^~~~~~~~~~~~~~~~
/Users/svenbreynaert/Downloads/ESP8266mqtt/PowerMaxEsp8266/PowerMaxEsp8266/PowerMaxEsp8266.ino:118:21: note: initializing argument 1 of 'void addLog(String&)'
118 | void addLog(String& string)
| ~~~~~~~~^~~~~~
/Users/svenbreynaert/Downloads/ESP8266mqtt/PowerMaxEsp8266/PowerMaxEsp8266/mqtt.ino: In function 'void callbackMqtt(char*, byte*, unsigned int)':
/Users/svenbreynaert/Downloads/ESP8266mqtt/PowerMaxEsp8266/PowerMaxEsp8266/mqtt.ino:53:50: error: cannot bind non-const lvalue reference of type 'String&' to an rvalue of type 'String'
53 | addLog("MQTT: callbackMqtt: "+(String)topic+" "+message);
| ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~^~~~~~~~
/Users/svenbreynaert/Downloads/ESP8266mqtt/PowerMaxEsp8266/PowerMaxEsp8266/PowerMaxEsp8266.ino:118:21: note: initializing argument 1 of 'void addLog(String&)'
118 | void addLog(String& string)
| ~~~~~~~~^~~~~~
/Users/svenbreynaert/Downloads/ESP8266mqtt/PowerMaxEsp8266/PowerMaxEsp8266/mqtt.ino: In function 'void publishSytemDisarmed(unsigned char, const char*)':
/Users/svenbreynaert/Downloads/ESP8266mqtt/PowerMaxEsp8266/PowerMaxEsp8266/mqtt.ino:215:22: error: cannot bind non-const lvalue reference of type 'String&' to an rvalue of type 'String'
215 | addLog("DISARMED: "+output);
| ~~~~~~~~~~~~^~~~~~~
/Users/svenbreynaert/Downloads/ESP8266mqtt/PowerMaxEsp8266/PowerMaxEsp8266/PowerMaxEsp8266.ino:118:21: note: initializing argument 1 of 'void addLog(String&)'
118 | void addLog(String& string)
| ~~~~~~~~^~~~~~
/Users/svenbreynaert/Downloads/ESP8266mqtt/PowerMaxEsp8266/PowerMaxEsp8266/mqtt.ino: In function 'void publishSytemArmed(unsigned char, const char*, unsigned char, const char*)':
/Users/svenbreynaert/Downloads/ESP8266mqtt/PowerMaxEsp8266/PowerMaxEsp8266/mqtt.ino:232:19: error: cannot bind non-const lvalue reference of type 'String&' to an rvalue of type 'String'
232 | addLog("ARMED: "+output);
| ~~~~~~~~~^~~~~~~
/Users/svenbreynaert/Downloads/ESP8266mqtt/PowerMaxEsp8266/PowerMaxEsp8266/PowerMaxEsp8266.ino:118:21: note: initializing argument 1 of 'void addLog(String&)'
118 | void addLog(String& string)
| ~~~~~~~~^~~~~~
/Users/svenbreynaert/Downloads/ESP8266mqtt/PowerMaxEsp8266/PowerMaxEsp8266/mqtt.ino: In function 'void publishAlarmStarted(unsigned char, const char*, unsigned char, const char*)':
/Users/svenbreynaert/Downloads/ESP8266mqtt/PowerMaxEsp8266/PowerMaxEsp8266/mqtt.ino:250:26: error: cannot bind non-const lvalue reference of type 'String&' to an rvalue of type 'String'
250 | addLog("ALARMSTARTED: "+output);
| ~~~~~~~~~~~~~~~~^~~~~~~
/Users/svenbreynaert/Downloads/ESP8266mqtt/PowerMaxEsp8266/PowerMaxEsp8266/PowerMaxEsp8266.ino:118:21: note: initializing argument 1 of 'void addLog(String&)'
118 | void addLog(String& string)
| ~~~~~~~~^~~~~~
/Users/svenbreynaert/Downloads/ESP8266mqtt/PowerMaxEsp8266/PowerMaxEsp8266/mqtt.ino: In function 'void publishAlarmCancelled(unsigned char, const char*)':
/Users/svenbreynaert/Downloads/ESP8266mqtt/PowerMaxEsp8266/PowerMaxEsp8266/mqtt.ino:267:28: error: cannot bind non-const lvalue reference of type 'String&' to an rvalue of type 'String'
267 | addLog("ALARMCANCELLED: "+output);
| ~~~~~~~~~~~~~~~~~~^~~~~~~
/Users/svenbreynaert/Downloads/ESP8266mqtt/PowerMaxEsp8266/PowerMaxEsp8266/PowerMaxEsp8266.ino:118:21: note: initializing argument 1 of 'void addLog(String&)'
118 | void addLog(String& string)
| ~~~~~~~~^~~~~~
exit status 1
Compilation error: cannot bind non-const lvalue reference of type 'String&' to an rvalue of type 'String'