Skip to content
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

Fix: increase BT NIMBLE task stack size by 1k #2618

Merged
merged 1 commit into from
Jul 17, 2023

Conversation

mverch67
Copy link
Collaborator

Stacksize for task nimble_host is too small and leads to crashes when sending text messages from phone:

DEBUG | 21:27:08 12 [Screen] Add packet record (id=0xf0f7443c fr=0x00 to=0xff, WantAck=1, HopLim=3 Ch=0x0 Portnum=1 rxtime=1689542828)
DEBUG | 21:27:08 12 Original length - 2 
DEBUG | 21:27:08 12 [GPS] Compressed length - 2 
DEBUG | 21:27:08 12 [GPS] Original message - Hi 
DEBUG | 21:27:08 12 [GPS] Not using compressing message.
DEBUG | 21:27:08 12 [GPS] Using AES256 key!

***ERROR*** A stack overflow in task nimble_host has been detected.

This PR increases the NIMBLE task stacksize for all esp32 devices by 1k which will finally fix #2416.

@thebentern thebentern merged commit ad5de5a into meshtastic:master Jul 17, 2023
@thebentern
Copy link
Contributor

Great fix! This sheds some light on why I experienced multiple consecutive crashes when trying to send an arbitrarily large text message from the iOS app recently.

@mverch67
Copy link
Collaborator Author

Great fix! This sheds some light on why I experienced multiple consecutive crashes when trying to send an arbitrarily large text message from the iOS app recently.

Thanks, finally this annoying bug is solved. I had this problem with the heltec-tracker, where every message sent from phone lead to the crash. But luckily I spotted this error message about nimble_host task.

@thebentern
Copy link
Contributor

thebentern commented Jul 17, 2023

Thanks, finally this annoying bug is solved. I had this problem with the heltec-tracker, where every message sent from phone lead to the crash. But luckily I spotted this error message about nimble_host task.

Annecdotal... but it seemed to occur on the new S3 based devices much more frequently

@mverch67 mverch67 deleted the nimble-stacksize branch July 17, 2023 12:38
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

[Bug]: sporadic crashes when sending text messages via phone
2 participants