How to access Galaxy S5 temperature sensor?
In the manual on the page 19 there is an info on temperature sensor in S5.
Temperature and Humidity sensor allows your device to read both temperature and humidity conditions. This is useful to calculate calories burned within S Health
But I cannot seem to find any data on how to use this sensor.
Did anyone find any way to use this sensor in our own app?
EDIT
Take note that if you install any 3rd party temperature application, it will say that your device (S5) does not have temperature sensor . So I cannot use the standard code to access the sensor because sensor is not being detected. But Samsung app S Health is using this sensor and I am not sure which API it uses.
Galaxy S5 does not have Temperature and Humidity sensors, unlike S4. Samsung announced it and close to publishing decided not to ship it. It seems that the reason was the fact that these two sensors could not work along with water-proof feature.
S Health app has ability to measure body temperature but its API is hidden at this moment. It means that we have no clue if it measures temperature via external devices (Gear) or it can measure it using heart-rate sensor. Also we don't know if it can measure air temperature (probably not).
http://developer.android.com/reference/android/hardware/Sensor.html#TYPE_AMBIENT_TEMPERATURE
I think this is what you're looking for
链接地址: http://www.djcxy.com/p/78874.html上一篇: Scalac发现错误:scala.Boolean(false)required:java.lang.Boolean
下一篇: 如何访问Galaxy S5温度传感器?