-
Notifications
You must be signed in to change notification settings - Fork 13.7k
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
Memory and mavlink problems pixhawk v2 #12502
Comments
You're running out of RAM. You need to either stop some modules (unused mavlink instances for example), or get newer hardware with more RAM (e.g Pixhawk 4) The Silicon Errata warning is about Flash, and is unrelated to the issues you're seeing. |
But it's standard px4 1.9.2 code. |
BTW "free" returns: nsh> free It seems there is some free RAM. |
Can you post logs from before and after your extras script runs? @dagar FYI |
Case 1 (happening at random, can't open ACM0):
Case 2 (happening at random, out of memory):
|
What's on you SD card? Can you format it and try again? |
There are only extras and logs. |
All the errors involve the sdcard. What size is it? How is it formatted? Do you have another you can try?
|
It's a Kingstone 4Gb that ships with pixhawk. |
mmm I said hurray too early. The problem is still there. It worked 3 reboots and now again at random. |
@tuloski can you see the log output when it fails? |
In the SD? |
No, that would be with a console connected: https://dev.px4.io/en/debug/system_console.html |
Yes, actually what I wrote in Case1 and Case2 are console outputs. Also when it fails I see it. |
Oh, sorry I missed that. |
Adding some usleep of 0.5s here and there in the extras.txt seems to solve the issue. |
That's odd though because when it fails it doesn't even mount the SD card (from what I see in the log above). |
This issue has been automatically marked as stale because it has not had recent activity. Thank you for your contributions. |
I noticed that my pixhawk v2 was having some problems, so I hooked up the console in telem 4/5.
What I see at random are different problems:
Revision A has a silicon errata:
This device can only utilize a maximum of 1MB flash safely!
https://docs.px4.io/en/flight_controller/silicon_errata.html" but I havn't found any way to fix it.
And it's not only a warning because later this happens:
"nsh: mount: mount failed: Out of memory
nsh: mkfatfs: mkfatfs failed: Out of memory"
what happens sometimes at random is this error:
"INFO [mavlink] all instances stopped
INFO [mavlink] mode: Custom, data rate: 50000 B/s on /dev/ttyACM0 @ 1000000B
ERROR [mavlink] could not open /dev/ttyACM0
WARN [mavlink] mavlink for device /dev/ttyACM0 is not running
WARN [mavlink] mavlink for device /dev/ttyACM0 is not running
WARN [mavlink] mavlink for device /dev/ttyACM0 is not running
WARN [mavlink] mavlink for device /dev/ttyACM0 is not running
WARN [mavlink] mavlink for device /dev/ttyACM0 is not running
WARN [mavlink] mavlink for device /dev/ttyACM0 is not running
"
I really don't know where to start fixing it. Can it be all related to memory issues? Why isn't it able to open /dev/ttyACM0 sometimes?
PS: I tried to update the bootloader with https://docs.px4.io/v1.9.0/en/advanced_config/parameter_reference.html#SYS_BL_UPDATE without any success.
The text was updated successfully, but these errors were encountered: