diff --git a/sonoff/_changelog.ino b/sonoff/_changelog.ino index 8429ce360..3f88ba690 100644 --- a/sonoff/_changelog.ino +++ b/sonoff/_changelog.ino @@ -5,7 +5,7 @@ * Add initial support for MQTT logging using command MqttLog (#6498) * Add Zigbee more support - collect endpoints and clusters, added ZigbeeDump command * Add initial support for shutters by Stefan Bode (#288) - * Add use case for sensor29 pin,1 and sensor29 pin,0 to substitute ON and OFF respectively with MCP230xx driver + * Add command to MCP230xx: sensor29 pin,0/1/2 for OFF/ON/TOGGLE * * 6.6.0.13 20190922 * Add command EnergyReset4 x,x to initialize total usage for two tarrifs diff --git a/sonoff/xsns_29_mcp230xx.ino b/sonoff/xsns_29_mcp230xx.ino index 855de1349..0e9cc1039 100644 --- a/sonoff/xsns_29_mcp230xx.ino +++ b/sonoff/xsns_29_mcp230xx.ino @@ -636,7 +636,7 @@ bool MCP230xx_Command(void) { MCP230xx_SetOutPin(pin,pincmd); return serviced; } - if (!strcmp(subStr(sub_string, XdrvMailbox.data, ",", 2), "T")) { + if ((!strcmp(subStr(sub_string, XdrvMailbox.data, ",", 2), "T")) || (!strcmp(subStr(sub_string, XdrvMailbox.data, ",", 2), "2"))) { MCP230xx_SetOutPin(pin,2); return serviced; }