Results 1 to 3 of 3

Thread: Estimating Tilt with 3-axis accelerometer

  1. #1
    Newbie
    Join Date
    Mar 2007
    Posts
    1

    Estimating Tilt with 3-axis accelerometer

    Would it be possible to estimate tilt (pitch, roll, theta) using a 3-axis accelerometer in MDX?

    I'd be very interested in displaying a graph in MDX showing pitch and roll.

    I'm currently not much more than a novice in MDX and as of yet haven't got my hands really dirty...

    Does MDX support the trigonometric and power functions required to calculate the pitch roll and theta values? (Basic equations in a static context can be found in this PDF: http://www.freescale.com/files/senso...ote/AN3461.pdf)

    As an aside, would it be possible to use a button to calibrate the accelerometer based on a given position. i.e. I guess it would need to set three offset variables based on the current X, Y and Z values, these offset variables would then be used in a (root?) function to set the values of calibrated X, Y and Z variables? Had a quick look in the MDX UI and can't see if its possible to set a variable based on another variable, or if its possible to set more than one.

    Thanks

  2. #2
    Fusion Brain Creator
    Join Date
    Mar 2005
    Posts
    2,220
    Both are possible, but be advised you can't really use an accelerometer to measure that stuff when the vehicle is in motion

  3. #3
    Newbie
    Join Date
    Nov 2007
    Posts
    17
    Quote Originally Posted by mbdishon View Post
    Would it be possible to estimate tilt (pitch, roll, theta) using a 3-axis accelerometer in MDX?

    I'd be very interested in displaying a graph in MDX showing pitch and roll.

    I'm currently not much more than a novice in MDX and as of yet haven't got my hands really dirty...

    Does MDX support the trigonometric and power functions required to calculate the pitch roll and theta values? (Basic equations in a static context can be found in this PDF: http://www.freescale.com/files/senso...ote/AN3461.pdf)

    As an aside, would it be possible to use a button to calibrate the accelerometer based on a given position. i.e. I guess it would need to set three offset variables based on the current X, Y and Z values, these offset variables would then be used in a (root?) function to set the values of calibrated X, Y and Z variables? Had a quick look in the MDX UI and can't see if its possible to set a variable based on another variable, or if its possible to set more than one.

    Thanks
    Looks like you could use the single axis method fairly easily. The only problem I see is that MDX doesn't seem to have the trig functions. And, if I were doing it, I would ignore any sensor reading over 1g. I'm no math wiz but looks like you could use sin=opp/hyp where opp=1 and hyp=sensor reading in g's. Since MDX can't do sin, I think I would hand calculate something like every 2° or so (maybe every 5°?) and then create a logic statement. A really big logic statement. Looks like it would work while moving as long as you don't hit any bumps and speed remains constant (yeah, right). I guess you could use averaging to help out there. The only thing it wouldn't tell you is in what direction you're tilting. If you are at rest, then the x and y axis could give direction but I don't know that it would be worth the trouble. Looks like all it would take is a lot of time, and since all I seem to have right now is lots of time..........

Similar Threads

  1. Replies: 3
    Last Post: 01-02-2011, 01:11 AM
  2. Tilt angle sensor
    By mx270a in forum FB Sensors
    Replies: 3
    Last Post: 03-02-2009, 11:48 PM
  3. Replies: 0
    Last Post: 04-21-2008, 03:56 PM
  4. Linux Space Navigator Development Thread
    By shotgunefx in forum Linux
    Replies: 43
    Last Post: 08-06-2007, 07:05 AM

Bookmarks

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •