Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Add Support - MAGICHOME zj-lb-rgbw-i RGBW LED BULB #1674

Open
wants to merge 1 commit into
base: dev
Choose a base branch
from
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
1 change: 1 addition & 0 deletions code/espurna/config/arduino.h
Original file line number Diff line number Diff line change
Expand Up @@ -92,6 +92,7 @@
//#define LYASI_LIGHT
//#define MAGICHOME_LED_CONTROLLER
//#define MAGICHOME_LED_CONTROLLER_20
//#define MAGICHOME_ZJ_LB_RGBW_I
//#define MAGICHOME_ZJ_WFMN_A_11
//#define MAGICHOME_ZJ_WFMN_B_11
//#define MANCAVEMADE_ESPLIVE
Expand Down
24 changes: 24 additions & 0 deletions code/espurna/config/hardware.h
Original file line number Diff line number Diff line change
Expand Up @@ -1235,6 +1235,30 @@
#define IR_RX_PIN 4
#define IR_BUTTON_SET 1

// -----------------------------------------------------------------------------
// MAGICHOME ZJ-LB-RGBW-I VL1 RGBW LED BULB
// -----------------------------------------------------------------------------

#elif defined(MAGICHOME_ZJ_LB_RGBW_I)

// Info
#define MANUFACTURER "MAGICHOME"
#define DEVICE "ZJ-LB-RGBW-I VL1"
#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 5 // RED
#define LIGHT_CH2_PIN 14 // GREEN
#define LIGHT_CH3_PIN 12 // BLUE
#define LIGHT_CH4_PIN 13 // WHITE
#define LIGHT_CH1_INVERSE 0
#define LIGHT_CH2_INVERSE 0
#define LIGHT_CH3_INVERSE 0
#define LIGHT_CH4_INVERSE 0

#elif defined(MAGICHOME_ZJ_WFMN_A_11)

// Info
Expand Down
24 changes: 24 additions & 0 deletions code/platformio.ini
Original file line number Diff line number Diff line change
Expand Up @@ -1329,6 +1329,30 @@ upload_flags = ${common.upload_flags}
monitor_speed = ${common.monitor_speed}
extra_scripts = ${common.extra_scripts}

[env:magichome-zj-lb-rgbw-i]
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} -DMAGICHOME_ZJ_LB_RGBW_I
monitor_speed = ${common.monitor_speed}
extra_scripts = ${common.extra_scripts}

[env:magichome-zj-lb-rgbw-i-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} -DMAGICHOME_ZJ_LB_RGBW_I
monitor_speed = ${common.monitor_speed}
upload_port = ${common.upload_port}
upload_flags = ${common.upload_flags}
extra_scripts = ${common.extra_scripts}

[env:magichome-zj-wfmn-a-11]
platform = ${common.platform}
framework = ${common.framework}
Expand Down