File APIs for Java Developers
Manipulate DOC, XLS, PPT, PDF and many others from your application.
http://aspose.com/file-tools
Win a copy of Clojure in Action this week in the Clojure forum!
  • Post Reply
  • Bookmark Topic Watch Topic
  • New Topic

Accelerometer Problem.

 
Hardik Trivedi
Ranch Hand
Posts: 252
  • 0
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Hi Friends,

I am doing some stuff with accelerometer. I am able to access this sensor using Sensor Listener service.As you all know it gives three values X,Y and Z. Now what this values are.
I got some info from google. But still I am not sure about it.

Can anyone elaborate those three values to me? I want to detect that user is walking or not? I want to detect the distance the user has walked.

Please Help.
 
Peter Johnson
author
Bartender
Posts: 5852
7
Android Eclipse IDE Ubuntu
  • 0
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
I would suspect that the three values represent the acceleration in each of the three directions of a 3-D graph (you know, that boring geometry stuff you slept through in math class ;) ). My guess is that if you lay your phone flat, the X axis goes left/right relative to the device, the Y axis goes forward/backwards (or rather away from the top and bottom of the device), while Z is up/down (that is upwards from the screen or downwards from the back of the device). A simple app that displays the values should be able to verify this.

I google and found this post which seems to agree the directions: http://www.anddev.org/accessing_the_accelerometer-t499.html
 
Hardik Trivedi
Ranch Hand
Posts: 252
  • 0
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Thanks Peter...
 
I agree. Here's the link: http://aspose.com/file-tools
  • Post Reply
  • Bookmark Topic Watch Topic
  • New Topic