MPU9250 STM32F411re

Working libraries, libraries being ported and related hardware
Post Reply
JoergSH
Posts: 7
Joined: Mon Aug 24, 2020 1:45 pm

MPU9250 STM32F411re

Post by JoergSH »

Hello I have problems with the sparkfun dmp libary. https://github.com/sparkfun/SparkFun_MP ... no_Library

Lib runs fine on Sam21d (m0 without FPU)

on the 411 filter is not working correct. I think it is a problem of the FPU. Any suggestions ?
there are other libs witch have same problem. on device with fpu calculations are bad.

regards
stevestrong
Posts: 502
Joined: Fri Dec 27, 2019 4:53 pm
Answers: 8
Location: Munich, Germany
Contact:

Re: MPU9250 STM32F411re

Post by stevestrong »

Do you have an example which shows the bad calculation?
Any reference to other lib which have the same problem?
Which core do you use?
Which board?
viewtopic.php?f=2&t=301
JoergSH
Posts: 7
Joined: Mon Aug 24, 2020 1:45 pm

Re: MPU9250 STM32F411re

Post by JoergSH »

thats not so easy to explain.
Board is a Blackpill with STM32f411.

[env:blackpill_f411ce]
platform = ststm32
board = blackpill_f411ce
framework = arduino

The code was written for the sam21d.
On sam after reset Kompass are fast in right direction. On the 411 compas starts count from 0 up to 50 degrees in about 10 seconds. Than is stabel but did not have the correct direction to north. there are no changes in code. I think there went something wrong when the fpu does the calculation.
stevestrong
Posts: 502
Joined: Fri Dec 27, 2019 4:53 pm
Answers: 8
Location: Munich, Germany
Contact:

Re: MPU9250 STM32F411re

Post by stevestrong »

I have a black F411 board, so I could eventually check, but without any example I cannot figure out what can go wrong.
I assume you use PIO. Have you tried with Arduino?
Again, which core do you use?
JoergSH
Posts: 7
Joined: Mon Aug 24, 2020 1:45 pm

Re: MPU9250 STM32F411re

Post by JoergSH »

I have blackpill too.
I use VS Code with PlattfomIo. Using as standard STM32Duino
it makes no difference when I use arduino IDE.

The Sample from github is for a MPU9250. There a Quaternions and Kalman Filter calculated. So my thought is a problem when compiler use FPU.
Attachments
STM32F411CEU6_WeAct_Black_Pill_V2.0-2.jpg
STM32F411CEU6_WeAct_Black_Pill_V2.0-2.jpg (82.54 KiB) Viewed 4728 times
User avatar
fpiSTM
Posts: 1738
Joined: Wed Dec 11, 2019 7:11 pm
Answers: 91
Location: Le Mans
Contact:

Re: MPU9250 STM32F411re

Post by fpiSTM »

My 2 cents is that some rounding in the operation...
JoergSH
Posts: 7
Joined: Mon Aug 24, 2020 1:45 pm

Re: MPU9250 STM32F411re

Post by JoergSH »

fpiSTM wrote: Sat Oct 17, 2020 3:45 pm My 2 cents is that some rounding in the operation...
Maybe but why only when using fpu ?
JoergSH
Posts: 7
Joined: Mon Aug 24, 2020 1:45 pm

Re: MPU9250 STM32F411re

Post by JoergSH »

is it possible to say the compiler not to use the fpu?
Post Reply

Return to “Libraries & Hardware”