Hi, I modified the code to add a functional invert option - not being a full github guru, I'm just documenting it here!!
The purpose was to invert the output driver ranges so that I could use the code for a single RGB LED (Common anode) built into a dummy 'mains lamp' linked directly to the ESP I/O pins through current limiting resistors...the arrangement meant that a GPIO of 255 is full off, and 0 is full on (inverted logic)
config.h - added a definition:
//NK LED Type - Common anode uses reverse value logic for intensities
#define MODE_INVERT 1
Hi, I modified the code to add a functional invert option - not being a full github guru, I'm just documenting it here!!
The purpose was to invert the output driver ranges so that I could use the code for a single RGB LED (Common anode) built into a dummy 'mains lamp' linked directly to the ESP I/O pins through current limiting resistors...the arrangement meant that a GPIO of 255 is full off, and 0 is full on (inverted logic)
config.h - added a definition:
In main code - added a variable at line 20:
const int modeInvert = MODE_INVERT;
Modified setColor: