Add SetOption147

Add SetOption147  (MQTT) Enable publish SSerialReceived MQTT messages. If disabled, use event rules instead.
If it is disabled, tasmota will not publish an MQTT message every time a SSerialReceived event fires. Use rules to control how and when publish these messages.
This commit is contained in:
ortegafernando 2022-09-20 23:38:59 +02:00 committed by GitHub
parent 3cb2c7c497
commit 8455a3fd3c
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23

View File

@ -167,7 +167,11 @@ void SerialBridgeInput(void) {
}
ResponseJsonEnd();
MqttPublishPrefixTopicRulesProcess_P(RESULT_OR_TELE, PSTR(D_JSON_SSERIALRECEIVED));
if (Settings->flag6.mqtt_sserialreceived) { // SetOption147 (MQTT) Enable publish SSerialReceived MQTT messages. If disabled, use event rules instead.
MqttPublishPrefixTopicRulesProcess_P(RESULT_OR_TELE, PSTR(D_JSON_SSERIALRECEIVED));
} else {
XdrvRulesProcess(0);
}
serial_bridge_in_byte_counter = 0;
}
}