-
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
Mag timeout current master #7746
Comments
I suspect this is because both the land detector and the external mag (i2c) are running in the high priority work queue. The additional code in the land detector probably pushed it over the edge. I think we need some way to instrument the work queue and understand what's running in each and for how long. @davids5 FYI |
Here's the full log of the bench test: https://logs.px4.io/plot_app?log=7308ecce-8078-4c20-a458-d8461a9fe6e5 |
I want to instrument the work queues to understand what's happening, but I probably won't have time in the next day or two. Is this easy to reproduce on the bench? If so connect a console, run top, and note the HPWORK cpu usage. Then stop each of the following, noting HPWORK cpu usage after stopping each. This is a crude way of trying to understand what's happening in the high priority work queue.
|
There was only very little code added to the land detector, I would not expect that to be the cause. However many tasks such as pos ctrl, sensors, estimator & att ctrl have higher prio than HPWORK, and if they use a bit more CPU due to a land detector state change, they can all be the cause of that. |
@bkueng no change with prio 253 |
Interestingly when i force no landing detected (by keeping throttle high) it doesn't timeout. it really only times out when if actually detects a landing (see messages above). I checked cpu usage with and without land detector. with everything running it's at +- 1.5% repeating this test with land_detector stopped keeps lpwork at 0.07% |
another interesting observation: this only happens on vtol in FW mode. in MC mode it's fine Likely during FW mode the logic breaks down running the MC land detector |
@sanderux, thats possible. I am looking at the log right now |
I'm now testing with adding
|
I mean it clearly breaks down. It has landdetected all over the place. interesting that it did not crash |
it's a bench test. or did you mean the process? |
I have a fix |
why did the current changes have an effect on the FW mode? |
@Stifael i am getting intermittent mag timeouts that coincide with the land detector.
I did notice on our last test flights the mag timeout every time it actually landed.
On this vehicle it seems to give constant 'maybe landed' jumps that constantly coincide with mag timeouts.
Maybe this is reversing cause and effect but this behavior is gone when i flash stable.
The text was updated successfully, but these errors were encountered: