I’ve looked around for this but can’t really seem to find it. I’m working on this led project from a tutorial but I can’t seem to figure out how to turn it on and off when I complete the project. I understand all the code but I need help adding more code to it turn it on and off. It would be greatly appreciated if you guys could supply me with some code or anything that you can do to help. The code will be linked below. Thanks!
Code: https://github.com/hansjny/Natural-Nerd/tree/master/Hexaleaf
Video: https://youtu.be/2OP-oEbzB6g
The guy has written a wrapper library which calls the fastLED library, but seems to have forgotten to include an off command.
The easiest way around that is probably to select black (RGB 0,0,0) as the desired colour(s) when you want the LEDs to be off, or just pull the mains plug.
If you’re comfortable amending the wrapper library yourself then have a go - if it doesn’t work then you can always revert back to the original. If not then I’d suggest that you contact the author directly and ask him to add an off option, although I suspect that he won’t do that unless you become one of his patreons.
Pete.