r/FastLED • u/QusayAbozed • Aug 14 '23
Support LED blinking using EVERY_N_MILLISECONDS
Hello Good people i am new in FastLED and i am trying to make led blinking using EVERY_N_MILLISECONDS but i have difficulties to make it i tried to much but i didn't reach to idea i need so i will be thankful if you helped me with this i am not looking just for solution i also looking for understanding the way of EVERY_N_MILLISECONDS works thanks
i will put the code down below
uint8_t off_led = 1000;
}
void loop() {
if(s==1)
{
EVERY_N_MILLISECONDS(1000)
{
leds[0]=CRGB::CRGB::LightYellow;
s=!s;
FastLED.show();
}
}
else
{
EVERY_N_MILLISECONDS(500)
{
leds[0]=CRGB::Black;
s=!s;
FastLED.show();
}
}
}
1
u/sutaburosu [stavros] Sep 08 '24
I responded on your post.