From 4d978a46ac68826a79bb28df0b57170adc3faffd Mon Sep 17 00:00:00 2001 From: Marcus Winkler Date: Mon, 13 Jan 2020 12:06:13 +0100 Subject: [PATCH] Add support for Teckin SB53 smart bulb (#2090) --- code/espurna/config/arduino.h | 1 + code/espurna/config/hardware.h | 19 +++++++++++++++++++ code/platformio.ini | 10 ++++++++++ 3 files changed, 30 insertions(+) diff --git a/code/espurna/config/arduino.h b/code/espurna/config/arduino.h index decdb899..76fc1f44 100644 --- a/code/espurna/config/arduino.h +++ b/code/espurna/config/arduino.h @@ -102,6 +102,7 @@ //#define LITESUN_LA_WF3 //#define LOHAS_E27_9W //#define LOHAS_E26_A19 +//#define TECKIN_SB53 //#define LOMBEX_LUX_NOVA2_TUNABLE_WHITE //#define LOMBEX_LUX_NOVA2_WHITE_COLOR //#define LUANI_HVIO diff --git a/code/espurna/config/hardware.h b/code/espurna/config/hardware.h index 77c550e7..dc969d1f 100644 --- a/code/espurna/config/hardware.h +++ b/code/espurna/config/hardware.h @@ -3432,6 +3432,25 @@ // ----------------------------------------------------------------------------- +#elif defined(TECKIN_SB53) + + // Info + #define MANUFACTURER "TECKIN" + #define DEVICE "SB53" + #define RELAY_PROVIDER RELAY_PROVIDER_LIGHT + #define LIGHT_PROVIDER LIGHT_PROVIDER_DIMMER + #define DUMMY_RELAY_COUNT 1 + + // Light + #define LIGHT_CHANNELS 5 + #define LIGHT_CH1_PIN 4 // RED + #define LIGHT_CH2_PIN 12 // GREEN + #define LIGHT_CH3_PIN 14 // BLUE + #define LIGHT_CH4_PIN 13 // WARM WHITE + #define LIGHT_CH5_PIN 5 // COLD WHITE + +// ----------------------------------------------------------------------------- + #elif defined(XIAOMI_SMART_DESK_LAMP) // Info diff --git a/code/platformio.ini b/code/platformio.ini index e33f3f18..e52ea639 100644 --- a/code/platformio.ini +++ b/code/platformio.ini @@ -1486,6 +1486,16 @@ build_flags = ${common.build_flags_1m0m} -DLOHAS_E26_A19 upload_port = ${common.ota_upload_port} upload_flags = ${common.ota_upload_flags} +[env:teckin-sb53] +board = ${common.board_1m} +build_flags = ${common.build_flags_1m0m} -DTECKIN_SB53 + +[env:teckin-sb53-ota] +board = ${common.board_1m} +build_flags = ${common.build_flags_1m0m} -DTECKIN_SB53 +upload_port = ${common.ota_upload_port} +upload_flags = ${common.ota_upload_flags} + [env:allterco-shelly1] board = ${common.board_2m} build_flags = ${common.build_flags_2m1m} -DALLTERCO_SHELLY1