]> git.karo-electronics.de Git - karo-tx-linux.git/blob - Documentation/devicetree/bindings/leds/leds-lp55xx.txt
Merge branch 'for-linus' of git://git.kernel.org/pub/scm/linux/kernel/git/dtor/input
[karo-tx-linux.git] / Documentation / devicetree / bindings / leds / leds-lp55xx.txt
1 Binding for TI/National Semiconductor LP55xx Led Drivers
2
3 Required properties:
4 - compatible: "national,lp5521" or "national,lp5523" or "ti,lp5562" or "ti,lp8501"
5 - reg: I2C slave address
6 - clock-mode: Input clock mode, (0: automode, 1: internal, 2: external)
7
8 Each child has own specific current settings
9 - led-cur: Current setting at each led channel (mA x10, 0 if led is not connected)
10 - max-cur: Maximun current at each led channel.
11
12 Optional properties:
13 - label: Used for naming LEDs
14 - pwr-sel: LP8501 specific property. Power selection for output channels.
15          0: D1~9 are connected to VDD
16          1: D1~6 with VDD, D7~9 with VOUT
17          2: D1~6 with VOUT, D7~9 with VDD
18          3: D1~9 are connected to VOUT
19
20 Alternatively, each child can have specific channel name
21 - chan-name: Name of each channel name
22
23 example 1) LP5521
24 3 LED channels, external clock used. Channel names are 'lp5521_pri:channel0',
25 'lp5521_pri:channel1' and 'lp5521_pri:channel2'
26
27 lp5521@32 {
28         compatible = "national,lp5521";
29         reg = <0x32>;
30         label = "lp5521_pri";
31         clock-mode = /bits/ 8 <2>;
32
33         chan0 {
34                 led-cur = /bits/ 8 <0x2f>;
35                 max-cur = /bits/ 8 <0x5f>;
36         };
37
38         chan1 {
39                 led-cur = /bits/ 8 <0x2f>;
40                 max-cur = /bits/ 8 <0x5f>;
41         };
42
43         chan2 {
44                 led-cur = /bits/ 8 <0x2f>;
45                 max-cur = /bits/ 8 <0x5f>;
46         };
47 };
48
49 example 2) LP5523
50 9 LED channels with specific name. Internal clock used.
51 The I2C slave address is configurable with ASEL1 and ASEL0 pins.
52 Available addresses are 32/33/34/35h.
53
54 ASEL1    ASEL0    Address
55 -------------------------
56  GND      GND       32h
57  GND      VEN       33h
58  VEN      GND       34h
59  VEN      VEN       35h
60
61 lp5523@32 {
62         compatible = "national,lp5523";
63         reg = <0x32>;
64         clock-mode = /bits/ 8 <1>;
65
66         chan0 {
67                 chan-name = "d1";
68                 led-cur = /bits/ 8 <0x14>;
69                 max-cur = /bits/ 8 <0x20>;
70         };
71
72         chan1 {
73                 chan-name = "d2";
74                 led-cur = /bits/ 8 <0x14>;
75                 max-cur = /bits/ 8 <0x20>;
76         };
77
78         chan2 {
79                 chan-name = "d3";
80                 led-cur = /bits/ 8 <0x14>;
81                 max-cur = /bits/ 8 <0x20>;
82         };
83
84         chan3 {
85                 chan-name = "d4";
86                 led-cur = /bits/ 8 <0x14>;
87                 max-cur = /bits/ 8 <0x20>;
88         };
89
90         chan4 {
91                 chan-name = "d5";
92                 led-cur = /bits/ 8 <0x14>;
93                 max-cur = /bits/ 8 <0x20>;
94         };
95
96         chan5 {
97                 chan-name = "d6";
98                 led-cur = /bits/ 8 <0x14>;
99                 max-cur = /bits/ 8 <0x20>;
100         };
101
102         chan6 {
103                 chan-name = "d7";
104                 led-cur = /bits/ 8 <0x14>;
105                 max-cur = /bits/ 8 <0x20>;
106         };
107
108         chan7 {
109                 chan-name = "d8";
110                 led-cur = /bits/ 8 <0x14>;
111                 max-cur = /bits/ 8 <0x20>;
112         };
113
114         chan8 {
115                 chan-name = "d9";
116                 led-cur = /bits/ 8 <0x14>;
117                 max-cur = /bits/ 8 <0x20>;
118         };
119 };
120
121 example 3) LP5562
122 4 channels are defined.
123
124 lp5562@30 {
125         compatible = "ti,lp5562";
126         reg = <0x30>;
127         clock-mode = /bits/8 <2>;
128
129         chan0 {
130                 chan-name = "R";
131                 led-cur = /bits/ 8 <0x20>;
132                 max-cur = /bits/ 8 <0x60>;
133         };
134
135         chan1 {
136                 chan-name = "G";
137                 led-cur = /bits/ 8 <0x20>;
138                 max-cur = /bits/ 8 <0x60>;
139         };
140
141         chan2 {
142                 chan-name = "B";
143                 led-cur = /bits/ 8 <0x20>;
144                 max-cur = /bits/ 8 <0x60>;
145         };
146
147         chan3 {
148                 chan-name = "W";
149                 led-cur = /bits/ 8 <0x20>;
150                 max-cur = /bits/ 8 <0x60>;
151         };
152 };
153
154 example 4) LP8501
155 9 channels are defined. The 'pwr-sel' is LP8501 specific property.
156 Others are same as LP5523.
157
158 lp8501@32 {
159         compatible = "ti,lp8501";
160         reg = <0x32>;
161         clock-mode = /bits/ 8 <2>;
162         pwr-sel = /bits/ 8 <3>; /* D1~9 connected to VOUT */
163
164         chan0 {
165                 chan-name = "d1";
166                 led-cur = /bits/ 8 <0x14>;
167                 max-cur = /bits/ 8 <0x20>;
168         };
169
170         chan1 {
171                 chan-name = "d2";
172                 led-cur = /bits/ 8 <0x14>;
173                 max-cur = /bits/ 8 <0x20>;
174         };
175
176         chan2 {
177                 chan-name = "d3";
178                 led-cur = /bits/ 8 <0x14>;
179                 max-cur = /bits/ 8 <0x20>;
180         };
181
182         chan3 {
183                 chan-name = "d4";
184                 led-cur = /bits/ 8 <0x14>;
185                 max-cur = /bits/ 8 <0x20>;
186         };
187
188         chan4 {
189                 chan-name = "d5";
190                 led-cur = /bits/ 8 <0x14>;
191                 max-cur = /bits/ 8 <0x20>;
192         };
193
194         chan5 {
195                 chan-name = "d6";
196                 led-cur = /bits/ 8 <0x14>;
197                 max-cur = /bits/ 8 <0x20>;
198         };
199
200         chan6 {
201                 chan-name = "d7";
202                 led-cur = /bits/ 8 <0x14>;
203                 max-cur = /bits/ 8 <0x20>;
204         };
205
206         chan7 {
207                 chan-name = "d8";
208                 led-cur = /bits/ 8 <0x14>;
209                 max-cur = /bits/ 8 <0x20>;
210         };
211
212         chan8 {
213                 chan-name = "d9";
214                 led-cur = /bits/ 8 <0x14>;
215                 max-cur = /bits/ 8 <0x20>;
216         };
217 };