fredebec
France
Asked
— Edited
Resolved by Steve G!
Hi,
I have bought the MPU9150 sensor and try to use the temperature sensor. But the sensor always displays 22 Celcius, whatever the condition...
I have followed the tutorial, and Gyro and compass seem to work just fine. I think it is just me who do not know how to use it, so any help is welcome... Thanks.
I can report the same here. Temp stuck on 22c. Compass and gyro working.
I'll throw my hat in the ring too and say I'm having the same issue. Accel, Gyro, compass are all running fine and updating no problem with the example script. But like the others, the temp stays at 22 C and does not change when exposed to subtle but different heat, even using a simple "run once" "Say("The temp is " +$TempC ) script.
@fredebec and @olegodo.
Can I ask you guys, what does it say on the back of your sensors? I ask because the MPU9150, 4 in 1 sensor I ordered says this on the back...
I'm curious to know why it doesn't say "Temprature" on the back as well, as it is meant to be a 4 in 1 sensor (unless I as sent the wrong one), and might go to answer why the temperature is not updating.
That is correct the MPU9150 does not do temperature if you look on the spec sheet from Sparkfun.
Interesting. That's not what the store description says...
confused
Yep, ez robot states it's a 4 in 1.... I guess we only get a 3 in 1?
The MPU9150 does provide temperature but I have not seen this well documented on any datasheets or from any vendors. I have an MPU9150 I got from ebay (Non-EZ-Robot) and it will provide temperature data, but I don't believe it was meant to provide room temp or weather type temp. I think of it as more like an "operating" system temp, like CPU temp sensor in a PC. In my experiments I used a heat gun to blow on the device the temperature would climb. Once the heat source was removed it slowly dropped back down.
here is the spec info on MPU9150 Features:
4 in one sensor.........Gyro + Accel + Compass + DMP.. dont know what the DMP stands for?
I just hooked it up again to have another play, and for a moment (about 2 seconds) it read at 21 C, then when to 22 and stayed there. I compaired this the the EZ-B CPU temp and they are not the same (EZ-B reading 24.87 C).
Somebody put it in the fridge and try again...
@rb550f
DMP... Digital Motion processing
Here is more info. Temperature sensor is for the MPU die. Not room temperature sensor.
chip temperature sensor and ADC are used to measure the MPU
9150 die tempera ture. The readings from the ADC can be read from the FIFO or the Sensor Data regist
Okay, it might time here in the UK so I have put my EZ-B outside with the 4 in 1'connected. 5 mins later at the temp has dropped to 20 C...
Weird thing, I put it in the palm of my hand for a few seconds and it dropped straight to 3 within a few seconds. Removed it and it shot straight back up to 22.
So I just bought my EZ-B back inside (no room in the fridge Richard, too much booze lol), and a couple of minutes later and the temp display has come back up 22 C...
And putting the sensor on a bottle of warm water, about 40'seconds later it drops to 3 C...
So as Justin and rb550f have said, I dont think this is reading ambient temperature at all, and is reading the sensor temp. Very irregular results, but it seems to be working. This kinda sucks as I (and others) thought it was going to read ambient room temp and I think it should be made clear in the description. But there is something going on with the results I'm getting.
@fredebec and anyone else.
So in answer to your question, you're not doing anything wrong by the sounds of it. You can run the example script found by clicking the ? In the MPU9150 control, copy and paste the code in to a script, and run it.
Then put the sensor on a bottle of warm water or in the palm of your hand, or in something cold like a can of drink from the fridge, wait a few seconds and the temprerure display should change. The readings seem irregular, but they do change.
For anyone interested, the sample script can be found here
Ok, I have tried to rise the temp by putting the sensor on my 3d printer heated bed (at 40°C), and it also changed to... 3. Then get back to 22 at room temperature. I am not sure to fully understand what is the purpose of this "temperature" sensor, but it is clearly not an ambient temperature sensor. I am really disappointed because I have bought it only for that function
@fredebec.
Same here. I was really hoping this would read room temp as well and was one of the reasons for me getting one. At least you got it working... Although not the way you want. eyeroll
In any case, thank you all for your help in solving this mystery (especially @Steve G)
I think I will contact EZ Robot and suggest them to change the description as it is really misleading...
Your welcome, and good idea.
I notice the description says it can "tell hot from cold". It may be a very nonlinear sensor and only reads temp points as opposed to linear changes for changes in temp. This may be a function of the software more than the sensor, but I think even the sensor is probably not very linear. Therefore the jumps in readings. It appears it simply reads cold, warm, and hot. At least with any reliability. Like, is your CPU running cool, normal, or hot? That's all you really get. It's misleading in it's title, but the description does not say it will measure temperature range with a linear voltage output through that range. This is probably a cost saving "feature." To give a truly linear output over a given range each unit would have to be calibrated through a range of temperatures. To do this would require a custom set of temperature vs voltage correction factors be entered into every unit or one or more tiny resistors burned by a laser to modify the resistance based on those same sort of correction factors. Either way, a time consuming effort, even if it is automated. Where production is concerned, time really is money.
@fredebec You could probably put in a temp. sensor and an amplifier and do the correction in Script Software to make the readings linear over a certain range of output readings vs temperature. There may even be some thermoresistive sensors (RTD - Resistance Temperature Detector) that would give you enough voltage change vs temp. output (using the existing voltage on the DAC port) to do the job without an amplifier. I don't know off hand. The more correction points you put in the more accurate it will be. Should be able to do this in Script using an array. OTOH, there are more expensive units already calibrated via the burning of resistor(s) by a laser. The usual tradeoff, cost vs accuracy. RTDs tend to be quite stable over time. Easy to hookup using a simple voltage divider.