I have a device with an IMU6 sensor. When it is laying on the table, the gyroscope and accelerometer data are constantly changing. The values between two measurements are similar, but they are never equal. There is always noise.
I need a formula for calculating the real angles to which the device was rotated if rotation has really happened. This will be used for game controlling, so I need as small an input lag as possible (I can't accumulate inputs to a buffer and then smooth them; that will give too big a delay).
How do I calculate the real rotation angles?