kriswiner / MPU9250

Arduino sketches for MPU9250 9DoF with AHRS sensor fusion
1.03k stars 472 forks source link

Multiple MPU latency problem #436

Open hedayat95 opened 3 years ago

hedayat95 commented 3 years ago

Hi Kris, First of all thank you for this amazing code! I want to read 12 mpu9250 with teensy3.2 and I'm worried about latency and fution rate! I have some questions and I would really appreciate if you help me.

  1. do you think I can read 12 sensors with this MCU and achieve 1 KHz fution rate?
  2. The thing that I can't actually understand is how i2c multiplexer can solve the latency while the bus is serial( can I read all sensors at the same time?). can you explain it ? 3.I don't have SPI multiplexer and it isn't also possible to buy it, but I have i2c multiplexer my question is which method is faster , using i2c multiplexer or SPI without multiplexer?
  3. I want to calibrate sensors individually and use calibration amount as const for every time. dose it make a problem?
  4. I want to measure the finger joint angles when the hand is parallel with gravity and do grasping . if I use Tait-Brayan angles the Yaw is desired angle ( finger flextion) when roll is 90 degree. in your opinion for this task which Euler rotation sequence is better?
  5. I use customize breakout board and used 10K pullup resistor for SDA and SCLK in every breakout board. when I read 12 sensors this resistor be parallel. dose it make problem?
kriswiner commented 3 years ago

1) you can read 12 MPU9250 but a fusion rate for all 12 at 1 kHz will be quite difficult using the Teeny 3.2. 2) You don't need an I2C multiplexer but using one would make the software much easier and probably faster. 3) would probably work fine. 4) yaw, pitch, roll is the same as Euler angles. Not sure I understand your question. 5) depend on the length of the connecting wires. But 12 x 10 K in parallel is going to be ~1K or so, you'll just have to try it.

On Sun, Oct 25, 2020 at 1:29 PM hedayat95 notifications@github.com wrote:

Hi Kris, First of all thank you for this amazing code! I want to read 12 mpu9250 with teensy3.2 and I'm worried about latency and fution rate! I have some questions and I would really appreciate if you help me.

  1. do you think I can read 12 sensors with this MCU and achieve 1 KHz fution rate?
  2. The thing that I can't actually understand is how i2c multiplexer can solve the latency while the bus is serial( can I read all sensors at the same time?). can you explain it ? 3.I don't have SPI multiplexer and it isn't also possible to buy it, but I have i2c multiplexer my question is which method is faster , using i2c multiplexer or SPI without multiplexer?
  3. I want to calibrate sensors individually and use calibration amount as const for every time. dose it make a problem?
  4. I want to measure the finger joint angles when the hand is parallel with gravity and do grasping . if I use Tait-Brayan angles the Yaw is desired angle ( finger flextion) when roll is 90 degree. in your opinion for this task which Euler rotation sequence is better?
  5. I use customize breakout board and used 10K pullup resistor for SDA and SCLK in every breakout board. when I read 12 sensors this resistor be parallel. dose it make problem?

— You are receiving this because you are subscribed to this thread. Reply to this email directly, view it on GitHub https://github.com/kriswiner/MPU9250/issues/436, or unsubscribe https://github.com/notifications/unsubscribe-auth/ABTDLKVONTBQK4FBAFMDQDDSMSDBTANCNFSM4S6SHW5A .

hedayat95 commented 3 years ago

Thank you for the quick response ! Do you think I can get sufficient accuracy with this MCU for hand movement ? Which method do you recommend? SPI or i2c When the order of rotation is changed subsequently the roll and etc. will change . I think depend on initial position which order is better . imagine the initial position of breakout board is perpendicular to the horizon plane. which order do you recommend?

hedayat95 commented 3 years ago

in each finger the length of the connecting wires is 10 cm and total length of bus is 50cm.

kriswiner commented 3 years ago

Probably better off using these https://www.tindie.com/products/onehorse/ultimate-sensor-fusion-solution-mpu9250/ with an I2C multiplexer. Or this https://www.tindie.com/products/onehorse/max32660-motion-co-processor/.

On Sun, Oct 25, 2020 at 2:55 PM hedayat95 notifications@github.com wrote:

in each finger the length of the connecting wires is 10 cm and total length of bus is 50cm.

— You are receiving this because you commented. Reply to this email directly, view it on GitHub https://github.com/kriswiner/MPU9250/issues/436#issuecomment-716218426, or unsubscribe https://github.com/notifications/unsubscribe-auth/ABTDLKWMLHMI4ZP5SUPHVPTSMSNEPANCNFSM4S6SHW5A .

hedayat95 commented 3 years ago

another problem is when I soldered the mpu9250 on my board, the accel data became saturated, and I believe it is because of the bias shift due to high temperature during soldering process. I tried to write zero (0x00) to accel offset register, but this approach didn’t solve my problem. but when select 16_G for ACCEL the problem was fixed

kriswiner commented 3 years ago

Should be able to calibrate out this bias offset.

On Sun, Oct 25, 2020 at 3:05 PM hedayat95 notifications@github.com wrote:

another problem is when I soldered the mpu9250 on my board, the accel data became saturated, and I believe it is because of the bias shift due to high temperature during soldering process. I tried to write zero (0x00) to accel offset register, but this approach didn’t solve my problem. but when select 16_G for ACCEL the problem was fixed

— You are receiving this because you commented. Reply to this email directly, view it on GitHub https://github.com/kriswiner/MPU9250/issues/436#issuecomment-716219734, or unsubscribe https://github.com/notifications/unsubscribe-auth/ABTDLKULG3JOP7IG67274LTSMSOJZANCNFSM4S6SHW5A .

hedayat95 commented 3 years ago

I am not able to buy this chips due to Corona .(there aren't in my Country ). again Do you think I can get sufficient accuracy with this MCU for hand movement ? or I waste my time

kriswiner commented 3 years ago

Waste your time

On Sun, Oct 25, 2020 at 3:12 PM hedayat95 notifications@github.com wrote:

I am not able to buy this chips due to Corona .(there aren't in my Country ). again Do you think I can get sufficient accuracy with this MCU for hand movement ? or I waste my time

— You are receiving this because you commented. Reply to this email directly, view it on GitHub https://github.com/kriswiner/MPU9250/issues/436#issuecomment-716220749, or unsubscribe https://github.com/notifications/unsubscribe-auth/ABTDLKX7KHVUX4SFGRJF3ADSMSPGVANCNFSM4S6SHW5A .

hedayat95 commented 3 years ago

Thank you very much.

hedayat95 commented 3 years ago

may I read all sensors and run the filter in labview that work with the CPU clock?

kriswiner commented 3 years ago

Maybe...I would try with one or two first

On Sun, Oct 25, 2020 at 3:20 PM hedayat95 notifications@github.com wrote:

may I read all sensors and run the filter in labview that work with the CPU clock?

— You are receiving this because you commented. Reply to this email directly, view it on GitHub https://github.com/kriswiner/MPU9250/issues/436#issuecomment-716221720, or unsubscribe https://github.com/notifications/unsubscribe-auth/ABTDLKVK3L5M3L36NXBQPPDSMSQB3ANCNFSM4S6SHW5A .