Go Down

Topic: Help me about freezing the fastled color palette effects (Read 180 times) previous topic - next topic


Hi all
My arduino has been running color palette effect for months, so far so good
Sometime the color just so perfect and I want to stop the effect right at that moment and keep the led that way by pushing a button, and then if I want them to continue running, I push the button again (or another button)
can anyone help me?


The way the library is written, it is impossible to immediately freeze things on a switch press.

If you rewrite the library, you could add code to monitor the switch and then achieve what you want.

But, always show us your 'current' complete sketch.
Use CTRL T to format the sketch.
Please use code tags.
Use the </> icon in the posting menu.   
[code] Paste sketch here. [/code]

No technical PMs.
If you are asked a question, please respond with an answer.
If you are asked for more information, please supply it.
If you need clarification, ask for help.


You need to write the code as a state machine. No need to change the libiary.

This means removing any delays and rewriting for loops that contain them into functions that only do one iteration of a loop before returning.

Go Up