summaryrefslogtreecommitdiff
path: root/drivers/led/issi/is31fl3741.c
diff options
context:
space:
mode:
authordonicrosby <doni.crosby1995@gmail.com>2021-11-01 19:40:01 -0400
committerGitHub <noreply@github.com>2021-11-02 10:40:01 +1100
commit0c725017638ec86011191bf835735fb6c569d298 (patch)
treed5c1076063ade21423de710ae9837b6edd16ae80 /drivers/led/issi/is31fl3741.c
parent7ae0f371cf55a589a4735098f52e722f579de41d (diff)
Enable de-ghosting for RGB/LED matrix on all ISSI LED drivers (#14508)
* Initial work for de-ghost enable * Dumb mistake with the redefine * Added Copywrite stuff on source files * Fixed whitespace errors * Added support for all ISSI LED drivers * Updated docs for support for ISSI LED driver pull-up pull-down * Applied clang format * Added 'boolean' flag to enable de-ghosting for the is31fl3731 IC * Fixed some of the grammer in the docs * Fixed comment placement and grammer of comment * Fixed whitespace errors from lint Co-authored-by: donicrosby <donicrosby1995@gmail.com>
Diffstat (limited to 'drivers/led/issi/is31fl3741.c')
-rw-r--r--drivers/led/issi/is31fl3741.c10
1 files changed, 9 insertions, 1 deletions
diff --git a/drivers/led/issi/is31fl3741.c b/drivers/led/issi/is31fl3741.c
index 24a273514e..5084f3b9fc 100644
--- a/drivers/led/issi/is31fl3741.c
+++ b/drivers/led/issi/is31fl3741.c
@@ -61,6 +61,14 @@
# define ISSI_PERSISTENCE 0
#endif
+#ifndef ISSI_SWPULLUP
+# define ISSI_SWPULLUP PUR_32KR
+#endif
+
+#ifndef ISSI_CSPULLUP
+# define ISSI_CSPULLUP PUR_32KR
+#endif
+
#define ISSI_MAX_LEDS 351
// Transfer buffer for TWITransmitData()
@@ -157,7 +165,7 @@ void IS31FL3741_init(uint8_t addr) {
// Set Golbal Current Control Register
IS31FL3741_write_register(addr, ISSI_REG_GLOBALCURRENT, 0xFF);
// Set Pull up & Down for SWx CSy
- IS31FL3741_write_register(addr, ISSI_REG_PULLDOWNUP, 0x77);
+ IS31FL3741_write_register(addr, ISSI_REG_PULLDOWNUP, ((ISSI_CSPULLUP << 4) | ISSI_SWPULLUP));
// IS31FL3741_update_led_scaling_registers(addr, 0xFF, 0xFF, 0xFF);