Here are some readings we found. Please read them to help your progress.
https://www.ardusub.com/developers/gps-positioning.html
https://dronekit-python.readthedocs.io/en/latest/guide/vehicle_state_and_parameters.html
https://dronekit-python.readthedocs.io/en/latest/
https://www.ardusub.com/developers/pymavlink.html
DataFaslh log
https://ardupilot.org/copter/docs/common-downloading-and-analyzing-data-logs-in-mission-planner.html
GPS Glitch detection
https://ardupilot.org/copter/docs/gps-failsafe-glitch-protection.html
EKF Control
MAVProxy GPS spoofing
https://github.com/ArduPilot/MAVProxy/blob/master/MAVProxy/modules/mavproxy_fakegps.py