I'm using the Adafruit Mahony / Madgwick AHRS filters to get quaternions (Euler angles to better understand output), using a calibrated BMX160 sensor. I'm polling the sensor at 100Hz.
I've read through the documentation and scoured the web, but couldn't find an explanation (at least not one without heavy mathematics) for how to select the beta and gain values for Madgwick, or the proportional and integral gain for Mahony respectively.
Only one forum post which suggested that (beta*sampleFreq)~=50 to 60 for madgwick.
I'm sorry if this is coming across as lazy, I really tried, but couldn't figure out a solution on my own. I'm slowly revising my maths, but don't think I'll ever get to the point of fully understanding the filters
I'll have a go at the link you forwarded, but from an initial look the maths is above my paygrade for now. So until I get to grips with it I suppose I'll have to just experiment, if there's no rule of thumb I can follow, e.g. for 100Hz data rate, X beta sort of relationship.
The experimental approach is fine. The serial plotter can be used to display angles, but print at the highest possible Baud rate, and not too often, or the loop time will become very slow, and the filter integration step will fail.