diff --git a/src/BlinkTask.h b/src/BlinkTask.h index 5da32c2..8916d9e 100644 --- a/src/BlinkTask.h +++ b/src/BlinkTask.h @@ -111,10 +111,10 @@ class BlinkTask : public Task byte _outPin; uint8_t _bitMask; -#ifndef ESP8266 - volatile uint8_t *_portRegister; -#else +#if defined(ESP8266) || defined(ARDUINO_ARCH_SAMD) volatile uint32_t *_portRegister; +#else + volatile uint8_t *_portRegister; #endif }; diff --git a/src/FrequencyTask.h b/src/FrequencyTask.h index fe83d16..b383b49 100644 --- a/src/FrequencyTask.h +++ b/src/FrequencyTask.h @@ -53,10 +53,10 @@ class FrequencyTask : public Task int _outPin; boolean _stateOn; uint8_t _bitMask; -#ifndef ESP8266 - volatile uint8_t *_portRegister; -#else +#if defined(ESP8266) || defined(ARDUINO_ARCH_SAMD) volatile uint32_t *_portRegister; +#else + volatile uint8_t *_portRegister; #endif static void step(Task* me); }; diff --git a/src/SoftPwmTask.h b/src/SoftPwmTask.h index b50859f..5d93ef2 100644 --- a/src/SoftPwmTask.h +++ b/src/SoftPwmTask.h @@ -68,10 +68,10 @@ class SoftPwmTask : public Task static void step(Task* me); uint8_t _bitMask; -#ifndef ESP8266 - volatile uint8_t *_portRegister; -#else +#if defined(ESP8266) || defined(ARDUINO_ARCH_SAMD) volatile uint32_t *_portRegister; +#else + volatile uint8_t *_portRegister; #endif };