pathfinder-for-autonomous-navigation / psim

Six DOF flight simulator and related GNC implementations.
MIT License
4 stars 6 forks source link

GPS, Gyroscope, and Magnetometer Sensor Models #278

Closed kylekrol closed 3 years ago

kylekrol commented 3 years ago

GPS, Gyroscope, and Magnetometer Sensor Models

Simple sensors models were implemented for the three sensors specified in the title above. Both the GPS and magnetometer models are just white noise models at the moment. We should moving forward add in dependence on the MTRs for the magnetometer model.

The gyroscope model is based off of Stewarts model he used during development of the attitude filter. It's a white noise model added on top of a hard offset (bias) that randomly walks over time.

All of the noise parameters are configurable via the simulation config prior to initialization!

I've attached some plots below showing the sensor model's error over time for the gyroscope and magnetometer. The command ran to obtain them was:

python -m psim -s 1000 -p sensors/gps,sensors/gyroscope,sensors/magnetometer -ps 1 -c sensors/base,truth/base,truth/deployment SingleAttitudeOrbitGnc

gyr gyr_err mag mag_err

kylekrol commented 3 years ago

This PR will be rebased onto master once #277 is merged.