Welcome to mirror list, hosted at ThFree Co, Russian Federation.

github.com/FastLED/FastLED.git - Unnamed repository; edit this file 'description' to name the repository.
summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
Diffstat (limited to 'src/platforms/arm/d51')
-rw-r--r--src/platforms/arm/d51/README.txt5
-rw-r--r--src/platforms/arm/d51/fastled_arm_d51.h1
-rw-r--r--src/platforms/arm/d51/fastpin_arm_d51.h18
-rw-r--r--src/platforms/arm/d51/led_sysdefs_arm_d51.h4
4 files changed, 24 insertions, 4 deletions
diff --git a/src/platforms/arm/d51/README.txt b/src/platforms/arm/d51/README.txt
index b00fb670..036a02a6 100644
--- a/src/platforms/arm/d51/README.txt
+++ b/src/platforms/arm/d51/README.txt
@@ -1,4 +1,7 @@
FastLED updates for adafruit FEATHER M4 and fixes to ITSBITSY M4 compiles
SAMD51
-only tested on FEATHER M4 with DOTSTAR and neopixel strips
+Tested on
+ - FEATHER M4 with DOTSTAR and neopixel strips
+ - Seeed Wio Terminal and WS2812B and APA102 LED strips using either SPI or GPIO pins
+
diff --git a/src/platforms/arm/d51/fastled_arm_d51.h b/src/platforms/arm/d51/fastled_arm_d51.h
index 0c14bf2f..912a9018 100644
--- a/src/platforms/arm/d51/fastled_arm_d51.h
+++ b/src/platforms/arm/d51/fastled_arm_d51.h
@@ -2,6 +2,7 @@
#define __INC_FASTLED_ARM_D51_H
#include "fastpin_arm_d51.h"
+#include "../../fastspi_ardunio_core.h"
#include "clockless_arm_d51.h"
#endif
diff --git a/src/platforms/arm/d51/fastpin_arm_d51.h b/src/platforms/arm/d51/fastpin_arm_d51.h
index e4483aff..6fb5682f 100644
--- a/src/platforms/arm/d51/fastpin_arm_d51.h
+++ b/src/platforms/arm/d51/fastpin_arm_d51.h
@@ -128,6 +128,24 @@ _FL_DEFPIN(23, 22, 1); _FL_DEFPIN(24, 23, 1); _FL_DEFPIN(25, 17, 0);
#define HAS_HARDWARE_PIN_SUPPORT 1
+#elif defined(SEEED_WIO_TERMINAL)
+
+#define MAX_PIN 9
+// D0/A0-D8/A8
+_FL_DEFPIN( 0, 8, 1); _FL_DEFPIN( 1, 9, 1); _FL_DEFPIN( 2, 7, 0); _FL_DEFPIN( 3, 4, 1);
+_FL_DEFPIN( 4, 5, 1); _FL_DEFPIN( 5, 6, 1); _FL_DEFPIN( 6, 4, 0); _FL_DEFPIN( 7, 7, 1);
+_FL_DEFPIN( 8, 6, 0);
+// SDA/SCL
+_FL_DEFPIN(12, 17, 0); _FL_DEFPIN(13, 16, 0);
+// match GPIO pin nubers 9..11 MISO/MOSI/SCK
+_FL_DEFPIN(PIN_SPI_MISO, 0, 1); _FL_DEFPIN(PIN_SPI_MOSI, 2, 1); _FL_DEFPIN(PIN_SPI_SCK, 3, 1);
+
+#define SPI_DATA PIN_SPI_MOSI
+#define SPI_CLOCK PIN_SPI_SCK
+
+#define ARDUNIO_CORE_SPI
+#define HAS_HARDWARE_PIN_SUPPORT 1
+
#elif defined(ADAFRUIT_MATRIXPORTAL_M4_EXPRESS)
#define MAX_PIN 21
diff --git a/src/platforms/arm/d51/led_sysdefs_arm_d51.h b/src/platforms/arm/d51/led_sysdefs_arm_d51.h
index fd6a25e2..77726fa2 100644
--- a/src/platforms/arm/d51/led_sysdefs_arm_d51.h
+++ b/src/platforms/arm/d51/led_sysdefs_arm_d51.h
@@ -3,8 +3,6 @@
#define FASTLED_ARM
-// Note this is an M4, not an M0+, but this enables the shared m0clockless.h
-#define FASTLED_ARM_M0_PLUS
#ifndef INTERRUPT_THRESHOLD
#define INTERRUPT_THRESHOLD 1
@@ -12,7 +10,7 @@
// Default to allowing interrupts
#ifndef FASTLED_ALLOW_INTERRUPTS
-#define FASTLED_ALLOW_INTERRUPTS 0
+#define FASTLED_ALLOW_INTERRUPTS 1
#endif
#if FASTLED_ALLOW_INTERRUPTS == 1