GPS denied navigation not working

Hi,
I am following the official guide to setup GPS-denied navigation on Ardupilot 4.1

I also followed the blogs series

but when I start the SITL and launch the set_orgin.py script. I enter the guided mode and try arming the copter I get the following error

FCU: PreArm: GPS and AHRS differ by 4916254.m

since I have disabled GPS, I am confused why there is a comparion between GPS and AHRS.

thanks

This error, unfortunately, means that the GPS is not completely disabled yet. See this topic for reference. Have you tried all of the related parameters Indoor Flying Guidelines — Copter documentation ?

If you are familiar with the advance params list, this error is related to ARMING_CHECK_GPS of the arming check procedure.
Hope this helps.

Hi, Yes, I have changed all the params mentioned in the docs and If I disable the arming checks, I am able to fly the copter in guided mode in SITL. I’ll look into the resources you mentioned and see if I can resolve it.

thanks @LuckyBird

Hi, I set the AHRS_GPS_USE param to 0 even after that I am getting the same error i am ble to fly only if I disable gps checks in pre arm checks, which is not ideal i guess

thanks

Hi, @LuckyBird can you reproduce this error?
thanks

I think you need to disable GPS_TYPE as well.
Otherwise, if GPS is not used then disabling the associated prearm check should be fine.

Hi, I have disabled all the params mentioned in docs, and GPS_TYPE is one of them

thanks