Browse Source

WS2812 PWM: prefix for DMA defines (#23111)

* WS2812 PWM: prefix for DMA defines

* Add backward compatibility defines
pull/23206/head
Ryan 2 months ago
committed by GitHub
parent
commit
569b0c70be
No known key found for this signature in database GPG Key ID: B5690EEEBB952194
98 changed files with 246 additions and 234 deletions
  1. +3
    -3
      docs/ws2812_driver.md
  2. +2
    -2
      keyboards/acheron/apollo/87h/delta/config.h
  3. +2
    -2
      keyboards/acheron/apollo/87htsc/config.h
  4. +2
    -2
      keyboards/acheron/apollo/88htsc/config.h
  5. +2
    -2
      keyboards/acheron/athena/alpha/config.h
  6. +2
    -2
      keyboards/acheron/athena/beta/config.h
  7. +2
    -2
      keyboards/acheron/shark/beta/config.h
  8. +2
    -2
      keyboards/acheron/themis/87h/config.h
  9. +2
    -2
      keyboards/acheron/themis/87htsc/config.h
  10. +2
    -2
      keyboards/acheron/themis/88htsc/config.h
  11. +2
    -2
      keyboards/artifact/lvl/rev_hs01/config.h
  12. +2
    -2
      keyboards/aurora65/config.h
  13. +2
    -2
      keyboards/bastardkb/charybdis/3x5/blackpill/config.h
  14. +2
    -2
      keyboards/bastardkb/charybdis/3x5/v2/stemcell/config.h
  15. +2
    -2
      keyboards/bastardkb/charybdis/3x6/blackpill/config.h
  16. +2
    -2
      keyboards/bastardkb/charybdis/3x6/v2/stemcell/config.h
  17. +2
    -2
      keyboards/bastardkb/charybdis/4x6/blackpill/config.h
  18. +2
    -2
      keyboards/bastardkb/charybdis/4x6/v2/stemcell/config.h
  19. +2
    -2
      keyboards/bastardkb/scylla/blackpill/config.h
  20. +2
    -2
      keyboards/bastardkb/scylla/v2/stemcell/config.h
  21. +2
    -2
      keyboards/bastardkb/skeletyl/blackpill/config.h
  22. +2
    -2
      keyboards/bastardkb/skeletyl/v2/stemcell/config.h
  23. +2
    -2
      keyboards/bastardkb/tbkmini/blackpill/config.h
  24. +2
    -2
      keyboards/bastardkb/tbkmini/v2/stemcell/config.h
  25. +2
    -2
      keyboards/bestway/config.h
  26. +2
    -2
      keyboards/black_hellebore/config.h
  27. +2
    -2
      keyboards/crypt_macro/config.h
  28. +2
    -2
      keyboards/custommk/evo70_r2/config.h
  29. +2
    -2
      keyboards/ebastler/isometria_75/rev1/config.h
  30. +2
    -2
      keyboards/edi/hardlight/mk2/config.h
  31. +2
    -2
      keyboards/geekboards/macropad_v2/config.h
  32. +2
    -2
      keyboards/handwired/cyberstar/config.h
  33. +2
    -2
      keyboards/handwired/macroboard/config.h
  34. +2
    -2
      keyboards/handwired/tractyl_manuform/5x6_right/f303/config.h
  35. +2
    -2
      keyboards/handwired/tractyl_manuform/5x6_right/f411/config.h
  36. +2
    -2
      keyboards/jacky_studio/piggy60/rev2/config.h
  37. +2
    -2
      keyboards/kabedon/kabedon98e/config.h
  38. +2
    -2
      keyboards/kprepublic/bm16a/v2/config.h
  39. +2
    -2
      keyboards/linworks/whale75/config.h
  40. +2
    -2
      keyboards/loki65/config.h
  41. +3
    -3
      keyboards/mariorion_v25/prod/config.h
  42. +3
    -3
      keyboards/mariorion_v25/proto/config.h
  43. +2
    -2
      keyboards/meetlab/kalice/config.h
  44. +2
    -2
      keyboards/meetlab/rena/config.h
  45. +2
    -2
      keyboards/misterknife/knife66/config.h
  46. +2
    -2
      keyboards/misterknife/knife66_iso/config.h
  47. +2
    -2
      keyboards/mode/m256wh/config.h
  48. +2
    -2
      keyboards/mode/m256ws/config.h
  49. +2
    -2
      keyboards/mode/m60h/config.h
  50. +2
    -2
      keyboards/mode/m60h_f/config.h
  51. +2
    -2
      keyboards/mode/m60s/config.h
  52. +2
    -2
      keyboards/mwstudio/mmk_3/config.h
  53. +2
    -2
      keyboards/mwstudio/mw660/config.h
  54. +2
    -2
      keyboards/novelkeys/nk20/config.h
  55. +2
    -2
      keyboards/novelkeys/nk65b/config.h
  56. +2
    -2
      keyboards/novelkeys/nk87b/config.h
  57. +2
    -2
      keyboards/novelkeys/nk_plus/config.h
  58. +2
    -2
      keyboards/planck/ez/config.h
  59. +2
    -2
      keyboards/planck/rev6/config.h
  60. +2
    -2
      keyboards/planck/rev6_drop/config.h
  61. +2
    -2
      keyboards/planck/rev7/config.h
  62. +2
    -2
      keyboards/preonic/rev3/config.h
  63. +2
    -2
      keyboards/preonic/rev3_drop/config.h
  64. +2
    -2
      keyboards/protozoa/p01/config.h
  65. +2
    -2
      keyboards/rgbkb/mun/config.h
  66. +2
    -2
      keyboards/rgbkb/sol3/config.h
  67. +2
    -2
      keyboards/skyloong/dt40/config.h
  68. +2
    -2
      keyboards/smithrune/iron165r2/f411/config.h
  69. +2
    -2
      keyboards/smithrune/magnus/m75h/config.h
  70. +2
    -2
      keyboards/smithrune/magnus/m75s/config.h
  71. +2
    -2
      keyboards/spaceholdings/nebula68/config.h
  72. +3
    -3
      keyboards/splitkb/kyria/rev1/config.h
  73. +3
    -3
      keyboards/splitkb/kyria/rev2/config.h
  74. +2
    -2
      keyboards/tg67/config.h
  75. +2
    -2
      keyboards/tkw/grandiceps/config.h
  76. +2
    -2
      keyboards/tkw/stoutgat/v2/config.h
  77. +3
    -3
      keyboards/tzarc/djinn/config.h
  78. +2
    -2
      keyboards/tzarc/ghoul/rev1/stm32/config.h
  79. +2
    -2
      keyboards/viendi8l/config.h
  80. +2
    -2
      keyboards/vinhcatba/uncertainty/config.h
  81. +2
    -2
      keyboards/xelus/ninjin/config.h
  82. +3
    -3
      keyboards/xelus/valor/rev2/config.h
  83. +2
    -2
      keyboards/yandrstudio/buff67v3/config.h
  84. +2
    -2
      keyboards/yandrstudio/eau_r2/config.h
  85. +2
    -2
      keyboards/yandrstudio/nightstar75/config.h
  86. +2
    -2
      keyboards/yandrstudio/nz64/config.h
  87. +2
    -2
      keyboards/yandrstudio/nz67v2/config.h
  88. +2
    -2
      keyboards/yandrstudio/tg67/config.h
  89. +2
    -2
      keyboards/yandrstudio/yr6095/config.h
  90. +2
    -2
      keyboards/yandrstudio/yr80/config.h
  91. +2
    -2
      keyboards/yanghu/unicorne/config.h
  92. +2
    -2
      keyboards/ymdk/id75/config.h
  93. +2
    -2
      keyboards/ymdk/ymd75/rev4/iso/config.h
  94. +2
    -2
      keyboards/zvecr/split_blackpill/config.h
  95. +2
    -2
      keyboards/zvecr/zv48/config.h
  96. +4
    -4
      platforms/chibios/boards/BONSAI_C4/configs/config.h
  97. +9
    -9
      platforms/chibios/drivers/vendor/RP/RP2040/ws2812_vendor.c
  98. +36
    -24
      platforms/chibios/drivers/ws2812_pwm.c

+ 3
- 3
docs/ws2812_driver.md View File

@ -208,9 +208,9 @@ The following `#define`s apply only to the `pwm` driver:
|`WS2812_PWM_DRIVER` |`PWMD2` |The PWM driver to use |
|`WS2812_PWM_CHANNEL` |`2` |The PWM channel to use |
|`WS2812_PWM_PAL_MODE` |`2` |The pin alternative function to use |
|`WS2812_DMA_STREAM` |`STM32_DMA1_STREAM2`|The DMA Stream for `TIMx_UP` |
|`WS2812_DMA_CHANNEL` |`2` |The DMA Channel for `TIMx_UP` |
|`WS2812_DMAMUX_ID` |*Not defined* |The DMAMUX configuration for `TIMx_UP` - only required if your MCU has a DMAMUX peripheral|
|`WS2812_PWM_DMA_STREAM` |`STM32_DMA1_STREAM2`|The DMA Stream for `TIMx_UP` |
|`WS2812_PWM_DMA_CHANNEL` |`2` |The DMA Channel for `TIMx_UP` |
|`WS2812_PWM_DMAMUX_ID` |*Not defined* |The DMAMUX configuration for `TIMx_UP` - only required if your MCU has a DMAMUX peripheral|
|`WS2812_PWM_COMPLEMENTARY_OUTPUT`|*Not defined* |Whether the PWM output is complementary (`TIMx_CHyN`) |
?> Using a complementary timer output (`TIMx_CHyN`) is possible only for advanced-control timers (1, 8 and 20 on STM32), and the `STM32_PWM_USE_ADVANCED` option in `mcuconf.h` must be set to `TRUE`. Complementary outputs of general-purpose timers are not supported due to ChibiOS limitations.


+ 2
- 2
keyboards/acheron/apollo/87h/delta/config.h View File

@ -28,5 +28,5 @@ along with this program. If not, see <http://www.gnu.org/licenses/>.
#define WS2812_PWM_DRIVER PWMD1
#define WS2812_PWM_CHANNEL 3
#define WS2812_PWM_PAL_MODE 1
#define WS2812_DMA_STREAM STM32_DMA2_STREAM5
#define WS2812_DMA_CHANNEL 6
#define WS2812_PWM_DMA_STREAM STM32_DMA2_STREAM5
#define WS2812_PWM_DMA_CHANNEL 6

+ 2
- 2
keyboards/acheron/apollo/87htsc/config.h View File

@ -28,5 +28,5 @@ along with this program. If not, see <http://www.gnu.org/licenses/>.
#define WS2812_PWM_DRIVER PWMD1
#define WS2812_PWM_CHANNEL 3
#define WS2812_PWM_PAL_MODE 1
#define WS2812_DMA_STREAM STM32_DMA2_STREAM5
#define WS2812_DMA_CHANNEL 6
#define WS2812_PWM_DMA_STREAM STM32_DMA2_STREAM5
#define WS2812_PWM_DMA_CHANNEL 6

+ 2
- 2
keyboards/acheron/apollo/88htsc/config.h View File

@ -28,5 +28,5 @@ along with this program. If not, see <http://www.gnu.org/licenses/>.
#define WS2812_PWM_DRIVER PWMD1
#define WS2812_PWM_CHANNEL 3
#define WS2812_PWM_PAL_MODE 1
#define WS2812_DMA_STREAM STM32_DMA2_STREAM5
#define WS2812_DMA_CHANNEL 6
#define WS2812_PWM_DMA_STREAM STM32_DMA2_STREAM5
#define WS2812_PWM_DMA_CHANNEL 6

+ 2
- 2
keyboards/acheron/athena/alpha/config.h View File

@ -27,8 +27,8 @@ along with this program. If not, see <http://www.gnu.org/licenses/>.
#define WS2812_PWM_DRIVER PWMD1
#define WS2812_PWM_CHANNEL 3
#define WS2812_PWM_PAL_MODE 1
#define WS2812_DMA_STREAM STM32_DMA2_STREAM5
#define WS2812_DMA_CHANNEL 6
#define WS2812_PWM_DMA_STREAM STM32_DMA2_STREAM5
#define WS2812_PWM_DMA_CHANNEL 6
// If this is defined, the caps lock LED will turn on and off according to the state of caps lock. If not, the LED will shine like all other LEDs despite the caps lock state.
#define CAPSLOCK_INDICATOR

+ 2
- 2
keyboards/acheron/athena/beta/config.h View File

@ -28,8 +28,8 @@ along with this program. If not, see <http://www.gnu.org/licenses/>.
#define WS2812_PWM_DRIVER PWMD1
#define WS2812_PWM_CHANNEL 3
#define WS2812_PWM_PAL_MODE 1
#define WS2812_DMA_STREAM STM32_DMA2_STREAM5
#define WS2812_DMA_CHANNEL 6
#define WS2812_PWM_DMA_STREAM STM32_DMA2_STREAM5
#define WS2812_PWM_DMA_CHANNEL 6
// If this is defined, the caps lock LED will turn on and off according to the state of caps lock. If not, the LED will shine like all other LEDs despite the caps lock state.
#define CAPSLOCK_INDICATOR

+ 2
- 2
keyboards/acheron/shark/beta/config.h View File

@ -27,7 +27,7 @@ along with this program. If not, see <http://www.gnu.org/licenses/>.
#define WS2812_PWM_DRIVER PWMD1
#define WS2812_PWM_CHANNEL 3
#define WS2812_PWM_PAL_MODE 1
#define WS2812_DMA_STREAM STM32_DMA2_STREAM5
#define WS2812_DMA_CHANNEL 6
#define WS2812_PWM_DMA_STREAM STM32_DMA2_STREAM5
#define WS2812_PWM_DMA_CHANNEL 6
#define EEPROM_I2C_24LC256

+ 2
- 2
keyboards/acheron/themis/87h/config.h View File

@ -24,5 +24,5 @@ along with this program. If not, see <http://www.gnu.org/licenses/>.
#define WS2812_PWM_DRIVER PWMD1
#define WS2812_PWM_CHANNEL 3
#define WS2812_PWM_PAL_MODE 1
#define WS2812_DMA_STREAM STM32_DMA2_STREAM5
#define WS2812_DMA_CHANNEL 6
#define WS2812_PWM_DMA_STREAM STM32_DMA2_STREAM5
#define WS2812_PWM_DMA_CHANNEL 6

+ 2
- 2
keyboards/acheron/themis/87htsc/config.h View File

@ -24,5 +24,5 @@ along with this program. If not, see <http://www.gnu.org/licenses/>.
#define WS2812_PWM_DRIVER PWMD1
#define WS2812_PWM_CHANNEL 3
#define WS2812_PWM_PAL_MODE 1
#define WS2812_DMA_STREAM STM32_DMA2_STREAM5
#define WS2812_DMA_CHANNEL 6
#define WS2812_PWM_DMA_STREAM STM32_DMA2_STREAM5
#define WS2812_PWM_DMA_CHANNEL 6

+ 2
- 2
keyboards/acheron/themis/88htsc/config.h View File

@ -24,5 +24,5 @@ along with this program. If not, see <http://www.gnu.org/licenses/>.
#define WS2812_PWM_DRIVER PWMD1
#define WS2812_PWM_CHANNEL 3
#define WS2812_PWM_PAL_MODE 1
#define WS2812_DMA_STREAM STM32_DMA2_STREAM5
#define WS2812_DMA_CHANNEL 6
#define WS2812_PWM_DMA_STREAM STM32_DMA2_STREAM5
#define WS2812_PWM_DMA_CHANNEL 6

+ 2
- 2
keyboards/artifact/lvl/rev_hs01/config.h View File

@ -19,7 +19,7 @@ along with this program. If not, see <http://www.gnu.org/licenses/>.
/* RGB Light */
#define WS2812_PWM_DRIVER PWMD1
#define WS2812_DMA_STREAM STM32_DMA1_STREAM5
#define WS2812_DMA_CHANNEL 5
#define WS2812_PWM_DMA_STREAM STM32_DMA1_STREAM5
#define WS2812_PWM_DMA_CHANNEL 5
#define WS2812_BYTE_ORDER WS2812_BYTE_ORDER_RGB

+ 2
- 2
keyboards/aurora65/config.h View File

@ -22,6 +22,6 @@ along with this program. If not, see <http://www.gnu.org/licenses/>.
#define WS2812_PWM_CHANNEL 3
#define WS2812_PWM_PAL_MODE 2
#define WS2812_PWM_COMPLEMENTARY_OUTPUT
#define WS2812_DMA_STREAM STM32_DMA1_STREAM5
#define WS2812_DMA_CHANNEL 5
#define WS2812_PWM_DMA_STREAM STM32_DMA1_STREAM5
#define WS2812_PWM_DMA_CHANNEL 5
#define WS2812_BYTE_ORDER WS2812_BYTE_ORDER_RGB

+ 2
- 2
keyboards/bastardkb/charybdis/3x5/blackpill/config.h View File

@ -27,8 +27,8 @@
#define WS2812_PWM_CHANNEL 2
#define WS2812_PWM_PAL_MODE 1
#define WS2812_EXTERNAL_PULLUP
#define WS2812_DMA_STREAM STM32_DMA1_STREAM1
#define WS2812_DMA_CHANNEL 3
#define WS2812_PWM_DMA_STREAM STM32_DMA1_STREAM1
#define WS2812_PWM_DMA_CHANNEL 3
#define WS2812_PWM_TARGET_PERIOD 800000
/* Serial configuration for split keyboard. */


+ 2
- 2
keyboards/bastardkb/charybdis/3x5/v2/stemcell/config.h View File

@ -30,8 +30,8 @@
#define WS2812_PWM_DRIVER PWMD2
#define WS2812_PWM_CHANNEL 4
#define WS2812_PWM_PAL_MODE 1
#define WS2812_DMA_STREAM STM32_DMA1_STREAM7
#define WS2812_DMA_CHANNEL 3
#define WS2812_PWM_DMA_STREAM STM32_DMA1_STREAM7
#define WS2812_PWM_DMA_CHANNEL 3
/* CRC. */
#define CRC8_USE_TABLE


+ 2
- 2
keyboards/bastardkb/charybdis/3x6/blackpill/config.h View File

@ -25,8 +25,8 @@
#define WS2812_PWM_CHANNEL 2
#define WS2812_PWM_PAL_MODE 1
#define WS2812_EXTERNAL_PULLUP
#define WS2812_DMA_STREAM STM32_DMA1_STREAM1
#define WS2812_DMA_CHANNEL 3
#define WS2812_PWM_DMA_STREAM STM32_DMA1_STREAM1
#define WS2812_PWM_DMA_CHANNEL 3
#define WS2812_PWM_TARGET_PERIOD 800000
/* Serial configuration for split keyboard. */


+ 2
- 2
keyboards/bastardkb/charybdis/3x6/v2/stemcell/config.h View File

@ -30,8 +30,8 @@
#define WS2812_PWM_DRIVER PWMD2
#define WS2812_PWM_CHANNEL 4
#define WS2812_PWM_PAL_MODE 1
#define WS2812_DMA_STREAM STM32_DMA1_STREAM7
#define WS2812_DMA_CHANNEL 3
#define WS2812_PWM_DMA_STREAM STM32_DMA1_STREAM7
#define WS2812_PWM_DMA_CHANNEL 3
/* CRC. */
#define CRC8_USE_TABLE


+ 2
- 2
keyboards/bastardkb/charybdis/4x6/blackpill/config.h View File

@ -27,8 +27,8 @@
#define WS2812_PWM_CHANNEL 2
#define WS2812_PWM_PAL_MODE 1
#define WS2812_EXTERNAL_PULLUP
#define WS2812_DMA_STREAM STM32_DMA1_STREAM1
#define WS2812_DMA_CHANNEL 3
#define WS2812_PWM_DMA_STREAM STM32_DMA1_STREAM1
#define WS2812_PWM_DMA_CHANNEL 3
#define WS2812_PWM_TARGET_PERIOD 800000
/* Serial configuration for split keyboard. */


+ 2
- 2
keyboards/bastardkb/charybdis/4x6/v2/stemcell/config.h View File

@ -30,8 +30,8 @@
#define WS2812_PWM_DRIVER PWMD2
#define WS2812_PWM_CHANNEL 4
#define WS2812_PWM_PAL_MODE 1
#define WS2812_DMA_STREAM STM32_DMA1_STREAM7
#define WS2812_DMA_CHANNEL 3
#define WS2812_PWM_DMA_STREAM STM32_DMA1_STREAM7
#define WS2812_PWM_DMA_CHANNEL 3
/* CRC. */
#define CRC8_USE_TABLE


+ 2
- 2
keyboards/bastardkb/scylla/blackpill/config.h View File

@ -27,8 +27,8 @@
#define WS2812_PWM_CHANNEL 2
#define WS2812_PWM_PAL_MODE 1
#define WS2812_EXTERNAL_PULLUP
#define WS2812_DMA_STREAM STM32_DMA1_STREAM1
#define WS2812_DMA_CHANNEL 3
#define WS2812_PWM_DMA_STREAM STM32_DMA1_STREAM1
#define WS2812_PWM_DMA_CHANNEL 3
#define WS2812_PWM_TARGET_PERIOD 800000
/* Serial configuration for split keyboard. */


+ 2
- 2
keyboards/bastardkb/scylla/v2/stemcell/config.h View File

@ -30,8 +30,8 @@
#define WS2812_PWM_DRIVER PWMD2
#define WS2812_PWM_CHANNEL 4
#define WS2812_PWM_PAL_MODE 1
#define WS2812_DMA_STREAM STM32_DMA1_STREAM7
#define WS2812_DMA_CHANNEL 3
#define WS2812_PWM_DMA_STREAM STM32_DMA1_STREAM7
#define WS2812_PWM_DMA_CHANNEL 3
/* CRC. */
#define CRC8_USE_TABLE


+ 2
- 2
keyboards/bastardkb/skeletyl/blackpill/config.h View File

@ -27,8 +27,8 @@
#define WS2812_PWM_CHANNEL 2
#define WS2812_PWM_PAL_MODE 1
#define WS2812_EXTERNAL_PULLUP
#define WS2812_DMA_STREAM STM32_DMA1_STREAM1
#define WS2812_DMA_CHANNEL 3
#define WS2812_PWM_DMA_STREAM STM32_DMA1_STREAM1
#define WS2812_PWM_DMA_CHANNEL 3
#define WS2812_PWM_TARGET_PERIOD 800000
/* Serial configuration for split keyboard. */


+ 2
- 2
keyboards/bastardkb/skeletyl/v2/stemcell/config.h View File

@ -30,8 +30,8 @@
#define WS2812_PWM_DRIVER PWMD2
#define WS2812_PWM_CHANNEL 4
#define WS2812_PWM_PAL_MODE 1
#define WS2812_DMA_STREAM STM32_DMA1_STREAM7
#define WS2812_DMA_CHANNEL 3
#define WS2812_PWM_DMA_STREAM STM32_DMA1_STREAM7
#define WS2812_PWM_DMA_CHANNEL 3
/* CRC. */
#define CRC8_USE_TABLE


+ 2
- 2
keyboards/bastardkb/tbkmini/blackpill/config.h View File

@ -27,8 +27,8 @@
#define WS2812_PWM_CHANNEL 2
#define WS2812_PWM_PAL_MODE 1
#define WS2812_EXTERNAL_PULLUP
#define WS2812_DMA_STREAM STM32_DMA1_STREAM1
#define WS2812_DMA_CHANNEL 3
#define WS2812_PWM_DMA_STREAM STM32_DMA1_STREAM1
#define WS2812_PWM_DMA_CHANNEL 3
#define WS2812_PWM_TARGET_PERIOD 800000
/* Serial configuration for split keyboard. */


+ 2
- 2
keyboards/bastardkb/tbkmini/v2/stemcell/config.h View File

@ -30,8 +30,8 @@
#define WS2812_PWM_DRIVER PWMD2
#define WS2812_PWM_CHANNEL 4
#define WS2812_PWM_PAL_MODE 1
#define WS2812_DMA_STREAM STM32_DMA1_STREAM7
#define WS2812_DMA_CHANNEL 3
#define WS2812_PWM_DMA_STREAM STM32_DMA1_STREAM7
#define WS2812_PWM_DMA_CHANNEL 3
/* CRC. */
#define CRC8_USE_TABLE


+ 2
- 2
keyboards/bestway/config.h View File

@ -18,5 +18,5 @@
#define WS2812_PWM_DRIVER PWMD2
#define WS2812_PWM_CHANNEL 4
#define WS2812_DMA_STREAM STM32_DMA1_STREAM2
#define WS2812_DMA_CHANNEL 2
#define WS2812_PWM_DMA_STREAM STM32_DMA1_STREAM2
#define WS2812_PWM_DMA_CHANNEL 2

+ 2
- 2
keyboards/black_hellebore/config.h View File

@ -20,5 +20,5 @@
#define WS2812_PWM_CHANNEL 1
#define WS2812_PWM_PAL_MODE 1 //TIM1_CH1N (AF1)
#define WS2812_PWM_COMPLEMENTARY_OUTPUT
#define WS2812_DMA_STREAM STM32_DMA1_STREAM6
#define WS2812_DMA_CHANNEL 7 //7 works, CxS[3:0] 0111 = TIM1_UP on Channel 6? (RM0394.pdf pg.298)
#define WS2812_PWM_DMA_STREAM STM32_DMA1_STREAM6
#define WS2812_PWM_DMA_CHANNEL 7 //7 works, CxS[3:0] 0111 = TIM1_UP on Channel 6? (RM0394.pdf pg.298)

+ 2
- 2
keyboards/crypt_macro/config.h View File

@ -24,6 +24,6 @@ along with this program. If not, see <http://www.gnu.org/licenses/>.
#define WS2812_PWM_DRIVER PWMD3
#define WS2812_PWM_CHANNEL 1
#define WS2812_PWM_PAL_MODE 1
#define WS2812_DMA_STREAM STM32_DMA1_STREAM3
#define WS2812_DMA_CHANNEL 3
#define WS2812_PWM_DMA_STREAM STM32_DMA1_STREAM3
#define WS2812_PWM_DMA_CHANNEL 3
#define WS2812_BYTE_ORDER WS2812_BYTE_ORDER_RGB

+ 2
- 2
keyboards/custommk/evo70_r2/config.h View File

@ -78,8 +78,8 @@
#define WS2812_PWM_DRIVER PWMD1
#define WS2812_PWM_CHANNEL 3
#define WS2812_PWM_PAL_MODE 1
#define WS2812_DMA_STREAM STM32_DMA2_STREAM5
#define WS2812_DMA_CHANNEL 6
#define WS2812_PWM_DMA_STREAM STM32_DMA2_STREAM5
#define WS2812_PWM_DMA_CHANNEL 6
#define TAP_CODE_DELAY 10


+ 2
- 2
keyboards/ebastler/isometria_75/rev1/config.h View File

@ -26,8 +26,8 @@ along with this program. If not, see <http://www.gnu.org/licenses/>.
#define WS2812_PWM_DRIVER PWMD2
#define WS2812_PWM_CHANNEL 2
#define WS2812_PWM_PAL_MODE 2
#define WS2812_DMA_STREAM STM32_DMA1_STREAM2
#define WS2812_DMA_CHANNEL 2
#define WS2812_PWM_DMA_STREAM STM32_DMA1_STREAM2
#define WS2812_PWM_DMA_CHANNEL 2
/* ADC - will be used for battery monitoring once BT support is added */
/* #define ADC_PIN B0 */

+ 2
- 2
keyboards/edi/hardlight/mk2/config.h View File

@ -28,8 +28,8 @@ along with this program. If not, see <http://www.gnu.org/licenses/>.
#define WS2812_PWM_DRIVER PWMD1
#define WS2812_PWM_CHANNEL 3
#define WS2812_PWM_PAL_MODE 2
#define WS2812_DMA_STREAM STM32_DMA1_STREAM5
#define WS2812_DMA_CHANNEL 3
#define WS2812_PWM_DMA_STREAM STM32_DMA1_STREAM5
#define WS2812_PWM_DMA_CHANNEL 3
#define WS2812_EXTERNAL_PULLUP
/* I2C driver overrides */


+ 2
- 2
keyboards/geekboards/macropad_v2/config.h View File

@ -19,7 +19,7 @@
#define WS2812_PWM_DRIVER PWMD3
#define WS2812_PWM_CHANNEL 2
#define WS2812_PWM_PAL_MODE 1
#define WS2812_DMA_STREAM STM32_DMA1_STREAM3
#define WS2812_DMA_CHANNEL 3
#define WS2812_PWM_DMA_STREAM STM32_DMA1_STREAM3
#define WS2812_PWM_DMA_CHANNEL 3
#define WAIT_FOR_USB

+ 2
- 2
keyboards/handwired/cyberstar/config.h View File

@ -24,6 +24,6 @@ along with this program. If not, see <http://www.gnu.org/licenses/>.
#define WS2812_PWM_DRIVER PWMD3
#define WS2812_PWM_CHANNEL 1
#define WS2812_PWM_PAL_MODE 1
#define WS2812_DMA_STREAM STM32_DMA1_STREAM3
#define WS2812_DMA_CHANNEL 3
#define WS2812_PWM_DMA_STREAM STM32_DMA1_STREAM3
#define WS2812_PWM_DMA_CHANNEL 3
#define WS2812_BYTE_ORDER WS2812_BYTE_ORDER_RGB

+ 2
- 2
keyboards/handwired/macroboard/config.h View File

@ -20,8 +20,8 @@ along with this program. If not, see <http://www.gnu.org/licenses/>.
#define WS2812_PWM_DRIVER PWMD4
#define WS2812_PWM_CHANNEL 4
#define WS2812_PWM_PAL_MODE 2
#define WS2812_DMA_STREAM STM32_DMA1_STREAM6 // DMA Stream for TIMx_UP, see the respective reference manual for the appropriate values for your MCU.
#define WS2812_DMA_CHANNEL 2 // DMA Channel for TIMx_UP, see the respective reference manual for the appropriate values for your MCU.
#define WS2812_PWM_DMA_STREAM STM32_DMA1_STREAM6 // DMA Stream for TIMx_UP, see the respective reference manual for the appropriate values for your MCU.
#define WS2812_PWM_DMA_CHANNEL 2 // DMA Channel for TIMx_UP, see the respective reference manual for the appropriate values for your MCU.
#define WS2812_PWM_TARGET_PERIOD 800000
/* Mechanical locking support. Use KC_LCAP, KC_LNUM or KC_LSCR instead in keymap */


+ 2
- 2
keyboards/handwired/tractyl_manuform/5x6_right/f303/config.h View File

@ -26,8 +26,8 @@ along with this program. If not, see <http://www.gnu.org/licenses/>.
#define WS2812_PWM_CHANNEL 1 // default: 2
#define WS2812_PWM_PAL_MODE 2 // Pin "alternate function", see the respective datasheet for the appropriate values for your MCU. default: 2
//#define WS2812_PWM_COMPLEMENTARY_OUTPUT // Define for a complementary timer output (TIMx_CHyN); omit for a normal timer output (TIMx_CHy).
// #define WS2812_DMA_STREAM STM32_DMA1_STREAM3 // DMA Stream for TIMx_UP, see the respective reference manual for the appropriate values for your MCU.
#define WS2812_DMA_CHANNEL 3 // DMA Channel for TIMx_UP, see the respective reference manual for the appropriate values for your MCU.
// #define WS2812_PWM_DMA_STREAM STM32_DMA1_STREAM3 // DMA Stream for TIMx_UP, see the respective reference manual for the appropriate values for your MCU.
#define WS2812_PWM_DMA_CHANNEL 3 // DMA Channel for TIMx_UP, see the respective reference manual for the appropriate values for your MCU.
#define DEBUG_LED_PIN C13


+ 2
- 2
keyboards/handwired/tractyl_manuform/5x6_right/f411/config.h View File

@ -27,8 +27,8 @@ along with this program. If not, see <http://www.gnu.org/licenses/>.
#define WS2812_PWM_PAL_MODE 1 // Pin "alternate function", see the respective datasheet for the appropriate values for your MCU. default: 2
#define WS2812_EXTERNAL_PULLUP
//#define WS2812_PWM_COMPLEMENTARY_OUTPUT // Define for a complementary timer output (TIMx_CHyN); omit for a normal timer output (TIMx_CHy).
#define WS2812_DMA_STREAM STM32_DMA1_STREAM7 // DMA Stream for TIMx_UP, see the respective reference manual for the appropriate values for your MCU.
#define WS2812_DMA_CHANNEL 3 // DMA Channel for TIMx_UP, see the respective reference manual for the appropriate values for your MCU.
#define WS2812_PWM_DMA_STREAM STM32_DMA1_STREAM7 // DMA Stream for TIMx_UP, see the respective reference manual for the appropriate values for your MCU.
#define WS2812_PWM_DMA_CHANNEL 3 // DMA Channel for TIMx_UP, see the respective reference manual for the appropriate values for your MCU.
#define WS2812_PWM_TARGET_PERIOD 800000
#define DEBUG_LED_PIN C13


+ 2
- 2
keyboards/jacky_studio/piggy60/rev2/config.h View File

@ -19,5 +19,5 @@
#define WS2812_PWM_DRIVER PWMD4
#define WS2812_PWM_CHANNEL 4
#define WS2812_PWM_PAL_MODE 2
#define WS2812_DMA_STREAM STM32_DMA1_STREAM7
#define WS2812_DMA_CHANNEL 7
#define WS2812_PWM_DMA_STREAM STM32_DMA1_STREAM7
#define WS2812_PWM_DMA_CHANNEL 7

+ 2
- 2
keyboards/kabedon/kabedon98e/config.h View File

@ -17,8 +17,8 @@
#define WS2812_PWM_DRIVER PWMD3
#define WS2812_PWM_CHANNEL 1
#define WS2812_DMA_STREAM STM32_DMA1_STREAM3
#define WS2812_DMA_CHANNEL 3
#define WS2812_PWM_DMA_STREAM STM32_DMA1_STREAM3
#define WS2812_PWM_DMA_CHANNEL 3
/* Mechanical locking support. Use KC_LCAP, KC_LNUM or KC_LSCR instead in keymap */
#define LOCKING_SUPPORT_ENABLE


+ 2
- 2
keyboards/kprepublic/bm16a/v2/config.h View File

@ -5,5 +5,5 @@
#define WS2812_PWM_DRIVER PWMD4
#define WS2812_PWM_CHANNEL 4
#define WS2812_DMA_STREAM STM32_DMA1_STREAM7
#define WS2812_DMA_CHANNEL 7
#define WS2812_PWM_DMA_STREAM STM32_DMA1_STREAM7
#define WS2812_PWM_DMA_CHANNEL 7

+ 2
- 2
keyboards/linworks/whale75/config.h View File

@ -24,5 +24,5 @@ along with this program. If not, see <http://www.gnu.org/licenses/>.
#define WS2812_PWM_DRIVER PWMD4
#define WS2812_PWM_CHANNEL 4
#define WS2812_PWM_PAL_MODE 2
#define WS2812_DMA_STREAM STM32_DMA1_STREAM7
#define WS2812_DMA_CHANNEL 7
#define WS2812_PWM_DMA_STREAM STM32_DMA1_STREAM7
#define WS2812_PWM_DMA_CHANNEL 7

+ 2
- 2
keyboards/loki65/config.h View File

@ -24,6 +24,6 @@ along with this program. If not, see <http://www.gnu.org/licenses/>.
#define WS2812_PWM_DRIVER PWMD1
#define WS2812_PWM_CHANNEL 2
#define WS2812_PWM_PAL_MODE 2
#define WS2812_DMA_STREAM STM32_DMA1_STREAM5
#define WS2812_DMA_CHANNEL 5
#define WS2812_PWM_DMA_STREAM STM32_DMA1_STREAM5
#define WS2812_PWM_DMA_CHANNEL 5
#define WS2812_BYTE_ORDER WS2812_BYTE_ORDER_RGB

+ 3
- 3
keyboards/mariorion_v25/prod/config.h View File

@ -7,9 +7,9 @@
#define WS2812_PWM_DRIVER PWMD17
#define WS2812_PWM_CHANNEL 1
#define WS2812_DMA_STREAM STM32_DMA1_STREAM1
#define WS2812_DMA_CHANNEL 1
// #define WS2812_DMAMUX_ID STM32_DMAMUX1_TIM17_UP
#define WS2812_PWM_DMA_STREAM STM32_DMA1_STREAM1
#define WS2812_PWM_DMA_CHANNEL 1
// #define WS2812_PWM_DMAMUX_ID STM32_DMAMUX1_TIM17_UP
#define INDICATOR_0 C9
#define INDICATOR_1 C8

+ 3
- 3
keyboards/mariorion_v25/proto/config.h View File

@ -7,9 +7,9 @@
#define WS2812_PWM_DRIVER PWMD17
#define WS2812_PWM_CHANNEL 1
#define WS2812_DMA_STREAM STM32_DMA1_STREAM1
#define WS2812_DMA_CHANNEL 1
// #define WS2812_DMAMUX_ID STM32_DMAMUX1_TIM17_UP
#define WS2812_PWM_DMA_STREAM STM32_DMA1_STREAM1
#define WS2812_PWM_DMA_CHANNEL 1
// #define WS2812_PWM_DMAMUX_ID STM32_DMAMUX1_TIM17_UP
#define INDICATOR_0 C8
#define INDICATOR_1 C7

+ 2
- 2
keyboards/meetlab/kalice/config.h View File

@ -19,5 +19,5 @@
#define WS2812_PWM_DRIVER PWMD1
#define WS2812_PWM_CHANNEL 2
#define WS2812_PWM_COMPLEMENTARY_OUTPUT
#define WS2812_DMA_STREAM STM32_DMA1_STREAM5
#define WS2812_DMA_CHANNEL 5
#define WS2812_PWM_DMA_STREAM STM32_DMA1_STREAM5
#define WS2812_PWM_DMA_CHANNEL 5

+ 2
- 2
keyboards/meetlab/rena/config.h View File

@ -18,5 +18,5 @@
#define WS2812_PWM_DRIVER PWMD2
#define WS2812_PWM_CHANNEL 3
#define WS2812_DMA_STREAM STM32_DMA1_STREAM2
#define WS2812_DMA_CHANNEL 2
#define WS2812_PWM_DMA_STREAM STM32_DMA1_STREAM2
#define WS2812_PWM_DMA_CHANNEL 2

+ 2
- 2
keyboards/misterknife/knife66/config.h View File

@ -20,5 +20,5 @@ along with this program. If not, see <http://www.gnu.org/licenses/>.
#define WS2812_PWM_DRIVER PWMD1 // default: PWMD1
#define WS2812_PWM_CHANNEL 2 // default: 2
#define WS2812_PWM_PAL_MODE 2 // Pin "alternate function", see the respective datasheet for the appropriate values for your MCU. default: 2
#define WS2812_DMA_STREAM STM32_DMA1_STREAM5 // DMA Stream for TIMx_UP, see the respective reference manual for the appropriate values for your MCU.
#define WS2812_DMA_CHANNEL 5 // DMA Channel for TIMx_UP, see the respective reference manual for the appropriate values for your MCU.
#define WS2812_PWM_DMA_STREAM STM32_DMA1_STREAM5 // DMA Stream for TIMx_UP, see the respective reference manual for the appropriate values for your MCU.
#define WS2812_PWM_DMA_CHANNEL 5 // DMA Channel for TIMx_UP, see the respective reference manual for the appropriate values for your MCU.

+ 2
- 2
keyboards/misterknife/knife66_iso/config.h View File

@ -20,5 +20,5 @@ along with this program. If not, see <http://www.gnu.org/licenses/>.
#define WS2812_PWM_DRIVER PWMD1 // default: PWMD1
#define WS2812_PWM_CHANNEL 2 // default: 2
#define WS2812_PWM_PAL_MODE 2 // Pin "alternate function", see the respective datasheet for the appropriate values for your MCU. default: 2
#define WS2812_DMA_STREAM STM32_DMA1_STREAM5 // DMA Stream for TIMx_UP, see the respective reference manual for the appropriate values for your MCU.
#define WS2812_DMA_CHANNEL 5 // DMA Channel for TIMx_UP, see the respective reference manual for the appropriate values for your MCU.
#define WS2812_PWM_DMA_STREAM STM32_DMA1_STREAM5 // DMA Stream for TIMx_UP, see the respective reference manual for the appropriate values for your MCU.
#define WS2812_PWM_DMA_CHANNEL 5 // DMA Channel for TIMx_UP, see the respective reference manual for the appropriate values for your MCU.

+ 2
- 2
keyboards/mode/m256wh/config.h View File

@ -21,7 +21,7 @@ along with this program. If not, see <http://www.gnu.org/licenses/>.
#define WS2812_PWM_DRIVER PWMD1
#define WS2812_PWM_CHANNEL 3
#define WS2812_PWM_PAL_MODE 1
#define WS2812_DMA_STREAM STM32_DMA2_STREAM5
#define WS2812_DMA_CHANNEL 6
#define WS2812_PWM_DMA_STREAM STM32_DMA2_STREAM5
#define WS2812_PWM_DMA_CHANNEL 6
#define EECONFIG_KB_DATA_SIZE (1)

+ 2
- 2
keyboards/mode/m256ws/config.h View File

@ -21,7 +21,7 @@ along with this program. If not, see <http://www.gnu.org/licenses/>.
#define WS2812_PWM_DRIVER PWMD1
#define WS2812_PWM_CHANNEL 3
#define WS2812_PWM_PAL_MODE 1
#define WS2812_DMA_STREAM STM32_DMA2_STREAM5
#define WS2812_DMA_CHANNEL 6
#define WS2812_PWM_DMA_STREAM STM32_DMA2_STREAM5
#define WS2812_PWM_DMA_CHANNEL 6
#define EECONFIG_KB_DATA_SIZE (1)

+ 2
- 2
keyboards/mode/m60h/config.h View File

@ -5,6 +5,6 @@
#define WS2812_PWM_DRIVER PWMD4
#define WS2812_PWM_CHANNEL 4
#define WS2812_DMA_STREAM STM32_DMA1_STREAM6
#define WS2812_DMA_CHANNEL 2
#define WS2812_PWM_DMA_STREAM STM32_DMA1_STREAM6
#define WS2812_PWM_DMA_CHANNEL 2
#define WS2812_PWM_TARGET_PERIOD 800000

+ 2
- 2
keyboards/mode/m60h_f/config.h View File

@ -5,6 +5,6 @@
#define WS2812_PWM_DRIVER PWMD4
#define WS2812_PWM_CHANNEL 4
#define WS2812_DMA_STREAM STM32_DMA1_STREAM6
#define WS2812_DMA_CHANNEL 2
#define WS2812_PWM_DMA_STREAM STM32_DMA1_STREAM6
#define WS2812_PWM_DMA_CHANNEL 2
#define WS2812_PWM_TARGET_PERIOD 800000

+ 2
- 2
keyboards/mode/m60s/config.h View File

@ -5,6 +5,6 @@
#define WS2812_PWM_DRIVER PWMD4
#define WS2812_PWM_CHANNEL 4
#define WS2812_DMA_STREAM STM32_DMA1_STREAM6
#define WS2812_DMA_CHANNEL 2
#define WS2812_PWM_DMA_STREAM STM32_DMA1_STREAM6
#define WS2812_PWM_DMA_CHANNEL 2
#define WS2812_PWM_TARGET_PERIOD 800000

+ 2
- 2
keyboards/mwstudio/mmk_3/config.h View File

@ -22,5 +22,5 @@
#define WS2812_PWM_DRIVER PWMD4
#define WS2812_PWM_CHANNEL 3
#define WS2812_PWM_PAL_MODE 1
#define WS2812_DMA_STREAM STM32_DMA1_STREAM7
#define WS2812_DMA_CHANNEL 2
#define WS2812_PWM_DMA_STREAM STM32_DMA1_STREAM7
#define WS2812_PWM_DMA_CHANNEL 2

+ 2
- 2
keyboards/mwstudio/mw660/config.h View File

@ -20,5 +20,5 @@
#define WS2812_PWM_CHANNEL 3 // default: 2
//#define WS2812_PWM_COMPLEMENTARY_OUTPUT // Define for a complementary timer output (TIMx_CHyN); omit for a normal timer output (TIMx_CHy).
#define WS2812_PWM_PAL_MODE 1 // Pin "alternate function", see the respective datasheet for the appropriate values for your MCU. default: 2
#define WS2812_DMA_STREAM STM32_DMA1_STREAM7 // DMA Stream for TIMx_UP, see the respective reference manual for the appropriate values for your MCU.
#define WS2812_DMA_CHANNEL 2
#define WS2812_PWM_DMA_STREAM STM32_DMA1_STREAM7 // DMA Stream for TIMx_UP, see the respective reference manual for the appropriate values for your MCU.
#define WS2812_PWM_DMA_CHANNEL 2

+ 2
- 2
keyboards/novelkeys/nk20/config.h View File

@ -20,5 +20,5 @@ along with this program. If not, see <http://www.gnu.org/licenses/>.
#define WS2812_PWM_DRIVER PWMD3
#define WS2812_PWM_CHANNEL 2
#define WS2812_PWM_PAL_MODE 1
#define WS2812_DMA_STREAM STM32_DMA1_STREAM3
#define WS2812_DMA_CHANNEL 3
#define WS2812_PWM_DMA_STREAM STM32_DMA1_STREAM3
#define WS2812_PWM_DMA_CHANNEL 3

+ 2
- 2
keyboards/novelkeys/nk65b/config.h View File

@ -20,5 +20,5 @@ along with this program. If not, see <http://www.gnu.org/licenses/>.
#define WS2812_PWM_DRIVER PWMD3
#define WS2812_PWM_CHANNEL 1
#define WS2812_PWM_PAL_MODE 1
#define WS2812_DMA_STREAM STM32_DMA1_STREAM3
#define WS2812_DMA_CHANNEL 3
#define WS2812_PWM_DMA_STREAM STM32_DMA1_STREAM3
#define WS2812_PWM_DMA_CHANNEL 3

+ 2
- 2
keyboards/novelkeys/nk87b/config.h View File

@ -20,5 +20,5 @@ along with this program. If not, see <http://www.gnu.org/licenses/>.
#define WS2812_PWM_DRIVER PWMD3
#define WS2812_PWM_CHANNEL 3
#define WS2812_PWM_PAL_MODE 1
#define WS2812_DMA_STREAM STM32_DMA1_STREAM3
#define WS2812_DMA_CHANNEL 3
#define WS2812_PWM_DMA_STREAM STM32_DMA1_STREAM3
#define WS2812_PWM_DMA_CHANNEL 3

+ 2
- 2
keyboards/novelkeys/nk_plus/config.h View File

@ -20,5 +20,5 @@ along with this program. If not, see <http://www.gnu.org/licenses/>.
#define WS2812_PWM_DRIVER PWMD3
#define WS2812_PWM_CHANNEL 1
#define WS2812_PWM_PAL_MODE 1
#define WS2812_DMA_STREAM STM32_DMA1_STREAM3
#define WS2812_DMA_CHANNEL 3
#define WS2812_PWM_DMA_STREAM STM32_DMA1_STREAM3
#define WS2812_PWM_DMA_CHANNEL 3

+ 2
- 2
keyboards/planck/ez/config.h View File

@ -46,8 +46,8 @@
// #define WS2812_TIM_CH 2
// #define PORT_WS2812 GPIOA
// #define PIN_WS2812 1
// #define WS2812_DMA_STREAM STM32_DMA1_STREAM2 // DMA stream for TIMx_UP (look up in reference manual under DMA Channel selection)
//#define WS2812_DMA_CHANNEL 7 // DMA channel for TIMx_UP
// #define WS2812_PWM_DMA_STREAM STM32_DMA1_STREAM2 // DMA stream for TIMx_UP (look up in reference manual under DMA Channel selection)
//#define WS2812_PWM_DMA_CHANNEL 7 // DMA channel for TIMx_UP
//#define WS2812_EXTERNAL_PULLUP
#define IS31FL3737_I2C_ADDRESS_1 IS31FL3737_I2C_ADDRESS_GND


+ 2
- 2
keyboards/planck/rev6/config.h View File

@ -46,5 +46,5 @@
#define WS2812_PWM_DRIVER PWMD2
#define WS2812_PWM_CHANNEL 2
#define WS2812_PWM_PAL_MODE 1
#define WS2812_DMA_STREAM STM32_DMA1_STREAM2
#define WS2812_DMA_CHANNEL 2
#define WS2812_PWM_DMA_STREAM STM32_DMA1_STREAM2
#define WS2812_PWM_DMA_CHANNEL 2

+ 2
- 2
keyboards/planck/rev6_drop/config.h View File

@ -46,5 +46,5 @@
#define WS2812_PWM_DRIVER PWMD2
#define WS2812_PWM_CHANNEL 2
#define WS2812_PWM_PAL_MODE 1
#define WS2812_DMA_STREAM STM32_DMA1_STREAM2
#define WS2812_DMA_CHANNEL 2
#define WS2812_PWM_DMA_STREAM STM32_DMA1_STREAM2
#define WS2812_PWM_DMA_CHANNEL 2

+ 2
- 2
keyboards/planck/rev7/config.h View File

@ -27,8 +27,8 @@
#define WS2812_PWM_DRIVER PWMD2
#define WS2812_PWM_CHANNEL 2
#define WS2812_PWM_PAL_MODE 1
#define WS2812_DMA_STREAM STM32_DMA1_STREAM2
#define WS2812_DMA_CHANNEL 2
#define WS2812_PWM_DMA_STREAM STM32_DMA1_STREAM2
#define WS2812_PWM_DMA_CHANNEL 2
/*
* Feature disable options


+ 2
- 2
keyboards/preonic/rev3/config.h View File

@ -44,5 +44,5 @@
#define WS2812_PWM_DRIVER PWMD2
#define WS2812_PWM_CHANNEL 2
#define WS2812_PWM_PAL_MODE 1
#define WS2812_DMA_STREAM STM32_DMA1_STREAM2
#define WS2812_DMA_CHANNEL 2
#define WS2812_PWM_DMA_STREAM STM32_DMA1_STREAM2
#define WS2812_PWM_DMA_CHANNEL 2

+ 2
- 2
keyboards/preonic/rev3_drop/config.h View File

@ -44,5 +44,5 @@
#define WS2812_PWM_DRIVER PWMD2
#define WS2812_PWM_CHANNEL 2
#define WS2812_PWM_PAL_MODE 1
#define WS2812_DMA_STREAM STM32_DMA1_STREAM2
#define WS2812_DMA_CHANNEL 2
#define WS2812_PWM_DMA_STREAM STM32_DMA1_STREAM2
#define WS2812_PWM_DMA_CHANNEL 2

+ 2
- 2
keyboards/protozoa/p01/config.h View File

@ -21,5 +21,5 @@ along with this program. If not, see <http://www.gnu.org/licenses/>.
#define WS2812_PWM_DRIVER PWMD1
#define WS2812_PWM_CHANNEL 2
#define WS2812_PWM_PAL_MODE 2
#define WS2812_DMA_STREAM STM32_DMA1_STREAM5
#define WS2812_DMA_CHANNEL 5
#define WS2812_PWM_DMA_STREAM STM32_DMA1_STREAM5
#define WS2812_PWM_DMA_CHANNEL 5

+ 2
- 2
keyboards/rgbkb/mun/config.h View File

@ -54,8 +54,8 @@
#define WS2812_PWM_DRIVER PWMD3
#define WS2812_PWM_CHANNEL 2
#define WS2812_PWM_PAL_MODE 2
#define WS2812_DMA_STREAM STM32_DMA1_STREAM3
#define WS2812_DMA_CHANNEL 3
#define WS2812_PWM_DMA_STREAM STM32_DMA1_STREAM3
#define WS2812_PWM_DMA_CHANNEL 3
#define TOUCH_UPDATE_INTERVAL 33
#define OLED_UPDATE_INTERVAL 33

+ 2
- 2
keyboards/rgbkb/sol3/config.h View File

@ -46,8 +46,8 @@
#define WS2812_PWM_DRIVER PWMD3
#define WS2812_PWM_CHANNEL 2
#define WS2812_PWM_PAL_MODE 2
#define WS2812_DMA_STREAM STM32_DMA1_STREAM3
#define WS2812_DMA_CHANNEL 3
#define WS2812_PWM_DMA_STREAM STM32_DMA1_STREAM3
#define WS2812_PWM_DMA_CHANNEL 3
#define TOUCH_UPDATE_INTERVAL 33
#define OLED_UPDATE_INTERVAL 33


+ 2
- 2
keyboards/skyloong/dt40/config.h View File

@ -24,5 +24,5 @@
#define WS2812_PWM_DRIVER PWMD3
#define WS2812_PWM_CHANNEL 1
#define WS2812_PWM_PAL_MODE 2
#define WS2812_DMA_STREAM STM32_DMA1_STREAM3
#define WS2812_DMA_CHANNEL 3
#define WS2812_PWM_DMA_STREAM STM32_DMA1_STREAM3
#define WS2812_PWM_DMA_CHANNEL 3

+ 2
- 2
keyboards/smithrune/iron165r2/f411/config.h View File

@ -24,5 +24,5 @@ along with this program. If not, see <http://www.gnu.org/licenses/>.
#define WS2812_PWM_DRIVER PWMD1
#define WS2812_PWM_CHANNEL 3
#define WS2812_PWM_PAL_MODE 1
#define WS2812_DMA_STREAM STM32_DMA2_STREAM5
#define WS2812_DMA_CHANNEL 6
#define WS2812_PWM_DMA_STREAM STM32_DMA2_STREAM5
#define WS2812_PWM_DMA_CHANNEL 6

+ 2
- 2
keyboards/smithrune/magnus/m75h/config.h View File

@ -25,5 +25,5 @@ along with this program. If not, see <http://www.gnu.org/licenses/>.
#define WS2812_PWM_DRIVER PWMD1
#define WS2812_PWM_CHANNEL 3
#define WS2812_PWM_PAL_MODE 1
#define WS2812_DMA_STREAM STM32_DMA2_STREAM5
#define WS2812_DMA_CHANNEL 6
#define WS2812_PWM_DMA_STREAM STM32_DMA2_STREAM5
#define WS2812_PWM_DMA_CHANNEL 6

+ 2
- 2
keyboards/smithrune/magnus/m75s/config.h View File

@ -27,5 +27,5 @@ along with this program. If not, see <http://www.gnu.org/licenses/>.
#define WS2812_PWM_DRIVER PWMD1
#define WS2812_PWM_CHANNEL 3
#define WS2812_PWM_PAL_MODE 1
#define WS2812_DMA_STREAM STM32_DMA2_STREAM5
#define WS2812_DMA_CHANNEL 6
#define WS2812_PWM_DMA_STREAM STM32_DMA2_STREAM5
#define WS2812_PWM_DMA_CHANNEL 6

+ 2
- 2
keyboards/spaceholdings/nebula68/config.h View File

@ -20,8 +20,8 @@ along with this program. If not, see <http://www.gnu.org/licenses/>.
#define WS2812_PWM_DRIVER PWMD3 // default: PWMD2
#define WS2812_PWM_CHANNEL 2 // default: 2
#define WS2812_PWM_PAL_MODE 2 // Pin "alternate function", see the respective datasheet for the appropriate values for your MCU. default: 2
#define WS2812_DMA_STREAM STM32_DMA1_STREAM3 // DMA Stream for TIMx_UP, see the respective reference manual for the appropriate values for your MCU.
#define WS2812_DMA_CHANNEL 3 // DMA Channel for TIMx_UP, see the respective reference manual for the appropriate values for your MCU.
#define WS2812_PWM_DMA_STREAM STM32_DMA1_STREAM3 // DMA Stream for TIMx_UP, see the respective reference manual for the appropriate values for your MCU.
#define WS2812_PWM_DMA_CHANNEL 3 // DMA Channel for TIMx_UP, see the respective reference manual for the appropriate values for your MCU.
/* Backlight options */


+ 3
- 3
keyboards/splitkb/kyria/rev1/config.h View File

@ -33,9 +33,9 @@ along with this program. If not, see <http://www.gnu.org/licenses/>.
# define WS2812_PWM_DRIVER PWMD2 // default: PWMD2
# define WS2812_PWM_CHANNEL 4 // default: 2
# define WS2812_PWM_PAL_MODE 1 // Pin "alternate function", see the respective datasheet for the appropriate values for your MCU. default: 2
# define WS2812_DMA_STREAM STM32_DMA1_STREAM2 // DMA Stream for TIMx_UP, see the respective reference manual for the appropriate values for your MCU.
# define WS2812_DMA_CHANNEL 2 // DMA Channel for TIMx_UP, see the respective reference manual for the appropriate values for your MCU.
# define WS2812_DMAMUX_ID STM32_DMAMUX1_TIM2_UP // DMAMUX configuration for TIMx_UP -- only required if your MCU has a DMAMUX peripheral, see the respective reference manual for the appropriate values for your MCU.
# define WS2812_PWM_DMA_STREAM STM32_DMA1_STREAM2 // DMA Stream for TIMx_UP, see the respective reference manual for the appropriate values for your MCU.
# define WS2812_PWM_DMA_CHANNEL 2 // DMA Channel for TIMx_UP, see the respective reference manual for the appropriate values for your MCU.
# define WS2812_PWM_DMAMUX_ID STM32_DMAMUX1_TIM2_UP // DMAMUX configuration for TIMx_UP -- only required if your MCU has a DMAMUX peripheral, see the respective reference manual for the appropriate values for your MCU.
#else
# define WS2812_DI_PIN D3
# define SOFT_SERIAL_PIN D2


+ 3
- 3
keyboards/splitkb/kyria/rev2/config.h View File

@ -38,9 +38,9 @@ along with this program. If not, see <http://www.gnu.org/licenses/>.
# define WS2812_PWM_DRIVER PWMD2 // default: PWMD2
# define WS2812_PWM_CHANNEL 4 // default: 2
# define WS2812_PWM_PAL_MODE 1 // Pin "alternate function", see the respective datasheet for the appropriate values for your MCU. default: 2
# define WS2812_DMA_STREAM STM32_DMA1_STREAM2 // DMA Stream for TIMx_UP, see the respective reference manual for the appropriate values for your MCU.
# define WS2812_DMA_CHANNEL 2 // DMA Channel for TIMx_UP, see the respective reference manual for the appropriate values for your MCU.
# define WS2812_DMAMUX_ID STM32_DMAMUX1_TIM2_UP // DMAMUX configuration for TIMx_UP -- only required if your MCU has a DMAMUX peripheral, see the respective reference manual for the appropriate values for your MCU.
# define WS2812_PWM_DMA_STREAM STM32_DMA1_STREAM2 // DMA Stream for TIMx_UP, see the respective reference manual for the appropriate values for your MCU.
# define WS2812_PWM_DMA_CHANNEL 2 // DMA Channel for TIMx_UP, see the respective reference manual for the appropriate values for your MCU.
# define WS2812_PWM_DMAMUX_ID STM32_DMAMUX1_TIM2_UP // DMAMUX configuration for TIMx_UP -- only required if your MCU has a DMAMUX peripheral, see the respective reference manual for the appropriate values for your MCU.
#else
# define WS2812_DI_PIN D3
# define SOFT_SERIAL_PIN D2


+ 2
- 2
keyboards/tg67/config.h View File

@ -19,5 +19,5 @@
#define WS2812_PWM_DRIVER PWMD1
#define WS2812_PWM_CHANNEL 3
#define WS2812_PWM_COMPLEMENTARY_OUTPUT
#define WS2812_DMA_STREAM STM32_DMA1_STREAM5
#define WS2812_DMA_CHANNEL 5
#define WS2812_PWM_DMA_STREAM STM32_DMA1_STREAM5
#define WS2812_PWM_DMA_CHANNEL 5

+ 2
- 2
keyboards/tkw/grandiceps/config.h View File

@ -20,5 +20,5 @@
#define WS2812_PWM_DRIVER PWMD3
#define WS2812_PWM_CHANNEL 4
#define WS2812_PWM_PAL_MODE 2
#define WS2812_DMA_STREAM STM32_DMA1_STREAM2
#define WS2812_DMA_CHANNEL 5
#define WS2812_PWM_DMA_STREAM STM32_DMA1_STREAM2
#define WS2812_PWM_DMA_CHANNEL 5

+ 2
- 2
keyboards/tkw/stoutgat/v2/config.h View File

@ -18,8 +18,8 @@
#define WS2812_PWM_DRIVER PWMD3
#define WS2812_PWM_CHANNEL 4
#define WS2812_PWM_PAL_MODE 2
#define WS2812_DMA_STREAM STM32_DMA1_STREAM2
#define WS2812_DMA_CHANNEL 5
#define WS2812_PWM_DMA_STREAM STM32_DMA1_STREAM2
#define WS2812_PWM_DMA_CHANNEL 5
/* Mechanical locking support. Use KC_LCAP, KC_LNUM or KC_LSCR instead in keymap */
#define LOCKING_SUPPORT_ENABLE


+ 3
- 3
keyboards/tzarc/djinn/config.h View File

@ -39,9 +39,9 @@
#define WS2812_PWM_DRIVER PWMD20
#define WS2812_PWM_CHANNEL 1
#define WS2812_PWM_PAL_MODE 3
#define WS2812_DMA_STREAM STM32_DMA1_STREAM1
#define WS2812_DMA_CHANNEL 1
#define WS2812_DMAMUX_ID STM32_DMAMUX1_TIM20_UP
#define WS2812_PWM_DMA_STREAM STM32_DMA1_STREAM1
#define WS2812_PWM_DMA_CHANNEL 1
#define WS2812_PWM_DMAMUX_ID STM32_DMAMUX1_TIM20_UP
// Audio configuration
#define AUDIO_PIN A5


+ 2
- 2
keyboards/tzarc/ghoul/rev1/stm32/config.h View File

@ -28,8 +28,8 @@
#define WS2812_PWM_DRIVER PWMD3
#define WS2812_PWM_CHANNEL 1
#define WS2812_PWM_PAL_MODE 2
#define WS2812_DMA_STREAM STM32_DMA1_STREAM2
#define WS2812_DMA_CHANNEL 5
#define WS2812_PWM_DMA_STREAM STM32_DMA1_STREAM2
#define WS2812_PWM_DMA_CHANNEL 5
#define RGB_ENABLE_PIN C0
// ADC Configuration


+ 2
- 2
keyboards/viendi8l/config.h View File

@ -37,5 +37,5 @@ along with this program. If not, see <http://www.gnu.org/licenses/>.
#define WS2812_PWM_DRIVER PWMD1
#define WS2812_PWM_CHANNEL 3
#define WS2812_PWM_PAL_MODE 1
#define WS2812_DMA_STREAM STM32_DMA2_STREAM5
#define WS2812_DMA_CHANNEL 6
#define WS2812_PWM_DMA_STREAM STM32_DMA2_STREAM5
#define WS2812_PWM_DMA_CHANNEL 6

+ 2
- 2
keyboards/vinhcatba/uncertainty/config.h View File

@ -11,8 +11,8 @@
#define WS2812_PWM_CHANNEL 4 // CH4
#define WS2812_PWM_PAL_MODE 2 // AF2
#define WS2812_DMA_STREAM STM32_DMA1_STREAM2 // DMA1 Stream 2 for TIM3_UP (table 28 in reference manual)
#define WS2812_DMA_CHANNEL 5 // DMA Channel 5 for TIM3_UP (table 28 in reference manual)
#define WS2812_PWM_DMA_STREAM STM32_DMA1_STREAM2 // DMA1 Stream 2 for TIM3_UP (table 28 in reference manual)
#define WS2812_PWM_DMA_CHANNEL 5 // DMA Channel 5 for TIM3_UP (table 28 in reference manual)
#define I2C1_CLOCK_SPEED 400000


+ 2
- 2
keyboards/xelus/ninjin/config.h View File

@ -20,8 +20,8 @@
#define WS2812_PWM_DRIVER PWMD1
#define WS2812_PWM_CHANNEL 3
#define WS2812_PWM_PAL_MODE 2
#define WS2812_DMA_STREAM STM32_DMA1_STREAM5
#define WS2812_DMA_CHANNEL 3
#define WS2812_PWM_DMA_STREAM STM32_DMA1_STREAM5
#define WS2812_PWM_DMA_CHANNEL 3
#define WS2812_EXTERNAL_PULLUP
/* Mechanical locking support. Use KC_LCAP, KC_LNUM or KC_LSCR instead in keymap */


+ 3
- 3
keyboards/xelus/valor/rev2/config.h View File

@ -40,9 +40,9 @@
#define WS2812_PWM_DRIVER PWMD1
#define WS2812_PWM_CHANNEL 2
#define WS2812_PWM_PAL_MODE 1
#define WS2812_DMA_STREAM STM32_DMA1_STREAM6
#define WS2812_DMA_CHANNEL 7
#define WS2812_DMAMUX_ID STM32_DMAMUX1_TIM1_UP
#define WS2812_PWM_DMA_STREAM STM32_DMA1_STREAM6
#define WS2812_PWM_DMA_CHANNEL 7
#define WS2812_PWM_DMAMUX_ID STM32_DMAMUX1_TIM1_UP
// RGB Pullup
#define WS2812_EXTERNAL_PULLUP


+ 2
- 2
keyboards/yandrstudio/buff67v3/config.h View File

@ -23,8 +23,8 @@
# define WS2812_PWM_DRIVER PWMD3 // default: PWMD2
# define WS2812_PWM_CHANNEL 1 // default: 2
# define WS2812_DMA_STREAM STM32_DMA1_STREAM3 // DMA Stream for TIMx_UP, see the respective reference manual for the appropriate values for your MCU.
# define WS2812_DMA_CHANNEL 3 // DMA Channel for TIMx_UP, see the respective reference manual for the appropriate values for your MCU.
# define WS2812_PWM_DMA_STREAM STM32_DMA1_STREAM3 // DMA Stream for TIMx_UP, see the respective reference manual for the appropriate values for your MCU.
# define WS2812_PWM_DMA_CHANNEL 3 // DMA Channel for TIMx_UP, see the respective reference manual for the appropriate values for your MCU.
#endif


+ 2
- 2
keyboards/yandrstudio/eau_r2/config.h View File

@ -17,5 +17,5 @@
#define WS2812_PWM_DRIVER PWMD1
#define WS2812_PWM_CHANNEL 1
#define WS2812_DMA_STREAM STM32_DMA1_STREAM5
#define WS2812_DMA_CHANNEL 5
#define WS2812_PWM_DMA_STREAM STM32_DMA1_STREAM5
#define WS2812_PWM_DMA_CHANNEL 5

+ 2
- 2
keyboards/yandrstudio/nightstar75/config.h View File

@ -20,5 +20,5 @@
#define WS2812_PWM_DRIVER PWMD3 // default: PWMD2
#define WS2812_PWM_CHANNEL 2 // default: 2
#define WS2812_PWM_PAL_MODE 2
#define WS2812_DMA_STREAM STM32_DMA1_STREAM3
#define WS2812_DMA_CHANNEL 3
#define WS2812_PWM_DMA_STREAM STM32_DMA1_STREAM3
#define WS2812_PWM_DMA_CHANNEL 3

+ 2
- 2
keyboards/yandrstudio/nz64/config.h View File

@ -18,5 +18,5 @@
#define WS2812_PWM_DRIVER PWMD3 // default: PWMD2
#define WS2812_PWM_CHANNEL 2 // default: 2
#define WS2812_PWM_PAL_MODE 2 // Pin "alternate function", see the respective datasheet for the appropriate values for your MCU. default: 2
#define WS2812_DMA_STREAM STM32_DMA1_STREAM2 // DMA Stream for TIMx_UP, see the respective reference manual for the appropriate values for your MCU.
#define WS2812_DMA_CHANNEL 5 // DMA Channel for TIMx_UP, see the respective reference manual for the appropriate values for your MCU.
#define WS2812_PWM_DMA_STREAM STM32_DMA1_STREAM2 // DMA Stream for TIMx_UP, see the respective reference manual for the appropriate values for your MCU.
#define WS2812_PWM_DMA_CHANNEL 5 // DMA Channel for TIMx_UP, see the respective reference manual for the appropriate values for your MCU.

+ 2
- 2
keyboards/yandrstudio/nz67v2/config.h View File

@ -18,5 +18,5 @@
#define WS2812_PWM_DRIVER PWMD3 // default: PWMD2
#define WS2812_PWM_CHANNEL 2 // default: 2
#define WS2812_DMA_STREAM STM32_DMA1_STREAM3 // DMA Stream for TIMx_UP, see the respective reference manual for the appropriate values for your MCU.
#define WS2812_DMA_CHANNEL 3 // DMA Channel for TIMx_UP, see the respective reference manual for the appropriate values for your MCU.
#define WS2812_PWM_DMA_STREAM STM32_DMA1_STREAM3 // DMA Stream for TIMx_UP, see the respective reference manual for the appropriate values for your MCU.
#define WS2812_PWM_DMA_CHANNEL 3 // DMA Channel for TIMx_UP, see the respective reference manual for the appropriate values for your MCU.

+ 2
- 2
keyboards/yandrstudio/tg67/config.h View File

@ -18,5 +18,5 @@
#define WS2812_PWM_DRIVER PWMD3
#define WS2812_PWM_CHANNEL 2
#define WS2812_PWM_PAL_MODE 2
#define WS2812_DMA_STREAM STM32_DMA1_STREAM3
#define WS2812_DMA_CHANNEL 3
#define WS2812_PWM_DMA_STREAM STM32_DMA1_STREAM3
#define WS2812_PWM_DMA_CHANNEL 3

+ 2
- 2
keyboards/yandrstudio/yr6095/config.h View File

@ -19,5 +19,5 @@
#define WS2812_PWM_DRIVER PWMD3
#define WS2812_PWM_CHANNEL 2
#define WS2812_DMA_STREAM STM32_DMA1_STREAM3
#define WS2812_DMA_CHANNEL 3
#define WS2812_PWM_DMA_STREAM STM32_DMA1_STREAM3
#define WS2812_PWM_DMA_CHANNEL 3

+ 2
- 2
keyboards/yandrstudio/yr80/config.h View File

@ -21,5 +21,5 @@
#define WS2812_PWM_DRIVER PWMD3
#define WS2812_PWM_CHANNEL 2
#define WS2812_PWM_PAL_MODE 2
#define WS2812_DMA_STREAM STM32_DMA1_STREAM3
#define WS2812_DMA_CHANNEL 3
#define WS2812_PWM_DMA_STREAM STM32_DMA1_STREAM3
#define WS2812_PWM_DMA_CHANNEL 3

+ 2
- 2
keyboards/yanghu/unicorne/config.h View File

@ -31,6 +31,6 @@
#define WS2812_PWM_DRIVER PWMD3
#define WS2812_PWM_CHANNEL 4
#define WS2812_PWM_PAL_MODE 2
#define WS2812_DMA_STREAM STM32_DMA1_STREAM2
#define WS2812_DMA_CHANNEL 5
#define WS2812_PWM_DMA_STREAM STM32_DMA1_STREAM2
#define WS2812_PWM_DMA_CHANNEL 5
#define WS2812_EXTERNAL_PULLUP

+ 2
- 2
keyboards/ymdk/id75/config.h View File

@ -19,5 +19,5 @@
#define WS2812_PWM_DRIVER PWMD4
#define WS2812_PWM_CHANNEL 4
#define WS2812_PWM_PAL_MODE 2
#define WS2812_DMA_STREAM STM32_DMA1_STREAM7
#define WS2812_DMA_CHANNEL 7
#define WS2812_PWM_DMA_STREAM STM32_DMA1_STREAM7
#define WS2812_PWM_DMA_CHANNEL 7

+ 2
- 2
keyboards/ymdk/ymd75/rev4/iso/config.h View File

@ -5,5 +5,5 @@
#define WS2812_PWM_DRIVER PWMD4
#define WS2812_PWM_CHANNEL 4
#define WS2812_PWM_PAL_MODE 2
#define WS2812_DMA_STREAM STM32_DMA1_STREAM7
#define WS2812_DMA_CHANNEL 7
#define WS2812_PWM_DMA_STREAM STM32_DMA1_STREAM7
#define WS2812_PWM_DMA_CHANNEL 7

+ 2
- 2
keyboards/zvecr/split_blackpill/config.h View File

@ -20,8 +20,8 @@
#define WS2812_PWM_DRIVER PWMD3
#define WS2812_PWM_CHANNEL 1
#define WS2812_DMA_STREAM STM32_DMA1_STREAM3
#define WS2812_DMA_CHANNEL 3
#define WS2812_PWM_DMA_STREAM STM32_DMA1_STREAM3
#define WS2812_PWM_DMA_CHANNEL 3
/* Mechanical locking support. Use KC_LCAP, KC_LNUM or KC_LSCR instead in keymap */
#define LOCKING_SUPPORT_ENABLE


+ 2
- 2
keyboards/zvecr/zv48/config.h View File

@ -22,8 +22,8 @@
#define WS2812_PWM_DRIVER PWMD3
#define WS2812_PWM_CHANNEL 4
#define WS2812_PWM_PAL_MODE 2
#define WS2812_DMA_STREAM STM32_DMA1_STREAM2
#define WS2812_DMA_CHANNEL 5
#define WS2812_PWM_DMA_STREAM STM32_DMA1_STREAM2
#define WS2812_PWM_DMA_CHANNEL 5
/* Mechanical locking support. Use KC_LCAP, KC_LNUM or KC_LSCR instead in keymap */
#define LOCKING_SUPPORT_ENABLE


+ 4
- 4
platforms/chibios/boards/BONSAI_C4/configs/config.h View File

@ -77,11 +77,11 @@
# ifndef WS2812_PWM_PAL_MODE
# define WS2812_PWM_PAL_MODE 1
# endif
# ifndef WS2812_DMA_STREAM
# define WS2812_DMA_STREAM STM32_DMA2_STREAM5
# ifndef WS2812_PWM_DMA_STREAM
# define WS2812_PWM_DMA_STREAM STM32_DMA2_STREAM5
# endif
# ifndef WS2812_DMA_CHANNEL
# define WS2812_DMA_CHANNEL 6
# ifndef WS2812_PWM_DMA_CHANNEL
# define WS2812_PWM_DMA_CHANNEL 6
# endif
#endif


+ 9
- 9
platforms/chibios/drivers/vendor/RP/RP2040/ws2812_vendor.c View File

@ -136,7 +136,7 @@ static const pio_program_t ws2812_program = {
};
static uint32_t WS2812_BUFFER[WS2812_LED_COUNT];
static const rp_dma_channel_t* WS2812_DMA_CHANNEL;
static const rp_dma_channel_t* dma_channel;
static uint32_t RP_DMA_MODE_WS2812;
static int STATE_MACHINE = -1;
@ -236,9 +236,9 @@ bool ws2812_init(void) {
pio_sm_init(pio, STATE_MACHINE, offset, &config);
pio_sm_set_enabled(pio, STATE_MACHINE, true);
WS2812_DMA_CHANNEL = dmaChannelAlloc(RP_DMA_CHANNEL_ID_ANY, RP_DMA_PRIORITY_WS2812, (rp_dmaisr_t)ws2812_dma_callback, NULL);
dmaChannelEnableInterruptX(WS2812_DMA_CHANNEL);
dmaChannelSetDestinationX(WS2812_DMA_CHANNEL, (uint32_t)&pio->txf[STATE_MACHINE]);
dma_channel = dmaChannelAlloc(RP_DMA_CHANNEL_ID_ANY, RP_DMA_PRIORITY_WS2812, (rp_dmaisr_t)ws2812_dma_callback, NULL);
dmaChannelEnableInterruptX(dma_channel);
dmaChannelSetDestinationX(dma_channel, (uint32_t)&pio->txf[STATE_MACHINE]);
// clang-format off
RP_DMA_MODE_WS2812 = DMA_CTRL_TRIG_INCR_READ |
@ -256,7 +256,7 @@ static inline void sync_ws2812_transfer(void) {
// count of LEDs in milliseconds. This is safely much longer than it
// would take to push all the data out.
dprintln("ERROR: WS2812 DMA transfer has stalled, aborting!");
dmaChannelDisableX(WS2812_DMA_CHANNEL);
dmaChannelDisableX(dma_channel);
pio_sm_clear_fifos(pio, STATE_MACHINE);
pio_sm_restart(pio, STATE_MACHINE);
chSemReset(&TRANSFER_COUNTER, 0);
@ -284,8 +284,8 @@ void ws2812_setleds(rgb_led_t* ledarray, uint16_t leds) {
#endif
}
dmaChannelSetSourceX(WS2812_DMA_CHANNEL, (uint32_t)WS2812_BUFFER);
dmaChannelSetCounterX(WS2812_DMA_CHANNEL, leds);
dmaChannelSetModeX(WS2812_DMA_CHANNEL, RP_DMA_MODE_WS2812);
dmaChannelEnableX(WS2812_DMA_CHANNEL);
dmaChannelSetSourceX(dma_channel, (uint32_t)WS2812_BUFFER);
dmaChannelSetCounterX(dma_channel, leds);
dmaChannelSetModeX(dma_channel, RP_DMA_MODE_WS2812);
dmaChannelEnableX(dma_channel);
}

+ 36
- 24
platforms/chibios/drivers/ws2812_pwm.c View File

@ -2,6 +2,18 @@
#include "gpio.h"
#include "chibios_config.h"
// ======== DEPRECATED DEFINES - DO NOT USE ========
#ifdef WS2812_DMA_STREAM
# define WS2812_PWM_DMA_STREAM WS2812_DMA_STREAM
#endif
#ifdef WS2812_DMA_CHANNEL
# define WS2812_PWM_DMA_CHANNEL WS2812_DMA_CHANNEL
#endif
#ifdef WS2812_DMAMUX_ID
# define WS2812_PWM_DMAMUX_ID WS2812_DMAMUX_ID
#endif
// ========
/* Adapted from https://github.com/joewa/WS2812-LED-Driver_ChibiOS/ */
#ifdef RGBW
@ -19,14 +31,14 @@
#ifndef WS2812_PWM_PAL_MODE
# define WS2812_PWM_PAL_MODE 2 // DI Pin's alternate function value
#endif
#ifndef WS2812_DMA_STREAM
# define WS2812_DMA_STREAM STM32_DMA1_STREAM2 // DMA Stream for TIMx_UP
#ifndef WS2812_PWM_DMA_STREAM
# define WS2812_PWM_DMA_STREAM STM32_DMA1_STREAM2 // DMA Stream for TIMx_UP
#endif
#ifndef WS2812_DMA_CHANNEL
# define WS2812_DMA_CHANNEL 2 // DMA Channel for TIMx_UP
#ifndef WS2812_PWM_DMA_CHANNEL
# define WS2812_PWM_DMA_CHANNEL 2 // DMA Channel for TIMx_UP
#endif
#if (STM32_DMA_SUPPORTS_DMAMUX == TRUE) && !defined(WS2812_DMAMUX_ID)
# error "please consult your MCU's datasheet and specify in your config.h: #define WS2812_DMAMUX_ID STM32_DMAMUX1_TIM?_UP"
#if (STM32_DMA_SUPPORTS_DMAMUX == TRUE) && !defined(WS2812_PWM_DMAMUX_ID)
# error "please consult your MCU's datasheet and specify in your config.h: #define WS2812_PWM_DMAMUX_ID STM32_DMAMUX1_TIM?_UP"
#endif
/* Summarize https://www.st.com/resource/en/application_note/an4013-stm32-crossseries-timer-overview-stmicroelectronics.pdf to
@ -270,20 +282,20 @@
// For all other STM32 DMA transfer will automatically zero pad. We only need to set the right peripheral width.
#if defined(STM32F2XX) || defined(STM32F4XX) || defined(STM32F7XX)
# if defined(WS2812_PWM_TIMER_32BIT)
# define WS2812_DMA_MEMORY_WIDTH STM32_DMA_CR_MSIZE_WORD
# define WS2812_DMA_PERIPHERAL_WIDTH STM32_DMA_CR_PSIZE_WORD
# define WS2812_PWM_DMA_MEMORY_WIDTH STM32_DMA_CR_MSIZE_WORD
# define WS2812_PWM_DMA_PERIPHERAL_WIDTH STM32_DMA_CR_PSIZE_WORD
typedef uint32_t ws2812_buffer_t;
# else
# define WS2812_DMA_MEMORY_WIDTH STM32_DMA_CR_MSIZE_HWORD
# define WS2812_DMA_PERIPHERAL_WIDTH STM32_DMA_CR_PSIZE_HWORD
# define WS2812_PWM_DMA_MEMORY_WIDTH STM32_DMA_CR_MSIZE_HWORD
# define WS2812_PWM_DMA_PERIPHERAL_WIDTH STM32_DMA_CR_PSIZE_HWORD
typedef uint16_t ws2812_buffer_t;
# endif
#else
# define WS2812_DMA_MEMORY_WIDTH STM32_DMA_CR_MSIZE_BYTE
# define WS2812_PWM_DMA_MEMORY_WIDTH STM32_DMA_CR_MSIZE_BYTE
# if defined(WS2812_PWM_TIMER_32BIT)
# define WS2812_DMA_PERIPHERAL_WIDTH STM32_DMA_CR_PSIZE_WORD
# define WS2812_PWM_DMA_PERIPHERAL_WIDTH STM32_DMA_CR_PSIZE_WORD
# else
# define WS2812_DMA_PERIPHERAL_WIDTH STM32_DMA_CR_PSIZE_HWORD
# define WS2812_PWM_DMA_PERIPHERAL_WIDTH STM32_DMA_CR_PSIZE_HWORD
# endif
typedef uint8_t ws2812_buffer_t;
#endif
@ -326,26 +338,26 @@ void ws2812_init(void) {
// Configure DMA
// dmaInit(); // Joe added this
#if defined(WB32F3G71xx) || defined(WB32FQ95xx)
dmaStreamAlloc(WS2812_DMA_STREAM - WB32_DMA_STREAM(0), 10, NULL, NULL);
dmaStreamSetSource(WS2812_DMA_STREAM, ws2812_frame_buffer);
dmaStreamSetDestination(WS2812_DMA_STREAM, &(WS2812_PWM_DRIVER.tim->CCR[WS2812_PWM_CHANNEL - 1])); // Ziel ist der An-Zeit im Cap-Comp-Register
dmaStreamSetMode(WS2812_DMA_STREAM, WB32_DMA_CHCFG_HWHIF(WS2812_DMA_CHANNEL) | WB32_DMA_CHCFG_DIR_M2P | WB32_DMA_CHCFG_PSIZE_WORD | WB32_DMA_CHCFG_MSIZE_WORD | WB32_DMA_CHCFG_MINC | WB32_DMA_CHCFG_CIRC | WB32_DMA_CHCFG_TCIE | WB32_DMA_CHCFG_PL(3));
dmaStreamAlloc(WS2812_PWM_DMA_STREAM - WB32_DMA_STREAM(0), 10, NULL, NULL);
dmaStreamSetSource(WS2812_PWM_DMA_STREAM, ws2812_frame_buffer);
dmaStreamSetDestination(WS2812_PWM_DMA_STREAM, &(WS2812_PWM_DRIVER.tim->CCR[WS2812_PWM_CHANNEL - 1])); // Ziel ist der An-Zeit im Cap-Comp-Register
dmaStreamSetMode(WS2812_PWM_DMA_STREAM, WB32_DMA_CHCFG_HWHIF(WS2812_PWM_DMA_CHANNEL) | WB32_DMA_CHCFG_DIR_M2P | WB32_DMA_CHCFG_PSIZE_WORD | WB32_DMA_CHCFG_MSIZE_WORD | WB32_DMA_CHCFG_MINC | WB32_DMA_CHCFG_CIRC | WB32_DMA_CHCFG_TCIE | WB32_DMA_CHCFG_PL(3));
#else
dmaStreamAlloc(WS2812_DMA_STREAM - STM32_DMA_STREAM(0), 10, NULL, NULL);
dmaStreamSetPeripheral(WS2812_DMA_STREAM, &(WS2812_PWM_DRIVER.tim->CCR[WS2812_PWM_CHANNEL - 1])); // Ziel ist der An-Zeit im Cap-Comp-Register
dmaStreamSetMemory0(WS2812_DMA_STREAM, ws2812_frame_buffer);
dmaStreamSetMode(WS2812_DMA_STREAM, STM32_DMA_CR_CHSEL(WS2812_DMA_CHANNEL) | STM32_DMA_CR_DIR_M2P | WS2812_DMA_PERIPHERAL_WIDTH | WS2812_DMA_MEMORY_WIDTH | STM32_DMA_CR_MINC | STM32_DMA_CR_CIRC | STM32_DMA_CR_PL(3));
dmaStreamAlloc(WS2812_PWM_DMA_STREAM - STM32_DMA_STREAM(0), 10, NULL, NULL);
dmaStreamSetPeripheral(WS2812_PWM_DMA_STREAM, &(WS2812_PWM_DRIVER.tim->CCR[WS2812_PWM_CHANNEL - 1])); // Ziel ist der An-Zeit im Cap-Comp-Register
dmaStreamSetMemory0(WS2812_PWM_DMA_STREAM, ws2812_frame_buffer);
dmaStreamSetMode(WS2812_PWM_DMA_STREAM, STM32_DMA_CR_CHSEL(WS2812_PWM_DMA_CHANNEL) | STM32_DMA_CR_DIR_M2P | WS2812_PWM_DMA_PERIPHERAL_WIDTH | WS2812_PWM_DMA_MEMORY_WIDTH | STM32_DMA_CR_MINC | STM32_DMA_CR_CIRC | STM32_DMA_CR_PL(3));
#endif
dmaStreamSetTransactionSize(WS2812_DMA_STREAM, WS2812_BIT_N);
dmaStreamSetTransactionSize(WS2812_PWM_DMA_STREAM, WS2812_BIT_N);
// M2P: Memory 2 Periph; PL: Priority Level
#if (STM32_DMA_SUPPORTS_DMAMUX == TRUE)
// If the MCU has a DMAMUX we need to assign the correct resource
dmaSetRequestSource(WS2812_DMA_STREAM, WS2812_DMAMUX_ID);
dmaSetRequestSource(WS2812_PWM_DMA_STREAM, WS2812_PWM_DMAMUX_ID);
#endif
// Start DMA
dmaStreamEnable(WS2812_DMA_STREAM);
dmaStreamEnable(WS2812_PWM_DMA_STREAM);
// Configure PWM
// NOTE: It's required that preload be enabled on the timer channel CCR register. This is currently enabled in the


Loading…
Cancel
Save