如何获得加速度计轴和运动矢量之间的旋转? [英] How to get the rotation between accelerometer's axis and motion vector?

查看:173
本文介绍了如何获得加速度计轴和运动矢量之间的旋转?的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

我正在研究Android上的行人导航系统.我目前正在尝试获取3轴加速度计参考值与应用于设备的运动之间的旋转矩阵.

I'm working on a Pedestrian Navigation System on Android. I am currently trying to get the rotation matrix between the 3-axis accelerometer referential and the motion that is applied to the device.

假设您用手拿着设备向前走,但是加速度计的Y轴(因此设备的Y轴)的方向与您要朝向自己的方向不同(基本上就是笨拙地握住设备).然后,如果我要应用距离(基于步距检测),将其应用于加速度计参考点(我知道其方向)将是错误的:必须根据运动方向进行相应的旋转.

Let's say you are walking straight forward with the device in your hand, but the Y axis of the accelerometer (thus the device's Y axis) is not oriented in the same direction as the one you're heading yourself (basically you're holding the device in an awkward way). Then if I want to apply distances (based on step detection), it would be wrong to apply them to the accelerometer referential (which I know the orientation) : it has to be rotated accordingly to the motion heading.

这就是为什么我想知道您是否可以启发我有关一种计算加速度计读数以将其转换为旋转角度(或矩阵)的方法.这种方法必须避免一次积分加速度,因为这种误差在廉价的加速度计上是很深的(否则我认为这很容易实现).

This is why I would like to know if you could enlighten me about a method to compute the accelerometer readings to turn them into rotation angles (or a matrix). Such a method has to avoid integrating the acceleration even once, as the error is abyssal on cheap accelerometers (otherwise it would be pretty easy to perform I think).

磁力计和陀螺仪即使在静止状态下也可以帮助您找到设备的方向,但不允许您知道设备向哪个方向移动.我有第一个,我在寻找第二个.基本上:

EDIT : Magnetometer and Gyroscope help you to find the device's orientation even when stationnary, but doesn't allow you to know in which direction the device is moving. I have the first one, and I'm searching for the second. Basically :

人体参考(运动方向)->设备参考(或加速度计参考)->地球参考

Human Referential (motion direction) -> Device Referential (or accelerometer referential) -> Earth Referential

并且我正在寻找找到旋转矩阵以计算从HR到DR的距离的方法,然后将其应用于我发现从DR到ER的旋转矩阵.

and i'm searching the way to find the rotation matrix to compute distances from HR to DR, which I would then apply to the rotation matrix I found to go from DR to ER.

推荐答案

我发现了一篇可能有用的文章,这是

I found an article which might be useful, here is the link.
The Idea is based upon acquiring the accelerometer data in the 3 axis, (which is an n times 3 matrix) and finding the PCA (principle component analysis) of the matrix. The PCA is the 3 vectors with the highest energy of the matrix).
Idealy, the main vector (with the highest energy) direction is upwards, and the second is the heading direction. You can read it all in the article. I tried implementing the algorithm in matlab, the result is o.k. (not great) Hope you can do better (I would like to hear about good results).

希望这会有所帮助

Ariel

这篇关于如何获得加速度计轴和运动矢量之间的旋转?的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆