如何用加速度计和陀螺仪通过电话测量汽车的速度?

编程入门 行业动态 更新时间:2024-10-27 04:31:26
本文介绍了如何用加速度计和陀螺仪通过电话测量汽车的速度?的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧! 问题描述

我想知道汽车的当前速度并确定经过的路径.我有一部带有加速度计和陀螺仪的 Android 手机,它向我发送了数据.这是电话坐标系中的数据,可能与汽车坐标系不同.

I want to know current speed of car and make a passed path. I have an Android phone with accelerometer and gyroscope which sent me data. This is the data in phone system of coordinate that probably wouldn't the same as coordiante system of car.

如何将加速度和旋转转换为汽车坐标系?

How I can transform this accelerations and rotations to car system of coordinate?

推荐答案

一般问题的一般答案是no.加速度衡量速度的变化,因此您可以从加速度中获得最好的结果是速度变化.

The generic answer for your generic question is no. The acceleration measures the changes in the speed, so the best you could get from acceleration, is the speed variation.

要获得绝对速度,您必须拥有初始速度并将其添加到速度变化中:

To get the absolute speed you would have to have the initial speed and add it to the speed change:

v(t) = v0 + a*t

因此,如果您让汽车沿直线行驶,并且您的设备固定在汽车上,则可以轻松获得速度变化(尽管测量误差会累加并迅速导致差异)

So, if you would have a car moving along a straight line, and your device was fixed to the car, you could get easly the speed changes (although measurements errors will add up and quickly lead to discrepancies)

在实践中,你会在尝试实现它时面临许多问题,即:

In practice you will face many issues trying to implement it, namely:

  • 您需要根据与加速度相同的参考来确定初始速度.这将需要一些测量和大量的三角测量,因为您将从不同的传感器以不同的速率获得这两个值.
  • 汽车不会直线移动,因此您的加速度参考将不断移动(更多的是三角学和微积分).
  • 如果设备在用户手中,设备相对于汽车的运动会增加更多的计算(和累积误差).
  • You need the initial speed to be determinate based on the same referential as the acceleration. This would require some measurements and a lot of trignometry, as you would get both values from different sensores at different rates.
  • The car will not move in a straight line, so your acceleration referential will be constantly moving (a lot more of trignometry and calculus).
  • If the device is in the user hand, the device movements in relation to the car will increase even more the calculations (and accumulated errors).

问候.

更多推荐

如何用加速度计和陀螺仪通过电话测量汽车的速度?

本文发布于:2023-10-08 02:06:29,感谢您对本站的认可!
本文链接:https://www.elefans.com/category/jswz/34/1471201.html
版权声明:本站内容均来自互联网,仅供演示用,请勿用于商业和其他非法用途。如果侵犯了您的权益请与我们联系,我们将在24小时内删除。
本文标签:加速度计   陀螺仪   如何用   测量   速度

发布评论

评论列表 (有 0 条评论)
草根站长

>www.elefans.com

编程频道|电子爱好者 - 技术资讯及电子产品介绍!