PX4-Autopilot
PX4-Autopilot copied to clipboard
introduce per GNSS instance configuration parameters (SENS_GNSSi_POS_{X,Y,Z})
- https://github.com/PX4/PX4-Autopilot/issues/15683
TODO:
- [ ] GPS blending incorporate antenna offsets
- [ ] GNSS priority parameter handling (replace SENS_GPS_PRIME)
- [ ] review parameter naming (SENS_GNSS0_XPOS -> SENS_GNSS0_POS_X?)
- [x] ekf2 add offsets to GPS sample ringbuffer
- [x] enable blending by default?
@JonasPerolini
Let's get this finished.
I think it looks good. I still don't like the GPS blending, and I like it even less with the offsets added in, but at least this proper handling of metadata is one step closer to a better system (no blending -> direct EKF fusion of GPS data).
Why do you like the blending even less with the offsets added in?
TODO: respect per GNSS configurable priorities? (if blending disabled)
@dagar Should we maybe just leave the GNSS blending question for another day (not a regression anyway) and merge the rest of the PR?
GPS blending is not the preferred method of using multiple GPS now that we have the ability to run multiple EKF and select based on EKF health and innovation levels. We will need to evaluate the current practice of being able to switch to another EKF that has a significantly smaller test ratio even if the current selected EKF is not failing innovation consistency tests. This will become more of a problem if one EKF has RTK GPS and the other doesn't because the non RTK GPS will have larger innovation variances and therefore could have smaller test ratios despite being more accurate.
Hi @priseborough, I also agree that GNSS blending is not best, however I don't understand the proposed multiple EKF strategy. Why do we need to run multiple EKF in parallel and chose the best one based on a criteria? Is there a blocking point for fusing both GNSS measurements in the same EKF? With a single EKF there is no issues if one unit has RTK and the other does not. The GNSS unit with the lower variance will have a greater influence in the final estimation.
Hi @priseborough, I also agree that GNSS blending is not best, however I don't understand the proposed multiple EKF strategy. Why do we need to run multiple EKF in parallel and chose the best one based on a criteria? Is there a blocking point for fusing both GNSS measurements in the same EKF? With a single EKF there is no issues if one unit has RTK and the other does not. The GNSS unit with the lower variance will have a greater influence in the final estimation.
Separation between GPS solutions can significantly exceed the reported position and height uncertainty when there is multi-path or they are using different satellites. This can cause the EKF state to jump as each measurement is fused or worse, one GPS will fail consistency checks and be rejected.
For larger drones with two GNSS units, it's crucial to have an offset for both antennas. Even if the blending is not enabled, if the main GNSS fails, falling back to the secondary GNSS with a wrong offset will cause issues (jump in the global position, velocity loop oscillations). I can provide some help to move this PR forward. What's the current status @dagar ?