I’ve got two functions, one that shows a blue colour on an LED strip, and one that shows a green colour.
I’m trying to use millis to swap between the two, but I am a bit unsure where to start.
I’m my many code interations, I can get both colours to show, but one of them is for a brief moment only, the other is solid, so the timing isn’t even.
Without seeing colourBlue(), colourGreen(), or how flash() is called (or even if it is called), it is hard to help.
I can see that, in the first 500 milliseconds, inside flash(), if the variable flashCounter ever makes it to one thus calling colourGreen()), flashCounter gets set back to zero (thus calling colourBlue()). I do not think that is your intention.