18c2ecf20Sopenharmony_ci* Single Byte SPI LED Device Driver. 28c2ecf20Sopenharmony_ci 38c2ecf20Sopenharmony_ciThe driver can be used for controllers with a very simple SPI protocol: 48c2ecf20Sopenharmony_ci- one LED is controlled by a single byte on MOSI 58c2ecf20Sopenharmony_ci- the value of the byte gives the brightness between two values (lowest to 68c2ecf20Sopenharmony_ci highest) 78c2ecf20Sopenharmony_ci- no return value is necessary (no MISO signal) 88c2ecf20Sopenharmony_ci 98c2ecf20Sopenharmony_ciThe value for lowest and highest brightness is dependent on the device and 108c2ecf20Sopenharmony_citherefore on the compatible string. 118c2ecf20Sopenharmony_ci 128c2ecf20Sopenharmony_ciDepending on the compatible string some special functions (like hardware 138c2ecf20Sopenharmony_ciaccelerated blinking) might can be supported too. 148c2ecf20Sopenharmony_ci 158c2ecf20Sopenharmony_ciThe driver currently only supports one LED. The properties of the LED are 168c2ecf20Sopenharmony_ciconfigured in a sub-node in the device node. 178c2ecf20Sopenharmony_ci 188c2ecf20Sopenharmony_ciRequired properties: 198c2ecf20Sopenharmony_ci- compatible: should be one of 208c2ecf20Sopenharmony_ci * "ubnt,acb-spi-led" microcontroller (SONiX 8F26E611LA) based device 218c2ecf20Sopenharmony_ci used for example in Ubiquiti airCube ISP 228c2ecf20Sopenharmony_ci 238c2ecf20Sopenharmony_ciProperty rules described in Documentation/devicetree/bindings/spi/spi-bus.txt 248c2ecf20Sopenharmony_ciapply. 258c2ecf20Sopenharmony_ci 268c2ecf20Sopenharmony_ciLED sub-node properties: 278c2ecf20Sopenharmony_ci- label: 288c2ecf20Sopenharmony_ci see Documentation/devicetree/bindings/leds/common.txt 298c2ecf20Sopenharmony_ci- default-state: 308c2ecf20Sopenharmony_ci see Documentation/devicetree/bindings/leds/common.txt 318c2ecf20Sopenharmony_ci Only "on" and "off" are supported. 328c2ecf20Sopenharmony_ci 338c2ecf20Sopenharmony_ciExample: 348c2ecf20Sopenharmony_ci 358c2ecf20Sopenharmony_ciled-controller@0 { 368c2ecf20Sopenharmony_ci compatible = "ubnt,acb-spi-led"; 378c2ecf20Sopenharmony_ci reg = <0>; 388c2ecf20Sopenharmony_ci spi-max-frequency = <100000>; 398c2ecf20Sopenharmony_ci 408c2ecf20Sopenharmony_ci led { 418c2ecf20Sopenharmony_ci label = "white:status"; 428c2ecf20Sopenharmony_ci default-state = "on"; 438c2ecf20Sopenharmony_ci }; 448c2ecf20Sopenharmony_ci}; 45