Changing effects from gpio v0.8.5

Hi, thank you for your good project
Tips for adding a feature that I can do by reading the status of the pins
I’m new in programming and I wanted (for etc) running effect and color to be executed when the pin was low, and go back to the lastest effect, speed, settings,… that were running when it was high.
I can apply the changes, but I could not return to the previous state
sry for my bad english thx for ur help