psiphi75/ahrs

Kp and Ki different?

Closed this issue · 4 comments

rclai commented

I noticed here that these values are different on other libraries in other languages like here, is there a reason why? Are those values supposed to be adjustable?

Thanks, it's fixed. It was due to me testing the Mahony algorithm when I first ported it. But I tend to use the Madgwick algorithm instead.

rclai commented

Thanks, but on second thought, I just saw that on the original AHRS code by x-io, you can actually pass the Kp, Ki, or both optionally and they default to 1.0 and 0, respectively. So I was misguided by looking at the C porting of the code that I mentioned above.

Is that something you can build in?

Fixed. There were other problems with the algorithm which have been fixed as well. Default value for Kp/Ki are 1.0/0.0.

rclai commented

Cool, thanks.