i2cdevlib icon indicating copy to clipboard operation
i2cdevlib copied to clipboard

dmpInitialize() @ MPU6050_9Axis_MotionApps41.h

Open Vannav opened this issue 13 years ago • 4 comments

Wanted to test out the 9Axis DMP with my MPU9150 which works fine with MPU6050_6Axis_MotionApps20.h. Can't get it past initialization state. Code gets stuck at line 558 because getFIFOCount() always returns 0.

DEBUG_PRINTLN(F("Waiting for FIRO count >= 46..."));
while ((fifoCount = getFIFOCount()) < 46);

Here is the full debug log:

Initializing I2C devices...
Testing device connections...
MPU6050 connection successful

Send any character to begin DMP programming and demo: 
Initializing DMP...


Resetting MPU6050...
Disabling sleep mode...
Getting product ID...
Product ID = 0Selecting user bank 16...
Selecting memory byte 6...
Checking hardware revision...
Revision @ user[16][6] = A5
Resetting memory bank selection to 0...
Reading OTP bank valid flag...
OTP bank is valid!
Reading gyro offset values...
X gyro offset = 1
Y gyro offset = 2
Z gyro offset = 0
Enabling interrupt latch, clear on any read, AUX bypass enabled
Setting magnetometer mode to power-down...
Setting magnetometer mode to fuse access...
Reading mag magnetometer factory calibration...
Adjustment X/Y/Z = 0 / 0 / 0
Setting magnetometer mode to power-down...
Writing DMP code to MPU memory banks (1962 bytes)
Success! DMP code written and verified.
Configuring DMP and related settings...
Writing DMP configuration to MPU memory banks (232 bytes in config def)
Success! DMP configuration written and verified.
Setting DMP and FIFO_OFLOW interrupts enabled...
Setting sample rate to 200Hz...
Setting clock source to Z Gyro...
Setting DLPF bandwidth to 42Hz...
Setting external frame sync to TEMP_OUT_L[0]...
Setting gyro sensitivity to +/- 2000 deg/sec...
Setting DMP configuration bytes (function unknown)...
Clearing OTP Bank flag...
Setting X/Y/Z gyro offsets to previous values...
Setting X/Y/Z gyro user offsets to zero...
Writing final memory update 1/19 (function unknown)...
Writing final memory update 2/19 (function unknown)...
Resetting FIFO...
Reading FIFO count...
Current FIFO count=0
Writing final memory update 3/19 (function unknown)...
Writing final memory update 4/19 (function unknown)...
Disabling all standby flags...
Setting accelerometer sensitivity to +/- 2g...
Setting motion detection threshold to 2...
Setting zero-motion detection threshold to 156...
Setting motion detection duration to 80...
Setting zero-motion detection duration to 0...
Setting AK8975 to single measurement mode...
Setting up AK8975 read slave 0...
Setting up AK8975 write slave 2...
Setting up slave access delay...
Enabling default interrupt behavior/no bypass...
Enabling I2C master mode...
Resetting FIFO...
Rewriting I2C master mode enabled because...I don't know
Enabling and resetting DMP/FIFO...
Writing final memory update 5/19 (function unknown)...
Writing final memory update 6/19 (function unknown)...
Writing final memory update 7/19 (function unknown)...
Writing final memory update 8/19 (function unknown)...
Writing final memory update 9/19 (function unknown)...
Writing final memory update 10/19 (function unknown)...
Writing final memory update 11/19 (function unknown)...
Reading final memory update 12/19 (function unknown)...
Read bytes: 0 0 0 0 
Writing final memory update 13/19 (function unknown)...
Writing final memory update 14/19 (function unknown)...
Writing final memory update 15/19 (function unknown)...
Writing final memory update 16/19 (function unknown)...
Writing final memory update 17/19 (function unknown)...
Waiting for FIRO count >= 46...

Vannav avatar Jul 14 '13 18:07 Vannav

I'm having the same issue... Any news about it? Thanks

shad0w82 avatar Oct 04 '13 11:10 shad0w82

Yup same here. At one point with an older version of MotionApps42 it worked. Not sure what happened. Might be an update....Try pulling the previous version before ARM support was added.

tsimon57 avatar Sep 29 '14 22:09 tsimon57

Did anyone get a solution to this?

dine909 avatar Nov 05 '16 00:11 dine909

Closing ancient issue for cleanup.

jrowberg avatar Sep 23 '21 11:09 jrowberg