summaryrefslogtreecommitdiff
path: root/keyboards/rgbkb
diff options
context:
space:
mode:
Diffstat (limited to 'keyboards/rgbkb')
-rw-r--r--keyboards/rgbkb/pan/pan.c2
-rw-r--r--keyboards/rgbkb/sol/keymaps/default/keymap.c2
-rw-r--r--keyboards/rgbkb/sol/keymaps/xyverz/keymap.c2
3 files changed, 3 insertions, 3 deletions
diff --git a/keyboards/rgbkb/pan/pan.c b/keyboards/rgbkb/pan/pan.c
index c367550e49..6a17456390 100644
--- a/keyboards/rgbkb/pan/pan.c
+++ b/keyboards/rgbkb/pan/pan.c
@@ -51,7 +51,7 @@ static inline void setled(int i, uint8_t r, uint8_t g, uint8_t b) {
}
static void setled_all(uint8_t r, uint8_t g, uint8_t b) {
- for (int i = 0; i < sizeof(rgb_matrix_ws2812_array) / sizeof(rgb_matrix_ws2812_array[0]); i++) {
+ for (int i = 0; i < ARRAY_SIZE(rgb_matrix_ws2812_array); i++) {
setled(i, r, g, b);
}
}
diff --git a/keyboards/rgbkb/sol/keymaps/default/keymap.c b/keyboards/rgbkb/sol/keymaps/default/keymap.c
index 1ce18bc1ab..87241521ae 100644
--- a/keyboards/rgbkb/sol/keymaps/default/keymap.c
+++ b/keyboards/rgbkb/sol/keymaps/default/keymap.c
@@ -202,7 +202,7 @@ const rgb_matrix_f rgb_matrix_functions[6][2] = {
#ifdef ENCODER_ENABLE
static pin_t encoders_pad_a[] = ENCODERS_PAD_A;
-#define NUMBER_OF_ENCODERS (sizeof(encoders_pad_a)/sizeof(pin_t))
+#define NUMBER_OF_ENCODERS ARRAY_SIZE(encoders_pad_a)
const uint16_t PROGMEM encoders[][NUMBER_OF_ENCODERS * 2][2] = {
[_QWERTY] = ENCODER_LAYOUT(
diff --git a/keyboards/rgbkb/sol/keymaps/xyverz/keymap.c b/keyboards/rgbkb/sol/keymaps/xyverz/keymap.c
index cdd0c6620a..d042a4fe27 100644
--- a/keyboards/rgbkb/sol/keymaps/xyverz/keymap.c
+++ b/keyboards/rgbkb/sol/keymaps/xyverz/keymap.c
@@ -232,7 +232,7 @@ const rgb_matrix_f rgb_matrix_functions[6][2] = {
#ifdef ENCODER_ENABLE
static pin_t encoders_pad_a[] = ENCODERS_PAD_A;
-#define NUMBER_OF_ENCODERS (sizeof(encoders_pad_a)/sizeof(pin_t))
+#define NUMBER_OF_ENCODERS ARRAY_SIZE(encoders_pad_a)
const uint16_t PROGMEM encoders[][NUMBER_OF_ENCODERS * 2][2] = {
[_QWERTY] = ENCODER_LAYOUT( \