Tilt oriented E-compass based Monkey C code.

Hey guys, 

I'm trying to find some Monkey C code, that uses the accelerometer and magnetometer, to output a gravity axis accelerometer reading.

Basically - what I'm trying to do is go from an array of readings saved of the acceleration in the gravity axis only..... and then apply  maths to calculate vertical displacement.

This does not need to occur realtime, and could occur after the event, or even at the end of the session.

My constraints are that - the orientation of the watch is not fixed, and there is another acceleration vector  ( total of 2  with Gravity being one )

The other acceleration vector opposes gravity all the time, but not directly - ie it is some angle off , that could be up to say 89 degrees if you could imagine that, so only 1% is opposed to gravity and the other 89% will be horizontal reference the earth acceleration, it could be 100% opposed, and the magnitude varies. up to say 4G.

I don't need to know the heading / the position / the pitch / roll / yaw....... just the component of the other force that is opposing gravity.

Any ideas?

  • Former Member
    Former Member over 5 years ago

    hi,

    perhaps these dev's can help you ?

    GPS Metrics

    Remote Motion Viewer

    happy & safe sporting

  • I've figured out the code for the Displacement, if can get the Gravity axis acceleration value

    Displacement at Time  = T, G = Gravity and assumed to be 1 G, Gz1 = the G axis gravity reading, Gz2 = the next G axis reading.

    (G – Gz1) * T + [(Gz1 – Gz2 )* 0.5 * T ] = Approximated average Velocity for T1 period

    Since sample time is constant, velocities can all be added up.

    VT2 + VT2 + VT3 + VT4 + VT5 ………………. = Net Velocity

    Net velocity x Total Time period = displacement

  • Thanks, but they are not really what I;m after, I'm looking for source code rather than someone else app.

    The Pitch and Roll calculation formula I found, but I don't think it is enough, because it doesn't have yaw, and without yaw two of the accelerometer readings are directionless... and therefore the G axis reading is not calcuable.

    That made me think - maybe there is another way to figure out the G axis - rather than the watch position in free space, and then from that convert to an equivalent G axis. 

  • Former Member
    Former Member over 5 years ago in reply to Former Member
    perhaps these dev's can help you ?

    tried suggesting you contact the dev Smile

    happy & safe sporting

  • Ahhh I see Slight smile

    I'm not quite down with the lingo yet Slight smile