From 29177652dd18028bfc1b9fa7bdff04409afc8f29 Mon Sep 17 00:00:00 2001 From: nagyrobi Date: Sat, 16 May 2020 17:30:43 +0200 Subject: [PATCH] Add SetOption59 capability to MCP230XX --- tasmota/xsns_29_mcp230xx.ino | 3 +++ 1 file changed, 3 insertions(+) diff --git a/tasmota/xsns_29_mcp230xx.ino b/tasmota/xsns_29_mcp230xx.ino index 0a831d869..208fbcdd8 100644 --- a/tasmota/xsns_29_mcp230xx.ino +++ b/tasmota/xsns_29_mcp230xx.ino @@ -306,6 +306,9 @@ void MCP230xx_CheckForInterrupt(void) { ResponseTime_P(PSTR(",\"MCP230XX_INT\":{\"D%i\":%i,\"MS\":%lu}}"), intp+(mcp230xx_port*8), ((mcp230xx_intcap >> intp) & 0x01),millis_since_last_int); MqttPublishPrefixTopic_P(RESULT_OR_STAT, PSTR("MCP230XX_INT")); + if (Settings.flag3.hass_tele_on_power) { // SetOption59 - Send tele/%topic%/SENSOR in addition to stat/%topic%/RESULT + MqttPublishSensor(); + } } if (int_event) { char command[19]; // Theoretical max = 'event MCPINT_D16=1' so 18 + 1 (for the \n)