atuline / WLED

Control WS2812B and many more types of digital RGB LEDs with an ESP32 over WiFi.
GNU General Public License v3.0
869 stars 131 forks source link

Cannot change the LED Preferences when total number of LEDs > 1500 (1D, after configuring 3 outputs) #245

Closed Patrickpopp closed 1 year ago

Patrickpopp commented 2 years ago

What happened?

I connnot change the led preferecnes. When i make changes and hit save nothing happens and then when i go back and back in the changes are gone. In the main branch it works so now if i whant to change something i flash the main branch change the settings and change back.

To Reproduce Bug

I use the quinled dig quad and after configuring 3 outputs with about 400 leds each and make a segment for each output i am not able to change the led preferences anymore

Expected Behavior

I can make changes on the led preferences and save them.

Install Method

From SoundReactive Release Page https://github.com/atuline/WLED/releases

What version of Soundreactive WLED?

WLED SR version 0.13.3 (build 2210301)

Which microcontroller/board are you seeing the problem on?

ESP32

Relevant log/trace output

No response

Anything else?

No response

Code of Conduct

softhack007 commented 2 years ago

Could it be that you tried to use a GPIO pin that is already configured in sound setting or other usermod settings? Like GPIO 14, 15, 32 or 36?

Patrickpopp commented 2 years ago

Could it be that you tried to use a GPIO pin that is already configured in sound setting or other usermod settings? Like GPIO 14, 15, 32 or 36?

I´m using pins 16, 3 and 1 and im not using any usermods or button pins. Sound is set on pin 36

softhack007 commented 2 years ago

Sorry I still cannot reproduce your problem. I've just configured 4 LED strips on my generic ESP32 board, then changed segments, then changed LED setting, and added a 5th LED pin. No problems. In general, there is not difference between "upstream" WLED 0.13.3 and SR 0.13.3 in the LED preferences code, so it must be something specific related to your setup.

Can you give some more details?

Patrickpopp commented 2 years ago

I installed it via OTA. I cannot save it when i do any change like boot preset, led length or diffrent pins. and it does not matter if it is 13.2 or 13.3. it happens in both i have this problem on 23 controllers and i had one working and after loading that config in another one and at first it was working and after changing some settings and segmants it stopped working again.

Wled Sound Wled info Wled config 2 Wled config 1
softhack007 commented 2 years ago

Please add the info page from SR 0.13.3.

It contains more information that could help us to understand what's going wrong. Maybe you also need to contact quindor, as it might be something specific to his board design.

Patrickpopp commented 2 years ago

Bild_2022-10-31_132150503

softhack007 commented 2 years ago

i had one working and after loading that config in another one

Not sure if "loading the config into another controller" is supposed to work at all. Please check if the WLED knowledge base has some information about this.

Can you take one of your 23 controllers, and start completely fresh?

  1. do a clean install of SR 0.13.3 from here: https://wled-install.github.io/
  2. make all necessary setting in the Web UI - without restoring anything
Patrickpopp commented 2 years ago

I used the Backup configuration an load configuration Feature. I am not on sight so I cannot reflash them at the moment. But I try to reproduce the error on one esp I have here

softhack007 commented 2 years ago

Edit: it might help if you could upload your cfg.json and presets.json from the controller that shows the problem. No worries about wifi passwords - they are stored in another file that is not included when you make a backup.


you might also want to join the discord, to get help from the WLED community. Maybe there is someone who already experienced your problem and knowns how to best solve it.

Join Discord to discuss beta testing of our sound reactive fork of WLED.

Join Discord to discuss AirCookie's WLED.

Patrickpopp commented 2 years ago

presets.txt cfg.txt

Patrickpopp commented 2 years ago

I recreated it with a fresh install. Setup 556 leds on 3 outputs with pins 16, 3 and 1 save. Go back to main page and manually set up 3 segmens each 556 big. Now try to change the settings and its broken.

Wled manual segment Wled first change Wled new setup
softhack007 commented 2 years ago

OK, thanks. One idea: as GPIO#1 is also "Serial TX" and we have very few Serial.print() still in the SR code and in external libraries ...

If you avoid using GPIO#1 for LEDs, does that make a difference? It could be that the serial USB driver is hung, because NeoPixelBus wants to use SerialTX exclusively for LEDs.

Patrickpopp commented 2 years ago

when i use 16, 3 and 4 it also breaks. but 3 ist also a serial pin if i read the pinout correctly

Patrickpopp commented 2 years ago

when i use 16, 3 and 4 it also breaks. but 3 ist also a serial pin if i read the pinout correctly

but it also braks with 16,12 and 4

softhack007 commented 2 years ago

but it also breaks with 16,12 and 4

so no luck ... guess we'll need to take some time and look in detail at your cfg.json and presets.json.

Patrickpopp commented 2 years ago

okay, but it also happens with no presets so it schoul only be the config. here it is from my last try cfg (3).txt

softhack007 commented 1 year ago

Update: I can reproduce the behaviour.

The following error appears in debug console (M$ Edge, dev tools) when I click on "save" in LEDs settings: image

https://github.com/atuline/WLED/blob/e7d5a04aa455410ae4519499abd01d29548942cd/wled00/data/settings_leds.htm#L548-L557

https://github.com/atuline/WLED/blob/e7d5a04aa455410ae4519499abd01d29548942cd/wled00/xml.cpp#L409-L410

https://github.com/atuline/WLED/blob/e7d5a04aa455410ae4519499abd01d29548942cd/wled00/xml.cpp#L501-L504

@ewoudwijma or @THATDONFC, can you take a look?

Edit: this part in cfg.json could be related:

"somp":0,"mxw":1668,"mxh":1,"mxp":0,"mph":1,"mpv":1,

the UI has min="1" max="1500" but the value of mxw is 1668.

softhack007 commented 1 year ago

Update: After changing to max="15000" in this line - and npm run build - I can save the LED settings page. https://github.com/atuline/WLED/blob/e7d5a04aa455410ae4519499abd01d29548942cd/wled00/data/settings_leds.htm#L550

However this will only cure the symptom, as max=1500 was surely picked for a good reason ....

softhack007 commented 1 year ago

Fix included in latest v0.13.4-beta release