Update xsns_29_mcp230xx.ino

This commit is contained in:
andrethomas 2018-08-18 16:34:41 +02:00 committed by GitHub
parent 5560e6ae4a
commit 1eebc2e4ee
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
1 changed files with 2 additions and 1 deletions

View File

@ -331,9 +331,10 @@ void MCP230xx_Reset(uint8_t pinmode) {
Settings.mcp230xx_config[pinx].pinmode=pinmode;
Settings.mcp230xx_config[pinx].pullup=pullup;
Settings.mcp230xx_config[pinx].saved_state=0;
Settings.mcp230xx_config[pinx].int_report_mode=3;
if (pinmode > 1 && pinmode < 5) {
Settings.mcp230xx_config[pinx].int_report_mode=0; // Enabled for ALL by default
} else {
Settings.mcp230xx_config[pinx].int_report_mode=3; // Disabled for pinmode 1, 5 and 6 (No interrupts there)
}
Settings.mcp230xx_config[pinx].b7=0;
}