
fredebec
France
Asked
— Edited

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.
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.