From 0153601dc24fc52ab9b62c0b6f2bf3800afe70f6 Mon Sep 17 00:00:00 2001 From: Matteo Albinola Date: Sat, 2 May 2020 15:22:37 +0200 Subject: [PATCH] Support new pin handling changes --- tasmota/xsns_68_windmeter.ino | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/tasmota/xsns_68_windmeter.ino b/tasmota/xsns_68_windmeter.ino index b0342984e..4738cfd9b 100644 --- a/tasmota/xsns_68_windmeter.ino +++ b/tasmota/xsns_68_windmeter.ino @@ -115,8 +115,8 @@ void WindMeterInit(void) WindMeterCheckSampleCount(); #endif // USE_WINDMETER_NOSTATISTICS - pinMode(pin[GPIO_WINDMETER_SPEED], INPUT_PULLUP); - attachInterrupt(pin[GPIO_WINDMETER_SPEED], WindMeterUpdateSpeed, FALLING); + pinMode(Pin(GPIO_WINDMETER_SPEED), INPUT_PULLUP); + attachInterrupt(Pin(GPIO_WINDMETER_SPEED), WindMeterUpdateSpeed, FALLING); } void WindMeterEverySecond(void) @@ -342,7 +342,7 @@ bool Xsns68Cmnd(void) bool Xsns68(uint8_t function) { bool result = false; - if (pin[GPIO_WINDMETER_SPEED] < 99) { + if (PinUsed(GPIO_WINDMETER_SPEED)) { switch (function) { case FUNC_INIT: WindMeterInit();