-
Notifications
You must be signed in to change notification settings - Fork 819
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
CORRUPTION in display of SSID and construction of discovery config strings #2012
Comments
Interestingly, on looking closer some but not all discovery config messages are corrupted. It's hard to find a pattern of which ones are vs. aren't. It's not device specific. |
Both with development version? |
Yes both development |
Let me summarize:
(Note my ssid itself has no weird characters -- it is of form myssid-2.4) Regarding corruption of the discovery config topic (only tested on lilygo-rtl-433 device)
SO seems like potentially 2 separate bugs...
The above is all reproducible going back and forth between versions. |
Note the above PR fixes ones of the bugs reported here (I initially thought they were related since they both involved corruption) but now I realize they are separate. I still haven't figured out why in there is sporadic corruption of the discovery JSON strings in the development branch (but v175 is fine). |
Interestingly, whereas before it would generate discovery topics for temperature, humidity, battery and rssi, now it generates all the humidity ones, some of the rssi ones, a couple of the temperature ones, and none of the battery ones.. What could be causing this???? |
Memory/concurrency issues due to the number of devices being processed. Try to play with the stack size for RTL_433, it may reduce/remove those. |
Any specific suggestions of what variables to try? |
OK - I was able to fix the problem of corrupted discovery data by reverting one of the recent changes to
Changing it back to:
eliminated the corruption of the discovery strings... HOWEVER reverting this causes the spurious spikes noted in to return #2014 Said another way:
Not sure how I can resolve one bug without causing the other to appear and vice-versa** Note I can understand why perhaps using Would appreciate some help and insight in debugging this further :) Thanks! |
One other thing that may be concerning (but seems to work ok now) is the newly added lines:
If this is meant to copy the uniqueID, I am concerned that 25 chars may not be enough as I already have some entities with UniqueID names longer than 25 chars, such as |
The above PR fixes the second of the 2 issues initially listed in this bug report. Rather than bypassing the queue by just publishing directly, it would be helpful to figure out why it is failing... |
… access Protecting mqtt->publish() fixed the problem with corruption of MQTT discovery config messages 1technophile#2012
Protecting mqtt->publish() fixed the problem with corruption of MQTT discovery config messages #2012
…ile#2034) Protecting mqtt->publish() fixed the problem with corruption of MQTT discovery config messages 1technophile#2012
Describe the bug
I just upgraded to the latest dev branch and am finding two potentially related errors:
Note: The problem is not due to my discovery_prefix patches since I reverted and still see the problems
Note: I also noted it on 2 different devices (lilygo-rtl-433 and esp32dev-ble)
In the WebUI, under "Configure WiFi" the WiFi network name appears as gibberish characters -- this persist even if I re-name the network. Note that the stored name must be working since it attaches to the correct network.

Separately, but perhaps related, looking at the discovery topic config lines (via mosquitto_sub), there is gibberish and over-writing in the value of the 'stat_t' key.
For example:
It as if it the components constructing the json string are pointing to the wrong elements of memory since the resulting json string looks like a combination of a valid discovery topic config keys & values PLUSsome elements of a published data topic PLUS some elements of the config string of another entity for the device -- all mashed together.
Note that it should look something like:
To Reproduce
Compile latest dev branch
Expected behavior
See above
Screenshots
See above
Environment (please complete the following information):
Development
The text was updated successfully, but these errors were encountered: