From 8f221052897754870e5c08a2de92c24d20cd307e Mon Sep 17 00:00:00 2001 From: Ryan Date: Tue, 19 Sep 2023 19:31:54 +1000 Subject: [PATCH] Add and use I2C address defines for ISSI LED drivers (#22008) --- docs/feature_led_matrix.md | 32 +++++---- docs/feature_rgb_matrix.md | 69 ++++++++++--------- drivers/led/ckled2001-simple.h | 5 ++ drivers/led/ckled2001.h | 5 ++ drivers/led/issi/is31fl3731-simple.c | 9 --- drivers/led/issi/is31fl3731-simple.h | 5 ++ drivers/led/issi/is31fl3731.c | 9 --- drivers/led/issi/is31fl3731.h | 5 ++ drivers/led/issi/is31fl3733-simple.c | 12 ---- drivers/led/issi/is31fl3733-simple.h | 17 +++++ drivers/led/issi/is31fl3733.c | 12 ---- drivers/led/issi/is31fl3733.h | 17 +++++ drivers/led/issi/is31fl3736.c | 12 ---- drivers/led/issi/is31fl3736.h | 17 +++++ drivers/led/issi/is31fl3737.c | 12 ---- drivers/led/issi/is31fl3737.h | 11 ++- drivers/led/issi/is31fl3741.c | 12 ---- drivers/led/issi/is31fl3741.h | 5 ++ keyboards/4pplet/perk60_iso/rev_a/config.h | 2 +- keyboards/abko/ak84bt/config.h | 4 +- keyboards/acheron/apollo/87h/gamma/config.h | 2 +- keyboards/aeboards/satellite/rev1/config.h | 4 +- keyboards/axolstudio/yeti/hotswap/config.h | 2 +- keyboards/canary/canary60rgb/v1/config.h | 2 +- keyboards/clueboard/66_hotswap/gen1/config.h | 9 +-- keyboards/dp60/config.h | 4 +- keyboards/drop/alt/v2/config.h | 4 +- keyboards/drop/ctrl/v2/config.h | 4 +- keyboards/drop/sense75/config.h | 4 +- keyboards/drop/shift/v2/config.h | 6 +- keyboards/durgod/dgk6x/config.h | 15 +--- keyboards/dztech/dz60rgb/v1/config.h | 2 +- keyboards/dztech/dz60rgb/v2/config.h | 2 +- keyboards/dztech/dz60rgb/v2_1/config.h | 2 +- keyboards/dztech/dz60rgb_ansi/v1/config.h | 2 +- keyboards/dztech/dz60rgb_ansi/v2/config.h | 2 +- keyboards/dztech/dz60rgb_ansi/v2_1/config.h | 2 +- keyboards/dztech/dz60rgb_wkl/v1/config.h | 2 +- keyboards/dztech/dz60rgb_wkl/v2/config.h | 2 +- keyboards/dztech/dz60rgb_wkl/v2_1/config.h | 2 +- keyboards/dztech/dz64rgb/config.h | 2 +- keyboards/dztech/dz65rgb/v1/config.h | 4 +- keyboards/dztech/dz65rgb/v2/config.h | 4 +- keyboards/dztech/dz65rgb/v3/config.h | 2 +- keyboards/dztech/tofu/ii/v1/config.h | 4 +- keyboards/dztech/tofu/jr/v1/config.h | 4 +- keyboards/ergodox_ez/config.h | 4 +- keyboards/evyd13/atom47/rev5/config.h | 12 +--- keyboards/exclusive/e6_rgb/config.h | 2 +- keyboards/fallacy/config.h | 2 +- keyboards/feker/ik75/config.h | 4 +- keyboards/ferris/0_2/bling/config.h | 4 +- keyboards/flashquark/horizon_z/config.h | 2 +- keyboards/frooastboard/walnut/config.h | 2 +- keyboards/geekboards/tester/config.h | 4 +- keyboards/gizmo_engineering/gk6/config.h | 4 +- keyboards/handwired/orbweaver/config.h | 2 +- keyboards/hs60/v1/config.h | 4 +- keyboards/ilumkb/simpler61/config.h | 2 +- keyboards/ilumkb/simpler64/config.h | 2 +- keyboards/inett_studio/sqx/hotswap/config.h | 4 +- keyboards/inett_studio/sqx/universal/config.h | 4 +- .../input_club/ergodox_infinity/config.h | 2 +- keyboards/input_club/k_type/config.h | 4 +- keyboards/input_club/k_type/is31fl3733-dual.c | 12 ---- keyboards/input_club/k_type/is31fl3733-dual.h | 17 +++++ keyboards/input_club/whitefox/config.h | 2 +- keyboards/kbdcraft/adam64/config.h | 2 +- keyboards/kbdfans/bella/rgb/config.h | 2 +- keyboards/kbdfans/bella/rgb_iso/config.h | 2 +- keyboards/kbdfans/boop65/rgb/config.h | 2 +- keyboards/kbdfans/kbd67/mkiirgb/v1/config.h | 4 +- keyboards/kbdfans/kbd67/mkiirgb/v2/config.h | 4 +- keyboards/kbdfans/kbd67/mkiirgb/v3/config.h | 2 +- keyboards/kbdfans/kbdmini/config.h | 2 +- keyboards/kbdfans/maja/config.h | 4 +- keyboards/keychron/c1_pro/ansi/rgb/config.h | 4 +- keyboards/keychron/c1_pro/ansi/white/config.h | 2 +- keyboards/keychron/c2_pro/ansi/rgb/config.h | 4 +- keyboards/keychron/c2_pro/ansi/white/config.h | 2 +- keyboards/keychron/q0/rev_0130/config.h | 2 +- keyboards/keychron/q0/rev_0131/config.h | 2 +- keyboards/keychron/q1/config.h | 4 +- keyboards/keychron/q10/config.h | 4 +- keyboards/keychron/q11/config.h | 2 +- keyboards/keychron/q12/config.h | 4 +- keyboards/keychron/q2/config.h | 4 +- keyboards/keychron/q3/config.h | 4 +- keyboards/keychron/q4/ansi_v1/config.h | 4 +- keyboards/keychron/q4/ansi_v2/config.h | 2 +- keyboards/keychron/q4/iso/config.h | 2 +- keyboards/keychron/q5/config.h | 4 +- keyboards/keychron/q6/config.h | 4 +- keyboards/keychron/q60/config.h | 2 +- keyboards/keychron/q65/config.h | 4 +- keyboards/keychron/q7/config.h | 4 +- keyboards/keychron/q8/config.h | 4 +- keyboards/keychron/q9/config.h | 2 +- keyboards/keychron/s1/ansi/rgb/config.h | 4 +- keyboards/keychron/s1/ansi/white/config.h | 2 +- keyboards/keychron/v1/config.h | 4 +- keyboards/keychron/v10/config.h | 4 +- keyboards/keychron/v2/config.h | 4 +- keyboards/keychron/v3/config.h | 4 +- keyboards/keychron/v4/config.h | 2 +- keyboards/keychron/v5/config.h | 4 +- keyboards/keychron/v6/config.h | 4 +- keyboards/keychron/v7/config.h | 4 +- keyboards/keychron/v8/config.h | 4 +- keyboards/kprepublic/bm60hsrgb/rev2/config.h | 2 +- .../kprepublic/bm60hsrgb_ec/rev2/config.h | 2 +- .../kprepublic/bm60hsrgb_iso/rev2/config.h | 2 +- .../kprepublic/bm60hsrgb_poker/rev2/config.h | 2 +- keyboards/kprepublic/bm68hsrgb/rev2/config.h | 2 +- keyboards/kprepublic/bm80v2/config.h | 2 +- keyboards/kprepublic/bm80v2_iso/config.h | 2 +- keyboards/latincompass/latin17rgb/config.h | 11 +-- keyboards/latincompass/latin60rgb/config.h | 2 +- keyboards/latincompass/latin6rgb/config.h | 9 +-- keyboards/matrix/m20add/config.h | 2 +- keyboards/matrix/noah/config.h | 4 +- .../mechlovin/adelais/rgb_led/rev2/config.h | 11 +-- .../mechlovin/adelais/rgb_led/rev3/config.h | 9 +-- keyboards/mechlovin/delphine/rgb_led/config.h | 10 +-- keyboards/mechlovin/hannah60rgb/rev2/config.h | 12 +--- .../mechlovin/infinity87/rgb_rev1/config.h | 9 +-- keyboards/mechlovin/olly/octagon/config.h | 9 +-- keyboards/mechlovin/zed65/mono_led/config.h | 9 +-- keyboards/melgeek/mach80/config.h | 2 +- keyboards/melgeek/mj61/config.h | 2 +- keyboards/melgeek/mj63/config.h | 2 +- keyboards/melgeek/mj64/config.h | 2 +- keyboards/melgeek/mj65/config.h | 2 +- keyboards/melgeek/mojo68/config.h | 2 +- keyboards/melgeek/mojo75/config.h | 2 +- keyboards/melgeek/tegic/config.h | 2 +- keyboards/melgeek/z70ultra/config.h | 2 +- keyboards/miller/gm862/config.h | 2 +- keyboards/moonlander/config.h | 4 +- keyboards/mt/mt64rgb/config.h | 2 +- keyboards/mt/mt84/config.h | 4 +- keyboards/neson_design/700e/config.h | 4 +- keyboards/neson_design/n6/config.h | 4 +- keyboards/opendeck/32/rev1/config.h | 2 +- keyboards/owlab/voice65/hotswap/config.h | 2 +- keyboards/owlab/voice65/soldered/config.h | 2 +- keyboards/planck/ez/config.h | 2 +- keyboards/planck/light/config.h | 11 +-- keyboards/playkbtw/pk64rgb/config.h | 2 +- keyboards/redragon/k667/config.h | 4 +- keyboards/smallkeyboard/config.h | 9 +-- keyboards/teleport/native/config.h | 4 +- keyboards/terrazzo/config.h | 2 +- keyboards/tkc/portico/config.h | 4 +- keyboards/tkc/portico68v2/config.h | 2 +- keyboards/tkc/portico75/config.h | 2 +- keyboards/wilba_tech/wt_rgb_backlight.c | 51 ++++---------- keyboards/xbows/knight/config.h | 6 +- keyboards/xbows/knight_plus/config.h | 6 +- keyboards/xbows/nature/config.h | 6 +- keyboards/xbows/numpad/config.h | 2 +- keyboards/xbows/ranger/config.h | 6 +- keyboards/xbows/woody/config.h | 4 +- keyboards/xelus/dawn60/rev1_qmk/config.h | 4 +- keyboards/xelus/pachi/rgb/rev1/config.h | 2 +- keyboards/xelus/pachi/rgb/rev2/config.h | 2 +- 166 files changed, 385 insertions(+), 496 deletions(-) diff --git a/docs/feature_led_matrix.md b/docs/feature_led_matrix.md index b22d4ad3a37..e44cc87e329 100644 --- a/docs/feature_led_matrix.md +++ b/docs/feature_led_matrix.md @@ -34,12 +34,14 @@ Here is an example using 2 drivers. // This is a 7-bit address, that gets left-shifted and bit 0 // set to 0 for write, 1 for read (as per I2C protocol) // The address will vary depending on your wiring: -// 0b1110100 AD <-> GND -// 0b1110111 AD <-> VCC -// 0b1110101 AD <-> SCL -// 0b1110110 AD <-> SDA -#define LED_DRIVER_ADDR_1 0b1110100 -#define LED_DRIVER_ADDR_2 0b1110110 +// 00 AD <-> GND +// 01 AD <-> SCL +// 10 AD <-> SDA +// 11 AD <-> VCC +// ADDR represents A1:A0 of the 7-bit address. +// The result is: 0b11101(ADDR) +#define LED_DRIVER_ADDR_1 IS31FL3731_I2C_ADDRESS_GND +#define LED_DRIVER_ADDR_2 IS31FL3731_I2C_ADDRESS_SDA #define IS31FL3731_DRIVER_COUNT 2 #define LED_DRIVER_1_LED_TOTAL 25 @@ -159,7 +161,7 @@ Then Define the array listing all the LEDs you want to override in your ` GND -// 0b1110111 AD <-> VCC -// 0b1110101 AD <-> SCL -// 0b1110110 AD <-> SDA -#define DRIVER_ADDR_1 0b1110100 -#define DRIVER_ADDR_2 0b1110110 +// 00 AD <-> GND +// 01 AD <-> SCL +// 10 AD <-> SDA +// 11 AD <-> VCC +// ADDR represents A1:A0 of the 7-bit address. +// The result is: 0b11101(ADDR) +#define DRIVER_ADDR_1 IS31FL3731_I2C_ADDRESS_GND +#define DRIVER_ADDR_2 IS31FL3731_I2C_ADDRESS_SDA #define IS31FL3731_DRIVER_COUNT 2 #define DRIVER_1_LED_TOTAL 25 @@ -118,15 +120,15 @@ Here is an example using 2 drivers. // This is a 7-bit address, that gets left-shifted and bit 0 // set to 0 for write, 1 for read (as per I2C protocol) // The address will vary depending on your wiring: -// 00 <-> GND -// 01 <-> SCL -// 10 <-> SDA -// 11 <-> VCC +// 00 ADDRn <-> GND +// 01 ADDRn <-> SCL +// 10 ADDRn <-> SDA +// 11 ADDRn <-> VCC // ADDR1 represents A1:A0 of the 7-bit address. // ADDR2 represents A3:A2 of the 7-bit address. // The result is: 0b101(ADDR2)(ADDR1) -#define DRIVER_ADDR_1 0b1010000 -#define DRIVER_ADDR_2 0b1010011 +#define DRIVER_ADDR_1 IS31FL3733_I2C_ADDRESS_GND_GND +#define DRIVER_ADDR_2 IS31FL3733_I2C_ADDRESS_GND_VCC #define IS31FL3733_DRIVER_COUNT 2 #define DRIVER_1_LED_TOTAL 58 @@ -202,14 +204,15 @@ Here is an example using 2 drivers. // This is a 7-bit address, that gets left-shifted and bit 0 // set to 0 for write, 1 for read (as per I2C protocol) // The address will vary depending on your wiring: -// 0000 <-> GND -// 0101 <-> SCL -// 1010 <-> SDA -// 1111 <-> VCC -// ADDR represents A3:A0 of the 7-bit address. -// The result is: 0b101(ADDR) -#define DRIVER_ADDR_1 0b1010000 -#define DRIVER_ADDR_2 0b1010001 +// 00 ADDRn <-> GND +// 01 ADDRn <-> SCL +// 10 ADDRn <-> SDA +// 11 ADDRn <-> VCC +// ADDR1 represents A1:A0 of the 7-bit address. +// ADDR2 represents A3:A2 of the 7-bit address. +// The result is: 0b101(ADDR2)(ADDR1) +#define DRIVER_ADDR_1 IS31FL3736_I2C_ADDRESS_GND_GND +#define DRIVER_ADDR_2 IS31FL3736_I2C_ADDRESS_GND_SCL #define IS31FL3736_DRIVER_COUNT 2 #define DRIVER_1_LED_TOTAL 30 @@ -278,14 +281,14 @@ Here is an example using 2 drivers. // This is a 7-bit address, that gets left-shifted and bit 0 // set to 0 for write, 1 for read (as per I2C protocol) // The address will vary depending on your wiring: -// 0000 <-> GND -// 0101 <-> SCL -// 1010 <-> SDA -// 1111 <-> VCC +// 0000 ADDR <-> GND +// 0101 ADDR <-> SCL +// 1010 ADDR <-> SDA +// 1111 ADDR <-> VCC // ADDR represents A3:A0 of the 7-bit address. // The result is: 0b101(ADDR) -#define DRIVER_ADDR_1 0b1010000 -#define DRIVER_ADDR_2 0b1010001 +#define DRIVER_ADDR_1 IS31FL3737_I2C_ADDRESS_GND +#define DRIVER_ADDR_2 IS31FL3737_I2C_ADDRESS_SCL #define IS31FL3737_DRIVER_COUNT 2 #define DRIVER_1_LED_TOTAL 30 @@ -407,7 +410,7 @@ Then Define the array listing all the LEDs you want to override in your ` GND -// 0b1110111 AD <-> VCC -// 0b1110101 AD <-> SCL -// 0b1110110 AD <-> SDA -#define IS31FL3731_I2C_ADDRESS_DEFAULT 0x74 - #define IS31FL3731_REG_CONFIG 0x00 #define IS31FL3731_REG_CONFIG_PICTUREMODE 0x00 #define IS31FL3731_REG_CONFIG_AUTOPLAYMODE 0x08 diff --git a/drivers/led/issi/is31fl3731-simple.h b/drivers/led/issi/is31fl3731-simple.h index ee830faca8e..e6c9ce37c54 100644 --- a/drivers/led/issi/is31fl3731-simple.h +++ b/drivers/led/issi/is31fl3731-simple.h @@ -37,6 +37,11 @@ #endif // ======== +#define IS31FL3731_I2C_ADDRESS_GND 0x74 +#define IS31FL3731_I2C_ADDRESS_SCL 0x75 +#define IS31FL3731_I2C_ADDRESS_SDA 0x76 +#define IS31FL3731_I2C_ADDRESS_VCC 0x77 + typedef struct is31_led { uint8_t driver : 2; uint8_t v; diff --git a/drivers/led/issi/is31fl3731.c b/drivers/led/issi/is31fl3731.c index 9e2d39c692a..2123438a5fc 100644 --- a/drivers/led/issi/is31fl3731.c +++ b/drivers/led/issi/is31fl3731.c @@ -21,15 +21,6 @@ #include "i2c_master.h" #include "wait.h" -// This is a 7-bit address, that gets left-shifted and bit 0 -// set to 0 for write, 1 for read (as per I2C protocol) -// The address will vary depending on your wiring: -// 0b1110100 AD <-> GND -// 0b1110111 AD <-> VCC -// 0b1110101 AD <-> SCL -// 0b1110110 AD <-> SDA -#define IS31FL3731_I2C_ADDRESS_DEFAULT 0x74 - #define IS31FL3731_REG_CONFIG 0x00 #define IS31FL3731_REG_CONFIG_PICTUREMODE 0x00 #define IS31FL3731_REG_CONFIG_AUTOPLAYMODE 0x08 diff --git a/drivers/led/issi/is31fl3731.h b/drivers/led/issi/is31fl3731.h index 97e3f454df6..ccd972a03eb 100644 --- a/drivers/led/issi/is31fl3731.h +++ b/drivers/led/issi/is31fl3731.h @@ -36,6 +36,11 @@ #endif // ======== +#define IS31FL3731_I2C_ADDRESS_GND 0x74 +#define IS31FL3731_I2C_ADDRESS_SCL 0x75 +#define IS31FL3731_I2C_ADDRESS_SDA 0x76 +#define IS31FL3731_I2C_ADDRESS_VCC 0x77 + typedef struct is31_led { uint8_t driver : 2; uint8_t r; diff --git a/drivers/led/issi/is31fl3733-simple.c b/drivers/led/issi/is31fl3733-simple.c index c52e1ff9f12..514d9e366d1 100644 --- a/drivers/led/issi/is31fl3733-simple.c +++ b/drivers/led/issi/is31fl3733-simple.c @@ -23,18 +23,6 @@ #include "i2c_master.h" #include "wait.h" -// This is a 7-bit address, that gets left-shifted and bit 0 -// set to 0 for write, 1 for read (as per I2C protocol) -// The address will vary depending on your wiring: -// 00 <-> GND -// 01 <-> SCL -// 10 <-> SDA -// 11 <-> VCC -// ADDR1 represents A1:A0 of the 7-bit address. -// ADDR2 represents A3:A2 of the 7-bit address. -// The result is: 0b101(ADDR2)(ADDR1) -#define IS31FL3733_I2C_ADDRESS_DEFAULT 0x50 - #define IS31FL3733_COMMANDREGISTER 0xFD #define IS31FL3733_COMMANDREGISTER_WRITELOCK 0xFE #define IS31FL3733_INTERRUPTMASKREGISTER 0xF0 diff --git a/drivers/led/issi/is31fl3733-simple.h b/drivers/led/issi/is31fl3733-simple.h index 7e06e2af020..b870c5c58c8 100644 --- a/drivers/led/issi/is31fl3733-simple.h +++ b/drivers/led/issi/is31fl3733-simple.h @@ -56,6 +56,23 @@ #define PUR_32KR IS31FL3733_PUR_32KR // ======== +#define IS31FL3733_I2C_ADDRESS_GND_GND 0x50 +#define IS31FL3733_I2C_ADDRESS_GND_SCL 0x51 +#define IS31FL3733_I2C_ADDRESS_GND_SDA 0x52 +#define IS31FL3733_I2C_ADDRESS_GND_VCC 0x53 +#define IS31FL3733_I2C_ADDRESS_SCL_GND 0x54 +#define IS31FL3733_I2C_ADDRESS_SCL_SCL 0x55 +#define IS31FL3733_I2C_ADDRESS_SCL_SDA 0x56 +#define IS31FL3733_I2C_ADDRESS_SCL_VCC 0x57 +#define IS31FL3733_I2C_ADDRESS_SDA_GND 0x58 +#define IS31FL3733_I2C_ADDRESS_SDA_SCL 0x59 +#define IS31FL3733_I2C_ADDRESS_SDA_SDA 0x5A +#define IS31FL3733_I2C_ADDRESS_SDA_VCC 0x5B +#define IS31FL3733_I2C_ADDRESS_VCC_GND 0x5C +#define IS31FL3733_I2C_ADDRESS_VCC_SCL 0x5D +#define IS31FL3733_I2C_ADDRESS_VCC_SDA 0x5E +#define IS31FL3733_I2C_ADDRESS_VCC_VCC 0x5F + typedef struct is31_led { uint8_t driver : 2; uint8_t v; diff --git a/drivers/led/issi/is31fl3733.c b/drivers/led/issi/is31fl3733.c index 3ee9b14c816..e501175a117 100644 --- a/drivers/led/issi/is31fl3733.c +++ b/drivers/led/issi/is31fl3733.c @@ -22,18 +22,6 @@ #include "i2c_master.h" #include "wait.h" -// This is a 7-bit address, that gets left-shifted and bit 0 -// set to 0 for write, 1 for read (as per I2C protocol) -// The address will vary depending on your wiring: -// 00 <-> GND -// 01 <-> SCL -// 10 <-> SDA -// 11 <-> VCC -// ADDR1 represents A1:A0 of the 7-bit address. -// ADDR2 represents A3:A2 of the 7-bit address. -// The result is: 0b101(ADDR2)(ADDR1) -#define IS31FL3733_I2C_ADDRESS_DEFAULT 0x50 - #define IS31FL3733_COMMANDREGISTER 0xFD #define IS31FL3733_COMMANDREGISTER_WRITELOCK 0xFE #define IS31FL3733_INTERRUPTMASKREGISTER 0xF0 diff --git a/drivers/led/issi/is31fl3733.h b/drivers/led/issi/is31fl3733.h index 3c17723f92d..e16560807fe 100644 --- a/drivers/led/issi/is31fl3733.h +++ b/drivers/led/issi/is31fl3733.h @@ -55,6 +55,23 @@ #define PUR_32KR IS31FL3733_PUR_32KR // ======== +#define IS31FL3733_I2C_ADDRESS_GND_GND 0x50 +#define IS31FL3733_I2C_ADDRESS_GND_SCL 0x51 +#define IS31FL3733_I2C_ADDRESS_GND_SDA 0x52 +#define IS31FL3733_I2C_ADDRESS_GND_VCC 0x53 +#define IS31FL3733_I2C_ADDRESS_SCL_GND 0x54 +#define IS31FL3733_I2C_ADDRESS_SCL_SCL 0x55 +#define IS31FL3733_I2C_ADDRESS_SCL_SDA 0x56 +#define IS31FL3733_I2C_ADDRESS_SCL_VCC 0x57 +#define IS31FL3733_I2C_ADDRESS_SDA_GND 0x58 +#define IS31FL3733_I2C_ADDRESS_SDA_SCL 0x59 +#define IS31FL3733_I2C_ADDRESS_SDA_SDA 0x5A +#define IS31FL3733_I2C_ADDRESS_SDA_VCC 0x5B +#define IS31FL3733_I2C_ADDRESS_VCC_GND 0x5C +#define IS31FL3733_I2C_ADDRESS_VCC_SCL 0x5D +#define IS31FL3733_I2C_ADDRESS_VCC_SDA 0x5E +#define IS31FL3733_I2C_ADDRESS_VCC_VCC 0x5F + typedef struct is31_led { uint8_t driver : 2; uint8_t r; diff --git a/drivers/led/issi/is31fl3736.c b/drivers/led/issi/is31fl3736.c index c8c035854f8..7f50411f1f3 100644 --- a/drivers/led/issi/is31fl3736.c +++ b/drivers/led/issi/is31fl3736.c @@ -20,18 +20,6 @@ #include "i2c_master.h" #include "wait.h" -// This is a 7-bit address, that gets left-shifted and bit 0 -// set to 0 for write, 1 for read (as per I2C protocol) -// The address will vary depending on your wiring: -// 00 <-> GND -// 01 <-> SCL -// 10 <-> SDA -// 11 <-> VCC -// ADDR1 represents A1:A0 of the 7-bit address. -// ADDR2 represents A3:A2 of the 7-bit address. -// The result is: 0b101(ADDR2)(ADDR1) -#define IS31FL3736_I2C_ADDRESS_DEFAULT 0x50 - #define IS31FL3736_COMMANDREGISTER 0xFD #define IS31FL3736_COMMANDREGISTER_WRITELOCK 0xFE #define IS31FL3736_INTERRUPTMASKREGISTER 0xF0 diff --git a/drivers/led/issi/is31fl3736.h b/drivers/led/issi/is31fl3736.h index 5cc1262633c..baf200f8ad2 100644 --- a/drivers/led/issi/is31fl3736.h +++ b/drivers/led/issi/is31fl3736.h @@ -51,6 +51,23 @@ #define PUR_32KR IS31FL3736_PUR_32KR // ======== +#define IS31FL3736_I2C_ADDRESS_GND_GND 0x50 +#define IS31FL3736_I2C_ADDRESS_GND_SCL 0x51 +#define IS31FL3736_I2C_ADDRESS_GND_SDA 0x52 +#define IS31FL3736_I2C_ADDRESS_GND_VCC 0x53 +#define IS31FL3736_I2C_ADDRESS_SCL_GND 0x54 +#define IS31FL3736_I2C_ADDRESS_SCL_SCL 0x55 +#define IS31FL3736_I2C_ADDRESS_SCL_SDA 0x56 +#define IS31FL3736_I2C_ADDRESS_SCL_VCC 0x57 +#define IS31FL3736_I2C_ADDRESS_SDA_GND 0x58 +#define IS31FL3736_I2C_ADDRESS_SDA_SCL 0x59 +#define IS31FL3736_I2C_ADDRESS_SDA_SDA 0x5A +#define IS31FL3736_I2C_ADDRESS_SDA_VCC 0x5B +#define IS31FL3736_I2C_ADDRESS_VCC_GND 0x5C +#define IS31FL3736_I2C_ADDRESS_VCC_SCL 0x5D +#define IS31FL3736_I2C_ADDRESS_VCC_SDA 0x5E +#define IS31FL3736_I2C_ADDRESS_VCC_VCC 0x5F + typedef struct is31_led { uint8_t driver : 2; uint8_t r; diff --git a/drivers/led/issi/is31fl3737.c b/drivers/led/issi/is31fl3737.c index 550d26da8d7..3d93548a465 100644 --- a/drivers/led/issi/is31fl3737.c +++ b/drivers/led/issi/is31fl3737.c @@ -22,18 +22,6 @@ #include "i2c_master.h" #include "wait.h" -// This is a 7-bit address, that gets left-shifted and bit 0 -// set to 0 for write, 1 for read (as per I2C protocol) -// The address will vary depending on your wiring: -// 00 <-> GND -// 01 <-> SCL -// 10 <-> SDA -// 11 <-> VCC -// ADDR1 represents A1:A0 of the 7-bit address. -// ADDR2 represents A3:A2 of the 7-bit address. -// The result is: 0b101(ADDR2)(ADDR1) -#define IS31FL3737_I2C_ADDRESS_DEFAULT 0x50 - #define IS31FL3737_COMMANDREGISTER 0xFD #define IS31FL3737_COMMANDREGISTER_WRITELOCK 0xFE #define IS31FL3737_INTERRUPTMASKREGISTER 0xF0 diff --git a/drivers/led/issi/is31fl3737.h b/drivers/led/issi/is31fl3737.h index e382602e9a8..2d6612b7045 100644 --- a/drivers/led/issi/is31fl3737.h +++ b/drivers/led/issi/is31fl3737.h @@ -19,6 +19,10 @@ #pragma once +#include +#include +#include "progmem.h" + // ======== DEPRECATED DEFINES - DO NOT USE ======== #ifdef DRIVER_COUNT # define IS31FL3737_DRIVER_COUNT DRIVER_COUNT @@ -52,9 +56,10 @@ #define PUR_32KR IS31FL3737_PUR_32KR // ======== -#include -#include -#include "progmem.h" +#define IS31FL3737_I2C_ADDRESS_GND 0x50 +#define IS31FL3737_I2C_ADDRESS_SCL 0x55 +#define IS31FL3737_I2C_ADDRESS_SDA 0x5A +#define IS31FL3737_I2C_ADDRESS_VCC 0x5F typedef struct is31_led { uint8_t driver : 2; diff --git a/drivers/led/issi/is31fl3741.c b/drivers/led/issi/is31fl3741.c index 2db1f021b1b..f34e0b87a12 100644 --- a/drivers/led/issi/is31fl3741.c +++ b/drivers/led/issi/is31fl3741.c @@ -22,18 +22,6 @@ #include "i2c_master.h" #include "wait.h" -// This is a 7-bit address, that gets left-shifted and bit 0 -// set to 0 for write, 1 for read (as per I2C protocol) -// The address will vary depending on your wiring: -// 00 <-> GND -// 01 <-> SCL -// 10 <-> SDA -// 11 <-> VCC -// ADDR1 represents A1:A0 of the 7-bit address. -// ADDR2 represents A3:A2 of the 7-bit address. -// The result is: 0b101(ADDR2)(ADDR1) -#define IS31FL3741_I2C_ADDRESS_DEFAULT 0x60 - #define IS31FL3741_COMMANDREGISTER 0xFD #define IS31FL3741_COMMANDREGISTER_WRITELOCK 0xFE #define IS31FL3741_INTERRUPTMASKREGISTER 0xF0 diff --git a/drivers/led/issi/is31fl3741.h b/drivers/led/issi/is31fl3741.h index b7317bdab6e..65f8af98c85 100644 --- a/drivers/led/issi/is31fl3741.h +++ b/drivers/led/issi/is31fl3741.h @@ -56,6 +56,11 @@ #define PUR_32KR IS31FL3741_PUR_32KR // ======== +#define IS31FL3741_I2C_ADDRESS_GND 0x30 +#define IS31FL3741_I2C_ADDRESS_SCL 0x31 +#define IS31FL3741_I2C_ADDRESS_SDA 0x32 +#define IS31FL3741_I2C_ADDRESS_VCC 0x33 + typedef struct is31_led { uint32_t driver : 2; uint32_t r : 10; diff --git a/keyboards/4pplet/perk60_iso/rev_a/config.h b/keyboards/4pplet/perk60_iso/rev_a/config.h index 76f2600590e..53919dd7ab3 100644 --- a/keyboards/4pplet/perk60_iso/rev_a/config.h +++ b/keyboards/4pplet/perk60_iso/rev_a/config.h @@ -21,7 +21,7 @@ along with this program. If not, see . /* Locking resynchronize hack */ #define LOCKING_RESYNC_ENABLE -#define DRIVER_ADDR_1 0b1010000 +#define DRIVER_ADDR_1 IS31FL3733_I2C_ADDRESS_GND_GND #define IS31FL3733_DRIVER_COUNT 1 #define RGB_MATRIX_LED_COUNT 62 #define IS31FL3733_PWM_FREQUENCY IS31FL3733_PWM_FREQUENCY_26K7_HZ diff --git a/keyboards/abko/ak84bt/config.h b/keyboards/abko/ak84bt/config.h index 8c08c88055f..24c16eccf08 100644 --- a/keyboards/abko/ak84bt/config.h +++ b/keyboards/abko/ak84bt/config.h @@ -17,8 +17,8 @@ #pragma once -#define DRIVER_ADDR_1 0b1010000 -#define DRIVER_ADDR_2 0b1010011 +#define DRIVER_ADDR_1 IS31FL3733_I2C_ADDRESS_GND_GND +#define DRIVER_ADDR_2 IS31FL3733_I2C_ADDRESS_GND_VCC #define IS31FL3733_DRIVER_COUNT 2 #define DRIVER_1_LED_TOTAL 45 diff --git a/keyboards/acheron/apollo/87h/gamma/config.h b/keyboards/acheron/apollo/87h/gamma/config.h index 9d681aedb5b..f7cad264d28 100644 --- a/keyboards/acheron/apollo/87h/gamma/config.h +++ b/keyboards/acheron/apollo/87h/gamma/config.h @@ -25,7 +25,7 @@ along with this program. If not, see . #define EARLY_INIT_PERFORM_BOOTLOADER_JUMP TRUE // RGB Matrix defines -#define DRIVER_ADDR_1 0b0110000 +#define DRIVER_ADDR_1 IS31FL3741_I2C_ADDRESS_GND #define IS31FL3741_DRIVER_COUNT 1 #define DRIVER_1_LED_TOTAL 87 diff --git a/keyboards/aeboards/satellite/rev1/config.h b/keyboards/aeboards/satellite/rev1/config.h index 915b9f4b49a..5eb44a5f53e 100644 --- a/keyboards/aeboards/satellite/rev1/config.h +++ b/keyboards/aeboards/satellite/rev1/config.h @@ -17,8 +17,8 @@ #pragma once //RGB Matrix defines -#define DRIVER_ADDR_1 0x74 -#define DRIVER_ADDR_2 0x76 +#define DRIVER_ADDR_1 IS31FL3731_I2C_ADDRESS_GND +#define DRIVER_ADDR_2 IS31FL3731_I2C_ADDRESS_SDA #define IS31FL3731_DRIVER_COUNT 2 #define DRIVER_1_LED_TOTAL 36 diff --git a/keyboards/axolstudio/yeti/hotswap/config.h b/keyboards/axolstudio/yeti/hotswap/config.h index 85d9cfbedde..66599c89f03 100644 --- a/keyboards/axolstudio/yeti/hotswap/config.h +++ b/keyboards/axolstudio/yeti/hotswap/config.h @@ -61,7 +61,7 @@ along with this program. If not, see . # define ENABLE_RGB_MATRIX_SOLID_MULTISPLASH # define RGB_MATRIX_LED_FLUSH_LIMIT 16 // 16 is equivalent to limiting to 60fps # define RGB_DISABLE_WHEN_USB_SUSPENDED // turn off effects when suspended -# define DRIVER_ADDR_1 0b1010000 +# define DRIVER_ADDR_1 IS31FL3733_I2C_ADDRESS_GND_GND # define IS31FL3733_DRIVER_COUNT 1 # define RGB_MATRIX_LED_COUNT 64 #endif diff --git a/keyboards/canary/canary60rgb/v1/config.h b/keyboards/canary/canary60rgb/v1/config.h index 2b733b26491..ca20d9c0f22 100644 --- a/keyboards/canary/canary60rgb/v1/config.h +++ b/keyboards/canary/canary60rgb/v1/config.h @@ -33,7 +33,7 @@ # define DISABLE_RGB_MATRIX_MULTISPLASH # define DISABLE_RGB_MATRIX_SOLID_SPLASH # define DISABLE_RGB_MATRIX_SOLID_MULTISPLASH -# define DRIVER_ADDR_1 0b1010000 +# define DRIVER_ADDR_1 IS31FL3733_I2C_ADDRESS_GND_GND # define IS31FL3733_DRIVER_COUNT 1 # define RGB_MATRIX_LED_COUNT 63 #endif diff --git a/keyboards/clueboard/66_hotswap/gen1/config.h b/keyboards/clueboard/66_hotswap/gen1/config.h index 5d3af942ad7..ff4863266ab 100644 --- a/keyboards/clueboard/66_hotswap/gen1/config.h +++ b/keyboards/clueboard/66_hotswap/gen1/config.h @@ -33,14 +33,7 @@ //#define NO_ACTION_TAPPING //#define NO_ACTION_ONESHOT -// This is a 7-bit address, that gets left-shifted and bit 0 -// set to 0 for write, 1 for read (as per I2C protocol) -// The address will vary depending on your wiring: -// 0b1110100 AD <-> GND -// 0b1110111 AD <-> VCC -// 0b1110101 AD <-> SCL -// 0b1110110 AD <-> SDA -#define LED_DRIVER_ADDR_1 0b1110100 +#define LED_DRIVER_ADDR_1 IS31FL3731_I2C_ADDRESS_GND #define I2C1_SCL_PIN B8 #define I2C1_SDA_PIN B9 diff --git a/keyboards/dp60/config.h b/keyboards/dp60/config.h index 857e03df80f..48c232b8e78 100644 --- a/keyboards/dp60/config.h +++ b/keyboards/dp60/config.h @@ -33,8 +33,8 @@ //#define NO_PRINT //rgb matrix setting -#define DRIVER_ADDR_1 0b1110100 -#define DRIVER_ADDR_2 0b1110111 +#define DRIVER_ADDR_1 IS31FL3731_I2C_ADDRESS_GND +#define DRIVER_ADDR_2 IS31FL3731_I2C_ADDRESS_VCC #define IS31FL3731_DRIVER_COUNT 2 #define DRIVER_1_LED_TOTAL 36 #define DRIVER_2_LED_TOTAL 36 diff --git a/keyboards/drop/alt/v2/config.h b/keyboards/drop/alt/v2/config.h index 8ab8d0fb38a..31b87501555 100644 --- a/keyboards/drop/alt/v2/config.h +++ b/keyboards/drop/alt/v2/config.h @@ -14,8 +14,8 @@ #define EXTERNAL_EEPROM_WP_PIN B5 #define EEPROM_I2C_24LC256 -#define DRIVER_ADDR_1 0b1010011 -#define DRIVER_ADDR_2 0b1011111 +#define DRIVER_ADDR_1 IS31FL3733_I2C_ADDRESS_GND_VCC +#define DRIVER_ADDR_2 IS31FL3733_I2C_ADDRESS_VCC_VCC #define IS31FL3733_DRIVER_COUNT 2 #define RGB_MATRIX_LED_COUNT 111 #define IS31FL3733_PWM_FREQUENCY IS31FL3733_PWM_FREQUENCY_26K7_HZ diff --git a/keyboards/drop/ctrl/v2/config.h b/keyboards/drop/ctrl/v2/config.h index 51990d856bc..f3292bcb9cc 100644 --- a/keyboards/drop/ctrl/v2/config.h +++ b/keyboards/drop/ctrl/v2/config.h @@ -14,8 +14,8 @@ #define EXTERNAL_EEPROM_WP_PIN B5 #define EEPROM_I2C_24LC256 -#define DRIVER_ADDR_1 0b1010011 -#define DRIVER_ADDR_2 0b1011111 +#define DRIVER_ADDR_1 IS31FL3733_I2C_ADDRESS_GND_VCC +#define DRIVER_ADDR_2 IS31FL3733_I2C_ADDRESS_VCC_VCC #define IS31FL3733_DRIVER_COUNT 2 #define RGB_MATRIX_LED_COUNT 119 #define IS31FL3733_PWM_FREQUENCY IS31FL3733_PWM_FREQUENCY_26K7_HZ diff --git a/keyboards/drop/sense75/config.h b/keyboards/drop/sense75/config.h index 6d2d50e5416..70e425eb747 100644 --- a/keyboards/drop/sense75/config.h +++ b/keyboards/drop/sense75/config.h @@ -9,8 +9,8 @@ #define EXTERNAL_EEPROM_WP_PIN B7 #define EEPROM_I2C_24LC256 -#define DRIVER_ADDR_1 0b1010000 -#define DRIVER_ADDR_2 0b1011111 +#define DRIVER_ADDR_1 IS31FL3733_I2C_ADDRESS_GND_GND +#define DRIVER_ADDR_2 IS31FL3733_I2C_ADDRESS_VCC_VCC #define IS31FL3733_DRIVER_COUNT 2 #define RGB_MATRIX_LED_COUNT 111 #define IS31FL3733_PWM_FREQUENCY IS31FL3733_PWM_FREQUENCY_26K7_HZ diff --git a/keyboards/drop/shift/v2/config.h b/keyboards/drop/shift/v2/config.h index 7334585d16d..29b77cba9b0 100644 --- a/keyboards/drop/shift/v2/config.h +++ b/keyboards/drop/shift/v2/config.h @@ -14,9 +14,9 @@ #define EXTERNAL_EEPROM_WP_PIN B5 #define EEPROM_I2C_24LC256 -#define DRIVER_ADDR_1 0b1010011 -#define DRIVER_ADDR_2 0b1011111 -#define DRIVER_ADDR_3 0b1010000 +#define DRIVER_ADDR_1 IS31FL3733_I2C_ADDRESS_GND_VCC +#define DRIVER_ADDR_2 IS31FL3733_I2C_ADDRESS_VCC_VCC +#define DRIVER_ADDR_3 IS31FL3733_I2C_ADDRESS_GND_GND #define IS31FL3733_DRIVER_COUNT 3 #define RGB_MATRIX_LED_COUNT 166 #define IS31FL3733_PWM_FREQUENCY IS31FL3733_PWM_FREQUENCY_26K7_HZ diff --git a/keyboards/durgod/dgk6x/config.h b/keyboards/durgod/dgk6x/config.h index 12addab8e83..542c6a231c8 100644 --- a/keyboards/durgod/dgk6x/config.h +++ b/keyboards/durgod/dgk6x/config.h @@ -34,19 +34,8 @@ #define LED_MR_LOCK_PIN LED_SCROLL_LOCK_PIN #ifdef RGB_MATRIX_ENABLE -// This is a 7-bit address, that gets left-shifted and bit 0 -// set to 0 for write, 1 for read (as per I2C protocol) -// The address will vary depending on your wiring: -// 00 <-> GND -// 01 <-> SCL -// 10 <-> SDA -// 11 <-> VCC -// ADDR1 represents A1:A0 of the 7-bit address. -// ADDR2 represents A3:A2 of the 7-bit address. -// The result is: 0b101(ADDR2)(ADDR1) - -#define DRIVER_ADDR_1 0b1010000 -#define DRIVER_ADDR_2 0b1010011 +#define DRIVER_ADDR_1 IS31FL3733_I2C_ADDRESS_GND_GND +#define DRIVER_ADDR_2 IS31FL3733_I2C_ADDRESS_GND_VCC #define IS31FL3733_DRIVER_COUNT 2 #define RGB_MATRIX_LED_COUNT (DRIVER_1_LED_TOTAL + DRIVER_2_LED_TOTAL) diff --git a/keyboards/dztech/dz60rgb/v1/config.h b/keyboards/dztech/dz60rgb/v1/config.h index bd5663d0f22..52ae406b987 100644 --- a/keyboards/dztech/dz60rgb/v1/config.h +++ b/keyboards/dztech/dz60rgb/v1/config.h @@ -55,7 +55,7 @@ // # define ENABLE_RGB_MATRIX_SOLID_MULTISPLASH # define RGB_MATRIX_DEFAULT_MODE RGB_MATRIX_CYCLE_ALL -# define DRIVER_ADDR_1 0b1010000 +# define DRIVER_ADDR_1 IS31FL3733_I2C_ADDRESS_GND_GND # define IS31FL3733_DRIVER_COUNT 1 # define RGB_MATRIX_LED_COUNT 63 #endif diff --git a/keyboards/dztech/dz60rgb/v2/config.h b/keyboards/dztech/dz60rgb/v2/config.h index 73e37406cb3..733e8f49661 100644 --- a/keyboards/dztech/dz60rgb/v2/config.h +++ b/keyboards/dztech/dz60rgb/v2/config.h @@ -53,7 +53,7 @@ // # define ENABLE_RGB_MATRIX_SOLID_SPLASH // # define ENABLE_RGB_MATRIX_SOLID_MULTISPLASH -# define DRIVER_ADDR_1 0b1010000 +# define DRIVER_ADDR_1 IS31FL3733_I2C_ADDRESS_GND_GND # define IS31FL3733_DRIVER_COUNT 1 # define RGB_MATRIX_LED_COUNT 63 #endif diff --git a/keyboards/dztech/dz60rgb/v2_1/config.h b/keyboards/dztech/dz60rgb/v2_1/config.h index 669c343fa0e..406b1141af1 100644 --- a/keyboards/dztech/dz60rgb/v2_1/config.h +++ b/keyboards/dztech/dz60rgb/v2_1/config.h @@ -69,7 +69,7 @@ // # define ENABLE_RGB_MATRIX_SOLID_SPLASH // # define ENABLE_RGB_MATRIX_SOLID_MULTISPLASH -# define DRIVER_ADDR_1 0b1010000 +# define DRIVER_ADDR_1 IS31FL3733_I2C_ADDRESS_GND_GND # define IS31FL3733_DRIVER_COUNT 1 # define RGB_MATRIX_LED_COUNT 63 #endif diff --git a/keyboards/dztech/dz60rgb_ansi/v1/config.h b/keyboards/dztech/dz60rgb_ansi/v1/config.h index 016588e7ba1..59a680615f5 100644 --- a/keyboards/dztech/dz60rgb_ansi/v1/config.h +++ b/keyboards/dztech/dz60rgb_ansi/v1/config.h @@ -55,7 +55,7 @@ // # define ENABLE_RGB_MATRIX_SOLID_MULTISPLASH # define RGB_MATRIX_DEFAULT_MODE RGB_MATRIX_CYCLE_ALL -# define DRIVER_ADDR_1 0b1010000 +# define DRIVER_ADDR_1 IS31FL3733_I2C_ADDRESS_GND_GND # define IS31FL3733_DRIVER_COUNT 1 # define RGB_MATRIX_LED_COUNT 61 #endif diff --git a/keyboards/dztech/dz60rgb_ansi/v2/config.h b/keyboards/dztech/dz60rgb_ansi/v2/config.h index 87718ad5e30..819b98e36ae 100644 --- a/keyboards/dztech/dz60rgb_ansi/v2/config.h +++ b/keyboards/dztech/dz60rgb_ansi/v2/config.h @@ -53,7 +53,7 @@ # define ENABLE_RGB_MATRIX_SOLID_SPLASH // # define ENABLE_RGB_MATRIX_SOLID_MULTISPLASH -# define DRIVER_ADDR_1 0b1010000 +# define DRIVER_ADDR_1 IS31FL3733_I2C_ADDRESS_GND_GND # define IS31FL3733_DRIVER_COUNT 1 # define RGB_MATRIX_LED_COUNT 61 #endif diff --git a/keyboards/dztech/dz60rgb_ansi/v2_1/config.h b/keyboards/dztech/dz60rgb_ansi/v2_1/config.h index 2981fb2f59d..a186cd82c38 100644 --- a/keyboards/dztech/dz60rgb_ansi/v2_1/config.h +++ b/keyboards/dztech/dz60rgb_ansi/v2_1/config.h @@ -69,7 +69,7 @@ // # define ENABLE_RGB_MATRIX_SOLID_SPLASH // # define ENABLE_RGB_MATRIX_SOLID_MULTISPLASH -# define DRIVER_ADDR_1 0b1010000 +# define DRIVER_ADDR_1 IS31FL3733_I2C_ADDRESS_GND_GND # define IS31FL3733_DRIVER_COUNT 1 # define RGB_MATRIX_LED_COUNT 61 #endif diff --git a/keyboards/dztech/dz60rgb_wkl/v1/config.h b/keyboards/dztech/dz60rgb_wkl/v1/config.h index e4819dd4158..850ecae4811 100644 --- a/keyboards/dztech/dz60rgb_wkl/v1/config.h +++ b/keyboards/dztech/dz60rgb_wkl/v1/config.h @@ -55,7 +55,7 @@ // # define ENABLE_RGB_MATRIX_SOLID_MULTISPLASH # define RGB_MATRIX_DEFAULT_MODE RGB_MATRIX_CYCLE_ALL -# define DRIVER_ADDR_1 0b1010000 +# define DRIVER_ADDR_1 IS31FL3733_I2C_ADDRESS_GND_GND # define IS31FL3733_DRIVER_COUNT 1 # define RGB_MATRIX_LED_COUNT 62 #endif diff --git a/keyboards/dztech/dz60rgb_wkl/v2/config.h b/keyboards/dztech/dz60rgb_wkl/v2/config.h index 286f0718c6f..1496a0cbe83 100644 --- a/keyboards/dztech/dz60rgb_wkl/v2/config.h +++ b/keyboards/dztech/dz60rgb_wkl/v2/config.h @@ -50,7 +50,7 @@ # define ENABLE_RGB_MATRIX_SOLID_SPLASH // # define ENABLE_RGB_MATRIX_SOLID_MULTISPLASH -# define DRIVER_ADDR_1 0b1010000 +# define DRIVER_ADDR_1 IS31FL3733_I2C_ADDRESS_GND_GND # define IS31FL3733_DRIVER_COUNT 1 # define RGB_MATRIX_LED_COUNT 62 #endif diff --git a/keyboards/dztech/dz60rgb_wkl/v2_1/config.h b/keyboards/dztech/dz60rgb_wkl/v2_1/config.h index 41274a6bac8..1c036310dc9 100644 --- a/keyboards/dztech/dz60rgb_wkl/v2_1/config.h +++ b/keyboards/dztech/dz60rgb_wkl/v2_1/config.h @@ -69,7 +69,7 @@ # define ENABLE_RGB_MATRIX_SOLID_SPLASH // # define ENABLE_RGB_MATRIX_SOLID_MULTISPLASH -# define DRIVER_ADDR_1 0b1010000 +# define DRIVER_ADDR_1 IS31FL3733_I2C_ADDRESS_GND_GND # define IS31FL3733_DRIVER_COUNT 1 # define RGB_MATRIX_LED_COUNT 62 #endif diff --git a/keyboards/dztech/dz64rgb/config.h b/keyboards/dztech/dz64rgb/config.h index a1e779f73c5..f7dd035eb85 100644 --- a/keyboards/dztech/dz64rgb/config.h +++ b/keyboards/dztech/dz64rgb/config.h @@ -48,7 +48,7 @@ #define ENABLE_RGB_MATRIX_PIXEL_FRACTAL #define ENABLE_RGB_MATRIX_TYPING_HEATMAP #define RGB_MATRIX_DEFAULT_MODE RGB_MATRIX_CYCLE_ALL -#define DRIVER_ADDR_1 0b1010000 +#define DRIVER_ADDR_1 IS31FL3733_I2C_ADDRESS_GND_GND #define IS31FL3733_DRIVER_COUNT 1 #define RGB_MATRIX_LED_COUNT 64 #endif diff --git a/keyboards/dztech/dz65rgb/v1/config.h b/keyboards/dztech/dz65rgb/v1/config.h index 79c1473f238..ac462043ac6 100644 --- a/keyboards/dztech/dz65rgb/v1/config.h +++ b/keyboards/dztech/dz65rgb/v1/config.h @@ -70,8 +70,8 @@ // # define ENABLE_RGB_MATRIX_SOLID_MULTISPLASH # define RGB_MATRIX_MAXIMUM_BRIGHTNESS 200 # define RGB_MATRIX_DEFAULT_MODE RGB_MATRIX_CYCLE_ALL -# define DRIVER_ADDR_1 0b1110100 -# define DRIVER_ADDR_2 0b1110111 +# define DRIVER_ADDR_1 IS31FL3731_I2C_ADDRESS_GND +# define DRIVER_ADDR_2 IS31FL3731_I2C_ADDRESS_VCC # define IS31FL3731_DRIVER_COUNT 2 # define DRIVER_1_LED_TOTAL 35 # define DRIVER_2_LED_TOTAL 33 diff --git a/keyboards/dztech/dz65rgb/v2/config.h b/keyboards/dztech/dz65rgb/v2/config.h index 187e661bdb3..2c849c96910 100644 --- a/keyboards/dztech/dz65rgb/v2/config.h +++ b/keyboards/dztech/dz65rgb/v2/config.h @@ -70,8 +70,8 @@ // # define ENABLE_RGB_MATRIX_SOLID_MULTISPLASH # define RGB_MATRIX_MAXIMUM_BRIGHTNESS 200 # define RGB_MATRIX_DEFAULT_MODE RGB_MATRIX_CYCLE_ALL -# define DRIVER_ADDR_1 0b1110100 -# define DRIVER_ADDR_2 0b1110111 +# define DRIVER_ADDR_1 IS31FL3731_I2C_ADDRESS_GND +# define DRIVER_ADDR_2 IS31FL3731_I2C_ADDRESS_VCC # define IS31FL3731_DRIVER_COUNT 2 # define DRIVER_1_LED_TOTAL 35 # define DRIVER_2_LED_TOTAL 33 diff --git a/keyboards/dztech/dz65rgb/v3/config.h b/keyboards/dztech/dz65rgb/v3/config.h index 2077bd93d41..f99315e0ed7 100755 --- a/keyboards/dztech/dz65rgb/v3/config.h +++ b/keyboards/dztech/dz65rgb/v3/config.h @@ -72,7 +72,7 @@ # define ENABLE_RGB_MATRIX_SOLID_MULTISPLASH # define RGB_MATRIX_DEFAULT_MODE RGB_MATRIX_CYCLE_ALL -# define DRIVER_ADDR_1 0b0110000 +# define DRIVER_ADDR_1 IS31FL3741_I2C_ADDRESS_GND # define IS31FL3741_DRIVER_COUNT 1 # define RGB_MATRIX_LED_COUNT 68 # define DRIVER_INDICATOR_LED_TOTAL 0 diff --git a/keyboards/dztech/tofu/ii/v1/config.h b/keyboards/dztech/tofu/ii/v1/config.h index b709c8d2baf..e4162972391 100644 --- a/keyboards/dztech/tofu/ii/v1/config.h +++ b/keyboards/dztech/tofu/ii/v1/config.h @@ -79,8 +79,8 @@ # define ENABLE_RGB_MATRIX_SOLID_MULTISPLASH # define RGB_MATRIX_MAXIMUM_BRIGHTNESS 180 // limits maximum brightness of LEDs to 200 out of 255. If not defined maximum brightness is set to 255 # define RGB_MATRIX_DEFAULT_MODE RGB_MATRIX_CYCLE_ALL -# define DRIVER_ADDR_1 0b1010000 -# define DRIVER_ADDR_2 0b1011111 +# define DRIVER_ADDR_1 IS31FL3737_I2C_ADDRESS_GND +# define DRIVER_ADDR_2 IS31FL3737_I2C_ADDRESS_VCC # define IS31FL3737_DRIVER_COUNT 2 # define DRIVER_1_LED_TOTAL 46 # define DRIVER_2_LED_TOTAL 20 diff --git a/keyboards/dztech/tofu/jr/v1/config.h b/keyboards/dztech/tofu/jr/v1/config.h index a9ab620c587..21de51ccfc5 100644 --- a/keyboards/dztech/tofu/jr/v1/config.h +++ b/keyboards/dztech/tofu/jr/v1/config.h @@ -79,8 +79,8 @@ # define ENABLE_RGB_MATRIX_SOLID_MULTISPLASH # define RGB_MATRIX_MAXIMUM_BRIGHTNESS 180 // limits maximum brightness of LEDs to 200 out of 255. If not defined maximum brightness is set to 255 # define RGB_MATRIX_DEFAULT_MODE RGB_MATRIX_CYCLE_ALL -# define DRIVER_ADDR_1 0b1010000 -# define DRIVER_ADDR_2 0b1011111 +# define DRIVER_ADDR_1 IS31FL3737_I2C_ADDRESS_GND +# define DRIVER_ADDR_2 IS31FL3737_I2C_ADDRESS_VCC # define IS31FL3737_DRIVER_COUNT 2 # define DRIVER_1_LED_TOTAL 48 # define DRIVER_2_LED_TOTAL 20 diff --git a/keyboards/ergodox_ez/config.h b/keyboards/ergodox_ez/config.h index 3741b72a67b..b4385af15d8 100644 --- a/keyboards/ergodox_ez/config.h +++ b/keyboards/ergodox_ez/config.h @@ -91,8 +91,8 @@ along with this program. If not, see . // RGB backlight -#define DRIVER_ADDR_1 0b1110100 -#define DRIVER_ADDR_2 0b1110111 +#define DRIVER_ADDR_1 IS31FL3731_I2C_ADDRESS_GND +#define DRIVER_ADDR_2 IS31FL3731_I2C_ADDRESS_VCC #define IS31FL3731_DRIVER_COUNT 2 #define DRIVER_1_LED_TOTAL 24 #define DRIVER_2_LED_TOTAL 24 diff --git a/keyboards/evyd13/atom47/rev5/config.h b/keyboards/evyd13/atom47/rev5/config.h index d15141e5a57..5f9fda9bbfc 100644 --- a/keyboards/evyd13/atom47/rev5/config.h +++ b/keyboards/evyd13/atom47/rev5/config.h @@ -38,17 +38,7 @@ along with this program. If not, see . //#define NO_ACTION_TAPPING //#define NO_ACTION_ONESHOT -// This is a 7-bit address, that gets left-shifted and bit 0 -// set to 0 for write, 1 for read (as per I2C protocol) -// The address will vary depending on your wiring: -// 00 <-> GND -// 01 <-> SCL -// 10 <-> SDA -// 11 <-> VCC -// ADDR1 represents A1:A0 of the 7-bit address. -// ADDR2 represents A3:A2 of the 7-bit address. -// The result is: 0b101(ADDR2)(ADDR1) -#define DRIVER_ADDR_1 0b1010000 +#define DRIVER_ADDR_1 IS31FL3733_I2C_ADDRESS_GND_GND #define IS31FL3733_DRIVER_COUNT 1 #define RGB_MATRIX_LED_COUNT 64 diff --git a/keyboards/exclusive/e6_rgb/config.h b/keyboards/exclusive/e6_rgb/config.h index 0e5ecaaa9d6..37a251b3f02 100644 --- a/keyboards/exclusive/e6_rgb/config.h +++ b/keyboards/exclusive/e6_rgb/config.h @@ -4,7 +4,7 @@ */ #pragma once -#define DRIVER_ADDR_1 0b1010000 +#define DRIVER_ADDR_1 IS31FL3733_I2C_ADDRESS_GND_GND #define IS31FL3733_DRIVER_COUNT 1 #define RGB_MATRIX_LED_COUNT 63 diff --git a/keyboards/fallacy/config.h b/keyboards/fallacy/config.h index dc66968bdc2..eff0cc4f50b 100755 --- a/keyboards/fallacy/config.h +++ b/keyboards/fallacy/config.h @@ -18,7 +18,7 @@ /* IS31FL3731 driver address (for status LEDs) * Using the default defines here, but using a custom implementation */ -#define LED_DRIVER_ADDR_1 0b1110100 +#define LED_DRIVER_ADDR_1 IS31FL3731_I2C_ADDRESS_GND #define IS31FL3731_DRIVER_COUNT 1 #define LED_MATRIX_LED_COUNT 3 diff --git a/keyboards/feker/ik75/config.h b/keyboards/feker/ik75/config.h index 2e813d14772..c266bf757e9 100644 --- a/keyboards/feker/ik75/config.h +++ b/keyboards/feker/ik75/config.h @@ -25,8 +25,8 @@ #define RGB_MATRIX_FRAMEBUFFER_EFFECTS /* RGB Matrix config */ - #define DRIVER_ADDR_1 0b1011111 - #define DRIVER_ADDR_2 0b1010000 + #define DRIVER_ADDR_1 IS31FL3733_I2C_ADDRESS_VCC_VCC + #define DRIVER_ADDR_2 IS31FL3733_I2C_ADDRESS_GND_GND #define IS31FL3733_DRIVER_COUNT 2 #define DRIVER_1_LED_TOTAL 63 #define DRIVER_2_LED_TOTAL 64 diff --git a/keyboards/ferris/0_2/bling/config.h b/keyboards/ferris/0_2/bling/config.h index 9d8e9786f19..382c4c1e001 100644 --- a/keyboards/ferris/0_2/bling/config.h +++ b/keyboards/ferris/0_2/bling/config.h @@ -18,8 +18,8 @@ along with this program. If not, see . #pragma once /* LED Drivers */ -#define DRIVER_ADDR_1 0b1110100 -#define DRIVER_ADDR_2 0b1110101 +#define DRIVER_ADDR_1 IS31FL3731_I2C_ADDRESS_GND +#define DRIVER_ADDR_2 IS31FL3731_I2C_ADDRESS_SCL #define IS31FL3731_DRIVER_COUNT 2 #define DRIVER_1_LED_TOTAL 7 #define DRIVER_2_LED_TOTAL 7 diff --git a/keyboards/flashquark/horizon_z/config.h b/keyboards/flashquark/horizon_z/config.h index dac6caa24da..f087af93c27 100755 --- a/keyboards/flashquark/horizon_z/config.h +++ b/keyboards/flashquark/horizon_z/config.h @@ -72,7 +72,7 @@ // # define ENABLE_RGB_MATRIX_SOLID_SPLASH // # define ENABLE_RGB_MATRIX_SOLID_MULTISPLASH -# define DRIVER_ADDR_1 0b1010000 +# define DRIVER_ADDR_1 IS31FL3733_I2C_ADDRESS_GND_GND # define IS31FL3733_DRIVER_COUNT 1 # define RGB_MATRIX_LED_COUNT 62 #endif diff --git a/keyboards/frooastboard/walnut/config.h b/keyboards/frooastboard/walnut/config.h index 3e7b8700756..f60c57dec53 100644 --- a/keyboards/frooastboard/walnut/config.h +++ b/keyboards/frooastboard/walnut/config.h @@ -6,7 +6,7 @@ #define IS31FL3737_PWM_FREQUENCY IS31FL3737_PWM_FREQUENCY_26K7_HZ #define IS31FL3737_DRIVER_COUNT 1 #define RGB_MATRIX_LED_COUNT 48 -#define DRIVER_ADDR_1 0b1010000 +#define DRIVER_ADDR_1 IS31FL3737_I2C_ADDRESS_GND #define RGB_MATRIX_MAXIMUM_BRIGHTNESS 191 diff --git a/keyboards/geekboards/tester/config.h b/keyboards/geekboards/tester/config.h index 0e7b8a17375..5933471b8c0 100644 --- a/keyboards/geekboards/tester/config.h +++ b/keyboards/geekboards/tester/config.h @@ -55,8 +55,8 @@ // # define ENABLE_RGB_MATRIX_SOLID_SPLASH // # define ENABLE_RGB_MATRIX_SOLID_MULTISPLASH -# define DRIVER_ADDR_1 0b1110100 -# define DRIVER_ADDR_2 0b1110101 +# define DRIVER_ADDR_1 IS31FL3731_I2C_ADDRESS_GND +# define DRIVER_ADDR_2 IS31FL3731_I2C_ADDRESS_SCL # define IS31FL3731_DRIVER_COUNT 2 # define DRIVER_1_LED_TOTAL 8 # define DRIVER_2_LED_TOTAL 0 diff --git a/keyboards/gizmo_engineering/gk6/config.h b/keyboards/gizmo_engineering/gk6/config.h index aabc2939226..dfd9f0c7038 100755 --- a/keyboards/gizmo_engineering/gk6/config.h +++ b/keyboards/gizmo_engineering/gk6/config.h @@ -18,8 +18,8 @@ along with this program. If not, see . #pragma once // RGB Matrix -#define DRIVER_ADDR_1 0b1110100 -#define DRIVER_ADDR_2 0b1110111 +#define DRIVER_ADDR_1 IS31FL3731_I2C_ADDRESS_GND +#define DRIVER_ADDR_2 IS31FL3731_I2C_ADDRESS_VCC #define IS31FL3731_DRIVER_COUNT 2 #define DRIVER_1_LED_TOTAL 32 diff --git a/keyboards/handwired/orbweaver/config.h b/keyboards/handwired/orbweaver/config.h index e0594697a12..a264089c714 100644 --- a/keyboards/handwired/orbweaver/config.h +++ b/keyboards/handwired/orbweaver/config.h @@ -18,7 +18,7 @@ #pragma once #define IS31FL3731_DRIVER_COUNT 1 -#define DRIVER_ADDR_1 0b1110100 +#define DRIVER_ADDR_1 IS31FL3731_I2C_ADDRESS_GND #define RGB_MATRIX_LED_COUNT 20 #define I2C1_CLOCK_SPEED 100000 #define RGB_MATRIX_CENTER { 40, 30 } diff --git a/keyboards/hs60/v1/config.h b/keyboards/hs60/v1/config.h index d9e94b2a14a..c7eac09b17c 100644 --- a/keyboards/hs60/v1/config.h +++ b/keyboards/hs60/v1/config.h @@ -41,8 +41,8 @@ along with this program. If not, see . // #define RGB_DISABLE_WHEN_USB_SUSPENDED // turn off effects when suspended #define RGB_MATRIX_MAXIMUM_BRIGHTNESS 215 -#define DRIVER_ADDR_1 0b1110100 -#define DRIVER_ADDR_2 0b1110101 +#define DRIVER_ADDR_1 IS31FL3731_I2C_ADDRESS_GND +#define DRIVER_ADDR_2 IS31FL3731_I2C_ADDRESS_SCL #define IS31FL3731_DRIVER_COUNT 2 #define DRIVER_1_LED_TOTAL 30 diff --git a/keyboards/ilumkb/simpler61/config.h b/keyboards/ilumkb/simpler61/config.h index 12c63906832..5a9b4df785b 100644 --- a/keyboards/ilumkb/simpler61/config.h +++ b/keyboards/ilumkb/simpler61/config.h @@ -21,7 +21,7 @@ #define RGB_MATRIX_LED_PROCESS_LIMIT 4 #define RGB_MATRIX_LED_FLUSH_LIMIT 26 #define RGB_MATRIX_DEFAULT_MODE RGB_MATRIX_CYCLE_ALL -#define DRIVER_ADDR_1 0b0110000 +#define DRIVER_ADDR_1 IS31FL3741_I2C_ADDRESS_GND #define IS31FL3741_DRIVER_COUNT 1 #define DRIVER_1_LED_TOTAL 61 #define RGB_MATRIX_LED_COUNT DRIVER_1_LED_TOTAL diff --git a/keyboards/ilumkb/simpler64/config.h b/keyboards/ilumkb/simpler64/config.h index 58268e23cff..ab1265fe1c6 100644 --- a/keyboards/ilumkb/simpler64/config.h +++ b/keyboards/ilumkb/simpler64/config.h @@ -21,7 +21,7 @@ #define RGB_MATRIX_LED_PROCESS_LIMIT 4 #define RGB_MATRIX_LED_FLUSH_LIMIT 26 #define RGB_MATRIX_DEFAULT_MODE RGB_MATRIX_CYCLE_ALL -#define DRIVER_ADDR_1 0b0110000 +#define DRIVER_ADDR_1 IS31FL3741_I2C_ADDRESS_GND #define IS31FL3741_DRIVER_COUNT 1 #define DRIVER_1_LED_TOTAL 64 #define RGB_MATRIX_LED_COUNT DRIVER_1_LED_TOTAL diff --git a/keyboards/inett_studio/sqx/hotswap/config.h b/keyboards/inett_studio/sqx/hotswap/config.h index c11317afc8f..66a6a8a6111 100644 --- a/keyboards/inett_studio/sqx/hotswap/config.h +++ b/keyboards/inett_studio/sqx/hotswap/config.h @@ -32,8 +32,8 @@ //rgb matrix setting #define DRIVER_1_LED_TOTAL 33 #define DRIVER_2_LED_TOTAL 31 -#define DRIVER_ADDR_1 0b1110100 -#define DRIVER_ADDR_2 0b1110111 +#define DRIVER_ADDR_1 IS31FL3731_I2C_ADDRESS_GND +#define DRIVER_ADDR_2 IS31FL3731_I2C_ADDRESS_VCC #define IS31FL3731_DRIVER_COUNT 2 #define RGB_MATRIX_LED_COUNT (DRIVER_1_LED_TOTAL + DRIVER_2_LED_TOTAL) diff --git a/keyboards/inett_studio/sqx/universal/config.h b/keyboards/inett_studio/sqx/universal/config.h index 772c8db16bd..73bda58206a 100644 --- a/keyboards/inett_studio/sqx/universal/config.h +++ b/keyboards/inett_studio/sqx/universal/config.h @@ -32,8 +32,8 @@ //rgb matrix setting #define DRIVER_1_LED_TOTAL 36 #define DRIVER_2_LED_TOTAL 36 -#define DRIVER_ADDR_1 0b1110100 -#define DRIVER_ADDR_2 0b1110111 +#define DRIVER_ADDR_1 IS31FL3731_I2C_ADDRESS_GND +#define DRIVER_ADDR_2 IS31FL3731_I2C_ADDRESS_VCC #define IS31FL3731_DRIVER_COUNT 2 #define RGB_MATRIX_LED_COUNT (DRIVER_1_LED_TOTAL + DRIVER_2_LED_TOTAL) diff --git a/keyboards/input_club/ergodox_infinity/config.h b/keyboards/input_club/ergodox_infinity/config.h index 17baf0013e8..7c35ccc7849 100644 --- a/keyboards/input_club/ergodox_infinity/config.h +++ b/keyboards/input_club/ergodox_infinity/config.h @@ -43,7 +43,7 @@ along with this program. If not, see . #define LED_BRIGHTNESS_HI 255 /* LED matrix driver */ -#define LED_DRIVER_ADDR_1 0x74 +#define LED_DRIVER_ADDR_1 IS31FL3731_I2C_ADDRESS_GND #define IS31FL3731_DRIVER_COUNT 1 #define LED_MATRIX_LED_COUNT 76 #define LED_MATRIX_SPLIT { 38, 38 } diff --git a/keyboards/input_club/k_type/config.h b/keyboards/input_club/k_type/config.h index 5d4d515d77c..b3365bd0af7 100644 --- a/keyboards/input_club/k_type/config.h +++ b/keyboards/input_club/k_type/config.h @@ -103,8 +103,8 @@ along with this program. If not, see . # define I2C2_SCL_PAL_MODE PAL_MODE_ALTERNATIVE_2 # define I2C2_SDA_PAL_MODE PAL_MODE_ALTERNATIVE_2 -# define DRIVER_ADDR_1 0b1010000 -# define DRIVER_ADDR_2 0b1010000 +# define DRIVER_ADDR_1 IS31FL3733_I2C_ADDRESS_GND_GND +# define DRIVER_ADDR_2 IS31FL3733_I2C_ADDRESS_GND_GND # define IS31FL3733_DRIVER_COUNT 2 # define DRIVER_1_LED_TOTAL 64 # define DRIVER_2_LED_TOTAL 55 diff --git a/keyboards/input_club/k_type/is31fl3733-dual.c b/keyboards/input_club/k_type/is31fl3733-dual.c index 2976f5aed49..851b56a37de 100644 --- a/keyboards/input_club/k_type/is31fl3733-dual.c +++ b/keyboards/input_club/k_type/is31fl3733-dual.c @@ -20,18 +20,6 @@ #include "i2c_master.h" #include "wait.h" -// This is a 7-bit address, that gets left-shifted and bit 0 -// set to 0 for write, 1 for read (as per I2C protocol) -// The address will vary depending on your wiring: -// 00 <-> GND -// 01 <-> SCL -// 10 <-> SDA -// 11 <-> VCC -// ADDR1 represents A1:A0 of the 7-bit address. -// ADDR2 represents A3:A2 of the 7-bit address. -// The result is: 0b101(ADDR2)(ADDR1) -#define IS31FL3733_I2C_ADDRESS_DEFAULT 0x50 - #define IS31FL3733_COMMANDREGISTER 0xFD #define IS31FL3733_COMMANDREGISTER_WRITELOCK 0xFE #define IS31FL3733_INTERRUPTMASKREGISTER 0xF0 diff --git a/keyboards/input_club/k_type/is31fl3733-dual.h b/keyboards/input_club/k_type/is31fl3733-dual.h index a5ef3ff008a..796708f5072 100644 --- a/keyboards/input_club/k_type/is31fl3733-dual.h +++ b/keyboards/input_club/k_type/is31fl3733-dual.h @@ -22,6 +22,23 @@ #include #include "progmem.h" +#define IS31FL3733_I2C_ADDRESS_GND_GND 0x50 +#define IS31FL3733_I2C_ADDRESS_GND_SCL 0x51 +#define IS31FL3733_I2C_ADDRESS_GND_SDA 0x52 +#define IS31FL3733_I2C_ADDRESS_GND_VCC 0x53 +#define IS31FL3733_I2C_ADDRESS_SCL_GND 0x54 +#define IS31FL3733_I2C_ADDRESS_SCL_SCL 0x55 +#define IS31FL3733_I2C_ADDRESS_SCL_SDA 0x56 +#define IS31FL3733_I2C_ADDRESS_SCL_VCC 0x57 +#define IS31FL3733_I2C_ADDRESS_SDA_GND 0x58 +#define IS31FL3733_I2C_ADDRESS_SDA_SCL 0x59 +#define IS31FL3733_I2C_ADDRESS_SDA_SDA 0x5A +#define IS31FL3733_I2C_ADDRESS_SDA_VCC 0x5B +#define IS31FL3733_I2C_ADDRESS_VCC_GND 0x5C +#define IS31FL3733_I2C_ADDRESS_VCC_SCL 0x5D +#define IS31FL3733_I2C_ADDRESS_VCC_SDA 0x5E +#define IS31FL3733_I2C_ADDRESS_VCC_VCC 0x5F + typedef struct is31_led { uint8_t driver : 2; uint8_t r; diff --git a/keyboards/input_club/whitefox/config.h b/keyboards/input_club/whitefox/config.h index bf8d3d6c9c2..aa8277d4ca0 100644 --- a/keyboards/input_club/whitefox/config.h +++ b/keyboards/input_club/whitefox/config.h @@ -21,7 +21,7 @@ along with this program. If not, see . #define LED_BRIGHTNESS_HI 255 /* LED matrix driver */ -#define LED_DRIVER_ADDR_1 0x74 +#define LED_DRIVER_ADDR_1 IS31FL3731_I2C_ADDRESS_GND #define IS31FL3731_DRIVER_COUNT 1 #define LED_MATRIX_LED_COUNT 71 #define LED_DISABLE_WHEN_USB_SUSPENDED diff --git a/keyboards/kbdcraft/adam64/config.h b/keyboards/kbdcraft/adam64/config.h index c7fa1aecc96..b2c0cca3d10 100644 --- a/keyboards/kbdcraft/adam64/config.h +++ b/keyboards/kbdcraft/adam64/config.h @@ -24,7 +24,7 @@ #define I2C1_DUTY_CYCLE FAST_DUTY_CYCLE_16_9 #define IS31FL3741_DRIVER_COUNT 1 -#define DRIVER_ADDR_1 0b0110000 +#define DRIVER_ADDR_1 IS31FL3741_I2C_ADDRESS_GND #define RGB_MATRIX_LED_COUNT 64 /* turn off effects when suspended */ diff --git a/keyboards/kbdfans/bella/rgb/config.h b/keyboards/kbdfans/bella/rgb/config.h index 8e416d77d98..c3c7e423f33 100644 --- a/keyboards/kbdfans/bella/rgb/config.h +++ b/keyboards/kbdfans/bella/rgb/config.h @@ -71,7 +71,7 @@ // # define ENABLE_RGB_MATRIX_SOLID_MULTISPLASH //#define RGB_MATRIX_DEFAULT_MODE RGB_MATRIX_SOLID_COLOR #define RGB_MATRIX_DEFAULT_MODE RGB_MATRIX_CYCLE_ALL -#define DRIVER_ADDR_1 0b0110000 +#define DRIVER_ADDR_1 IS31FL3741_I2C_ADDRESS_GND #define IS31FL3741_DRIVER_COUNT 1 #define RGB_MATRIX_LED_COUNT 108 #define DRIVER_INDICATOR_LED_TOTAL 0 diff --git a/keyboards/kbdfans/bella/rgb_iso/config.h b/keyboards/kbdfans/bella/rgb_iso/config.h index 50d5120beb1..dc3f987bbe4 100644 --- a/keyboards/kbdfans/bella/rgb_iso/config.h +++ b/keyboards/kbdfans/bella/rgb_iso/config.h @@ -71,7 +71,7 @@ // # define ENABLE_RGB_MATRIX_SOLID_MULTISPLASH //#define RGB_MATRIX_DEFAULT_MODE RGB_MATRIX_SOLID_COLOR #define RGB_MATRIX_DEFAULT_MODE RGB_MATRIX_CYCLE_ALL -#define DRIVER_ADDR_1 0b0110000 +#define DRIVER_ADDR_1 IS31FL3741_I2C_ADDRESS_GND #define IS31FL3741_DRIVER_COUNT 1 #define RGB_MATRIX_LED_COUNT 109 #define DRIVER_INDICATOR_LED_TOTAL 0 diff --git a/keyboards/kbdfans/boop65/rgb/config.h b/keyboards/kbdfans/boop65/rgb/config.h index 0e80e2c67e9..89375078d7f 100644 --- a/keyboards/kbdfans/boop65/rgb/config.h +++ b/keyboards/kbdfans/boop65/rgb/config.h @@ -26,7 +26,7 @@ # define RGB_MATRIX_MAXIMUM_BRIGHTNESS 200 // limits maximum brightness of LEDs to 200 out of 255. If not defined maximum brightness is set to 255 # define RGB_MATRIX_DEFAULT_VAL RGB_MATRIX_MAXIMUM_BRIGHTNESS // Sets the default brightness value, if none has been set # define RGB_MATRIX_DEFAULT_MODE RGB_MATRIX_CYCLE_ALL -# define DRIVER_ADDR_1 0b0110000 +# define DRIVER_ADDR_1 IS31FL3741_I2C_ADDRESS_GND # define IS31FL3741_DRIVER_COUNT 1 # define RGB_MATRIX_LED_COUNT 83 # define DRIVER_INDICATOR_LED_TOTAL 0 diff --git a/keyboards/kbdfans/kbd67/mkiirgb/v1/config.h b/keyboards/kbdfans/kbd67/mkiirgb/v1/config.h index cae6b8bf92c..b836410d601 100644 --- a/keyboards/kbdfans/kbd67/mkiirgb/v1/config.h +++ b/keyboards/kbdfans/kbd67/mkiirgb/v1/config.h @@ -55,8 +55,8 @@ #define RGB_MATRIX_MAXIMUM_BRIGHTNESS 200 #define RGB_MATRIX_DEFAULT_MODE RGB_MATRIX_CYCLE_ALL -#define DRIVER_ADDR_1 0b1110100 -#define DRIVER_ADDR_2 0b1110111 +#define DRIVER_ADDR_1 IS31FL3731_I2C_ADDRESS_GND +#define DRIVER_ADDR_2 IS31FL3731_I2C_ADDRESS_VCC #define IS31FL3731_DRIVER_COUNT 2 #define DRIVER_1_LED_TOTAL 35 #define DRIVER_2_LED_TOTAL 32 diff --git a/keyboards/kbdfans/kbd67/mkiirgb/v2/config.h b/keyboards/kbdfans/kbd67/mkiirgb/v2/config.h index c55b0c7f1fa..0dad3d6767c 100644 --- a/keyboards/kbdfans/kbd67/mkiirgb/v2/config.h +++ b/keyboards/kbdfans/kbd67/mkiirgb/v2/config.h @@ -55,8 +55,8 @@ // #define ENABLE_RGB_MATRIX_SOLID_SPLASH // #define ENABLE_RGB_MATRIX_SOLID_MULTISPLASH # define RGB_MATRIX_MAXIMUM_BRIGHTNESS 255 -# define DRIVER_ADDR_1 0b1110100 -# define DRIVER_ADDR_2 0b1110111 +# define DRIVER_ADDR_1 IS31FL3731_I2C_ADDRESS_GND +# define DRIVER_ADDR_2 IS31FL3731_I2C_ADDRESS_VCC # define IS31FL3731_DRIVER_COUNT 2 # define DRIVER_1_LED_TOTAL 35 # define DRIVER_2_LED_TOTAL 32 diff --git a/keyboards/kbdfans/kbd67/mkiirgb/v3/config.h b/keyboards/kbdfans/kbd67/mkiirgb/v3/config.h index d36bce7d834..971ed5c866c 100755 --- a/keyboards/kbdfans/kbd67/mkiirgb/v3/config.h +++ b/keyboards/kbdfans/kbd67/mkiirgb/v3/config.h @@ -72,7 +72,7 @@ #define RGB_MATRIX_LED_PROCESS_LIMIT 4 #define RGB_MATRIX_LED_FLUSH_LIMIT 26 #define RGB_MATRIX_DEFAULT_MODE RGB_MATRIX_CYCLE_ALL -#define DRIVER_ADDR_1 0b0110000 +#define DRIVER_ADDR_1 IS31FL3741_I2C_ADDRESS_GND #define IS31FL3741_DRIVER_COUNT 1 #define RGB_MATRIX_LED_COUNT 67 #define DRIVER_INDICATOR_LED_TOTAL 0 diff --git a/keyboards/kbdfans/kbdmini/config.h b/keyboards/kbdfans/kbdmini/config.h index 031dd23e5d8..243693d57e4 100644 --- a/keyboards/kbdfans/kbdmini/config.h +++ b/keyboards/kbdfans/kbdmini/config.h @@ -53,7 +53,7 @@ // #define ENABLE_RGB_MATRIX_SOLID_SPLASH // #define ENABLE_RGB_MATRIX_SOLID_MULTISPLASH -#define DRIVER_ADDR_1 0b1010000 +#define DRIVER_ADDR_1 IS31FL3733_I2C_ADDRESS_GND_GND #define IS31FL3733_DRIVER_COUNT 1 #define RGB_MATRIX_LED_COUNT 52 #endif diff --git a/keyboards/kbdfans/maja/config.h b/keyboards/kbdfans/maja/config.h index e2a27f01b1b..b7f75f982ab 100755 --- a/keyboards/kbdfans/maja/config.h +++ b/keyboards/kbdfans/maja/config.h @@ -54,8 +54,8 @@ // #define ENABLE_RGB_MATRIX_SOLID_MULTISPLASH #define RGB_MATRIX_DEFAULT_MODE RGB_MATRIX_CYCLE_ALL -#define DRIVER_ADDR_1 0b1110100 -#define DRIVER_ADDR_2 0b1110110 +#define DRIVER_ADDR_1 IS31FL3731_I2C_ADDRESS_GND +#define DRIVER_ADDR_2 IS31FL3731_I2C_ADDRESS_SDA #define IS31FL3731_DRIVER_COUNT 2 #define DRIVER_1_LED_TOTAL 36 #define DRIVER_2_LED_TOTAL 31 diff --git a/keyboards/keychron/c1_pro/ansi/rgb/config.h b/keyboards/keychron/c1_pro/ansi/rgb/config.h index cc95a6b45c9..c6b63b4d7c6 100644 --- a/keyboards/keychron/c1_pro/ansi/rgb/config.h +++ b/keyboards/keychron/c1_pro/ansi/rgb/config.h @@ -21,8 +21,8 @@ /* RGB Matrix Driver Configuration */ #define CKLED2001_DRIVER_COUNT 2 -#define DRIVER_ADDR_1 0b1110111 -#define DRIVER_ADDR_2 0b1110100 +#define DRIVER_ADDR_1 CKLED2001_I2C_ADDRESS_VDDIO +#define DRIVER_ADDR_2 CKLED2001_I2C_ADDRESS_GND /* RGB Matrix Configuration */ #define DRIVER_1_LED_TOTAL 49 diff --git a/keyboards/keychron/c1_pro/ansi/white/config.h b/keyboards/keychron/c1_pro/ansi/white/config.h index 898f59cdcaf..5492eca28f5 100644 --- a/keyboards/keychron/c1_pro/ansi/white/config.h +++ b/keyboards/keychron/c1_pro/ansi/white/config.h @@ -21,7 +21,7 @@ /* LED Matrix Driver Configuration */ #define CKLED2001_DRIVER_COUNT 1 -#define DRIVER_ADDR_1 0b1110100 +#define DRIVER_ADDR_1 CKLED2001_I2C_ADDRESS_GND /* LED Matrix Configuration */ #define LED_MATRIX_LED_COUNT 90 diff --git a/keyboards/keychron/c2_pro/ansi/rgb/config.h b/keyboards/keychron/c2_pro/ansi/rgb/config.h index f783f37a14f..d2d3d61f290 100644 --- a/keyboards/keychron/c2_pro/ansi/rgb/config.h +++ b/keyboards/keychron/c2_pro/ansi/rgb/config.h @@ -18,8 +18,8 @@ /* RGB Matrix Driver Configuration */ #define CKLED2001_DRIVER_COUNT 2 -#define DRIVER_ADDR_1 0b1110111 -#define DRIVER_ADDR_2 0b1110100 +#define DRIVER_ADDR_1 CKLED2001_I2C_ADDRESS_VDDIO +#define DRIVER_ADDR_2 CKLED2001_I2C_ADDRESS_GND /* Set LED driver current */ #define CKLED2001_CURRENT_TUNE \ diff --git a/keyboards/keychron/c2_pro/ansi/white/config.h b/keyboards/keychron/c2_pro/ansi/white/config.h index e8c282a5519..fb2ca3aa41d 100644 --- a/keyboards/keychron/c2_pro/ansi/white/config.h +++ b/keyboards/keychron/c2_pro/ansi/white/config.h @@ -18,7 +18,7 @@ /* LED Matrix Driver Configuration */ #define CKLED2001_DRIVER_COUNT 1 -#define DRIVER_ADDR_1 0b1110100 +#define DRIVER_ADDR_1 CKLED2001_I2C_ADDRESS_GND /* Set LED driver current */ #define CKLED2001_CURRENT_TUNE \ diff --git a/keyboards/keychron/q0/rev_0130/config.h b/keyboards/keychron/q0/rev_0130/config.h index ce4d510e10c..c6a241a1ced 100644 --- a/keyboards/keychron/q0/rev_0130/config.h +++ b/keyboards/keychron/q0/rev_0130/config.h @@ -18,7 +18,7 @@ /* RGB Matrix Driver Configuration */ #define CKLED2001_DRIVER_COUNT 1 -#define DRIVER_ADDR_1 0b1110100 +#define DRIVER_ADDR_1 CKLED2001_I2C_ADDRESS_GND /* RGB Matrix Configuration */ #define DRIVER_1_LED_TOTAL 21 diff --git a/keyboards/keychron/q0/rev_0131/config.h b/keyboards/keychron/q0/rev_0131/config.h index 214bfc34553..f1d06a28423 100644 --- a/keyboards/keychron/q0/rev_0131/config.h +++ b/keyboards/keychron/q0/rev_0131/config.h @@ -18,7 +18,7 @@ /* RGB Matrix Driver Configuration */ #define CKLED2001_DRIVER_COUNT 1 -#define DRIVER_ADDR_1 0b1110111 +#define DRIVER_ADDR_1 CKLED2001_I2C_ADDRESS_VDDIO /* RGB Matrix Configuration */ #define DRIVER_1_LED_TOTAL 26 diff --git a/keyboards/keychron/q1/config.h b/keyboards/keychron/q1/config.h index 52b53e47d0b..543f62f9d80 100644 --- a/keyboards/keychron/q1/config.h +++ b/keyboards/keychron/q1/config.h @@ -18,8 +18,8 @@ /* RGB Matrix Driver Configuration */ #define IS31FL3733_DRIVER_COUNT 2 -#define DRIVER_ADDR_1 0b1010000 -#define DRIVER_ADDR_2 0b1011111 +#define DRIVER_ADDR_1 IS31FL3733_I2C_ADDRESS_GND_GND +#define DRIVER_ADDR_2 IS31FL3733_I2C_ADDRESS_VCC_VCC /* DIP switch */ #define DIP_SWITCH_MATRIX_GRID { {0,1} } diff --git a/keyboards/keychron/q10/config.h b/keyboards/keychron/q10/config.h index 6361990798a..3a0d613510c 100644 --- a/keyboards/keychron/q10/config.h +++ b/keyboards/keychron/q10/config.h @@ -31,8 +31,8 @@ /* RGB Matrix Driver Configuration */ #define CKLED2001_DRIVER_COUNT 2 -#define DRIVER_ADDR_1 0b1110111 -#define DRIVER_ADDR_2 0b1110100 +#define DRIVER_ADDR_1 CKLED2001_I2C_ADDRESS_VDDIO +#define DRIVER_ADDR_2 CKLED2001_I2C_ADDRESS_GND /* Increase I2C speed to 1000 KHz */ #define I2C1_TIMINGR_PRESC 0U diff --git a/keyboards/keychron/q11/config.h b/keyboards/keychron/q11/config.h index 3285823d546..90bd7e0a56f 100755 --- a/keyboards/keychron/q11/config.h +++ b/keyboards/keychron/q11/config.h @@ -28,7 +28,7 @@ /* RGB Matrix Driver Configuration */ #define CKLED2001_DRIVER_COUNT 1 -#define DRIVER_ADDR_1 0b1110100 +#define DRIVER_ADDR_1 CKLED2001_I2C_ADDRESS_GND /* Increase I2C speed to 1000 KHz */ #define I2C1_TIMINGR_PRESC 0U diff --git a/keyboards/keychron/q12/config.h b/keyboards/keychron/q12/config.h index 309b4266127..52c4ade5a6c 100644 --- a/keyboards/keychron/q12/config.h +++ b/keyboards/keychron/q12/config.h @@ -27,8 +27,8 @@ /* RGB Matrix Driver Configuration */ #define CKLED2001_DRIVER_COUNT 2 -#define DRIVER_ADDR_1 0b1110111 -#define DRIVER_ADDR_2 0b1110100 +#define DRIVER_ADDR_1 CKLED2001_I2C_ADDRESS_VDDIO +#define DRIVER_ADDR_2 CKLED2001_I2C_ADDRESS_GND /* Increase I2C speed to 1000 KHz */ #define I2C1_TIMINGR_PRESC 0U diff --git a/keyboards/keychron/q2/config.h b/keyboards/keychron/q2/config.h index f58633d2e4f..1ecff68e4d3 100644 --- a/keyboards/keychron/q2/config.h +++ b/keyboards/keychron/q2/config.h @@ -23,8 +23,8 @@ /* RGB Matrix Driver Configuration */ #define CKLED2001_DRIVER_COUNT 2 -#define DRIVER_ADDR_1 0b1110111 -#define DRIVER_ADDR_2 0b1110100 +#define DRIVER_ADDR_1 CKLED2001_I2C_ADDRESS_VDDIO +#define DRIVER_ADDR_2 CKLED2001_I2C_ADDRESS_GND #define CKLED2001_PHASE_CHANNEL CKLED2001_MSKPHASE_9CHANNEL diff --git a/keyboards/keychron/q3/config.h b/keyboards/keychron/q3/config.h index 9fbe1ed7450..5914df02006 100644 --- a/keyboards/keychron/q3/config.h +++ b/keyboards/keychron/q3/config.h @@ -25,8 +25,8 @@ /* RGB Matrix Driver Configuration */ #define CKLED2001_DRIVER_COUNT 2 -#define DRIVER_ADDR_1 0b1110111 -#define DRIVER_ADDR_2 0b1110100 +#define DRIVER_ADDR_1 CKLED2001_I2C_ADDRESS_VDDIO +#define DRIVER_ADDR_2 CKLED2001_I2C_ADDRESS_GND /* Increase I2C speed to 1000 KHz */ #define I2C1_TIMINGR_PRESC 0U diff --git a/keyboards/keychron/q4/ansi_v1/config.h b/keyboards/keychron/q4/ansi_v1/config.h index d20feacd294..cf12c759668 100644 --- a/keyboards/keychron/q4/ansi_v1/config.h +++ b/keyboards/keychron/q4/ansi_v1/config.h @@ -18,8 +18,8 @@ /* RGB Matrix Driver Configuration */ #define CKLED2001_DRIVER_COUNT 2 -#define DRIVER_ADDR_1 0b1110111 -#define DRIVER_ADDR_2 0b1110100 +#define DRIVER_ADDR_1 CKLED2001_I2C_ADDRESS_VDDIO +#define DRIVER_ADDR_2 CKLED2001_I2C_ADDRESS_GND /* RGB Matrix Configuration */ #define DRIVER_1_LED_TOTAL 31 diff --git a/keyboards/keychron/q4/ansi_v2/config.h b/keyboards/keychron/q4/ansi_v2/config.h index 0772fa576ec..1bcaf204ef9 100644 --- a/keyboards/keychron/q4/ansi_v2/config.h +++ b/keyboards/keychron/q4/ansi_v2/config.h @@ -18,7 +18,7 @@ /* RGB Matrix Driver Configuration */ #define CKLED2001_DRIVER_COUNT 1 -#define DRIVER_ADDR_1 0b1110100 +#define DRIVER_ADDR_1 CKLED2001_I2C_ADDRESS_GND /* RGB Matrix Configuration */ #define DRIVER_1_LED_TOTAL 61 diff --git a/keyboards/keychron/q4/iso/config.h b/keyboards/keychron/q4/iso/config.h index 2b934eb8013..b61f8be4a41 100644 --- a/keyboards/keychron/q4/iso/config.h +++ b/keyboards/keychron/q4/iso/config.h @@ -18,7 +18,7 @@ /* RGB Matrix Driver Configuration */ #define CKLED2001_DRIVER_COUNT 1 -#define DRIVER_ADDR_1 0b1110100 +#define DRIVER_ADDR_1 CKLED2001_I2C_ADDRESS_GND /* RGB Matrix Configuration */ #define DRIVER_1_LED_TOTAL 62 diff --git a/keyboards/keychron/q5/config.h b/keyboards/keychron/q5/config.h index 7fefee341e0..d459d8c54e2 100644 --- a/keyboards/keychron/q5/config.h +++ b/keyboards/keychron/q5/config.h @@ -31,8 +31,8 @@ /* RGB Matrix Driver Configuration */ #define CKLED2001_DRIVER_COUNT 2 -#define DRIVER_ADDR_1 0b1110111 -#define DRIVER_ADDR_2 0b1110100 +#define DRIVER_ADDR_1 CKLED2001_I2C_ADDRESS_VDDIO +#define DRIVER_ADDR_2 CKLED2001_I2C_ADDRESS_GND #define CKLED2001_CURRENT_TUNE \ { 0xB6, 0xB6, 0x56, 0xB6, 0xB6, 0x56, 0xB6, 0xB6, 0x56, 0xB6, 0xB6, 0x56 } diff --git a/keyboards/keychron/q6/config.h b/keyboards/keychron/q6/config.h index cca00a631d1..98e3642c4d3 100644 --- a/keyboards/keychron/q6/config.h +++ b/keyboards/keychron/q6/config.h @@ -25,8 +25,8 @@ /* RGB Matrix Driver Configuration */ #define CKLED2001_DRIVER_COUNT 2 -#define DRIVER_ADDR_1 0b1110111 -#define DRIVER_ADDR_2 0b1110100 +#define DRIVER_ADDR_1 CKLED2001_I2C_ADDRESS_VDDIO +#define DRIVER_ADDR_2 CKLED2001_I2C_ADDRESS_GND #define CKLED2001_CURRENT_TUNE \ { 0xA4, 0xA4, 0x52, 0xA4, 0xA4, 0x52, 0xA4, 0xA4, 0x52, 0xA4, 0xA4, 0x52 } diff --git a/keyboards/keychron/q60/config.h b/keyboards/keychron/q60/config.h index 9a560a0927a..e5d0954ba0f 100644 --- a/keyboards/keychron/q60/config.h +++ b/keyboards/keychron/q60/config.h @@ -18,7 +18,7 @@ /* RGB Matrix Driver Configuration */ #define CKLED2001_DRIVER_COUNT 1 -#define DRIVER_ADDR_1 0b1110100 +#define DRIVER_ADDR_1 CKLED2001_I2C_ADDRESS_GND /* Increase I2C speed to 1000 KHz */ #define I2C1_TIMINGR_PRESC 0U diff --git a/keyboards/keychron/q65/config.h b/keyboards/keychron/q65/config.h index 533d5ae0dd5..35d05ffab73 100644 --- a/keyboards/keychron/q65/config.h +++ b/keyboards/keychron/q65/config.h @@ -27,8 +27,8 @@ /* RGB Matrix Driver Configuration */ #define CKLED2001_DRIVER_COUNT 2 -#define DRIVER_ADDR_1 0b1110111 -#define DRIVER_ADDR_2 0b1110100 +#define DRIVER_ADDR_1 CKLED2001_I2C_ADDRESS_VDDIO +#define DRIVER_ADDR_2 CKLED2001_I2C_ADDRESS_GND /* Increase I2C speed to 1000 KHz */ #define I2C1_TIMINGR_PRESC 0U diff --git a/keyboards/keychron/q7/config.h b/keyboards/keychron/q7/config.h index 450a9a3bcb2..125e17a3da3 100644 --- a/keyboards/keychron/q7/config.h +++ b/keyboards/keychron/q7/config.h @@ -18,8 +18,8 @@ /* RGB Matrix Driver Configuration */ #define CKLED2001_DRIVER_COUNT 2 -#define DRIVER_ADDR_1 0b1110111 -#define DRIVER_ADDR_2 0b1110100 +#define DRIVER_ADDR_1 CKLED2001_I2C_ADDRESS_VDDIO +#define DRIVER_ADDR_2 CKLED2001_I2C_ADDRESS_GND /* Increase I2C speed to 1000 KHz */ #define I2C1_TIMINGR_PRESC 0U diff --git a/keyboards/keychron/q8/config.h b/keyboards/keychron/q8/config.h index 33de9af247a..4b6d5f16144 100644 --- a/keyboards/keychron/q8/config.h +++ b/keyboards/keychron/q8/config.h @@ -21,8 +21,8 @@ /* RGB Matrix Driver Configuration */ #define CKLED2001_DRIVER_COUNT 2 -#define DRIVER_ADDR_1 0b1110111 -#define DRIVER_ADDR_2 0b1110100 +#define DRIVER_ADDR_1 CKLED2001_I2C_ADDRESS_VDDIO +#define DRIVER_ADDR_2 CKLED2001_I2C_ADDRESS_GND /* Increase I2C speed to 1000 KHz */ #define I2C1_TIMINGR_PRESC 0U diff --git a/keyboards/keychron/q9/config.h b/keyboards/keychron/q9/config.h index 7973a1ff85b..de5795a5f68 100644 --- a/keyboards/keychron/q9/config.h +++ b/keyboards/keychron/q9/config.h @@ -24,7 +24,7 @@ /* RGB Matrix Driver Configuration */ #define CKLED2001_DRIVER_COUNT 1 -#define DRIVER_ADDR_1 0b1110100 +#define DRIVER_ADDR_1 CKLED2001_I2C_ADDRESS_GND /* Increase I2C speed to 1000 KHz */ #define I2C1_TIMINGR_PRESC 0U diff --git a/keyboards/keychron/s1/ansi/rgb/config.h b/keyboards/keychron/s1/ansi/rgb/config.h index 3d54864bdf3..1f77559339c 100644 --- a/keyboards/keychron/s1/ansi/rgb/config.h +++ b/keyboards/keychron/s1/ansi/rgb/config.h @@ -18,8 +18,8 @@ /* RGB Matrix Driver Configuration */ #define CKLED2001_DRIVER_COUNT 2 -#define DRIVER_ADDR_1 0b1110111 -#define DRIVER_ADDR_2 0b1110100 +#define DRIVER_ADDR_1 CKLED2001_I2C_ADDRESS_VDDIO +#define DRIVER_ADDR_2 CKLED2001_I2C_ADDRESS_GND #define DRIVER_1_LED_TOTAL 46 #define DRIVER_2_LED_TOTAL 38 #define RGB_MATRIX_LED_COUNT (DRIVER_1_LED_TOTAL + DRIVER_2_LED_TOTAL) diff --git a/keyboards/keychron/s1/ansi/white/config.h b/keyboards/keychron/s1/ansi/white/config.h index 18b676c941a..02eeb7fc814 100644 --- a/keyboards/keychron/s1/ansi/white/config.h +++ b/keyboards/keychron/s1/ansi/white/config.h @@ -18,7 +18,7 @@ /* LED Matrix Driver Configuration */ #define CKLED2001_DRIVER_COUNT 1 -#define DRIVER_ADDR_1 0b1110100 +#define DRIVER_ADDR_1 CKLED2001_I2C_ADDRESS_GND #define DRIVER_1_LED_TOTAL 84 #define LED_MATRIX_LED_COUNT DRIVER_1_LED_TOTAL diff --git a/keyboards/keychron/v1/config.h b/keyboards/keychron/v1/config.h index bf6de31e136..8edbf05ca85 100644 --- a/keyboards/keychron/v1/config.h +++ b/keyboards/keychron/v1/config.h @@ -33,8 +33,8 @@ /* RGB Matrix Driver Configuration */ #define CKLED2001_DRIVER_COUNT 2 -#define DRIVER_ADDR_1 0b1110111 -#define DRIVER_ADDR_2 0b1110100 +#define DRIVER_ADDR_1 CKLED2001_I2C_ADDRESS_VDDIO +#define DRIVER_ADDR_2 CKLED2001_I2C_ADDRESS_GND /* Increase I2C speed to 1000 KHz */ #define I2C1_TIMINGR_PRESC 0U diff --git a/keyboards/keychron/v10/config.h b/keyboards/keychron/v10/config.h index 7cdf465f5a1..b8aa40a1869 100644 --- a/keyboards/keychron/v10/config.h +++ b/keyboards/keychron/v10/config.h @@ -32,8 +32,8 @@ /* RGB Matrix Driver Configuration */ #define CKLED2001_DRIVER_COUNT 2 -#define DRIVER_ADDR_1 0b1110111 -#define DRIVER_ADDR_2 0b1110100 +#define DRIVER_ADDR_1 CKLED2001_I2C_ADDRESS_VDDIO +#define DRIVER_ADDR_2 CKLED2001_I2C_ADDRESS_GND /* Increase I2C speed to 1000 KHz */ #define I2C1_TIMINGR_PRESC 0U diff --git a/keyboards/keychron/v2/config.h b/keyboards/keychron/v2/config.h index 6b44dba17fc..8e881da987b 100644 --- a/keyboards/keychron/v2/config.h +++ b/keyboards/keychron/v2/config.h @@ -21,8 +21,8 @@ /* RGB Matrix Driver Configuration */ #define CKLED2001_DRIVER_COUNT 2 -#define DRIVER_ADDR_1 0b1110111 -#define DRIVER_ADDR_2 0b1110100 +#define DRIVER_ADDR_1 CKLED2001_I2C_ADDRESS_VDDIO +#define DRIVER_ADDR_2 CKLED2001_I2C_ADDRESS_GND /* Increase I2C speed to 1000 KHz */ #define I2C1_TIMINGR_PRESC 0U diff --git a/keyboards/keychron/v3/config.h b/keyboards/keychron/v3/config.h index 8af491f1c71..8757f6bacec 100644 --- a/keyboards/keychron/v3/config.h +++ b/keyboards/keychron/v3/config.h @@ -21,8 +21,8 @@ /* RGB Matrix Driver Configuration */ #define CKLED2001_DRIVER_COUNT 2 -#define DRIVER_ADDR_1 0b1110111 -#define DRIVER_ADDR_2 0b1110100 +#define DRIVER_ADDR_1 CKLED2001_I2C_ADDRESS_VDDIO +#define DRIVER_ADDR_2 CKLED2001_I2C_ADDRESS_GND /* Increase I2C speed to 1000 KHz */ #define I2C1_TIMINGR_PRESC 0U diff --git a/keyboards/keychron/v4/config.h b/keyboards/keychron/v4/config.h index 2cea12c06a8..2fc94aaaeed 100644 --- a/keyboards/keychron/v4/config.h +++ b/keyboards/keychron/v4/config.h @@ -18,7 +18,7 @@ /* RGB Matrix Driver Configuration */ #define CKLED2001_DRIVER_COUNT 1 -#define DRIVER_ADDR_1 0b1110111 +#define DRIVER_ADDR_1 CKLED2001_I2C_ADDRESS_VDDIO /* Increase I2C speed to 1000 KHz */ #define I2C1_TIMINGR_PRESC 0U diff --git a/keyboards/keychron/v5/config.h b/keyboards/keychron/v5/config.h index 7282b281818..0ee5e4e46b0 100644 --- a/keyboards/keychron/v5/config.h +++ b/keyboards/keychron/v5/config.h @@ -27,8 +27,8 @@ /* RGB Matrix Driver Configuration */ #define CKLED2001_DRIVER_COUNT 2 -#define DRIVER_ADDR_1 0b1110111 -#define DRIVER_ADDR_2 0b1110100 +#define DRIVER_ADDR_1 CKLED2001_I2C_ADDRESS_VDDIO +#define DRIVER_ADDR_2 CKLED2001_I2C_ADDRESS_GND /* Increase I2C speed to 1000 KHz */ #define I2C1_TIMINGR_PRESC 0U diff --git a/keyboards/keychron/v6/config.h b/keyboards/keychron/v6/config.h index 4416591fb97..e836cced84b 100644 --- a/keyboards/keychron/v6/config.h +++ b/keyboards/keychron/v6/config.h @@ -21,8 +21,8 @@ /* RGB Matrix Driver Configuration */ #define CKLED2001_DRIVER_COUNT 2 -#define DRIVER_ADDR_1 0b1110111 -#define DRIVER_ADDR_2 0b1110100 +#define DRIVER_ADDR_1 CKLED2001_I2C_ADDRESS_VDDIO +#define DRIVER_ADDR_2 CKLED2001_I2C_ADDRESS_GND /* Increase I2C speed to 1000 KHz */ #define I2C1_TIMINGR_PRESC 0U diff --git a/keyboards/keychron/v7/config.h b/keyboards/keychron/v7/config.h index 5d7e6cf22ed..606f6827192 100644 --- a/keyboards/keychron/v7/config.h +++ b/keyboards/keychron/v7/config.h @@ -18,8 +18,8 @@ /* RGB Matrix Driver Configuration */ #define CKLED2001_DRIVER_COUNT 2 -#define DRIVER_ADDR_1 0b1110111 -#define DRIVER_ADDR_2 0b1110100 +#define DRIVER_ADDR_1 CKLED2001_I2C_ADDRESS_VDDIO +#define DRIVER_ADDR_2 CKLED2001_I2C_ADDRESS_GND /* Increase I2C speed to 1000 KHz */ #define I2C1_TIMINGR_PRESC 0U diff --git a/keyboards/keychron/v8/config.h b/keyboards/keychron/v8/config.h index 902f0202e71..3dc6d58518e 100644 --- a/keyboards/keychron/v8/config.h +++ b/keyboards/keychron/v8/config.h @@ -21,8 +21,8 @@ /* RGB Matrix Driver Configuration */ #define CKLED2001_DRIVER_COUNT 2 -#define DRIVER_ADDR_1 0b1110111 -#define DRIVER_ADDR_2 0b1110100 +#define DRIVER_ADDR_1 CKLED2001_I2C_ADDRESS_VDDIO +#define DRIVER_ADDR_2 CKLED2001_I2C_ADDRESS_GND /* Increase I2C speed to 1000 KHz */ #define I2C1_TIMINGR_PRESC 0U diff --git a/keyboards/kprepublic/bm60hsrgb/rev2/config.h b/keyboards/kprepublic/bm60hsrgb/rev2/config.h index 68fba527895..e3f763567c5 100644 --- a/keyboards/kprepublic/bm60hsrgb/rev2/config.h +++ b/keyboards/kprepublic/bm60hsrgb/rev2/config.h @@ -18,7 +18,7 @@ #define RGBLIGHT_DEFAULT_MODE RGBLIGHT_MODE_RAINBOW_MOOD #define RGB_DISABLE_WHEN_USB_SUSPENDED true // turn off effects when suspended -#define DRIVER_ADDR_1 0b1010000 +#define DRIVER_ADDR_1 IS31FL3733_I2C_ADDRESS_GND_GND #define RGB_MATRIX_KEYPRESSES // RGB Matrix Animation modes. Explicitly enabled diff --git a/keyboards/kprepublic/bm60hsrgb_ec/rev2/config.h b/keyboards/kprepublic/bm60hsrgb_ec/rev2/config.h index ce422ff43e6..0b83af45f5a 100644 --- a/keyboards/kprepublic/bm60hsrgb_ec/rev2/config.h +++ b/keyboards/kprepublic/bm60hsrgb_ec/rev2/config.h @@ -18,7 +18,7 @@ #define RGBLIGHT_DEFAULT_MODE RGBLIGHT_MODE_RAINBOW_MOOD # define RGB_DISABLE_WHEN_USB_SUSPENDED true // turn off effects when suspended -# define DRIVER_ADDR_1 0b1010000 +# define DRIVER_ADDR_1 IS31FL3733_I2C_ADDRESS_GND_GND # define IS31FL3733_DRIVER_COUNT 2 # define DRIVER_1_LED_TOTAL 63 # define RGB_MATRIX_LED_COUNT DRIVER_1_LED_TOTAL diff --git a/keyboards/kprepublic/bm60hsrgb_iso/rev2/config.h b/keyboards/kprepublic/bm60hsrgb_iso/rev2/config.h index f4b463f2618..3e049824a7f 100644 --- a/keyboards/kprepublic/bm60hsrgb_iso/rev2/config.h +++ b/keyboards/kprepublic/bm60hsrgb_iso/rev2/config.h @@ -26,7 +26,7 @@ # define DISABLE_RGB_MATRIX_BAND_SPIRAL_SAT # define DISABLE_RGB_MATRIX_RAINDROPS # define DISABLE_RGB_MATRIX_JELLYBEAN_RAINDROPS -# define DRIVER_ADDR_1 0b1010000 +# define DRIVER_ADDR_1 IS31FL3733_I2C_ADDRESS_GND_GND # define IS31FL3733_DRIVER_COUNT 1 # define DRIVER_1_LED_TOTAL 64 diff --git a/keyboards/kprepublic/bm60hsrgb_poker/rev2/config.h b/keyboards/kprepublic/bm60hsrgb_poker/rev2/config.h index f3ad3e07811..d3222d703e0 100644 --- a/keyboards/kprepublic/bm60hsrgb_poker/rev2/config.h +++ b/keyboards/kprepublic/bm60hsrgb_poker/rev2/config.h @@ -78,7 +78,7 @@ // Configure the IS31FL3733 driver for per-key RGB LEDs #define IS31FL3733_DRIVER_COUNT 1 -#define DRIVER_ADDR_1 0b1010000 +#define DRIVER_ADDR_1 IS31FL3733_I2C_ADDRESS_GND_GND #define DRIVER_1_LED_TOTAL 61 #define ISSI_LED_TOTAL DRIVER_1_LED_TOTAL diff --git a/keyboards/kprepublic/bm68hsrgb/rev2/config.h b/keyboards/kprepublic/bm68hsrgb/rev2/config.h index 15f47e8ba51..b3b1abf137d 100644 --- a/keyboards/kprepublic/bm68hsrgb/rev2/config.h +++ b/keyboards/kprepublic/bm68hsrgb/rev2/config.h @@ -18,7 +18,7 @@ #define RGBLIGHT_DEFAULT_MODE RGBLIGHT_MODE_RAINBOW_MOOD -#define DRIVER_ADDR_1 0b0110000 +#define DRIVER_ADDR_1 IS31FL3741_I2C_ADDRESS_GND #define IS31FL3741_DRIVER_COUNT 1 #define DRIVER_1_LED_TOTAL 68 diff --git a/keyboards/kprepublic/bm80v2/config.h b/keyboards/kprepublic/bm80v2/config.h index 3eea8c3aa49..3678c642020 100644 --- a/keyboards/kprepublic/bm80v2/config.h +++ b/keyboards/kprepublic/bm80v2/config.h @@ -53,7 +53,7 @@ #define ENABLE_RGB_MATRIX_MULTISPLASH #define ENABLE_RGB_MATRIX_SOLID_SPLASH #define ENABLE_RGB_MATRIX_SOLID_MULTISPLASH -#define DRIVER_ADDR_1 0b0110000 +#define DRIVER_ADDR_1 IS31FL3741_I2C_ADDRESS_GND #define IS31FL3741_DRIVER_COUNT 1 #define DRIVER_1_LED_TOTAL 87 #define RGB_MATRIX_LED_COUNT DRIVER_1_LED_TOTAL diff --git a/keyboards/kprepublic/bm80v2_iso/config.h b/keyboards/kprepublic/bm80v2_iso/config.h index 98c712703d2..a8fac742188 100644 --- a/keyboards/kprepublic/bm80v2_iso/config.h +++ b/keyboards/kprepublic/bm80v2_iso/config.h @@ -54,7 +54,7 @@ #define ENABLE_RGB_MATRIX_MULTISPLASH #define ENABLE_RGB_MATRIX_SOLID_SPLASH #define ENABLE_RGB_MATRIX_SOLID_MULTISPLASH -#define DRIVER_ADDR_1 0b0110000 +#define DRIVER_ADDR_1 IS31FL3741_I2C_ADDRESS_GND #define IS31FL3741_DRIVER_COUNT 1 #define DRIVER_1_LED_TOTAL 88 #define RGB_MATRIX_LED_COUNT DRIVER_1_LED_TOTAL diff --git a/keyboards/latincompass/latin17rgb/config.h b/keyboards/latincompass/latin17rgb/config.h index f858709eae1..0ce80e584e5 100644 --- a/keyboards/latincompass/latin17rgb/config.h +++ b/keyboards/latincompass/latin17rgb/config.h @@ -69,15 +69,8 @@ // # define ENABLE_RGB_MATRIX_SOLID_SPLASH // # define ENABLE_RGB_MATRIX_SOLID_MULTISPLASH - // This is a 7-bit address, that gets left-shifted and bit 0 - // set to 0 for write, 1 for read (as per I2C protocol) - // The address will vary depending on your wiring: - // 0b1110100 AD <-> GND - // 0b1110111 AD <-> VCC - // 0b1110101 AD <-> SCL - // 0b1110110 AD <-> SDA -# define DRIVER_ADDR_1 0b1110100 -# define DRIVER_ADDR_2 0b1110110 +# define DRIVER_ADDR_1 IS31FL3731_I2C_ADDRESS_GND +# define DRIVER_ADDR_2 IS31FL3731_I2C_ADDRESS_SDA # define IS31FL3731_DRIVER_COUNT 2 # define DRIVER_1_LED_TOTAL 25 diff --git a/keyboards/latincompass/latin60rgb/config.h b/keyboards/latincompass/latin60rgb/config.h index 053bb2eab80..23cfdf24ee4 100644 --- a/keyboards/latincompass/latin60rgb/config.h +++ b/keyboards/latincompass/latin60rgb/config.h @@ -67,7 +67,7 @@ // # define ENABLE_RGB_MATRIX_MULTISPLASH // # define ENABLE_RGB_MATRIX_SOLID_SPLASH // # define ENABLE_RGB_MATRIX_SOLID_MULTISPLASH -# define DRIVER_ADDR_1 0b1010000 +# define DRIVER_ADDR_1 IS31FL3733_I2C_ADDRESS_GND_GND # define IS31FL3733_DRIVER_COUNT 1 # define RGB_MATRIX_LED_COUNT 60 #endif diff --git a/keyboards/latincompass/latin6rgb/config.h b/keyboards/latincompass/latin6rgb/config.h index 5cfafd6bece..424dcd5beff 100644 --- a/keyboards/latincompass/latin6rgb/config.h +++ b/keyboards/latincompass/latin6rgb/config.h @@ -70,14 +70,7 @@ // # define ENABLE_RGB_MATRIX_SOLID_SPLASH // # define ENABLE_RGB_MATRIX_SOLID_MULTISPLASH -// This is a 7-bit address, that gets left-shifted and bit 0 -// set to 0 for write, 1 for read (as per I2C protocol) -// The address will vary depending on your wiring: -// 0b1110100 AD <-> GND -// 0b1110111 AD <-> VCC -// 0b1110101 AD <-> SCL -// 0b1110110 AD <-> SDA -#define DRIVER_ADDR_1 0b1110100 +#define DRIVER_ADDR_1 IS31FL3731_I2C_ADDRESS_GND #define IS31FL3731_DRIVER_COUNT 1 #define RGB_MATRIX_LED_COUNT 6 diff --git a/keyboards/matrix/m20add/config.h b/keyboards/matrix/m20add/config.h index 2ae50174875..048796c7932 100644 --- a/keyboards/matrix/m20add/config.h +++ b/keyboards/matrix/m20add/config.h @@ -78,6 +78,6 @@ #define I2C1_CLOCK_SPEED 400000 #define I2C1_DUTY_CYCLE FAST_DUTY_CYCLE_2 -#define DRIVER_ADDR_1 0b1110100 +#define DRIVER_ADDR_1 IS31FL3731_I2C_ADDRESS_GND #define IS31FL3731_DRIVER_COUNT 1 #define RGB_MATRIX_LED_COUNT 20 diff --git a/keyboards/matrix/noah/config.h b/keyboards/matrix/noah/config.h index 38859b12928..428fe98d2ef 100644 --- a/keyboards/matrix/noah/config.h +++ b/keyboards/matrix/noah/config.h @@ -19,8 +19,8 @@ #define PAL_MODE_STM32_ALTERNATE_OPENDRAIN (PAL_MODE_ALTERNATE(4) | PAL_STM32_OTYPE_OPENDRAIN) // rgb matrix setting -#define DRIVER_ADDR_1 0b1110100 -#define DRIVER_ADDR_2 0b1110110 +#define DRIVER_ADDR_1 IS31FL3731_I2C_ADDRESS_GND +#define DRIVER_ADDR_2 IS31FL3731_I2C_ADDRESS_SDA #define IS31FL3731_DRIVER_COUNT 2 #define DRIVER_1_LED_TOTAL 36 #define DRIVER_2_LED_TOTAL 36 diff --git a/keyboards/mechlovin/adelais/rgb_led/rev2/config.h b/keyboards/mechlovin/adelais/rgb_led/rev2/config.h index 4c7bc3a1daa..7e1bd430126 100644 --- a/keyboards/mechlovin/adelais/rgb_led/rev2/config.h +++ b/keyboards/mechlovin/adelais/rgb_led/rev2/config.h @@ -1,15 +1,8 @@ #pragma once //rgb matrix setting -// This is a 7-bit address, that gets left-shifted and bit 0 -// set to 0 for write, 1 for read (as per I2C protocol) -// The address will vary depending on your wiring: -// 0b1110100 AD <-> GND -// 0b1110111 AD <-> VCC -// 0b1110101 AD <-> SCL -// 0b1110110 AD <-> SDA -#define DRIVER_ADDR_1 0b1110100 -#define DRIVER_ADDR_2 0b1110110 +#define DRIVER_ADDR_1 IS31FL3731_I2C_ADDRESS_GND +#define DRIVER_ADDR_2 IS31FL3731_I2C_ADDRESS_SDA #define IS31FL3731_DRIVER_COUNT 2 #define DRIVER_1_LED_TOTAL 32 #define DRIVER_2_LED_TOTAL 36 diff --git a/keyboards/mechlovin/adelais/rgb_led/rev3/config.h b/keyboards/mechlovin/adelais/rgb_led/rev3/config.h index 8620ab39495..72011af8df2 100644 --- a/keyboards/mechlovin/adelais/rgb_led/rev3/config.h +++ b/keyboards/mechlovin/adelais/rgb_led/rev3/config.h @@ -22,14 +22,7 @@ along with this program. If not, see . #ifdef RGB_MATRIX_ENABLE //rgb matrix setting -// This is a 7-bit address, that gets left-shifted and bit 0 -// set to 0 for write, 1 for read (as per I2C protocol) -// The address will vary depending on your wiring: -// 0b1110100 AD <-> GND -// 0b1110111 AD <-> VCC -// 0b1110101 AD <-> SCL -// 0b1110110 AD <-> SDA -#define DRIVER_ADDR_1 0b0110010 +#define DRIVER_ADDR_1 IS31FL3741_I2C_ADDRESS_SDA #define IS31FL3741_DRIVER_COUNT 1 #define RGB_MATRIX_LED_COUNT 66 diff --git a/keyboards/mechlovin/delphine/rgb_led/config.h b/keyboards/mechlovin/delphine/rgb_led/config.h index 048bed9e03d..66455e1158f 100644 --- a/keyboards/mechlovin/delphine/rgb_led/config.h +++ b/keyboards/mechlovin/delphine/rgb_led/config.h @@ -1,13 +1,7 @@ #pragma once -//rgb matrix setting// This is a 7-bit address, that gets left-shifted and bit 0 -// set to 0 for write, 1 for read (as per I2C protocol) -// The address will vary depending on your wiring: -// 0b1110100 AD <-> GND -// 0b1110111 AD <-> VCC -// 0b1110101 AD <-> SCL -// 0b1110110 AD <-> SDA -#define DRIVER_ADDR_1 0b1110110 +//rgb matrix setting +#define DRIVER_ADDR_1 IS31FL3731_I2C_ADDRESS_SDA #define IS31FL3731_DRIVER_COUNT 1 #define RGB_MATRIX_LED_COUNT 25 #define RGB_MATRIX_KEYPRESSES // reacts to keypresses diff --git a/keyboards/mechlovin/hannah60rgb/rev2/config.h b/keyboards/mechlovin/hannah60rgb/rev2/config.h index 4e4eb7f7bd1..5c7bb7abfe7 100644 --- a/keyboards/mechlovin/hannah60rgb/rev2/config.h +++ b/keyboards/mechlovin/hannah60rgb/rev2/config.h @@ -1,14 +1,8 @@ #pragma once -//rgb matrix setting// This is a 7-bit address, that gets left-shifted and bit 0 -// set to 0 for write, 1 for read (as per I2C protocol) -// The address will vary depending on your wiring: -// 0b1110100 AD <-> GND -// 0b1110111 AD <-> VCC -// 0b1110101 AD <-> SCL -// 0b1110110 AD <-> SDA -#define DRIVER_ADDR_1 0b1110100 -#define DRIVER_ADDR_2 0b1110110 +//rgb matrix setting +#define DRIVER_ADDR_1 IS31FL3731_I2C_ADDRESS_GND +#define DRIVER_ADDR_2 IS31FL3731_I2C_ADDRESS_SDA #define IS31FL3731_DRIVER_COUNT 2 #define DRIVER_1_LED_TOTAL 44 #define DRIVER_2_LED_TOTAL 34 diff --git a/keyboards/mechlovin/infinity87/rgb_rev1/config.h b/keyboards/mechlovin/infinity87/rgb_rev1/config.h index 84acb093080..9777e290bb5 100644 --- a/keyboards/mechlovin/infinity87/rgb_rev1/config.h +++ b/keyboards/mechlovin/infinity87/rgb_rev1/config.h @@ -17,13 +17,6 @@ #pragma once //rgb matrix setting -// This is a 7-bit address, that gets left-shifted and bit 0 -// set to 0 for write, 1 for read (as per I2C protocol) -// The address will vary depending on your wiring: -// 0b0110000 AD <-> GND -// 0b0110011 AD <-> VCC -// 0b0110001 AD <-> SCL -// 0b0110010 AD <-> SDA #define RGB_DISABLE_WHEN_USB_SUSPENDED // turn off effects when suspended #define RGB_MATRIX_KEYPRESSES #undef ENABLE_RGB_MATRIX_SPLASH @@ -80,7 +73,7 @@ //#define RGB_MATRIX_DEFAULT_MODE RGB_MATRIX_SOLID_COLOR #define RGB_MATRIX_DEFAULT_MODE RGB_MATRIX_CYCLE_ALL //#define RGB_MATRIX_DEFAULT_MODE RGB_MATRIX_SOLID_REACTIVE_SIMPLE -#define DRIVER_ADDR_1 0b0110010 +#define DRIVER_ADDR_1 IS31FL3741_I2C_ADDRESS_SDA #define IS31FL3741_DRIVER_COUNT 1 #define RGB_MATRIX_LED_COUNT 91 #define DRIVER_INDICATOR_LED_TOTAL 0 diff --git a/keyboards/mechlovin/olly/octagon/config.h b/keyboards/mechlovin/olly/octagon/config.h index a59c651bd7b..573a11f88f7 100644 --- a/keyboards/mechlovin/olly/octagon/config.h +++ b/keyboards/mechlovin/olly/octagon/config.h @@ -18,14 +18,7 @@ along with this program. If not, see . #pragma once #ifdef LED_MATRIX_ENABLE -// This is a 7-bit address, that gets left-shifted and bit 0 -// set to 0 for write, 1 for read (as per I2C protocol) -// The address will vary depending on your wiring: -// 0b1110100 AD <-> GND -// 0b1110111 AD <-> VCC -// 0b1110101 AD <-> SCL -// 0b1110110 AD <-> SDA -#define LED_DRIVER_ADDR_1 0b1110110 +#define LED_DRIVER_ADDR_1 IS31FL3731_I2C_ADDRESS_SDA #define I2C_DRIVER I2CD2 #define I2C1_SCL_PIN B10 #define I2C1_SDA_PIN B11 diff --git a/keyboards/mechlovin/zed65/mono_led/config.h b/keyboards/mechlovin/zed65/mono_led/config.h index d6a8e9cd028..65f9ba2a94f 100644 --- a/keyboards/mechlovin/zed65/mono_led/config.h +++ b/keyboards/mechlovin/zed65/mono_led/config.h @@ -18,14 +18,7 @@ along with this program. If not, see . #pragma once #ifdef LED_MATRIX_ENABLE -// This is a 7-bit address, that gets left-shifted and bit 0 -// set to 0 for write, 1 for read (as per I2C protocol) -// The address will vary depending on your wiring: -// 0b1110100 AD <-> GND -// 0b1110111 AD <-> VCC -// 0b1110101 AD <-> SCL -// 0b1110110 AD <-> SDA -#define LED_DRIVER_ADDR_1 0b1110110 +#define LED_DRIVER_ADDR_1 IS31FL3731_I2C_ADDRESS_SDA #define I2C_DRIVER I2CD2 #define I2C1_SCL_PIN B10 #define I2C1_SDA_PIN B11 diff --git a/keyboards/melgeek/mach80/config.h b/keyboards/melgeek/mach80/config.h index 4850f9a1773..000b81eef95 100755 --- a/keyboards/melgeek/mach80/config.h +++ b/keyboards/melgeek/mach80/config.h @@ -25,7 +25,7 @@ #define DISABLE_RGB_MATRIX_SOLID_MULTISPLASH //#define RGB_MATRIX_DEFAULT_MODE RGB_MATRIX_SOLID_COLOR #define RGB_MATRIX_DEFAULT_MODE RGB_MATRIX_CYCLE_ALL -#define DRIVER_ADDR_1 0b0110000 +#define DRIVER_ADDR_1 IS31FL3741_I2C_ADDRESS_GND #define IS31FL3741_DRIVER_COUNT 1 #define ENABLE_RGB_MATRIX_ALPHAS_MODS diff --git a/keyboards/melgeek/mj61/config.h b/keyboards/melgeek/mj61/config.h index 64f144d43af..e07d2078cde 100644 --- a/keyboards/melgeek/mj61/config.h +++ b/keyboards/melgeek/mj61/config.h @@ -70,5 +70,5 @@ // # define ENABLE_RGB_MATRIX_SOLID_MULTISPLASH //#define RGB_MATRIX_DEFAULT_MODE RGB_MATRIX_SOLID_COLOR #define RGB_MATRIX_DEFAULT_MODE RGB_MATRIX_CYCLE_ALL -#define DRIVER_ADDR_1 0b0110000 +#define DRIVER_ADDR_1 IS31FL3741_I2C_ADDRESS_GND #define IS31FL3741_DRIVER_COUNT 1 diff --git a/keyboards/melgeek/mj63/config.h b/keyboards/melgeek/mj63/config.h index 64f144d43af..e07d2078cde 100644 --- a/keyboards/melgeek/mj63/config.h +++ b/keyboards/melgeek/mj63/config.h @@ -70,5 +70,5 @@ // # define ENABLE_RGB_MATRIX_SOLID_MULTISPLASH //#define RGB_MATRIX_DEFAULT_MODE RGB_MATRIX_SOLID_COLOR #define RGB_MATRIX_DEFAULT_MODE RGB_MATRIX_CYCLE_ALL -#define DRIVER_ADDR_1 0b0110000 +#define DRIVER_ADDR_1 IS31FL3741_I2C_ADDRESS_GND #define IS31FL3741_DRIVER_COUNT 1 diff --git a/keyboards/melgeek/mj64/config.h b/keyboards/melgeek/mj64/config.h index 64f144d43af..e07d2078cde 100644 --- a/keyboards/melgeek/mj64/config.h +++ b/keyboards/melgeek/mj64/config.h @@ -70,5 +70,5 @@ // # define ENABLE_RGB_MATRIX_SOLID_MULTISPLASH //#define RGB_MATRIX_DEFAULT_MODE RGB_MATRIX_SOLID_COLOR #define RGB_MATRIX_DEFAULT_MODE RGB_MATRIX_CYCLE_ALL -#define DRIVER_ADDR_1 0b0110000 +#define DRIVER_ADDR_1 IS31FL3741_I2C_ADDRESS_GND #define IS31FL3741_DRIVER_COUNT 1 diff --git a/keyboards/melgeek/mj65/config.h b/keyboards/melgeek/mj65/config.h index 64f144d43af..e07d2078cde 100644 --- a/keyboards/melgeek/mj65/config.h +++ b/keyboards/melgeek/mj65/config.h @@ -70,5 +70,5 @@ // # define ENABLE_RGB_MATRIX_SOLID_MULTISPLASH //#define RGB_MATRIX_DEFAULT_MODE RGB_MATRIX_SOLID_COLOR #define RGB_MATRIX_DEFAULT_MODE RGB_MATRIX_CYCLE_ALL -#define DRIVER_ADDR_1 0b0110000 +#define DRIVER_ADDR_1 IS31FL3741_I2C_ADDRESS_GND #define IS31FL3741_DRIVER_COUNT 1 diff --git a/keyboards/melgeek/mojo68/config.h b/keyboards/melgeek/mojo68/config.h index 0353fb8fc70..b7bcb36c2dc 100755 --- a/keyboards/melgeek/mojo68/config.h +++ b/keyboards/melgeek/mojo68/config.h @@ -69,5 +69,5 @@ // # define ENABLE_RGB_MATRIX_SOLID_MULTISPLASH //#define RGB_MATRIX_DEFAULT_MODE RGB_MATRIX_SOLID_COLOR #define RGB_MATRIX_DEFAULT_MODE RGB_MATRIX_CYCLE_ALL -#define DRIVER_ADDR_1 0b0110000 +#define DRIVER_ADDR_1 IS31FL3741_I2C_ADDRESS_GND #define IS31FL3741_DRIVER_COUNT 1 diff --git a/keyboards/melgeek/mojo75/config.h b/keyboards/melgeek/mojo75/config.h index 3f95a82ea91..77d27fe2c38 100644 --- a/keyboards/melgeek/mojo75/config.h +++ b/keyboards/melgeek/mojo75/config.h @@ -71,5 +71,5 @@ //#define RGB_MATRIX_DEFAULT_MODE RGB_MATRIX_SOLID_COLOR #define RGB_MATRIX_DEFAULT_MODE RGB_MATRIX_CYCLE_ALL //#define RGB_MATRIX_DEFAULT_MODE RGB_MATRIX_SOLID_REACTIVE_SIMPLE -#define DRIVER_ADDR_1 0b0110000 +#define DRIVER_ADDR_1 IS31FL3741_I2C_ADDRESS_GND #define IS31FL3741_DRIVER_COUNT 1 diff --git a/keyboards/melgeek/tegic/config.h b/keyboards/melgeek/tegic/config.h index ea457a3fcba..5e4087dcc5c 100755 --- a/keyboards/melgeek/tegic/config.h +++ b/keyboards/melgeek/tegic/config.h @@ -22,7 +22,7 @@ #define RGB_MATRIX_LED_FLUSH_LIMIT 26 //#define RGB_MATRIX_DEFAULT_MODE RGB_MATRIX_SOLID_COLOR #define RGB_MATRIX_DEFAULT_MODE RGB_MATRIX_CYCLE_ALL -#define DRIVER_ADDR_1 0b0110000 +#define DRIVER_ADDR_1 IS31FL3741_I2C_ADDRESS_GND #define IS31FL3741_DRIVER_COUNT 1 #define ENABLE_RGB_MATRIX_ALPHAS_MODS diff --git a/keyboards/melgeek/z70ultra/config.h b/keyboards/melgeek/z70ultra/config.h index 978982a5b1d..3ae466044ca 100644 --- a/keyboards/melgeek/z70ultra/config.h +++ b/keyboards/melgeek/z70ultra/config.h @@ -70,7 +70,7 @@ // # define ENABLE_RGB_MATRIX_SOLID_MULTISPLASH //#define RGB_MATRIX_DEFAULT_MODE RGB_MATRIX_SOLID_COLOR #define RGB_MATRIX_DEFAULT_MODE RGB_MATRIX_CYCLE_ALL -#define DRIVER_ADDR_1 0b0110000 +#define DRIVER_ADDR_1 IS31FL3741_I2C_ADDRESS_GND #define IS31FL3741_DRIVER_COUNT 1 #define RGB_MATRIX_LED_COUNT 69 #define DRIVER_INDICATOR_LED_TOTAL 6 diff --git a/keyboards/miller/gm862/config.h b/keyboards/miller/gm862/config.h index 6c47183dbfb..7378c18290e 100644 --- a/keyboards/miller/gm862/config.h +++ b/keyboards/miller/gm862/config.h @@ -53,7 +53,7 @@ // # define ENABLE_RGB_MATRIX_SOLID_SPLASH // # define ENABLE_RGB_MATRIX_SOLID_MULTISPLASH -# define DRIVER_ADDR_1 0b1010000 +# define DRIVER_ADDR_1 IS31FL3733_I2C_ADDRESS_GND_GND # define IS31FL3733_DRIVER_COUNT 1 # define RGB_MATRIX_LED_COUNT 62 #endif diff --git a/keyboards/moonlander/config.h b/keyboards/moonlander/config.h index 6b2377db1a8..cabfaf9900c 100644 --- a/keyboards/moonlander/config.h +++ b/keyboards/moonlander/config.h @@ -65,8 +65,8 @@ //#define NO_ACTION_TAPPING //#define NO_ACTION_ONESHOT -#define DRIVER_ADDR_1 0b1110100 -#define DRIVER_ADDR_2 0b1110111 +#define DRIVER_ADDR_1 IS31FL3731_I2C_ADDRESS_GND +#define DRIVER_ADDR_2 IS31FL3731_I2C_ADDRESS_VCC #define IS31FL3731_DRIVER_COUNT 2 #define DRIVER_1_LED_TOTAL 36 diff --git a/keyboards/mt/mt64rgb/config.h b/keyboards/mt/mt64rgb/config.h index c15d1aedbcb..d13942461fb 100644 --- a/keyboards/mt/mt64rgb/config.h +++ b/keyboards/mt/mt64rgb/config.h @@ -22,7 +22,7 @@ #define RGB_MATRIX_MAXIMUM_BRIGHTNESS 160 #define RGB_MATRIX_LED_PROCESS_LIMIT 20 #define RGB_MATRIX_LED_FLUSH_LIMIT 26 -#define DRIVER_ADDR_1 0b1010000 +#define DRIVER_ADDR_1 IS31FL3733_I2C_ADDRESS_GND_GND #define IS31FL3733_DRIVER_COUNT 1 #define RGB_MATRIX_LED_COUNT 64 diff --git a/keyboards/mt/mt84/config.h b/keyboards/mt/mt84/config.h index aba06321794..d76fdd262e0 100644 --- a/keyboards/mt/mt84/config.h +++ b/keyboards/mt/mt84/config.h @@ -22,8 +22,8 @@ #define RGB_MATRIX_DEFAULT_MODE RGB_MATRIX_CYCLE_ALL #define RGB_MATRIX_LED_PROCESS_LIMIT 20 #define RGB_MATRIX_LED_FLUSH_LIMIT 26 - #define DRIVER_ADDR_1 0b1010000 - #define DRIVER_ADDR_2 0b1011111 + #define DRIVER_ADDR_1 IS31FL3737_I2C_ADDRESS_GND + #define DRIVER_ADDR_2 IS31FL3737_I2C_ADDRESS_VCC diff --git a/keyboards/neson_design/700e/config.h b/keyboards/neson_design/700e/config.h index ea666617e09..64af470bac1 100644 --- a/keyboards/neson_design/700e/config.h +++ b/keyboards/neson_design/700e/config.h @@ -32,8 +32,8 @@ #define DRIVER_1_LED_TOTAL 32 #define DRIVER_2_LED_TOTAL 32 -#define DRIVER_ADDR_1 0b1110100 -#define DRIVER_ADDR_2 0b1110111 +#define DRIVER_ADDR_1 IS31FL3731_I2C_ADDRESS_GND +#define DRIVER_ADDR_2 IS31FL3731_I2C_ADDRESS_VCC #define IS31FL3731_DRIVER_COUNT 2 #define RGB_MATRIX_LED_COUNT (DRIVER_1_LED_TOTAL+DRIVER_2_LED_TOTAL) diff --git a/keyboards/neson_design/n6/config.h b/keyboards/neson_design/n6/config.h index dfdb5b93aa2..50eda4e586e 100644 --- a/keyboards/neson_design/n6/config.h +++ b/keyboards/neson_design/n6/config.h @@ -32,7 +32,7 @@ #define DRIVER_1_LED_TOTAL 32 #define DRIVER_2_LED_TOTAL 32 -#define DRIVER_ADDR_1 0b1110100 -#define DRIVER_ADDR_2 0b1110111 +#define DRIVER_ADDR_1 IS31FL3731_I2C_ADDRESS_GND +#define DRIVER_ADDR_2 IS31FL3731_I2C_ADDRESS_VCC #define IS31FL3731_DRIVER_COUNT 2 #define RGB_MATRIX_LED_COUNT (DRIVER_1_LED_TOTAL+DRIVER_2_LED_TOTAL) diff --git a/keyboards/opendeck/32/rev1/config.h b/keyboards/opendeck/32/rev1/config.h index 41b6e2d0b69..2857ef04b1d 100644 --- a/keyboards/opendeck/32/rev1/config.h +++ b/keyboards/opendeck/32/rev1/config.h @@ -16,7 +16,7 @@ #pragma once // RGB matrix -#define DRIVER_ADDR_1 0b1110100 +#define DRIVER_ADDR_1 IS31FL3731_I2C_ADDRESS_GND #define IS31FL3731_DRIVER_COUNT 1 #define RGB_MATRIX_LED_COUNT (4 * 8 * 3) #define RGB_DISABLE_WHEN_USB_SUSPENDED diff --git a/keyboards/owlab/voice65/hotswap/config.h b/keyboards/owlab/voice65/hotswap/config.h index ccf103cfa3f..50876e8302d 100644 --- a/keyboards/owlab/voice65/hotswap/config.h +++ b/keyboards/owlab/voice65/hotswap/config.h @@ -29,7 +29,7 @@ along with this program. If not, see . # define RGB_MATRIX_LED_FLUSH_LIMIT 26 # define RGB_MATRIX_MAXIMUM_BRIGHTNESS 200 # define RGB_MATRIX_DEFAULT_VAL 128 -# define DRIVER_ADDR_1 0b0110000 +# define DRIVER_ADDR_1 IS31FL3741_I2C_ADDRESS_GND # define IS31FL3741_DRIVER_COUNT 1 # define RGB_MATRIX_LED_COUNT 67 // RGB Matrix Animation modes. Explicitly enabled diff --git a/keyboards/owlab/voice65/soldered/config.h b/keyboards/owlab/voice65/soldered/config.h index 0cb0678b435..ab66f4368d6 100644 --- a/keyboards/owlab/voice65/soldered/config.h +++ b/keyboards/owlab/voice65/soldered/config.h @@ -29,7 +29,7 @@ along with this program. If not, see . # define RGB_MATRIX_LED_FLUSH_LIMIT 26 # define RGB_MATRIX_MAXIMUM_BRIGHTNESS 200 # define RGB_MATRIX_DEFAULT_VAL 128 -# define DRIVER_ADDR_1 0b0110000 +# define DRIVER_ADDR_1 IS31FL3741_I2C_ADDRESS_GND # define IS31FL3741_DRIVER_COUNT 1 # define RGB_MATRIX_LED_COUNT 71 diff --git a/keyboards/planck/ez/config.h b/keyboards/planck/ez/config.h index ca57e4e7725..f4998282e60 100644 --- a/keyboards/planck/ez/config.h +++ b/keyboards/planck/ez/config.h @@ -50,7 +50,7 @@ //#define WS2812_DMA_CHANNEL 7 // DMA channel for TIMx_UP //#define WS2812_EXTERNAL_PULLUP -#define DRIVER_ADDR_1 0b1010000 +#define DRIVER_ADDR_1 IS31FL3737_I2C_ADDRESS_GND #define IS31FL3737_DRIVER_COUNT 1 #define RGB_MATRIX_LED_COUNT 47 diff --git a/keyboards/planck/light/config.h b/keyboards/planck/light/config.h index 827028cd3aa..20c729ec51a 100644 --- a/keyboards/planck/light/config.h +++ b/keyboards/planck/light/config.h @@ -7,15 +7,8 @@ #define PLANCK_MIT_LAYOUT -// This is a 7-bit address, that gets left-shifted and bit 0 -// set to 0 for write, 1 for read (as per I2C protocol) -// The address will vary depending on your wiring: -// 0b1110100 AD <-> GND -// 0b1110111 AD <-> VCC -// 0b1110101 AD <-> SCL -// 0b1110110 AD <-> SDA -#define DRIVER_ADDR_1 0b1110100 -#define DRIVER_ADDR_2 0b1110110 +#define DRIVER_ADDR_1 IS31FL3731_I2C_ADDRESS_GND +#define DRIVER_ADDR_2 IS31FL3731_I2C_ADDRESS_SDA #define IS31FL3731_DRIVER_COUNT 2 #define DRIVER_1_LED_TOTAL 25 diff --git a/keyboards/playkbtw/pk64rgb/config.h b/keyboards/playkbtw/pk64rgb/config.h index 4ae2454bd14..bd4d53d0b5e 100644 --- a/keyboards/playkbtw/pk64rgb/config.h +++ b/keyboards/playkbtw/pk64rgb/config.h @@ -23,7 +23,7 @@ #define RGB_MATRIX_MAXIMUM_BRIGHTNESS 160 #define RGB_MATRIX_LED_PROCESS_LIMIT 20 #define RGB_MATRIX_LED_FLUSH_LIMIT 26 - #define DRIVER_ADDR_1 0b1010000 + #define DRIVER_ADDR_1 IS31FL3733_I2C_ADDRESS_GND_GND #define IS31FL3733_DRIVER_COUNT 1 #define RGB_MATRIX_LED_COUNT 64 diff --git a/keyboards/redragon/k667/config.h b/keyboards/redragon/k667/config.h index 90ac3d465fd..938befa8fc7 100644 --- a/keyboards/redragon/k667/config.h +++ b/keyboards/redragon/k667/config.h @@ -17,8 +17,8 @@ #pragma once -#define DRIVER_ADDR_1 0b1010000 -#define DRIVER_ADDR_2 0b1010011 +#define DRIVER_ADDR_1 IS31FL3733_I2C_ADDRESS_GND_GND +#define DRIVER_ADDR_2 IS31FL3733_I2C_ADDRESS_GND_VCC #define IS31FL3733_DRIVER_COUNT 2 #define DRIVER_1_LED_TOTAL 45 diff --git a/keyboards/smallkeyboard/config.h b/keyboards/smallkeyboard/config.h index cc454fe82e9..784aece4694 100644 --- a/keyboards/smallkeyboard/config.h +++ b/keyboards/smallkeyboard/config.h @@ -66,14 +66,7 @@ // #define ENABLE_RGB_MATRIX_SOLID_SPLASH // #define ENABLE_RGB_MATRIX_SOLID_MULTISPLASH -// This is a 7-bit address, that gets left-shifted and bit 0 -// set to 0 for write, 1 for read (as per I2C protocol) -// The address will vary depending on your wiring: -// 0b1110100 AD <-> GND -// 0b1110111 AD <-> VCC -// 0b1110101 AD <-> SCL -// 0b1110110 AD <-> SDA -#define DRIVER_ADDR_1 0b1110100 +#define DRIVER_ADDR_1 IS31FL3731_I2C_ADDRESS_GND #define IS31FL3731_DRIVER_COUNT 1 #define RGB_MATRIX_LED_COUNT 6 diff --git a/keyboards/teleport/native/config.h b/keyboards/teleport/native/config.h index 705450ed51f..ed858db0c7a 100644 --- a/keyboards/teleport/native/config.h +++ b/keyboards/teleport/native/config.h @@ -30,8 +30,8 @@ along with this program. If not, see . /* RGB Matrix driver config */ #define IS31FL3733_DRIVER_COUNT 2 -#define DRIVER_ADDR_1 0b1010000 -#define DRIVER_ADDR_2 0b1010011 +#define DRIVER_ADDR_1 IS31FL3733_I2C_ADDRESS_GND_GND +#define DRIVER_ADDR_2 IS31FL3733_I2C_ADDRESS_GND_VCC #define DRIVER_1_LED_TOTAL 46 #define DRIVER_2_LED_TOTAL 39 #define RGB_MATRIX_LED_COUNT (DRIVER_1_LED_TOTAL + DRIVER_2_LED_TOTAL) diff --git a/keyboards/terrazzo/config.h b/keyboards/terrazzo/config.h index dc0fa100e85..6ad8c363a32 100644 --- a/keyboards/terrazzo/config.h +++ b/keyboards/terrazzo/config.h @@ -17,7 +17,7 @@ #ifdef LED_MATRIX_ENABLE -#define LED_DRIVER_ADDR_1 0x74 +#define LED_DRIVER_ADDR_1 IS31FL3731_I2C_ADDRESS_GND #define IS31FL3731_DRIVER_COUNT 1 #define LED_MATRIX_LED_COUNT 105 #define LED_MATRIX_ROWS 15 diff --git a/keyboards/tkc/portico/config.h b/keyboards/tkc/portico/config.h index 5adf42127e7..442a0900b2e 100644 --- a/keyboards/tkc/portico/config.h +++ b/keyboards/tkc/portico/config.h @@ -39,8 +39,8 @@ along with this program. If not, see . # undef ENABLE_RGB_MATRIX_SOLID_MULTISPLASH # undef ENABLE_RGB_MATRIX_DIGITAL_RAIN # define RGB_MATRIX_MAXIMUM_BRIGHTNESS 200 -# define DRIVER_ADDR_1 0x74 -# define DRIVER_ADDR_2 0x77 +# define DRIVER_ADDR_1 IS31FL3731_I2C_ADDRESS_GND +# define DRIVER_ADDR_2 IS31FL3731_I2C_ADDRESS_VCC # define IS31FL3731_DRIVER_COUNT 2 # define DRIVER_1_LED_TOTAL 36 # define DRIVER_2_LED_TOTAL 31 diff --git a/keyboards/tkc/portico68v2/config.h b/keyboards/tkc/portico68v2/config.h index 1c9f946cb75..f350af712bc 100644 --- a/keyboards/tkc/portico68v2/config.h +++ b/keyboards/tkc/portico68v2/config.h @@ -17,7 +17,7 @@ along with this program. If not, see . #pragma once -#define DRIVER_ADDR_1 0b0110000 +#define DRIVER_ADDR_1 IS31FL3741_I2C_ADDRESS_GND #define IS31FL3741_DRIVER_COUNT 1 #define DRIVER_1_LED_TOTAL 82 #define RGB_MATRIX_LED_COUNT DRIVER_1_LED_TOTAL diff --git a/keyboards/tkc/portico75/config.h b/keyboards/tkc/portico75/config.h index d00d38e36ab..d512608f9c5 100644 --- a/keyboards/tkc/portico75/config.h +++ b/keyboards/tkc/portico75/config.h @@ -72,7 +72,7 @@ along with this program. If not, see . // # define ENABLE_RGB_MATRIX_SOLID_MULTISPLASH # define RGB_MATRIX_MAXIMUM_BRIGHTNESS 200 -# define DRIVER_ADDR_1 0b0110000 +# define DRIVER_ADDR_1 IS31FL3741_I2C_ADDRESS_GND # define IS31FL3741_DRIVER_COUNT 1 # define DRIVER_1_LED_TOTAL 98 # define RGB_MATRIX_LED_COUNT DRIVER_1_LED_TOTAL diff --git a/keyboards/wilba_tech/wt_rgb_backlight.c b/keyboards/wilba_tech/wt_rgb_backlight.c index 8a0f3b7f913..20932138edc 100644 --- a/keyboards/wilba_tech/wt_rgb_backlight.c +++ b/keyboards/wilba_tech/wt_rgb_backlight.c @@ -155,11 +155,7 @@ uint8_t g_key_hit[BACKLIGHT_LED_COUNT]; uint32_t g_any_key_hit = 0; #if defined(RGB_BACKLIGHT_HS60) - -// This is a 7-bit address, that gets left-shifted and bit 0 -// set to 0 for write, 1 for read (as per I2C protocol) -// ADDR_2 is not needed. it is here as a dummy -#define ISSI_ADDR_1 0x50 +#define ISSI_ADDR_1 IS31FL3733_I2C_ADDRESS_GND_GND const is31_led PROGMEM g_is31_leds[RGB_MATRIX_LED_COUNT] = { /* Refer to IS31 manual for these locations @@ -235,12 +231,8 @@ const is31_led PROGMEM g_is31_leds[RGB_MATRIX_LED_COUNT] = { }; #elif defined(RGB_BACKLIGHT_NK65) || defined(RGB_BACKLIGHT_NEBULA68) || defined(RGB_BACKLIGHT_NK87) || defined(RGB_BACKLIGHT_KW_MEGA) - -// This is a 7-bit address, that gets left-shifted and bit 0 -// set to 0 for write, 1 for read (as per I2C protocol) -// ADDR_2 is not needed. it is here as a dummy -#define ISSI_ADDR_1 0x50 -#define ISSI_ADDR_2 0x52 +#define ISSI_ADDR_1 IS31FL3733_I2C_ADDRESS_GND_GND +#define ISSI_ADDR_2 IS31FL3733_I2C_ADDRESS_GND_SDA const is31_led PROGMEM g_is31_leds[RGB_MATRIX_LED_COUNT] = { /* Refer to IS31 manual for these locations @@ -381,9 +373,7 @@ const is31_led PROGMEM g_is31_leds[RGB_MATRIX_LED_COUNT] = { }; #elif defined(RGB_BACKLIGHT_NEBULA12) -// This is a 7-bit address, that gets left-shifted and bit 0 -// set to 0 for write, 1 for read (as per I2C protocol) -#define ISSI_ADDR_1 0x74 +#define ISSI_ADDR_1 IS31FL3731_I2C_ADDRESS_GND const is31_led PROGMEM g_is31_leds[RGB_MATRIX_LED_COUNT] = { /* Refer to IS31 manual for these locations @@ -411,11 +401,10 @@ const is31_led PROGMEM g_is31_leds[RGB_MATRIX_LED_COUNT] = { }; #elif defined(RGB_BACKLIGHT_U80_A) - // U80-A prototype uses 3 ISSI drivers -#define ISSI_ADDR_1 0x74 // 11101[00] <- GND -#define ISSI_ADDR_2 0x76 // 11101[10] <- SDA -#define ISSI_ADDR_3 0x75 // 11101[01] <- SCL +#define ISSI_ADDR_1 IS31FL3731_I2C_ADDRESS_GND +#define ISSI_ADDR_2 IS31FL3731_I2C_ADDRESS_SDA +#define ISSI_ADDR_3 IS31FL3731_I2C_ADDRESS_SCL const is31_led PROGMEM g_is31_leds[RGB_MATRIX_LED_COUNT] = { /* Refer to IS31 manual for these locations @@ -539,10 +528,8 @@ const is31_led PROGMEM g_is31_leds[RGB_MATRIX_LED_COUNT] = { {2, C8_16, C7_16, C6_16}, // LF17 }; #elif defined(RGB_BACKLIGHT_DAWN60) -// This is a 7-bit address, that gets left-shifted and bit 0 -// set to 0 for write, 1 for read (as per I2C protocol) -#define ISSI_ADDR_1 0x74 -#define ISSI_ADDR_2 0x76 +#define ISSI_ADDR_1 IS31FL3731_I2C_ADDRESS_GND +#define ISSI_ADDR_2 IS31FL3731_I2C_ADDRESS_SDA const is31_led PROGMEM g_is31_leds[RGB_MATRIX_LED_COUNT] = { /* Refer to IS31 manual for these locations @@ -620,10 +607,8 @@ const is31_led PROGMEM g_is31_leds[RGB_MATRIX_LED_COUNT] = { {1, C9_16, C7_15, C6_15} //D16 }; #elif defined(RGB_BACKLIGHT_PORTICO) -// This is a 7-bit address, that gets left-shifted and bit 0 -// set to 0 for write, 1 for read (as per I2C protocol) -#define ISSI_ADDR_1 0x74 -#define ISSI_ADDR_2 0x77 +#define ISSI_ADDR_1 IS31FL3731_I2C_ADDRESS_GND +#define ISSI_ADDR_2 IS31FL3731_I2C_ADDRESS_VCC const is31_led PROGMEM g_is31_leds[RGB_MATRIX_LED_COUNT] = { /* Refer to IS31 manual for these locations @@ -706,9 +691,7 @@ const is31_led PROGMEM g_is31_leds[RGB_MATRIX_LED_COUNT] = { }; #elif defined(RGB_BACKLIGHT_PORTICO75) -// This is a 7-bit address, that gets left-shifted and bit 0 -// set to 0 for write, 1 for read (as per I2C protocol) -#define ISSI_ADDR_1 0x30 +#define ISSI_ADDR_1 IS31FL3741_I2C_ADDRESS_GND #define ISSI_ADDR_2 const is31_led PROGMEM g_is31_leds[RGB_MATRIX_LED_COUNT] = { @@ -843,9 +826,7 @@ const is31fl3218_led_t PROGMEM g_is31fl3218_leds[RGB_MATRIX_LED_COUNT] = { {OUT16, OUT17, OUT18} }; #elif defined(RGB_BACKLIGHT_M10_C) -// This is a 7-bit address, that gets left-shifted and bit 0 -// set to 0 for write, 1 for read (as per I2C protocol) -#define ISSI_ADDR_1 0x74 +#define ISSI_ADDR_1 IS31FL3731_I2C_ADDRESS_GND #define ISSI_ADDR_2 const is31_led PROGMEM g_is31_leds[RGB_MATRIX_LED_COUNT] = { @@ -863,10 +844,8 @@ const is31_led PROGMEM g_is31_leds[RGB_MATRIX_LED_COUNT] = { {0, C9_16, C7_15, C6_15} // LB16 }; #else -// This is a 7-bit address, that gets left-shifted and bit 0 -// set to 0 for write, 1 for read (as per I2C protocol) -#define ISSI_ADDR_1 0x74 -#define ISSI_ADDR_2 0x76 +#define ISSI_ADDR_1 IS31FL3731_I2C_ADDRESS_GND +#define ISSI_ADDR_2 IS31FL3731_I2C_ADDRESS_SDA const is31_led PROGMEM g_is31_leds[RGB_MATRIX_LED_COUNT] = { /* Refer to IS31 manual for these locations diff --git a/keyboards/xbows/knight/config.h b/keyboards/xbows/knight/config.h index dcf3c5a52f2..c38628fef1e 100644 --- a/keyboards/xbows/knight/config.h +++ b/keyboards/xbows/knight/config.h @@ -47,9 +47,9 @@ # define ENABLE_RGB_MATRIX_SPLASH // Full gradient & value pulse away from a single key hit then fades value out # define ENABLE_RGB_MATRIX_SOLID_MULTISPLASH // Hue & value pulse away from multiple key hits then fades value out -# define DRIVER_ADDR_1 0b1110100 -# define DRIVER_ADDR_2 0b1110110 -# define DRIVER_ADDR_3 0b1110101 +# define DRIVER_ADDR_1 IS31FL3731_I2C_ADDRESS_GND +# define DRIVER_ADDR_2 IS31FL3731_I2C_ADDRESS_SDA +# define DRIVER_ADDR_3 IS31FL3731_I2C_ADDRESS_SCL # define IS31FL3731_DRIVER_COUNT 3 # define DRIVER_1_LED_TOTAL 36 # define DRIVER_2_LED_TOTAL 35 diff --git a/keyboards/xbows/knight_plus/config.h b/keyboards/xbows/knight_plus/config.h index 417393d4f8a..7a26ca99445 100644 --- a/keyboards/xbows/knight_plus/config.h +++ b/keyboards/xbows/knight_plus/config.h @@ -47,9 +47,9 @@ # define ENABLE_RGB_MATRIX_SPLASH // Full gradient & value pulse away from a single key hit then fades value out # define ENABLE_RGB_MATRIX_SOLID_MULTISPLASH // Hue & value pulse away from multiple key hits then fades value out -# define DRIVER_ADDR_1 0b1110100 -# define DRIVER_ADDR_2 0b1110110 -# define DRIVER_ADDR_3 0b1110101 +# define DRIVER_ADDR_1 IS31FL3731_I2C_ADDRESS_GND +# define DRIVER_ADDR_2 IS31FL3731_I2C_ADDRESS_SDA +# define DRIVER_ADDR_3 IS31FL3731_I2C_ADDRESS_SCL # define IS31FL3731_DRIVER_COUNT 3 # define DRIVER_1_LED_TOTAL 36 # define DRIVER_2_LED_TOTAL 35 diff --git a/keyboards/xbows/nature/config.h b/keyboards/xbows/nature/config.h index e3db6b5b7a6..f408d626997 100644 --- a/keyboards/xbows/nature/config.h +++ b/keyboards/xbows/nature/config.h @@ -49,9 +49,9 @@ # define ENABLE_RGB_MATRIX_SPLASH // Full gradient & value pulse away from a single key hit then fades value out # define ENABLE_RGB_MATRIX_SOLID_MULTISPLASH // Hue & value pulse away from multiple key hits then fades value out -# define DRIVER_ADDR_1 0b1110100 -# define DRIVER_ADDR_2 0b1110110 -# define DRIVER_ADDR_3 0b1110101 +# define DRIVER_ADDR_1 IS31FL3731_I2C_ADDRESS_GND +# define DRIVER_ADDR_2 IS31FL3731_I2C_ADDRESS_SDA +# define DRIVER_ADDR_3 IS31FL3731_I2C_ADDRESS_SCL # define IS31FL3731_DRIVER_COUNT 3 # define DRIVER_1_LED_TOTAL 36 # define DRIVER_2_LED_TOTAL 36 diff --git a/keyboards/xbows/numpad/config.h b/keyboards/xbows/numpad/config.h index ec0b7d8e8b5..d0c5d884912 100644 --- a/keyboards/xbows/numpad/config.h +++ b/keyboards/xbows/numpad/config.h @@ -47,7 +47,7 @@ # define ENABLE_RGB_MATRIX_SPLASH // Full gradient & value pulse away from a single key hit then fades value out # define ENABLE_RGB_MATRIX_SOLID_MULTISPLASH // Hue & value pulse away from multiple key hits then fades value out -# define DRIVER_ADDR_1 0b1110111 +# define DRIVER_ADDR_1 IS31FL3731_I2C_ADDRESS_VCC # define IS31FL3731_DRIVER_COUNT 1 # define RGB_MATRIX_LED_COUNT 22 #endif diff --git a/keyboards/xbows/ranger/config.h b/keyboards/xbows/ranger/config.h index 2ae5db6289e..81d97374498 100644 --- a/keyboards/xbows/ranger/config.h +++ b/keyboards/xbows/ranger/config.h @@ -46,9 +46,9 @@ # define ENABLE_RGB_MATRIX_SPLASH // Full gradient & value pulse away from a single key hit then fades value out # define ENABLE_RGB_MATRIX_SOLID_MULTISPLASH // Hue & value pulse away from multiple key hits then fades value out -# define DRIVER_ADDR_1 0b1110100 -# define DRIVER_ADDR_2 0b1110101 -# define DRIVER_ADDR_3 0b1110110 +# define DRIVER_ADDR_1 IS31FL3731_I2C_ADDRESS_GND +# define DRIVER_ADDR_2 IS31FL3731_I2C_ADDRESS_SCL +# define DRIVER_ADDR_3 IS31FL3731_I2C_ADDRESS_SDA # define IS31FL3731_DRIVER_COUNT 3 # define DRIVER_1_LED_TOTAL 36 # define DRIVER_2_LED_TOTAL 36 diff --git a/keyboards/xbows/woody/config.h b/keyboards/xbows/woody/config.h index 0228b954d7e..4b6ea9f70a4 100644 --- a/keyboards/xbows/woody/config.h +++ b/keyboards/xbows/woody/config.h @@ -56,8 +56,8 @@ // # define ENABLE_RGB_MATRIX_SOLID_SPLASH // # define ENABLE_RGB_MATRIX_SOLID_MULTISPLASH -# define DRIVER_ADDR_1 0b1110100 -# define DRIVER_ADDR_2 0b1110110 +# define DRIVER_ADDR_1 IS31FL3731_I2C_ADDRESS_GND +# define DRIVER_ADDR_2 IS31FL3731_I2C_ADDRESS_SDA # define IS31FL3731_DRIVER_COUNT 2 # define DRIVER_1_LED_TOTAL 35 # define DRIVER_2_LED_TOTAL 32 diff --git a/keyboards/xelus/dawn60/rev1_qmk/config.h b/keyboards/xelus/dawn60/rev1_qmk/config.h index 0c3f8208a46..9958f8c2bb6 100644 --- a/keyboards/xelus/dawn60/rev1_qmk/config.h +++ b/keyboards/xelus/dawn60/rev1_qmk/config.h @@ -24,8 +24,8 @@ #define WS2812_LED_TOTAL 20 //RGB Matrix defines -#define DRIVER_ADDR_1 0x74 -#define DRIVER_ADDR_2 0x76 +#define DRIVER_ADDR_1 IS31FL3731_I2C_ADDRESS_GND +#define DRIVER_ADDR_2 IS31FL3731_I2C_ADDRESS_SDA #define IS31FL3731_DRIVER_COUNT 2 #define DRIVER_1_LED_TOTAL 32 diff --git a/keyboards/xelus/pachi/rgb/rev1/config.h b/keyboards/xelus/pachi/rgb/rev1/config.h index dd4c378a665..882f2a7e365 100644 --- a/keyboards/xelus/pachi/rgb/rev1/config.h +++ b/keyboards/xelus/pachi/rgb/rev1/config.h @@ -40,7 +40,7 @@ #define DYNAMIC_KEYMAP_EEPROM_MAX_ADDR 8191 // RGB Matrix defines -#define DRIVER_ADDR_1 0b0110000 +#define DRIVER_ADDR_1 IS31FL3741_I2C_ADDRESS_GND #define IS31FL3741_DRIVER_COUNT 1 #define DRIVER_1_LED_TOTAL 117 diff --git a/keyboards/xelus/pachi/rgb/rev2/config.h b/keyboards/xelus/pachi/rgb/rev2/config.h index 939721c2249..826e8f869ec 100644 --- a/keyboards/xelus/pachi/rgb/rev2/config.h +++ b/keyboards/xelus/pachi/rgb/rev2/config.h @@ -37,7 +37,7 @@ #define EEPROM_I2C_24LC64 // RGB Matrix defines -#define DRIVER_ADDR_1 0b0110000 +#define DRIVER_ADDR_1 IS31FL3741_I2C_ADDRESS_GND #define IS31FL3741_DRIVER_COUNT 1 #define DRIVER_1_LED_TOTAL 117