From 0c725017638ec86011191bf835735fb6c569d298 Mon Sep 17 00:00:00 2001 From: donicrosby Date: Mon, 1 Nov 2021 19:40:01 -0400 Subject: 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 --- drivers/led/issi/is31fl3731.c | 7 +++++++ 1 file changed, 7 insertions(+) (limited to 'drivers/led/issi/is31fl3731.c') diff --git a/drivers/led/issi/is31fl3731.c b/drivers/led/issi/is31fl3731.c index 110bdc1be4..fbf24c30fb 100644 --- a/drivers/led/issi/is31fl3731.c +++ b/drivers/led/issi/is31fl3731.c @@ -1,5 +1,6 @@ /* Copyright 2017 Jason Williams * Copyright 2018 Jack Humbert + * Copyright 2021 Doni Crosby * * This program is free software: you can redistribute it and/or modify * it under the terms of the GNU General Public License as published by @@ -39,6 +40,9 @@ #define ISSI_REG_PICTUREFRAME 0x01 +// Not defined in the datasheet -- See AN for IC +#define ISSI_REG_GHOST_IMAGE_PREVENTION 0xC2 // Set bit 4 to enable de-ghosting + #define ISSI_REG_SHUTDOWN 0x0A #define ISSI_REG_AUDIOSYNC 0x06 @@ -132,6 +136,9 @@ void IS31FL3731_init(uint8_t addr) { // enable software shutdown IS31FL3731_write_register(addr, ISSI_REG_SHUTDOWN, 0x00); +#ifdef ISSI_3731_DEGHOST // set to enable de-ghosting of the array + IS31FL3731_write_register(addr, ISSI_REG_GHOST_IMAGE_PREVENTION, 0x10); +#endif // this delay was copied from other drivers, might not be needed wait_ms(10); -- cgit v1.2.3