psiphi75 / ahrs

AHRS (Attitude Heading Reference Systems) calculation for JavaScript
Apache License 2.0
87 stars 16 forks source link

Is this possible to get the position difference or the distance the device was moved from the initial point? #18

Closed arthedza closed 3 years ago

arthedza commented 3 years ago

Or at least the device rotation angle from the initial attitude.

psiphi75 commented 3 years ago

Is this possible to get the position difference or the distance the device was moved from the initial point?

No, not with this library. I have to say I don’t know what library is available for that. Doing it by first principals should work.

Or at least the device rotation angle from the initial attitude.

Same as previous answer. Using first principles you would sum the gyroscope values for each axis and multiple by elapsed time.

arthedza commented 3 years ago

Thank you for your fast response. And I have one more question: what algorithm I should choose for this purpose?

psiphi75 commented 3 years ago

That depends what you want to do. What angle of rotation do you want to measure and about which axis? Can you make the angle of rotation always be around one axis only? Then you can use this library. You just start measuring the angles.