"Error pos horiz variance" while using PX1122R RTK GPS

Hello,
I am trying to use the RTK GPS based on PX1122R by NavSpark.

Hardware : Pixhawk 2
Firmware: Copter 4.2.2
Frame Type : Quad X
Frame size : 290mm diagonal
GPS1 on serial3 : UBlox M8N
GPS2 on serial4 : PX1122R NS-HP-GN2 @ 230400 baud and 5 Hz update rate. Only the GGA, RMC and VTG sentences are enabled as Ardupilot only uses these. The other sentences such as KSXT and PHD are not available on PX1122R. It does not report the vertical velocity.

The GPS is verified and provides a good rtk fixed solution.
However, when we connect it to pixhawk and move the copter around (by hand without flying it, as we are not very confident yet that it will work), the GPS position drifts when we take a turn or if there is a velocity change. The horizontal position and velocity variance goes very high and results in “Error pos horiz variance”. The position and velocity innovations under XKF3 shoot up as well.

There is no horizontal position drift when copter is stationary on ground or if we move it very very very slowly.

Please refer to the graph below taken from flight controller logs. The vehicle was moved manually by hand. No actual flight was carried out.
It shows the GPS Lat (Red) with the EKF estimated Lat (Green) when using PX1122R.
You will observe that there is a difference in estimated position when we change direction of movement or the velocity is changed.
We did not use any RTK correction here. The raw GPS readings are consistent with movement. The number of satellites was 25.

To verify that there is no problem with the setup, we carried out similar experiment with UBlox M8N GPS receiver. the graph below shows same parameters for Ublox M8N. The vehicle was moved manually by hand. No actual flight was carried out. The GPS Lat (red) and estimated Lat by EKF (Green) do not have such a large difference even when the direction of motion and velocity changes. We are using the same setup. Just the GPS is switched by enabling / disabling appropriate ports.

We have tried following things

  1. Ensure that GPA.delta is under control
  2. Use GPS_DELAY_MS 30ms, 40ms, 50ms, 60ms, 70ms, 80ms, 90ms, 100ms, 120ms, 180ms
  3. Use EKF2 instead of EKF3
    However the drift in horizontal position is not going away. I repeat, this happens only when there is sudden change in velocity or direction of motion.

The logs can be found here for your reference.
https://drive.google.com/file/d/1WsnRqiyQw3QRLXUWM2Uk4aJLhyJyh8re/view?usp=sharing

Hope someone can point me in right direction.

Best
Anant

1 Like

Hi @Anant

I also get the same error in my quadcopter. I just wanted to know if you have found any solution to this yet. I am using the M8N gps and there is no magnetic interference and the satellite count is around 15 always.

Regards
Numair

Can you post a log (.BIN)?

Not sure this can help, probably not, anyway: I’ve been testing with GPS a lot and it seems that GPS_NAVFILTER settings impacts frequency of messages sent by GPS despite GPS_RATE_MS settings (but must confirm this by spoofing GPS serial there) at least here with the MN-880 GPS module. Like if I play with navigation output filters (static hold t. and static hold exit dist), specially trying pedestrian profile makes EKF crazy, even just hovering in loiter (no position change).

Perhaps measuring the real frequency GPS is sending messages looks like interesting thing to check