mirror of
https://github.com/lumapu/ahoy.git
synced 2025-07-28 05:37:21 +02:00
fix HMS only installation
This commit is contained in:
parent
124cbf6ba2
commit
28868a6ca6
1 changed files with 8 additions and 10 deletions
|
@ -70,11 +70,11 @@ void app::setup() {
|
||||||
#endif
|
#endif
|
||||||
});
|
});
|
||||||
}
|
}
|
||||||
if (mConfig->nrf.enabled) {
|
|
||||||
mPayload.setup(this, &mSys, &mNrfStat, mConfig->nrf.maxRetransPerPyld, &mTimestamp);
|
mPayload.setup(this, &mSys, &mNrfStat, mConfig->nrf.maxRetransPerPyld, &mTimestamp);
|
||||||
mPayload.enableSerialDebug(mConfig->serial.debug);
|
mPayload.enableSerialDebug(mConfig->serial.debug);
|
||||||
mPayload.addPayloadListener(std::bind(&app::payloadEventListener, this, std::placeholders::_1, std::placeholders::_2));
|
mPayload.addPayloadListener(std::bind(&app::payloadEventListener, this, std::placeholders::_1, std::placeholders::_2));
|
||||||
|
if (mConfig->nrf.enabled) {
|
||||||
mMiPayload.setup(this, &mSys, &mNrfRadio, &mNrfStat, mConfig->nrf.maxRetransPerPyld, &mTimestamp);
|
mMiPayload.setup(this, &mSys, &mNrfRadio, &mNrfStat, mConfig->nrf.maxRetransPerPyld, &mTimestamp);
|
||||||
mMiPayload.enableSerialDebug(mConfig->serial.debug);
|
mMiPayload.enableSerialDebug(mConfig->serial.debug);
|
||||||
mMiPayload.addPayloadListener(std::bind(&app::payloadEventListener, this, std::placeholders::_1, std::placeholders::_2));
|
mMiPayload.addPayloadListener(std::bind(&app::payloadEventListener, this, std::placeholders::_1, std::placeholders::_2));
|
||||||
|
@ -431,14 +431,12 @@ void app::tickSend(void) {
|
||||||
|
|
||||||
if (NULL != iv) {
|
if (NULL != iv) {
|
||||||
if (iv->config->enabled) {
|
if (iv->config->enabled) {
|
||||||
if(mConfig->nrf.enabled) {
|
if((iv->ivGen == IV_MI) && mConfig->nrf.enabled)
|
||||||
if(iv->ivGen == IV_MI)
|
|
||||||
mMiPayload.ivSend(iv);
|
mMiPayload.ivSend(iv);
|
||||||
else
|
else
|
||||||
mPayload.ivSend(iv);
|
mPayload.ivSend(iv);
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
|
||||||
} else {
|
} else {
|
||||||
if (mConfig->serial.debug)
|
if (mConfig->serial.debug)
|
||||||
DPRINTLN(DBG_WARN, F("Time not set or it is night time, therefore no communication to the inverter!"));
|
DPRINTLN(DBG_WARN, F("Time not set or it is night time, therefore no communication to the inverter!"));
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue