# TCA6507 LED and GPIO controller

_Peios Kernel / Hardware and drivers / Device-tree binding reference / LED bindings_

> Device-tree binding reference for TCA6507 LED and GPIO controller.

<!-- SPDX-License-Identifier: GPL-2.0-only -->


<a id="dt-root"></a>

**Schema identifier (<code>&#36;id</code>):** <span id="dt-09f478f44eb202ea573e"><code>&#34;http&#58;&#47;&#47;devicetree&#46;org&#47;schemas&#47;leds&#47;ti&#44;tca6507&#46;yaml&#35;&#34;</code></span>

**Schema dialect (<code>&#36;schema</code>):** <span id="dt-dcb375baab6014763a68"><code>&#34;http&#58;&#47;&#47;devicetree&#46;org&#47;meta&#45;schemas&#47;core&#46;yaml&#35;&#34;</code></span>

<a id="dt-e46b5a5dd81dbd751c9f"></a>

**Maintainers (<code>maintainers</code>):** <a id="dt-fbc39820abb8bb999095"></a> <span id="dt-fb78ddfc22abfc6fe56d"><code>&#34;NeilBrown &#60;neilb&#64;suse&#46;de&#62;&#34;</code></span>

<div id="dt-6d1c5ef59f0239d38c02">
<p style="white-space: pre-wrap">The TCA6507 is a programmable LED controller connected via I2C that can drive 7 separate lines either by holding them low, or by pulsing them with modulated width.</p>
</div>

<a id="dt-e1f655ed0ff4d595dadc"></a>

## Properties and child nodes (<code>properties</code>)

<a id="dt-5c1d81699dcbe840de83"></a>

### <code>compatible</code> — not listed as required here

**Exact value (<code>const</code>):** <span id="dt-1765195bf8e86c3ccec6"><code>&#34;ti&#44;tca6507&#34;</code></span>

<a id="dt-9c1635fdb65d87e33d77"></a>

### <code>reg</code> — not listed as required here

<div id="dt-571d87f60678ead6c5ff">
<p style="white-space: pre-wrap">I2C slave address of the controller.</p>
</div>

**Maximum number of items (<code>maxItems</code>):** <span id="dt-71421d35675d9a533ad2"><code>1</code></span>

<a id="dt-2efe70314a961a652abe"></a>

### <code>&#35;address&#45;cells</code> — not listed as required here

**Exact value (<code>const</code>):** <span id="dt-e6e6af09ab617572731b"><code>1</code></span>

<a id="dt-ee0e5bf71366d312f1dc"></a>

### <code>&#35;size&#45;cells</code> — not listed as required here

**Exact value (<code>const</code>):** <span id="dt-793e842f88ef513a8f93"><code>0</code></span>

<a id="dt-f5d51cae76398cdb9d95"></a>

### <code>gpio&#45;controller</code> — not listed as required here

<code>true</code> — No constraints added by this property rule.

<a id="dt-cfb238e0b7cdb276d83f"></a>

### <code>&#35;gpio&#45;cells</code> — not listed as required here

**Exact value (<code>const</code>):** <span id="dt-8950f722147d2cd640b8"><code>2</code></span>

<a id="dt-14035f3a8826cdac18bd"></a>

### <code>gpio&#45;line&#45;names</code> — not listed as required here

<code>true</code> — No constraints added by this property rule.

<a id="dt-e92215bd3c2f5373b164"></a>

## Properties matching a name pattern (<code>patternProperties</code>)

<a id="dt-b7b17956075a155836a0"></a>

### <code>&#94;led&#64;&#91;0&#45;6&#93;&#36;</code> — name matches this regular expression

**Value type (<code>type</code>):** <span id="dt-423128fd9230652539b4"><code>&#34;object&#34;</code></span>

**Shared schema rule (<code>&#36;ref</code>):** <span id="dt-a77709c39b4f72b837bf">[<code>common&#46;yaml&#35;</code>](</kernel/hardware/devicetree-bindings/dt-leds/common.md#dt-root>)</span>

<a id="dt-f0be1b254b366913347b"></a>

#### Properties not evaluated by applicable rules (<code>unevaluatedProperties</code>)

<code>false</code>

Not allowed by this rule.

<a id="dt-0f1dff026eae906d5ce8"></a>

#### Properties and child nodes (<code>properties</code>)

<a id="dt-68317305b10552604846"></a>

**<code>reg</code> — required here**

**Minimum value (<code>minimum</code>):** <span id="dt-31a930d6f42a4ba048a0"><code>0</code></span>

**Maximum value (<code>maximum</code>):** <span id="dt-876e876d6fe480df289f"><code>6</code></span>

**Required in this object (<code>required</code>):** <a id="dt-3cfcf9830b9bd18a98e3"></a> <span id="dt-eabfab8e21ab212334de"><code>&#34;reg&#34;</code></span>

<a id="dt-3d50eacea4f3099dc59a"></a>

### <code>&#94;gpio&#64;&#91;0&#45;6&#93;&#36;</code> — name matches this regular expression

**Value type (<code>type</code>):** <span id="dt-63ad3ea02cac42d31dbe"><code>&#34;object&#34;</code></span>

<a id="dt-de78a184aa88a1a3be07"></a>

#### Properties and child nodes (<code>properties</code>)

<a id="dt-b64139076cd79de5c76d"></a>

**<code>compatible</code> — required here**

**Exact value (<code>const</code>):** <span id="dt-5972cf5ae6d0fc77bc7a"><code>&#34;gpio&#34;</code></span>

<a id="dt-248c9847eddcb00c92b2"></a>

**<code>reg</code> — required here**

**Minimum value (<code>minimum</code>):** <span id="dt-da55f2bedc5ce5ae8339"><code>0</code></span>

**Maximum value (<code>maximum</code>):** <span id="dt-744b1dc5613381e2c875"><code>6</code></span>

<a id="dt-e126b283104f5b100441"></a>

#### Properties not matched by properties or patternProperties in this schema (<code>additionalProperties</code>)

<code>false</code>

Not allowed by this rule.

**Required in this object (<code>required</code>):** <a id="dt-28397c04c3be4ebcad20"></a> <span id="dt-72ee72247eab5c543353"><code>&#34;reg&#34;</code></span>, <span id="dt-2d9fddfa3a54655cfa0c"><code>&#34;compatible&#34;</code></span>

<a id="dt-158e3f6339df9dc0e448"></a>

## Condition (<code>if</code>)

> <a id="dt-2f1551355a8fd64fce9e"></a>
>
> ### Properties matching a name pattern (<code>patternProperties</code>)
>
> <a id="dt-c60fce8c3e65b7c136c7"></a>
>
> #### <code>&#94;gpio&#64;&#91;0&#45;6&#93;&#36;</code> — name matches this regular expression
>
> **Value type (<code>type</code>):** <span id="dt-79e0c70d88eff1e725f8"><code>&#34;object&#34;</code></span>
>
> <a id="dt-2bdfe54ab204a4d0cd4e"></a>
>
> **Properties and child nodes (<code>properties</code>)**
>
> <a id="dt-8903027f92c91ca15c37"></a>
>
> **<code>compatible</code> — not listed as required here**
>
> <a id="dt-b2aa74ca3e61634737e3"></a>
>
> **Rule for matching array elements (<code>contains</code>)**
>
> > **Exact value (<code>const</code>):** <span id="dt-0f4406160c6084774e33"><code>&#34;gpio&#34;</code></span>

<a id="dt-94d3067a06aec87aad7f"></a>

## When the condition matches (<code>then</code>)

> **Required in this object (<code>required</code>):** <a id="dt-824165741bab07e919e7"></a> <span id="dt-0be16f81402541b26aff"><code>&#34;gpio&#45;controller&#34;</code></span>, <span id="dt-dd9db9085e2885964a9c"><code>&#34;&#35;gpio&#45;cells&#34;</code></span>

<a id="dt-738c4b4f9e483441138b"></a>

## Properties not matched by properties or patternProperties in this schema (<code>additionalProperties</code>)

<code>false</code>

Not allowed by this rule.

<a id="dt-1a130cabaa8a47b058bf"></a>

## Examples (<code>examples</code>)

<pre id="dt-0bd6510295af0c95ff2d"><code class="language-dts">
#include &lt;dt-bindings/gpio/gpio.h&gt;
#include &lt;dt-bindings/leds/common.h&gt;

i2c {
    #address-cells = &lt;1&gt;;
    #size-cells = &lt;0&gt;;

    led-controller@45 {
        compatible = "ti,tca6507";
        #address-cells = &lt;1&gt;;
        #size-cells = &lt;0&gt;;
        reg = &lt;0x45&gt;;

        gpio-controller;
        #gpio-cells = &lt;2&gt;;

        gpio-line-names = "wifi_reset@6";

        led@0 {
            label = "gta04:red:aux";
            reg = &lt;0x0&gt;;
        };

        led@1 {
            label = "gta04:green:aux";
            reg = &lt;0x1&gt;;
        };

        led@3 {
            reg = &lt;0x3&gt;;
            color = &lt;LED_COLOR_ID_RED&gt;;
            function = LED_FUNCTION_POWER;
            linux,default-trigger = "default-on";
        };

        led@4 {
            color = &lt;LED_COLOR_ID_GREEN&gt;;
            function = LED_FUNCTION_POWER;
            reg = &lt;0x4&gt;;
        };

        gpio@6 {
            compatible = "gpio";
            reg = &lt;0x6&gt;;
        };
    };
};
</code></pre>

## Source notes

<details>
<summary>Annotations retained from the schema source</summary>

<p id="dt-comment-0"><strong>Line 1:</strong> <span> SPDX-License-Identifier: GPL-2.0-only</span></p>

</details>
