From 92e033fe6de69951453cefa9218d7f8a765e796f Mon Sep 17 00:00:00 2001 From: Drew Sloan Date: Thu, 14 Nov 2024 11:34:17 -0500 Subject: [PATCH] Extending support to other SAMD21 variants. --- CapacitiveSensor.h | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/CapacitiveSensor.h b/CapacitiveSensor.h index 8922947..d9318a3 100644 --- a/CapacitiveSensor.h +++ b/CapacitiveSensor.h @@ -224,7 +224,9 @@ void directModeOutput(IO_REG_TYPE pin) #define interrupts() portEXIT_CRITICAL(&mux);} //#warning, code is copied from "ESP32 OneWire testing" -#elif defined(__SAMD21G18A__) +#elif defined(__SAMD21G18A__) || defined(__SAMD21G17A__) || \ + defined(__SAMD21J18A__) || defined(__SAMD21G17A__) || \ + defined(__SAMD21E18A__) || defined(__SAMD21E17A__) // runs extremely slow/unreliable on Arduino Zero - help wanted.... #define PIN_TO_BASEREG(pin) portModeRegister(digitalPinToPort(pin)) #define PIN_TO_BITMASK(pin) (digitalPinToBitMask(pin))