views:

52

answers:

1

HI, I am willing to implement a logic in which i need to know about the amount of motion made by phone on x y or z axis, using accelerometer i can only find acceleration on these axis, even if i try calculating the relative x coordinate value based on acceleration on x axis, its of no use as i cannot determine the direction of motion (i.e whether it was left movement or right) i must be missing on something.. it will be great if anyone could provide any pointers to this.. :) thanks in advance...

A: 

You should be able to get the sign of the acceleration, but integrating acceleration to determine velocity and integrating it again to determine position tends to give poor results, since errors quickly grow out of control.

Further, to make an IMU you need not only good accelerometers, you need 3 good gyros to determine the orientation of your accelerometers - and you don't have any, just a rather flaky compass sensor.

Chris Stratton
thanks for quick response, but i think that we cannot determine the position via accelerometers negetive or positive values as they are only telling abut the change in velocity... so even if i am moving in single direction i can find both negative and positive values on same axis... hence accelerometer does not seems to be my answer!
Abhinava
First, there is no answer to your problem with current or likely near future phone hardware. It's a cell phone, not a guidance system. In terms of the difference between acceleration and velocity, you need to understand from calculus that acceleration is the derivative of velocity, so that working backwards would be integrating - a process notorious for magnifying the measurement errors of cheap sensors.
Chris Stratton
mmm.. sorry but i strongly feel that there has to be a workaround available.. we already have applications like compass which can tell us the direction of our motion.. m not looking for any precision value.. i need data to work with!! basically i need a motion angle along with the velocity!
Abhinava
If that is your belief you are welcome to try... but there's a saying in the sciences: two months in the lab will save you a half hour in the library.
Chris Stratton