Skip to content

Commit

Permalink
chore: ws2812 support to comply with EdgeTX#5232 style (EdgeTX#5276)
Browse files Browse the repository at this point in the history
  • Loading branch information
3djc authored Jul 13, 2024
1 parent 195f039 commit fad6f44
Show file tree
Hide file tree
Showing 5 changed files with 4 additions and 11 deletions.
1 change: 1 addition & 0 deletions radio/src/boards/generic_stm32/CMakeLists.txt
Original file line number Diff line number Diff line change
Expand Up @@ -31,6 +31,7 @@ set(BOARD_LIB_SRC
boards/generic_stm32/analog_inputs.cpp
boards/generic_stm32/switches.cpp
boards/generic_stm32/bor_level.cpp
boards/generic_stm32/rgb_leds.cpp
)

add_library(minimal_board_lib OBJECT EXCLUDE_FROM_ALL ${MINIMAL_BOARD_LIB_SRC})
Expand Down
1 change: 1 addition & 0 deletions radio/src/targets/horus/CMakeLists.txt
Original file line number Diff line number Diff line change
Expand Up @@ -294,6 +294,7 @@ add_library(board OBJECT EXCLUDE_FROM_ALL
targets/common/arm/stm32/stm32_softserial_driver.cpp
targets/common/arm/stm32/stm32_switch_driver.cpp
targets/common/arm/stm32/trainer_driver.cpp
targets/common/arm/stm32/stm32_ws2812.cpp
)
set(FIRMWARE_SRC ${FIRMWARE_SRC} $<TARGET_OBJECTS:board>)

Expand Down
1 change: 1 addition & 0 deletions radio/src/targets/nv14/CMakeLists.txt
Original file line number Diff line number Diff line change
Expand Up @@ -135,6 +135,7 @@ add_library(board OBJECT EXCLUDE_FROM_ALL
targets/common/arm/stm32/stm32_switch_driver.cpp
targets/common/arm/stm32/trainer_driver.cpp
targets/common/arm/stm32/vs1053b.cpp
targets/common/arm/stm32/stm32_ws2812.cpp
)
set(FIRMWARE_SRC ${FIRMWARE_SRC} $<TARGET_OBJECTS:board>)

Expand Down
1 change: 0 additions & 1 deletion radio/src/targets/pl18/CMakeLists.txt
Original file line number Diff line number Diff line change
Expand Up @@ -145,7 +145,6 @@ add_library(board OBJECT EXCLUDE_FROM_ALL
targets/common/arm/stm32/trainer_driver.cpp
targets/common/arm/stm32/spi_flash.cpp
targets/common/arm/stm32/diskio_spi_flash.cpp
boards/generic_stm32/rgb_leds.cpp
drivers/frftl.cpp
)
set(FIRMWARE_SRC ${FIRMWARE_SRC} $<TARGET_OBJECTS:board>)
Expand Down
11 changes: 1 addition & 10 deletions radio/src/targets/taranis/CMakeLists.txt
Original file line number Diff line number Diff line change
Expand Up @@ -7,7 +7,6 @@ option(INTERNAL_MODULE_PPM "Support for PPM internal module" OFF)
option(AUTOUPDATE "Auto update internal chips from SD" OFF)
option(BIND_KEY "Enable bind button" OFF)
option(BLUETOOTH "FrSky BT module support" OFF)
option(WS2812 "Support for ws2812 RGB leds" OFF)

set(USE_RTC_CLOCK YES)
set(HARDWARE_EXTERNAL_MODULE YES)
Expand Down Expand Up @@ -148,7 +147,6 @@ elseif(PCB STREQUAL X7)
set(DEFAULT_INTERNAL_MODULE CROSSFIRE CACHE STRING "Default internal module")
set(INTERNAL_MODULE_SERIAL YES)
set(MODULE_SIZE_SML YES)
set(WS2812 YES)
set(FLAVOUR t14)
set(ROTARY_ENCODER YES)
set(CPU_TYPE_FULL STM32F407xG)
Expand Down Expand Up @@ -262,7 +260,6 @@ elseif(PCB STREQUAL X7)
set(CPU_TYPE_FULL STM32F407xG)
set(ROTARY_ENCODER YES)
set(BLUETOOTH NO)
set(WS2812 YES)
set(USB_CHARGER YES)
set(HELI NO)
add_definitions(-DRADIO_MT12)
Expand Down Expand Up @@ -573,6 +570,7 @@ add_library(board OBJECT EXCLUDE_FROM_ALL
targets/common/arm/stm32/stm32_softserial_driver.cpp
targets/common/arm/stm32/stm32_switch_driver.cpp
targets/common/arm/stm32/trainer_driver.cpp
targets/common/arm/stm32/stm32_ws2812.cpp
)
set(FIRMWARE_SRC ${FIRMWARE_SRC} $<TARGET_OBJECTS:board>)

Expand Down Expand Up @@ -626,13 +624,6 @@ if(PCB STREQUAL XLITE OR PCB STREQUAL XLITES OR PCBREV STREQUAL COMMANDO8)
targets/common/arm/stm32/sticks_pwm_driver.cpp)
endif()

if(WS2812)
set(FIRMWARE_SRC
${FIRMWARE_SRC}
targets/common/arm/stm32/stm32_ws2812.cpp
boards/generic_stm32/rgb_leds.cpp)
endif()

set(FIRMWARE_SRC
${FIRMWARE_SRC}
targets/common/arm/loadboot.cpp
Expand Down

0 comments on commit fad6f44

Please sign in to comment.