Use beacon and gps for EK3_Pos_SRC switch

Hello everyone:
Recently, I used the NooPloop manufacturer’s device for switching between beacon and GPS positioning during flight tests. However, during flights with beacon positioning, there was an issue of oscillation, and the drone couldn’t maintain a stable position. After making some adjustments to the code and setting the beacon’s position, I observed that the oscillation issue disappeared, and the drone could hover stably. However, a new issue emerged – when switching from beacon to GPS as the data source, the aircraft could still maintain a stable position (though the position in Mission Planner showed a sudden jump of over 70 meters). Yet, when switching back from GPS to the beacon, the drone could no longer hover and would drift in one direction.

Upon inspecting the log data, I found that the PosX and PosY data under the BCN (beacon) tag remained within normal ranges. However, in the XKF0 tag, the BPN (beacon position) and OFN (offset) values showed significant variations. I suspect that this might be the root cause of the issue.

I’m seeking assistance to understand why the beacon data in XKF0 is inconsistent with the position data in BCN.


new update

In the pares_node_frame2 method, I just print the pos_err like in the upon pic, I found the NoopLoop device has very large precision error values that are returned, and then I contract with the Official team, They say this EOP value should only be used as a guide and does not provide accurate data
So I changed pos_err to a const value of 0.2
And I did other fly to test again, I found that before I switched the Pos Source of EK3 everything was ok

Once I started switching data sources, the location information started to suck again