1
0
Fork 0

[Docs] Recommend the use of RGB matrix functions for code (#15744)

* Recommend the use of functions instead of keycodes

* Commit suggested review

Co-authored-by: Nick Brassel <nick@tzarc.org>

Co-authored-by: Nick Brassel <nick@tzarc.org>
This commit is contained in:
Albert Y 2022-01-11 00:23:28 +08:00 committed by GitHub
parent 63d3ad155a
commit 8a4fae3b32
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23

View file

@ -417,6 +417,7 @@ All RGB keycodes are currently shared with the RGBLIGHT system:
`RGB_MODE_PLAIN`, `RGB_MODE_BREATHE`, `RGB_MODE_RAINBOW`, and `RGB_MODE_SWIRL` are the only ones that are mapped properly. The rest don't have a direct equivalent, and are not mapped.
?> `RGB_*` keycodes cannot be used with functions like `tap_code16(RGB_HUD)` as they're not USB HID keycodes. If you wish to replicate similar behaviour in custom code within your firmware (e.g. inside `encoder_update_user()` or `process_record_user()`), the equivalent [RGB functions](#functions-idfunctions) should be used instead.
!> By default, if you have both the [RGB Light](feature_rgblight.md) and the RGB Matrix feature enabled, these keycodes will work for both features, at the same time. You can disable the keycode functionality by defining the `*_DISABLE_KEYCODES` option for the specific feature.
## RGB Matrix Effects :id=rgb-matrix-effects