I have a 6050 running om I2C.
my startup configuration is:
0x6B ---> 0b00100000
0x6C ---> 0b01000000
means i use wake and sleep with a 10 Hz update.
I can read the Temperature and all 3 axis on accelerometer.... and verified that they are correct.
....but i get "0" on all the gyro axis... what have i forgotten? (and yes i do tilt the module in all axes, without luck)..
can anyone pls put me on right spot.
I use a 16F877a controller. yes i know, it's a matter of taste, so please stick to the subject
Sticking to the subject would mean I would follow the same path as you, with the same result. I'm here to look at it with a broader view than just your subject
The data for acceleration, temperature and gyro can be retrieved in a single I2C session as one chunk of data.
Can you do a test ? Just clear the sleep bit, and read that data.
If your I2C library allows a chunk of data of 14 bytes it should work.
Maybe the undocumented registers can disable the gyro, but not the normal registers.
thx for the reply.
I tried your proposal, and i recieved all the informations, buuuuuuut..... it says
"xx xx xx xx xx xx xx xx 00 00 00 00 00 00"
calculating values gives me 9.8 m/s^2 in z axis-accelerometer, and nice 22 degreeC in room temperature.
according to the 6050 datasheet the gyro have a startup time of 30 ms, but i'm sure i've included that.
i have checked the registers that concerns the gyro:
0x1B = 0
0x6C = 128, and therefore gyro is not set to standby.
did i miss something?.
No, but if only the first 8 bytes are valid, that could be something.
What if you request the same amount of data, but starting with the register of the gyro data ?
Try another MPU-6050, and try this MPU-6050 with an Arduino. That is the only way to be sure that sensor is still working.
Did you accidently connect one of the pins of the MPU-6050 to 5V ?
Yes i tried with gyro register first, still the same. i mean that the gyro is sending me "0" .
I'll try the other 6050 when i get the chance. guess thats be monday.
AND i run with 5V , this one i have is a 2014 breakout board( i suppose), and is 5V conpatible ( accordingy to the datasheet) . I mean , the I2C is working and the Acc and Temp sensor is working so i can't see the idea of the gyro is not "working" .
MPU-6050 + 5V = broken
Don't tell me one of the standard nonsense one-liners:
"But it worked before" :~
"Everyone else is doing it"
"I'm sure they made the chip 5V tolerant" ]
"I personally know the designer of the chip and he told me that 5V is fine" ]
If the breakout board has 5V regulator on board, you can apply 5V to the VCC. But it still is a 3.3V chip.
Let me know if the new MPU-6050 is working.
I am surelly not gonna give you any of those one-liners.
i put on the new chip and its still the same...
but but but.... i am sure that i read somewhere that the board had a 3.3 regulator integrated, but now i cant find it... :~ (ya ya... shame on me)
i'll try find a 3.3 regulator and see if its gonna work, guess i have to order another 6050
buuuuut, i find it strange that i can read the temperature and Accelerometer, even though is says on datasheet the same V_dd specs. (and the values read are plausible)
and the I2C communication is working as well. how can that be explained? (i'm not trying to be a smartass, only search for a logical explanation )
I mean, if the board is intollerant for 5V then the 6050 should be dead or at least write outrageus values.
if curious my board have this product spec: "SPS06050S"
Like this one ?
That one has a 3.3V voltage regulator (the black smd component with 3 pins).
You can apply 5V to VCC, but you must use a 3.3V I2C bus. The module has pullup resistors to 3.3V itself, so if your 5V microcontroller has real open-collector outputs for the I2C you can connect them.
A MPU-6050 + voltage regulator + shipping costs about 3 dollars:
Did you try one of them with an Arduino board ?
Yes that's the one.
Somehow I managed to receive data from the gyro in a session, but when I restart the system to se if that was real it's back to zeros. Damn.... Guess I did something right and again something wrong.
I go try different configurations.
I put the power management register 6B to "0", instead of cycle mode, and that turned the key. I read in manual that when put in cycle mode the gyro is disabled. so voila... this is it.
now its time for kalman filter, and fine adjustement. wonder if i can do a kalman filter using only + ,-, / and * cause the picmicro does not allow advanced calculation :~
i might turn into arduino someday if i need more sophisticated calculations.
So it had to do with register 6B as you wrote in your first post after all.
I didn't know that the gyro was disabled in that situation, but I'm glad you have it working now.
I glad too that it worked out.
Dude... i were so sure that i read every **** line to make sure that i understood the configuration i was doing, but i guess that i did read what i wanted to read not what i should have been reading.
thx for your support, nice to know that there is someone to help sort things out, rather to be alone with this s***.