-
Notifications
You must be signed in to change notification settings - Fork 29
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
Brownout reset problem. #12
Comments
@reddomon Are you sure it is brownout reset? Maybe connect the board to a computer, and see what the serial output is. I had random resets when homing before, turned out it was noise from the endstops that triggered the EN pin. Added a capacitor between the EN pin and GND and it helped to get rid of the resets. |
Thanks for your reply. Yeap I am pretty sure. Serial output says it is brownout reset. I will give a try with your suggestion. But if it was noise, why serial output says brownout reset.? :( |
I tried many things but did not solve my problem. added a cap between EN and GND pin that @vivian-ng suggested bu it did not work.added 100uf ceramic cap didint work, 100nf didbnot work, seperate 3.3 v powersupply did not work, seperate 5v powersupply did not work. I even soldered directly to esp32 module 100uf and 100nf caps bu it did not work either. I lost my mind. |
@reddomon BOR in my experience happens often when WiFi gets enabled (300-400mA current peak). If you can connect an Oscilloscope at the 3.3V rail. check the voltage when homing. A fast Multimeter might catch a voltage drop as well but often the voltage drop is very short. An other issue is the internal reference voltage on some rev of ESP32. |
@Aggebitter Hi. Wifi is not enabled and i tried 3.3v 5A Meanwell powersupply, but did not work. When i examine with oscilloscope doesnt catch any negative spike. Tried diffrent brand esp32. I will test again for 3.3v voltage drop. I think I have a clone card,because doesnt have any namings on it. |
@reddomon Are you able to connect to the ESP32 via serial terminal to see what are the error messages that are thrown when brownout occurs? If there is something like a stack trace that is thrown, it would help if you can get the stack trace decoded so that we can see where the error actually occurred. For my case, I had
And it seems to suggest an error occurred in
You can decode the stack trace using this tool. I suspect the issue is with how I2S handles |
I will try rightaway and add results |
@reddomon While you are testing, can you also try out this possible solution? Basically, it seems that there is an issue with using float calculation in the |
Hi @vivian-ng I tried divide 2 instead of 0.5f is working like a charm. 250+ homing cycles tried and no more brownout reset or any other reset issues. Thank you for your effort. Se you an another problem :). By the way I am working on an nextion display controller for marlin 2+. |
A double would do just fine too. |
You said that Fpu is not permitted on ISR, but double is performed by software so it is permitted. Thank you for your contribution @misan . |
@reddomon What I understood is that FPU registers are not saved during the ISR, so using the FPU is not allowed there. Both integers, longs, and doubles seem to work ok as they do not use the FPU. The integer solution is the fastest, but I mentioned this as in some other cases floating-point might be needed and using doubles may enable that (though it is slower). |
My bad, I forgot to add the link to why float cannot be used in interrupts. Crash in timer interupt when data type "float" is used This is actually a known issue for a while, but the Marlin firmware never really had ESP32 support until sometime last year, and I don't think many of us were playing around with coreXY+ESP32 and so this problem was not discovered for a while. Hopefully, someone can make the necessary changes and push a PR back to MarlinFirmware. Maybe encapsulate the changes inside #ifdef ESP32 statements so that it does not affect other platforms. I would do it if I could, but unfortunately, my fork of Marlin is based on luc's and we are still pending decision on how his fork can be merged back to Marlin. |
Hi, i am experiencing brownout reset issues. I double check power module, use 10A 5V and even splitted esp32 from 5v and powered 5A 3V but nothing changes. When homing, randomly brownout reset occurs but when printing begins prints perfectly and no brownout reset. PS I added directly a 100uf cap on esp32 module power pins.
The text was updated successfully, but these errors were encountered: