Loving the FastLED library, this is an incredible piece of work, but I’m coming at this as a beginner programmer who hasn’t touched C in more than 20 years.
I’ve gotten all my proof of concept code working, but I’m struggling with trying to make it more flexible. I’m writing a user interface where I want the ability for people to add a friendly name to the LED strip, and specify how many LEDs they’re using.
I have a fixed set of CRGB arrays, named leds_A, leds_B… leds_F, and I’m trying to create a way to add friendly names and settings to these.
I think I probably need to be saving a pointer to the CRGB array rather than the string name of the CRGB array, but I’m struggling to find answers online. Can anybody advise either what I’m doing wrong, or whether there’s a better way to do this?
//Structure to define LED strips
typedef struct ledArray_struct
//Create an array to track all led strips
//TODO: Populate this with saved data for actual LED strip details
ledStrips.ledStripName = “Top”;
ledStrips.ledArray = “leds_A”;
ledStrips.numberOfLeds = 7;
//Add LEDs and ensure LEDs are off at start