-
Notifications
You must be signed in to change notification settings - Fork 16.8k
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
Catch FPEs on stm32, raise InternalError on same #11470
Conversation
nice! I think we need a test to run on stm32 boards (F4, F7, H7) to check the behavior. We need to make sure we keep flying after a FPE and get the right Inf etc |
@tridge I used a patch on a bench-test Pixhawk which did a floating-point division-by-zero when switching into loiter. The Pixhawk continued to run. I was considering adding an RC option to do it - but that's starting to feeling the "everything looks like a nail" part of ArduPilot. I was wondering whether we should not clear these flags, just look at them. That would be a little safer but lose the ability to count the number of floating point exceptions occurring. |
.... I should also point out that I'm not attempting to catch/handle the exception. These flags appear to be set regardless of any vectors, and clearing them shouldn't affect anything other than anybody else trying to monitor them. |
Worth testing with some simple lua scripts that would provoke these. I could easily see them creating a FPE which we then would be panicing the user with, but since it's a script it isn't nearly as worrisome. |
76424c1
to
1eae034
Compare
1eae034
to
66fdd75
Compare
Stopped clearing the FPE registers as per devcall discussions. |
bc153b2
to
7341776
Compare
7341776
to
0ebef0b
Compare
No description provided.