r/WLED • u/Embarrassed-Lab6622 • 11h ago
Using presets with input pins
Good afternoon. I am trying to set up the WLED program to use one of five presets based on the input pin going HIGH. After quite some time, I still cannot figure out how to assign the preset to a specific GPIO via the WLED web interface. FYI, all outputs are the same, just multiple 12v strips for the inside of my truck shell.
2
Upvotes
1
u/Substantial_Goat6969 11h ago
You set presets are set with led numbers. If you have three outputs with 200 leds each, you would make one group 1 - 200, second group 200 - 400 third group 400 - 600. After you can make your groups, you can individually select those and change effects on just that section.
1
u/saratoga3 9h ago
Your resistors pull 5v down to ~2v, which is probably too low to trigger a GPIO pin. Try removing R11 so that you pull up to 2.5v and see if that works better.
1
u/JamesM_007 7h ago
The circuit design is rather minimal, which could lead to unreliable hardware operation. There are no bulk filter capacitors on the DC-DC input and output. The LED data line is missing a buffer transceiver such as the SN74HC245 to increase signal drive strength. Robust hardware is essential for consistent firmware
1
u/Individual_Nobody739 7h ago
You don’t need a separate LED segment for each input if all the strips should run the same effect. First, save one preset and select it manually to make sure it does what you want across all the outputs.
Then configure one GPIO as a Switch under Config → LED Preferences. The preset assignment is on a different page: Config → Time & Macros → Button Action Presets. A switch has separate actions for Off to On and On to Off. Test which action fires when your input goes HIGH, and assign the preset to that action. Test the return transition too: a value of
0uses WLED’s default action, so don’t assume it means “do nothing.”Once one input works, check that your installed build exposes five button slots before setting up the other four. If it doesn’t, check your WLED version and build first; creating more LED segments won’t add input slots.