Terminate after offboard switching

We have been flying with this setup for a few months and this issue is new for us.

When the drone was on pos mode we shitchet to offboard and it entered in terminate mode, drooping to the ground. we have made a deep investigation, however i cant added in the forum due to max character limit, but if anyone is interested i can share the drive.

we were flying with the magnetometers disabled, because we had magnetic interference issues before, so the EKF2_mag_type was using accelerometer and gps for heading.

On the crash log There are temporal jumps (time-jumps) in vehicle_gps_position_0 which precisely coincide with the loss of data in the graphs. From that point on, after 100 milliseconds, we start losing data in other graphs, such as acceleration. This is because the data displayed by the graphs is the data processed by the EKF (Extended Kalman Filter). This means that if GPS data is not received, the EKF fails.

The system termination (terminate) appears to be triggered when it receives the attitude invalid failsafe. This can be verified using the following resource: https://docs.px4.io/v1.14/en/config/safety_simulation.html

This seems to be caused because upon losing GPS data, and not having the magnetometer enabled, the attitude is calculated relying on that GPS data. Consequently, the system cannot estimate the heading (yaw), leading to the failsafe condition.

isn’t this a poor reliability sistem when not using magnetometers?

hope anyone can help us!

Crash Log