From bd8c3f673910f1aec164604b7095ff1dc5ab418b Mon Sep 17 00:00:00 2001 From: David Madison Date: Thu, 18 Oct 2018 18:19:00 -0400 Subject: [PATCH] Adds APA102 to CI --- .travis.yml | 5 ++++- Arduino/LEDstream_FastLED/LEDstream_FastLED.ino | 5 +++++ 2 files changed, 9 insertions(+), 1 deletion(-) diff --git a/.travis.yml b/.travis.yml index 1aae66b..eff5962 100644 --- a/.travis.yml +++ b/.travis.yml @@ -5,6 +5,9 @@ env: matrix: include: - name: "WS2812B" + env: BUILD_FLAGS="-DDEBUG_CI -DLED_CHIPSET=WS2812B" + - name: "APA102" + env: BUILD_FLAGS="-DDEBUG_CI -DLED_CHIPSET=APA102 -DPIN_CLOCK=7" before_install: - "/sbin/start-stop-daemon --start --quiet --pidfile /tmp/custom_xvfb_1.pid --make-pidfile --background --exec /usr/bin/Xvfb -- :1 -ac -screen 0 1280x1024x16" @@ -24,7 +27,7 @@ before_install: - CYAN="\033[36m"; YELLOW="\033[33m"; NOC="\033[0m"; - buildSketchPath() { echo -e "\n${CYAN}Building sketch ${1##*/}${NOC}"; - arduino --verify --board $BOARD "$1"; + arduino --verify --board $BOARD --pref build.extra_flags="$BUILD_FLAGS" "$1"; } - buildAllSketches() { for f in $(find $PWD -name '*.ino'); diff --git a/Arduino/LEDstream_FastLED/LEDstream_FastLED.ino b/Arduino/LEDstream_FastLED/LEDstream_FastLED.ino index d53f816..911f8e0 100644 --- a/Arduino/LEDstream_FastLED/LEDstream_FastLED.ino +++ b/Arduino/LEDstream_FastLED/LEDstream_FastLED.ino @@ -93,6 +93,11 @@ static unsigned long lastAckTime; // Debug macros initialized +#ifdef DEBUG_CI +#undef LED_TYPE +#define LED_TYPE LED_CHIPSET // Use command line chipset definition +#endif + #ifdef DEBUG_LED #define ON 1 #define OFF 0