LED effects must be implemented in the lower-half of the LED driver.
The interface is designed to supports the following LED effects:
- intenisty (PWM)
- Bling (Timer)
- Fade in, Fade out (Ramp)
0c3db448bb
added the option to generate the waveforms to drive ws2812 and similar LEDs using different
hardware (e.g. RP2040 PIO instead of SPI).
For that new mode, the concept of CONFIG_WS2812_FREQUENCY is different. Instead of
the SPI frequency (commonly a few MHz), it is the frequency of the actual output waveform
(commonly 400 or 800 kHz).
There was an attempt to express the SPI frequency divided by 10, but it's not actually the
case either (it would be divided by 8).
I think it is clearer to explain in Kconfig what CONFIG_WS2812_FREQUENCY means for each mode
and go back to the previous behaviour for the original SPI mode (also to avoid breaking
out-of-tree boards).
The WS2812 is very common in LED strips as it is an integrated
controller and LED. It is driven by a single data line, but
the timing requirements can be met by using most SPI controllers
and the use of DMA.
This driver has been validated on the nRF52 arch both with a
single LED and a strip of 144.
Signed-off-by: Brennan Ashton <bashton@brennanashton.com>
so the lower half driver don't need include the specific board.h
Signed-off-by: Xiang Xiao <xiaoxiang@xiaomi.com>
Change-Id: Icf6638a6865bac42150b5957376e55909f041d40
and let USERLED_LOWER depends on ARCH_HAVE_LEDS instead
Signed-off-by: Xiang Xiao <xiaoxiang@xiaomi.com>
Change-Id: Ie03e76d90b61a3d8d3457ccdd319a247b6075fa8
configs/stm32f4discovery/src: Add board support to MAX7219 as numeric display controller
drivers/leds/max7219.c: Add support to MAX7219 to control 7-segment displays