获取电池温度和结果单位
我正在阅读如何获取电池的温度,我制作了一个小应用程序,在我的接收器中,我有类似这样的东西
int temp = intent.getIntExtra("temperature", 0);
,这个温度有像 390 或 380 这样的值,对于摄氏度来说确实很大,但我认为即使对于华氏度来说这也是一个很大的数字......
有人可以告诉我单位是什么吗,做到了有一个范围等等。
在官方文档中我发现的只是“包含当前电池温度的整数”
谢谢
I was reading how to get the temperature of the battery and I make small app, and in my receiver I have something like this
int temp = intent.getIntExtra("temperature", 0);
well , this temp have values like 390 or 380 something that is really big to be Celsius but I think that is big number even for Fahrenheit...
can someone please tall what is the unit, does it have a range and so on.
in the official documentation all I found was "integer containing the current battery temperature"
Thanks
如果你对这篇内容有疑问,欢迎到本站社区发帖提问 参与讨论,获取更多帮助,或者扫码二维码加入 Web 技术交流群。
绑定邮箱获取回复消息
由于您还没有绑定你的真实邮箱,如果其他用户或者作者回复了您的评论,将不能在第一时间通知您!
发布评论
评论(2)
温度在零点摄氏度。还在问题此处进行了讨论< /a>.
The temperature is in tenths of a degree centigrade. Also discussed in question here.
结果是您从意图获得的值的 1/10,这意味着如果您获得 380,则为 38 度。
the result is 1/10 of the value you get from the intent it means if you get 380 it is 38 degrees.