* fixed translation #1403
* fixed sending commands to inverters which are soft turned off #1397
* reduce switchChannel command for HMS (only each 5th cycle it will be send now)
This commit is contained in:
lumapu 2024-02-04 13:21:02 +01:00
parent 883aefbe64
commit 14c5a7ad32
6 changed files with 28 additions and 14 deletions

View file

@ -152,7 +152,6 @@ class Inverter {
static uint32_t *timestamp; // system timestamp
static cfgInst_t *generalConfig; // general inverter configuration from setup
//static IApp *app; // pointer to app interface
public:
@ -290,18 +289,18 @@ class Inverter {
}
bool setDevControlRequest(uint8_t cmd) {
if(InverterStatus::PRODUCING == status) {
if(InverterStatus::OFF != status) {
mDevControlRequest = true;
devControlCmd = cmd;
//app->triggerTickSend(); // done in RestApi.h, because of "chicken-and-egg problem ;-)"
}
return (InverterStatus::PRODUCING == status);
return (InverterStatus::OFF != status);
}
bool setDevCommand(uint8_t cmd) {
if(InverterStatus::PRODUCING == status)
if(InverterStatus::OFF != status)
devControlCmd = cmd;
return (InverterStatus::PRODUCING == status);
return (InverterStatus::OFF != status);
}
void addValue(uint8_t pos, uint8_t buf[], record_t<> *rec) {