-
Notifications
You must be signed in to change notification settings - Fork 28
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
Ringbuffer library has issues with ESP32 #29
Comments
is this bug still valid ? drvkmr what was the fix you made ? can you share ? |
Yes I simply eliminated the use of ring buffer which fixed the issue. Here is the fork if you want to try out. |
anyone ported to esp-idf ? |
I tried your fork (thanks for that) but you didn't update the example which still uses the ring buffer, and you didn't provide a working working example of how to get the packets now. Can you update the example so it uses no ring buffer? Thanks :) |
@UnexpectedMaker I'll do that later this week. Btw love your boards! |
Oh, thanks for the quick reply!!! |
Hey @UnexpectedMaker , do you want to try it now? |
Hello,
This has been already mentioned in #8 , I spent a significant amount of time trying to figure this out.
Basically the problem is with using ringbuffer which for some reason breaks ESP32 sooner or later. Apparently it's because of the way ESP32 uses multiple cores but I don't really knpw.
I am transferring a relatively large amount of data (24 universes), which works surprisingly well generally until it suddenly stops. It can happen within a few seconds or after a couple of minutes. The interesting thing is lot of other parts of the program still keep working and I have no clue why.
For a long time, I tried to fix the issue in my code, but eventually the warnings-
drew my attention I decided to get rid of ringbuffer. This took some time but once it was done there have been no issues even if I run at 60fps for hours.
I have a larger bytearray wsRawData in my code and am simply using memcpy in the callback like this -
Here packet is sbuff (which I made public) not pbuff.
Now I don't know what's the best way to fix this for the library itself because my implementation is similar to #9 but it does force you to go to a lower level and deal with the data yourself which is not ideal.
I found this from Espressif but not sure how to implement this or if it's even possible.
The text was updated successfully, but these errors were encountered: