Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Migrate RGB Matrix config to info.json - B #22806

Merged
merged 2 commits into from
Jan 4, 2024
Merged
Show file tree
Hide file tree
Changes from 1 commit
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Next Next commit
Migrate RGB Matrix config to info.json
  • Loading branch information
zvecr committed Jan 4, 2024
commit afd9729cf966f10d2aa2d8e9005c3fde4816df25
14 changes: 2 additions & 12 deletions keyboards/bandominedoni/config.h
Original file line number Diff line number Diff line change
Expand Up @@ -24,18 +24,10 @@
#define SPLIT_USB_DETECT

#ifdef RGB_MATRIX_ENABLE

/* ws2812 RGB MATRIX */
# define RGB_MATRIX_LED_COUNT 76

// reacts to keypresses
# define RGB_MATRIX_KEYPRESSES

// for all fingers used at once.
# define LED_HITS_TO_REMEMBER 10

# define RGB_MATRIX_MAXIMUM_BRIGHTNESS 50
// the above brighness setting has no effect on rgb_matrix_set_color().
// the max brightness setting has no effect on rgb_matrix_set_color().
// Use darker colors instead.
/* RGB darker COLORS */
# define RGB_DARKWHITE 0x33, 0x33, 0x33
Expand All @@ -58,8 +50,6 @@
# define RGB_DARKPINK 0x33, 0x19, 0x26

// https://docs.qmk.fm/#/feature_rgb_matrix
// Enable suspend mode.
# define RGB_MATRIX_SLEEP

# ifdef CONSOLE_ENABLE
# define ENABLE_RGB_MATRIX_SOLID_REACTIVE_MULTIWIDE
Expand All @@ -84,7 +74,7 @@
// RAINDROPS don't match well with layer LED indicator (oc) using rgb_matrix_set_color().
// #define ENABLE_RGB_MATRIX_RAINDROPS
// #define ENABLE_RGB_MATRIX_JELLYBEAN_RAINDROPS
// Recommendend not to use these.
// Recommended not to use these.
# ifndef VIA_ENABLE
# define ENABLE_RGB_MATRIX_GRADIENT_LEFT_RIGHT
# define ENABLE_RGB_MATRIX_BAND_VAL
Expand Down
4 changes: 3 additions & 1 deletion keyboards/bandominedoni/info.json
Original file line number Diff line number Diff line change
Expand Up @@ -9,7 +9,9 @@
"device_version": "0.0.1"
},
"rgb_matrix": {
"driver": "ws2812"
"driver": "ws2812",
"max_brightness": 50,
"sleep": true
},
"matrix_pins": {
"cols": ["D1", "E6", "F7", "B1", "B3", "B2", "D0"],
Expand Down
64 changes: 0 additions & 64 deletions keyboards/basekeys/trifecta/config.h
Original file line number Diff line number Diff line change
Expand Up @@ -16,8 +16,6 @@

#pragma once

#define RGB_MATRIX_LED_COUNT 80

/* Mechanical locking support. Use KC_LCAP, KC_LNUM or KC_LSCR instead in keymap */
#define LOCKING_SUPPORT_ENABLE

Expand All @@ -26,65 +24,3 @@

/* EEPROM for via */
#define DYNAMIC_KEYMAP_LAYER_COUNT 3

#ifdef RGB_MATRIX_ENABLE
# define RGB_MATRIX_KEYPRESSES // reacts to keypresses
// # define RGB_MATRIX_KEYRELEASES // reacts to keyreleases (instead of keypresses)
//# define RGB_MATRIX_SLEEP // turn off effects when suspended
# define RGB_MATRIX_FRAMEBUFFER_EFFECTS
# define RGB_MATRIX_LED_PROCESS_LIMIT (RGB_MATRIX_LED_COUNT + 4) / 5 // limits the number of LEDs to process in an animation per task run (increases keyboard responsiveness)
# define RGB_MATRIX_LED_FLUSH_LIMIT 16 // limits in milliseconds how frequently an animation will update the LEDs. 16 (16ms) is equivalent to limiting to 60fps (increases keyboard responsiveness)
# define RGB_MATRIX_MAXIMUM_BRIGHTNESS 150 // limits maximum brightness of LEDs to 150 out of 255. Higher may cause the controller to crash.

/* Disable the animations you don't want/need. You will need to disable a good number of these *
* because they take up a lot of space. Disable until you can successfully compile your firmware. */
// RGB Matrix Animation modes. Explicitly enabled
// For full list of effects, see:
// https://docs.qmk.fm/#/feature_rgb_matrix?id=rgb-matrix-effects
# define ENABLE_RGB_MATRIX_ALPHAS_MODS
# define ENABLE_RGB_MATRIX_GRADIENT_UP_DOWN
# define ENABLE_RGB_MATRIX_GRADIENT_LEFT_RIGHT
# define ENABLE_RGB_MATRIX_BREATHING
# define ENABLE_RGB_MATRIX_BAND_SAT
# define ENABLE_RGB_MATRIX_BAND_VAL
# define ENABLE_RGB_MATRIX_BAND_PINWHEEL_SAT
# define ENABLE_RGB_MATRIX_BAND_PINWHEEL_VAL
# define ENABLE_RGB_MATRIX_BAND_SPIRAL_SAT
# define ENABLE_RGB_MATRIX_BAND_SPIRAL_VAL
# define ENABLE_RGB_MATRIX_CYCLE_ALL
# define ENABLE_RGB_MATRIX_CYCLE_LEFT_RIGHT
# define ENABLE_RGB_MATRIX_CYCLE_UP_DOWN
# define ENABLE_RGB_MATRIX_RAINBOW_MOVING_CHEVRON
# define ENABLE_RGB_MATRIX_CYCLE_OUT_IN
# define ENABLE_RGB_MATRIX_CYCLE_OUT_IN_DUAL
# define ENABLE_RGB_MATRIX_CYCLE_PINWHEEL
# define ENABLE_RGB_MATRIX_CYCLE_SPIRAL
# define ENABLE_RGB_MATRIX_DUAL_BEACON
# define ENABLE_RGB_MATRIX_RAINBOW_BEACON
# define ENABLE_RGB_MATRIX_RAINBOW_PINWHEELS
# define ENABLE_RGB_MATRIX_RAINDROPS
# define ENABLE_RGB_MATRIX_JELLYBEAN_RAINDROPS
# define ENABLE_RGB_MATRIX_HUE_BREATHING
# define ENABLE_RGB_MATRIX_HUE_PENDULUM
# define ENABLE_RGB_MATRIX_HUE_WAVE
# define ENABLE_RGB_MATRIX_PIXEL_RAIN
# define ENABLE_RGB_MATRIX_PIXEL_FLOW
# define ENABLE_RGB_MATRIX_PIXEL_FRACTAL
// enabled only if RGB_MATRIX_FRAMEBUFFER_EFFECTS is defined
# define ENABLE_RGB_MATRIX_TYPING_HEATMAP
# define ENABLE_RGB_MATRIX_DIGITAL_RAIN
// enabled only of RGB_MATRIX_KEYPRESSES or RGB_MATRIX_KEYRELEASES is defined
# define ENABLE_RGB_MATRIX_SOLID_REACTIVE_SIMPLE
# define ENABLE_RGB_MATRIX_SOLID_REACTIVE
# define ENABLE_RGB_MATRIX_SOLID_REACTIVE_WIDE
# define ENABLE_RGB_MATRIX_SOLID_REACTIVE_MULTIWIDE
# define ENABLE_RGB_MATRIX_SOLID_REACTIVE_CROSS
# define ENABLE_RGB_MATRIX_SOLID_REACTIVE_MULTICROSS
# define ENABLE_RGB_MATRIX_SOLID_REACTIVE_NEXUS
# define ENABLE_RGB_MATRIX_SOLID_REACTIVE_MULTINEXUS
# define ENABLE_RGB_MATRIX_SPLASH
# define ENABLE_RGB_MATRIX_MULTISPLASH
# define ENABLE_RGB_MATRIX_SOLID_SPLASH
# define ENABLE_RGB_MATRIX_SOLID_MULTISPLASH

#endif
50 changes: 48 additions & 2 deletions keyboards/basekeys/trifecta/info.json
Original file line number Diff line number Diff line change
Expand Up @@ -46,11 +46,57 @@
"rgb_matrix": {
"sat_steps": 8,
"val_steps": 8,
"speed_steps": 10
"speed_steps": 10,
"max_brightness": 150,
"animations": {
"alphas_mods": true,
"gradient_up_down": true,
"gradient_left_right": true,
"breathing": true,
"band_sat": true,
"band_val": true,
"band_pinwheel_sat": true,
"band_pinwheel_val": true,
"band_spiral_sat": true,
"band_spiral_val": true,
"cycle_all": true,
"cycle_left_right": true,
"cycle_up_down": true,
"rainbow_moving_chevron": true,
"cycle_out_in": true,
"cycle_out_in_dual": true,
"cycle_pinwheel": true,
"cycle_spiral": true,
"dual_beacon": true,
"rainbow_beacon": true,
"rainbow_pinwheels": true,
"raindrops": true,
"jellybean_raindrops": true,
"hue_breathing": true,
"hue_pendulum": true,
"hue_wave": true,
"pixel_rain": true,
"pixel_flow": true,
"pixel_fractal": true,
"typing_heatmap": true,
"digital_rain": true,
"solid_reactive_simple": true,
"solid_reactive": true,
"solid_reactive_wide": true,
"solid_reactive_multiwide": true,
"solid_reactive_cross": true,
"solid_reactive_multicross": true,
"solid_reactive_nexus": true,
"solid_reactive_multinexus": true,
"splash": true,
"multisplash": true,
"solid_splash": true,
"solid_multisplash": true
}
},
"processor": "atmega32u4",
"bootloader": "atmel-dfu",
"layouts": {
"layouts": {
"LAYOUT": {
"layout": [
{"matrix": [1, 0], "x": 0, "y": 0},
Expand Down
7 changes: 0 additions & 7 deletions keyboards/bastardkb/charybdis/3x5/config.h
Original file line number Diff line number Diff line change
Expand Up @@ -20,10 +20,3 @@

/* Trackball angle adjustment. */
#define ROTATIONAL_TRANSFORM_ANGLE -25

/* RGB settings. */
#ifdef RGB_MATRIX_ENABLE
# define RGB_MATRIX_LED_COUNT 36
# define RGB_MATRIX_SPLIT \
{ 18, 18 }
#endif
3 changes: 3 additions & 0 deletions keyboards/bastardkb/charybdis/3x5/info.json
Original file line number Diff line number Diff line change
Expand Up @@ -5,6 +5,9 @@
"pid": "0x1832",
"vid": "0xA8F8"
},
"rgb_matrix": {
"split_count": [18, 18]
},
"layout_aliases": {
"LAYOUT_charybdis_3x5": "LAYOUT"
},
Expand Down
7 changes: 0 additions & 7 deletions keyboards/bastardkb/charybdis/3x6/config.h
Original file line number Diff line number Diff line change
Expand Up @@ -20,10 +20,3 @@

/* Trackball angle adjustment. */
#define ROTATIONAL_TRANSFORM_ANGLE -25

/* RGB settings. */
#ifdef RGB_MATRIX_ENABLE
# define RGB_MATRIX_LED_COUNT 42
# define RGB_MATRIX_SPLIT \
{ 21, 21 }
#endif
5 changes: 4 additions & 1 deletion keyboards/bastardkb/charybdis/3x6/info.json
Original file line number Diff line number Diff line change
Expand Up @@ -3,10 +3,13 @@
"usb": {
"pid": "0x1834"
},
"rgb_matrix": {
"split_count": [21, 21]
},
"layout_aliases": {
"LAYOUT_charybdis_3x6": "LAYOUT"
},
"layouts": {
"layouts": {
"LAYOUT": {
"layout": [
{"label": "L00", "matrix": [0, 0], "x": 0, "y": 0},
Expand Down
7 changes: 0 additions & 7 deletions keyboards/bastardkb/charybdis/4x6/config.h
Original file line number Diff line number Diff line change
Expand Up @@ -20,10 +20,3 @@

/* Trackball angle adjustment. */
#define ROTATIONAL_TRANSFORM_ANGLE -25

/* RGB settings. */
#ifdef RGB_MATRIX_ENABLE
# define RGB_MATRIX_LED_COUNT 58
# define RGB_MATRIX_SPLIT \
{ 29, 29 }
#endif
3 changes: 3 additions & 0 deletions keyboards/bastardkb/charybdis/4x6/info.json
Original file line number Diff line number Diff line change
Expand Up @@ -5,6 +5,9 @@
"pid": "0x1833",
"vid": "0xA8F8"
},
"rgb_matrix": {
"split_count": [29, 29]
},
"layout_aliases": {
"LAYOUT_charybdis_4x6": "LAYOUT"
},
Expand Down
16 changes: 0 additions & 16 deletions keyboards/bastardkb/charybdis/config.h
Original file line number Diff line number Diff line change
Expand Up @@ -18,7 +18,6 @@

#pragma once


/* Pointing device configuration. */

// Enable use of pointing device on slave split.
Expand All @@ -35,21 +34,6 @@

/* RGB matrix support. */
#ifdef RGB_MATRIX_ENABLE
# define SPLIT_TRANSPORT_MIRROR
# define RGB_MATRIX_MAXIMUM_BRIGHTNESS 255
# define RGB_MATRIX_SLEEP
# define RGB_MATRIX_KEYPRESSES

// Startup values.
# define RGB_MATRIX_DEFAULT_VAL 64

// Rainbow swirl as startup mode.
# define ENABLE_RGB_MATRIX_CYCLE_LEFT_RIGHT
# define RGB_MATRIX_DEFAULT_MODE RGB_MATRIX_CYCLE_LEFT_RIGHT

// Slow swirl at startup.
# define RGB_MATRIX_DEFAULT_SPD 32

# ifndef __arm__
// Disable control of RGB matrix by keycodes (must use firmware implementation
// to control the feature).
Expand Down
19 changes: 19 additions & 0 deletions keyboards/bastardkb/charybdis/info.json
Original file line number Diff line number Diff line change
@@ -0,0 +1,19 @@
{
"rgb_matrix": {
"animations": {
"cycle_left_right": true
},
"default": {
"speed": 32,
"val": 64
},
"sleep": true
},
"split": {
"transport": {
"sync": {
"matrix_state": true
}
}
}
}
12 changes: 0 additions & 12 deletions keyboards/bastardkb/dilemma/3x5_3/config.h
Original file line number Diff line number Diff line change
Expand Up @@ -42,15 +42,3 @@
#define RP2040_BOOTLOADER_DOUBLE_TAP_RESET
#define RP2040_BOOTLOADER_DOUBLE_TAP_RESET_LED GP17
#define RP2040_BOOTLOADER_DOUBLE_TAP_RESET_TIMEOUT 500U

/* RGB matrix support. */
#ifdef RGB_MATRIX_ENABLE
# define SPLIT_TRANSPORT_MIRROR
# define RGB_MATRIX_SLEEP
# define RGB_MATRIX_KEYPRESSES
# define RGB_MATRIX_FRAMEBUFFER_EFFECTS

// Startup values.
# define RGB_MATRIX_DEFAULT_VAL 128
# define RGB_MATRIX_DEFAULT_SPD 32
#endif
10 changes: 9 additions & 1 deletion keyboards/bastardkb/dilemma/3x5_3/info.json
Original file line number Diff line number Diff line change
Expand Up @@ -17,6 +17,9 @@
"soft_serial_pin": "GP1",
"bootmagic": {
"matrix": [4, 0]
},
"sync": {
"matrix_state": true
}
},
"encoder": {
Expand Down Expand Up @@ -90,6 +93,10 @@
"solid_splash": true,
"solid_multisplash": true
},
"default": {
"speed": 32,
"val": 128
},
"layout": [
{"x": 82, "y": 0, "flags": 2},
{"x": 60, "y": 0, "flags": 2},
Expand Down Expand Up @@ -180,7 +187,8 @@
{"matrix": [7, 2], "x": 179, "y": 51, "flags": 4},
{"matrix": [7, 0], "x": 160, "y": 53, "flags": 4},
{"matrix": [7, 1], "x": 143, "y": 60, "flags": 4}
]
],
"sleep": true
},
"community_layouts": ["split_3x5_3"],
"layouts": {
Expand Down
9 changes: 1 addition & 8 deletions keyboards/bastardkb/dilemma/4x6_4/config.h
Original file line number Diff line number Diff line change
Expand Up @@ -44,11 +44,4 @@
#define RP2040_BOOTLOADER_DOUBLE_TAP_RESET_TIMEOUT 500U

/* RGB matrix support. */
#define SPLIT_TRANSPORT_MIRROR
#define RGB_MATRIX_SLEEP
#define RGB_MATRIX_KEYPRESSES
#define RGB_MATRIX_FRAMEBUFFER_EFFECTS

// Startup values.
#define RGB_MATRIX_DEFAULT_VAL 64
#define RGB_MATRIX_DEFAULT_SPD 32
#define SPLIT_TRANSPORT_MIRROR
10 changes: 9 additions & 1 deletion keyboards/bastardkb/dilemma/4x6_4/info.json
Original file line number Diff line number Diff line change
Expand Up @@ -17,6 +17,9 @@
"soft_serial_pin": "GP1",
"bootmagic": {
"matrix": [5, 0]
},
"sync": {
"matrix_state": true
}
},
"encoder": {
Expand Down Expand Up @@ -91,6 +94,10 @@
"solid_splash": true,
"solid_multisplash": true
},
"default": {
"speed": 32,
"val": 128
},
"layout": [
{"x": 81, "y": 4, "flags": 2},
{"x": 65, "y": 2, "flags": 2},
Expand Down Expand Up @@ -199,7 +206,8 @@
{"matrix": [9, 2], "x": 156, "y": 53, "flags": 4},
{"matrix": [9, 1], "x": 143, "y": 57, "flags": 4},
{"matrix": [9, 3], "x": 132, "y": 64, "flags": 4}
]
],
"sleep": true
},
"layouts": {
"LAYOUT": {
Expand Down
Loading