Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

[Question] how to compute relative position (vector) with sensor fusion? #31

Open
gotgot1995 opened this issue Apr 9, 2018 · 4 comments

Comments

@gotgot1995
Copy link

@kriswiner Hi,

Thanks for your work on sensor fusion. It has been a real help for my classmates and I. It's also great that you got interested in porting your work on the STM32 board family, these are great products.

For our school project, we're more interested in the trajectory than in the orientation of the sensor (in other words "where is it going in 3D space").

How can we retrieve that information based on sensor fusion ? We have the same breakout bord as described in your article.

We're not algebra masters so we don't really know how to compute this data.

Any ideas ?

Thanks in advance,

@gotgot1995 gotgot1995 changed the title [Question] how to compute relative position (position vector) once you have the [Question] how to compute relative position (vector) with sensor fusion? Apr 9, 2018
@kriswiner
Copy link
Owner

kriswiner commented Apr 9, 2018 via email

@SoulPedal
Copy link

Hi Kris,

I'm sharing a YouTube link where I demonstrated this "1-2 seconds" of positional accuracy (inaccuracy). https://www.youtube.com/watch?v=1Unwo9w_I28
I'm using the 9250, cousins I think, but my code is not efficient yet because I'm not reading motion data using it's interrupt, I'm just polling it and that screws up my time accuracy. I sample around 30/sec, and even with my random code timing, it does track somewhat.

Ironically, I took the exact same approach as you did (gotgot1995) in that I removed gravity and double integrated Accel. (probably got that tip from Kris... I've been at this a while). Keep in mind, I had to also remove acceleration vectors due to rotation and that had some Tan functions in there. I also only need the position over a 1 second period of foot travel with clear start and end sensing because of the pressure sensor in the pedal, so I may have a use case for this approach. Also, notice that I'm squeezing the pedal near the toe - just before moving and when I stop. Any longer and it would drift off to infinity very quickly (butterfly effect from errors). And this is only 1 axis, I need 2 for my application, and in space you need 3 and then come those Euler coordinates and stuff.

I will be attempting to update my code soon (working on the SoulPedal.com hardware still/again) and I could speed things up (I think) but that's going to be a lot of calculations. Oh, and I believe I was only using floats not doubles. I just realized this in looking at the compiler where double option was unselected.

Anyway, fun stuff and I do watch this topic. Kris has been a big help so far, thanks man. My plan is to complete a build of 15 units then look for beta testers. I'm thinking this forum might be a good start for the Arduino interface, right?

21 (AKA John)

@gotgot1995
Copy link
Author

gotgot1995 commented Apr 18, 2018

Thanks a lot for all these precious details @kriswiner, I'll take a look into these sensors. Also thanks for the heads-up @SoulPedal .

I know that most things you can find on the Internet are irrelevant, however I was surprised to see what this guy could achieve with just a simple 6DoF IMU : 3D Tracking with IMU .

What do you guys think ?

@kriswiner
Copy link
Owner

kriswiner commented Apr 18, 2018 via email

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

3 participants