I plan to add lighting to my baseboard. (ignore the doorways for the moment and power injection requirements)
In the schematic:
Blue line is the entire strip
The Red circle is the controller.
The brown circles are sensors (PIR or ToF)
The green, yellow, pink and cyan are segments I wanna control.
I would like to light up some areas (segments) when a sensor is triggered. How would I go about this? Setting up segments within the main strip? Can I tell WLED “light up segment X when GPIO Y gets logical 1 and turn it off after 5 seconds of going back to logical 0”.
I know it supports PIR sensors which are Digital, so 1 and 0. Bu can these be linked to segments? Is a better approach to wire the “segments” as different strips on the ESP32, and assign them to the sensor activation logic?
Everything you’ve described is doable within WLED.
When you physically wire your strip to WLED, it presents the entire strip as one long length.
You control smaller section within that length by defining Segments that have a Start # within the main strip and a Stop # which is a count of how many LEDs in that segment (see: Segments in the KB).
You set a particular segment to a colour/brightness/effect you want and then save that as a Preset. You can trigger the Presets you create either manually or via an input switch/button/PIR/Sensor (see: Buttons ). Presets can also be combined into a timed Playlist, which is just a sequence of Presets.
WLED will still present your setup as one long strip whether you break it into multiple sections or not. The main reason to break it up would be to reduce the total LED count on a single GPIO so that you can keep effect speed at the maximum possible (see: Multistrip).
The one area that can become tricky is the logic you want to have behind all your various sensors. It can be tricky to handle multiple sensors simultaneously. I would suggest you setup a small testbed with perhaps 30 LEDs and see how you can setup and control small segments.
You can also just use WLED by itself with the “Peek” function to simulate LEDs, but that isn’t always a good example of how LEDs respond in the real world.
OK, so basically create 7 segments and assign these to presets. Trigger the presets via the “buttons”. Thank you for the explanation. I don’t currently have the hardware bought and I am in the research phase atm.