GV

GeezerVison

The World Wide Web, restored to 800 pixels of glory.

Home|About|Gaming cabinet|Archives|How it works|Starter sites

On this site

  • Sign in
  • ActionsCI/CD and automation
  • CodespacesCloud development environments
  • All Features
  • Documentation
  • Training
  • Certifications
  • Build with Copilot
  • Customize Copilot
  • Integrations
  • Trending repos
  • GitHub Sponsors
  • Developer articles
  • Enterprises

This view

  • Original page
  • New address

GeezerVison is showing github.com — GitHub - alspitz/complementary_filter

BranchesTags
Open more actions menu

Latest commit

 

History

8 Commits
8 Commits

Folders and files

NameName
Last commit message
Last commit date
media
media
 
 
.gitignore
.gitignore
 
 
LICENSE
LICENSE
 
 
README.md
README.md
 
 
accel.py
accel.py
 
 
est.py
est.py
 
 
gyro.py
gyro.py
 
 
main.py
main.py
 
 
param_tune.py
param_tune.py
 
 
utils.py
utils.py
 
 

Repository files navigation

2D Complementary Attitude Filter Simulation

This implements a 2D complementary attitude filter for the purposes of analyzing how accelerometer and gyroscope noise affects attitude estimate accuracy.

Supports

  • Gaussian accelerometer noise
  • Gaussian gyroscope noise
  • Brownian motion gyroscope bias drift

Run python main.py --help to see a list of available parameters and their default values.

Run python param_tune.py to see a plot of attitude error vs. accelerometer weight.

Sample Results

Parameter Sweep

Here we attempt to find the best value of the accelerometer weight by plotting the error for a series of values.

Keep in mind that the best value will depend heavily on the noise properties of the accelerometer and gyroscope data.

Sweep Results

We see that the best value of the accelerometer weight is somewhere around 0.05. The sweep can be refined by searching over more values as well as computing standard deviations of the error for each parameter value.

Low Accel Noise, Low Gyro Noise

python main.py  --gyro-stddev 0.01 --accel-stddev-x 0.01 --accel-stddev-z 0.01
Mean abs error is 0.000424 radians (0.024310 degrees)

Low Accel Noise, High Gyro Noise

python main.py  --gyro-stddev 1.0 --accel-stddev-x 0.01 --accel-stddev-z 0.01
Mean abs error is 0.004991 radians (0.285978 degrees)

High Accel Noise, Low Gyro Noise

python main.py  --gyro-stddev 0.01 --accel-stddev-x 0.5 --accel-stddev-z 0.5
Mean abs error is 0.013562 radians (0.777072 degrees)

High Accel Noise, High Gyro Noise

python main.py  --gyro-stddev 1.0 --accel-stddev-x 0.5 --accel-stddev-z 0.5
Mean abs error is 0.014568 radians (0.834661 degrees)

These results suggest that gyroscope additive noise has a much lower effect on attitude error than accelerometer additive noise, likely because all gyroscope measurements are multiplied by the sampling time (dt).

Results Error Accelerometer Data Gyroscope Data

About

No description or website provided.

Topics

accelerometeraccelerometer-and-gyroscopeattitude-estimationcomplementary-filtergyroscopeimuimu-sensororientation-estimationorientation-sensor

Resources

Readme
MIT license
Activity

Stars

2 stars

Watchers

1 watching

Forks

2 forks
Report repository

Releases

Packages

Contributors

Languages

You are visitor 01402775 — GeezerVison does not store the pages you look up.
Best viewed with Netscape Navigator 4.7 or Internet Explorer 6 at 800×600. No cookies required.