EKF waiting for GPS config data Ardusub 4.1

I am getting this message in qgroundcontrol and it look like it comes from this bit of code in AP_NavEKF2_core.cpp

    // GPS sensing can have large delays and should not be included if disabled
    if (frontend->sources.usingGPS()) {
        // Wait for the configuration of all GPS units to be confirmed. Until this has occurred the GPS driver cannot provide a correct time delay
        float gps_delay_sec = 0;
        if (!dal.gps().get_lag(selected_gps, gps_delay_sec)) {
            const uint32_t now = dal.millis();
            if (now - lastInitFailReport_ms > 10000) {
                lastInitFailReport_ms = now;
                // provide an escalating series of messages
                MAV_SEVERITY severity = MAV_SEVERITY_INFO;
                if (now > 30000) {
                    severity = MAV_SEVERITY_ERROR;
                } else if (now > 15000) {
                    severity = MAV_SEVERITY_WARNING;
                GCS_SEND_TEXT(severity, "EKF3 waiting for GPS config data");
            return false;

I’ve tried to implement a Sublocus GPS like the AP_GPS_MAV. I can see the position is correct. I’m guessing the problem is with the get _lag() call. I’m not sure what that does or what I need to do to get that not to fail. Could I be missing something in my model?

I also don’t understand the test for now > 30000. now is always increasing.

I think that means “It’s been 30 seconds after boot and we still haven’t properly identified the GPS!”

It is hard to tell exactly what is wrong without having the code and hardware to debug.
Have you overridden the get_lag() function?

You can also try setting the parameter GPS_DELAY_MS manually

1 Like

That makes sense about the now test.

I saw the GPS_DELAY_MS after I made a fool of myself for posting this.


1 Like