From f0ea93b08c7bd1fecf6d12e48624207d6fadbd17 Mon Sep 17 00:00:00 2001 From: sq5gvm Date: Fri, 4 Jan 2019 20:48:43 +0100 Subject: [PATCH] Support for newer AL-LC02 boards with different pinout. --- code/espurna/config/hardware.h | 20 ++++++++++++++++++++ code/platformio.ini | 25 +++++++++++++++++++++++++ 2 files changed, 45 insertions(+) diff --git a/code/espurna/config/hardware.h b/code/espurna/config/hardware.h index 92ac23a8..9e662e0d 100644 --- a/code/espurna/config/hardware.h +++ b/code/espurna/config/hardware.h @@ -1637,6 +1637,26 @@ #define LIGHT_CH3_INVERSE 0 #define LIGHT_CH4_INVERSE 0 +#elif defined(ARILUX_AL_LC02V14) + + // Info + #define MANUFACTURER "ARILUX" + #define DEVICE "AL_LC02V14" + #define RELAY_PROVIDER RELAY_PROVIDER_LIGHT + #define LIGHT_PROVIDER LIGHT_PROVIDER_DIMMER + #define DUMMY_RELAY_COUNT 1 + + // Light + #define LIGHT_CHANNELS 4 + #define LIGHT_CH1_PIN 14 // RED + #define LIGHT_CH2_PIN 5 // GREEN + #define LIGHT_CH3_PIN 12 // BLUE + #define LIGHT_CH4_PIN 13 // WHITE1 + #define LIGHT_CH1_INVERSE 0 + #define LIGHT_CH2_INVERSE 0 + #define LIGHT_CH3_INVERSE 0 + #define LIGHT_CH4_INVERSE 0 + #elif defined(ARILUX_AL_LC06) // Info diff --git a/code/platformio.ini b/code/platformio.ini index f4543225..66908c5f 100644 --- a/code/platformio.ini +++ b/code/platformio.ini @@ -1404,6 +1404,31 @@ upload_flags = ${common.upload_flags} monitor_speed = ${common.monitor_speed} extra_scripts = ${common.extra_scripts} +[env:arilux-al-lc02v14] +platform = ${common.platform} +framework = ${common.framework} +board = ${common.board_1m} +board_build.flash_mode = ${common.flash_mode} +lib_deps = ${common.lib_deps} +lib_ignore = ${common.lib_ignore} +build_flags = ${common.build_flags_1m0m} -DARILUX_AL_LC02V14 +monitor_speed = ${common.monitor_speed} +extra_scripts = ${common.extra_scripts} + +[env:arilux-al-lc02v14-ota] +platform = ${common.platform} +framework = ${common.framework} +board = ${common.board_1m} +board_build.flash_mode = ${common.flash_mode} +lib_deps = ${common.lib_deps} +lib_ignore = ${common.lib_ignore} +build_flags = ${common.build_flags_1m0m} -DARILUX_AL_LC02V14 +upload_speed = ${common.upload_speed} +upload_port = ${common.upload_port} +upload_flags = ${common.upload_flags} +monitor_speed = ${common.monitor_speed} +extra_scripts = ${common.extra_scripts} + [env:arilux-al-lc06] platform = ${common.platform} framework = ${common.framework}