From 895ed2d041560dcd4aa59cb535c5614f0287ccf5 Mon Sep 17 00:00:00 2001 From: Theo Arends <11044339+arendst@users.noreply.github.com> Date: Tue, 29 Sep 2020 14:41:45 +0200 Subject: [PATCH] Redesign GPIO to 16-bit --- tasmota/settings.ino | 2 +- tasmota/support.ino | 2 +- tasmota/xdrv_01_webserver.ino | 4 ++-- tasmota/xsns_02_analog.ino | 4 +--- 4 files changed, 5 insertions(+), 7 deletions(-) diff --git a/tasmota/settings.ino b/tasmota/settings.ino index c1f3cb4de..767cc9ed8 100644 --- a/tasmota/settings.ino +++ b/tasmota/settings.ino @@ -1259,7 +1259,7 @@ void SettingsDelta(void) Settings.ledmask = APP_LEDMASK; } if (Settings.version < 0x0605000A) { -// Settings.my_adc0 = ADC0_NONE; + Settings.my_adc0 = GPIO_NONE; } if (Settings.version < 0x0605000D) { Settings.param[P_IR_UNKNOW_THRESHOLD] = IR_RCV_MIN_UNKNOWN_SIZE; diff --git a/tasmota/support.ino b/tasmota/support.ino index e94170759..892bedd0f 100644 --- a/tasmota/support.ino +++ b/tasmota/support.ino @@ -1390,7 +1390,7 @@ bool ValidGPIO(uint32_t pin, uint32_t gpio) { #ifdef ESP8266 #ifdef USE_ADC_VCC - if (17 == pin) { return false; } // ADC0 = GPIO17 + if (ADC0_PIN == pin) { return false; } // ADC0 = GPIO17 #endif #endif return (GPIO_USER == ValidPin(pin, BGPIO(gpio))); // Only allow GPIO_USER pins diff --git a/tasmota/xdrv_01_webserver.ino b/tasmota/xdrv_01_webserver.ino index b73a264e5..1258d10d8 100644 --- a/tasmota/xdrv_01_webserver.ino +++ b/tasmota/xdrv_01_webserver.ino @@ -1804,7 +1804,7 @@ void HandleTemplateConfiguration(void) //#ifdef ESP8266 // WSContentSend_P(PSTR("