MoonModules / WLED

Control WS2812B and many more types of digital RGB LEDs with an ESP8266 or ESP32 over WiFi! MoonModules adds features on top of upstream.
https://mm.kno.wled.ge
European Union Public License 1.2
233 stars 71 forks source link

Implement WLED issue #3554 - [dis]respect LEDmaps when receiving UDP #191

Open spblat opened 2 days ago

spblat commented 2 days ago

Adapted from from my request #3579 in Aircookie/WLED which was resolved by #3554:

Is your feature request related to a problem? Please describe.

When a string of LEDs is operating independently, sometimes it’s helpful to use LEDmaps. When that same string is controlled using DDP/UDP, we may or may not not want the active LEDmap to affect the ordering of the LEDs.

Describe the solution you'd like In main branch issue #3554, a client-side setting was implemented which “allows to tell WLED to not respect LED maps for all realtime modes.”

Describe alternatives you've considered I considered alternatives in my original issue, https://github.com/Aircoookie/WLED/issues/3579

Thank you!

softhack007 commented 1 day ago

Hi @spblat, thanks for the pointer.

Actually the upstream (AC WLED) solution introduces a performance bottleneck in setPixelcolor(), so we'll need to find a different way to implement this feature in WLED-MM.

We'll look into it after the upcoming release.

For the time being, you could use a preset without ledMap and activate it before starting realtime mode.

softhack007 commented 1 day ago

PS: I think the "HTTP Request API" can be used to switch to a specific preset ID

&PL= | 1 to 250 | Applies entire preset

https://kno.wled.ge/interfaces/http-api/#presets

spblat commented 1 day ago

PS: I think the "HTTP Request API" can be used to switch to a specific preset ID

If you could use the HTTP or JSON API from one WLED to tell another WLED to change to a specific preset, that would be a perfect workaround. But I don’t think this is possible. The implemented fix in main WLED adds an option on the DDP receiving side to disregard its local ledmap when DDP receiving is active. Isn’t that as workable here as it is there?

softhack007 commented 1 day ago

main WLED adds an option on the DDP receiving side to disregard its local ledmap when DDP receiving is active. Isn’t that as workable here as it is there?

No it's not. It is technicially possible to do a similar change, but this change is in conflict with the performance improvements we did in MM.

As I explained before, the change in main WLED (aka upstream) would introduce a new performance bottleneck, while just supporting a very special use case.

That's what I meant when saying

Actually the upstream (AC WLED) solution introduces a performance bottleneck in setPixelColor(), so we'll need to find a different way to implement this feature in WLED-MM.

Edit: I didn't mean to say "its impossible". But we'll need to think about a more efficient implementation to add the same feature in MM - because reducing performance of setPixelColor() is not an option.

dosipod commented 1 day ago

I am also not in favor of doing that from the slave side as that does not solve the issue if we are using old builds for the slaves . Something we used from the master is create a blank ledmap and once it is activated then DDP worked as expected , seems dirty workaround but it means we could do that from master @softhack007 what do you think ? image