mirror of
https://github.com/qmk/qmk_firmware.git
synced 2025-02-27 01:56:43 +00:00
16 lines
62 KiB
JavaScript
16 lines
62 KiB
JavaScript
|
import { _ as _export_sfc, c as createElementBlock, o as openBlock, a8 as createStaticVNode } from "./chunks/framework.DyMmIvSC.js";
|
|||
|
const __pageData = JSON.parse('{"title":"LED Matrix Lighting","description":"","frontmatter":{},"headers":[],"relativePath":"features/led_matrix.md","filePath":"features/led_matrix.md"}');
|
|||
|
const _sfc_main = { name: "features/led_matrix.md" };
|
|||
|
const _hoisted_1 = /* @__PURE__ */ createStaticVNode('<h1 id="led-matrix-lighting" tabindex="-1">LED Matrix Lighting <a class="header-anchor" href="#led-matrix-lighting" aria-label="Permalink to "LED Matrix Lighting {#led-matrix-lighting}""></a></h1><p>This feature allows you to use LED matrices driven by external drivers. It hooks into the backlight system so you can use the same keycodes as backlighting to control it.</p><p>If you want to use RGB LED's you should use the <a href="./rgb_matrix">RGB Matrix Subsystem</a> instead.</p><h2 id="driver-configuration" tabindex="-1">Driver Configuration <a class="header-anchor" href="#driver-configuration" aria-label="Permalink to "Driver Configuration {#driver-configuration}""></a></h2><p>LED Matrix is an abstraction layer on top of an underlying LED driver API. The list of supported LED drivers is below; see the respective documentation for information on how to configure the driver.</p><table><thead><tr><th>Driver</th><th>Max LEDs</th></tr></thead><tbody><tr><td><a href="./../drivers/is31fl3218">IS31FL3218</a></td><td>18</td></tr><tr><td><a href="./../drivers/is31fl3236">IS31FL3236</a></td><td>36</td></tr><tr><td><a href="./../drivers/is31fl3729">IS31FL3729</a></td><td>135</td></tr><tr><td><a href="./../drivers/is31fl3731">IS31FL3731</a></td><td>144</td></tr><tr><td><a href="./../drivers/is31fl3733">IS31FL3733</a></td><td>192</td></tr><tr><td><a href="./../drivers/is31fl3736">IS31FL3736</a></td><td>96</td></tr><tr><td><a href="./../drivers/is31fl3737">IS31FL3737</a></td><td>144</td></tr><tr><td><a href="./../drivers/is31fl3741">IS31FL3741</a></td><td>351</td></tr><tr><td><a href="./../drivers/is31fl3742a">IS31FL3742A</a></td><td>180</td></tr><tr><td><a href="./../drivers/is31fl3743a">IS31FL3743A</a></td><td>198</td></tr><tr><td><a href="./../drivers/is31fl3745">IS31FL3745</a></td><td>144</td></tr><tr><td><a href="./../drivers/is31fl3746a">IS31FL3746A</a></td><td>72</td></tr><tr><td><a href="./../drivers/snled27351">SNLED27351</a></td><td>192</td></tr></tbody></table><p>To assign the LED Matrix driver, add the following to your <code>rules.mk</code>, for example:</p><div class="language-make vp-adaptive-theme"><button title="Copy Code" class="copy"></button><span class="lang">make</span><pre class="shiki shiki-themes github-light github-dark vp-code"><code><span class="line"><span style="--shiki-light:#24292E;--shiki-dark:#E1E4E8;">LED_MATRIX_DRIVER = is31fl3218</span></span></code></pre></div><h2 id="common-configuration" tabindex="-1">Common Configuration <a class="header-anchor" href="#common-configuration" aria-label="Permalink to "Common Configuration {#common-configuration}""></a></h2><p>From this point forward the configuration is the same for all the drivers. The <code>led_config_t</code> struct provides a key electrical matrix to led index lookup table, what the physical position of each LED is on the board, and what type of key or usage the LED if the LED represents. Here is a brief example:</p><div class="language-c vp-adaptive-theme"><button title="Copy Code" class="copy"></button><span class="lang">c</span><pre class="shiki shiki-themes github-light github-dark vp-code"><code><span class="line"><span style="--shiki-light:#005CC5;--shiki-dark:#79B8FF;">led_config_t</span><span style="--shiki-light:#24292E;--shiki-dark:#E1E4E8;"> g_led_config </span><span style="--shiki-light:#D73A49;--shiki-dark:#F97583;">=</span><span style="--shiki-light:#24292E;--shiki-dark:#E1E4E8;"> { {</span></span>\n<span class="line"><span style="--shiki-light:#6A737D;--shiki-dark:#6A737D;"> // Key Matrix to LED Index</span></span>\n<span class="line"><span style="--shiki-light:#24292E;--shiki-dark:#E1E4E8;"> { </span><span style="--shiki-light:#005CC5;--shiki-dark:#79B8FF;">5</span><span style="--shiki-light:#24292E;--shiki-dark:#E1E4E8;">, NO_LED, NO_LED, </span><span style="--shiki-light:#005CC5;--shiki-dark:#79B8FF;">0</span><span style="--shiki-light:#24292E;--shiki-dark:#E1E4E8;"> },</span></span>\n<span class="line"><span style="--shi
|
|||
|
const _hoisted_183 = [
|
|||
|
_hoisted_1
|
|||
|
];
|
|||
|
function _sfc_render(_ctx, _cache, $props, $setup, $data, $options) {
|
|||
|
return openBlock(), createElementBlock("div", null, _hoisted_183);
|
|||
|
}
|
|||
|
const led_matrix = /* @__PURE__ */ _export_sfc(_sfc_main, [["render", _sfc_render]]);
|
|||
|
export {
|
|||
|
__pageData,
|
|||
|
led_matrix as default
|
|||
|
};
|