Skip to content

Commit

Permalink
feather-nrf52840: add config for NeoPixel LED
Browse files Browse the repository at this point in the history
  • Loading branch information
miri64 committed Nov 21, 2024
1 parent 7832253 commit 5dd5400
Show file tree
Hide file tree
Showing 2 changed files with 16 additions and 0 deletions.
1 change: 1 addition & 0 deletions boards/feather-nrf52840/Makefile.dep
Original file line number Diff line number Diff line change
@@ -1,5 +1,6 @@
ifneq (,$(filter saul_default,$(USEMODULE)))
USEMODULE += saul_gpio
USEMODULE += ws281x
endif

# include common nrf52 dependencies
Expand Down
15 changes: 15 additions & 0 deletions boards/feather-nrf52840/include/board.h
Original file line number Diff line number Diff line change
Expand Up @@ -57,6 +57,21 @@ extern "C" {
#define BTN0_MODE GPIO_IN_PU
/** @} */

/**
* @name WS281x RGB LEDs configuration
* @{
*/
#ifndef WS281X_PARAM_PIN
/**
* @brief GPIO pin connected to the data pin of the first LED
*/
#define WS281X_PARAM_PIN GPIO_PIN(0, 16)
#endif
#ifndef WS281X_PARAM_NUMOF
#define WS281X_PARAM_NUMOF (1U) /**< Number of LEDs chained */
#endif
/** @} */

#ifdef __cplusplus
}
#endif
Expand Down

0 comments on commit 5dd5400

Please sign in to comment.