I am wanting to be able to dynamically set the color of my leds.

I am wanting to be able to dynamically set the color of my leds.
I would like to use an encoder to scroll through and then using the encoder’s position control the color. Where can I find documentation or examples of how to pass the color(which seems to be a uint8 array of length 3. Any ideas would be great. Or could I just call on CRGB::HTMLColorCoding(currentcolor); //current color is a variable.
I’m not sure if I can work with enums like this. the code compiles, but I’ve not seen anywhere that this is ok. Any ideas or suggestions would be greatly appriciated.

You can just map the encoder’s position reading to a byte (0-255), then just use it as the hue when creating a color: leds[i] = CHSV(hue, sat, val);

I almost always work in CHSV values. That is, unless I’m using palettes.

Here’s an example I made that allows color to be dialed in with a potentiometer.

Similar idea can be used with an encoder.

The ability to use an encoder with select platforms also requires some forethought when calling FastLED.show();

Most interrupt libraries (and most efficient use of encoders in general) require interrupts.

But Jason Coon is correct in mapping to a byte, just be aware that many encoders are quad (increments of 4 per tick) which can be erratic if you’re not expecting it.

So from what I gather, give up on the CRGB:: and use CHSV. That is acceptable, now that I get how it is working. As for the interrupts I think I’ll use a push-button to enter menu. from the menu I can change colors and brightness. then i can not monitor them any more until i reenter the menu.Thank you @Jason_Coon , @marmil

maybe my wiki gives you an additional hint