Kodi Community Forum

Full Version: [LINUX] CPU temperature incorrect in XBMC for Linux?
You're currently viewing a stripped down version of our content. View the full version with proper formatting.
Pages: 1 2 3 4 5 6 7 8
I noticed that the cpu temperature is displayed as ?.

I checked the code and found that the cpu temperature is coming from CPUInfo.cpp:

m_fProcTemperature = fopen("/proc/acpi/thermal_zone/THRM/temperature", "r");
if (m_fProcTemperature == NULL)
m_fProcTemperature = fopen("/proc/acpi/thermal_zone/THR1/temperature", "r");
if (m_fProcTemperature == NULL)
m_fProcTemperature = fopen("/proc/acpi/thermal_zone/THM/temperature", "r");

Unfornately, in Ubuntu 8.10 64bit that file doesn't exist ...
Actually it's always a ? on 32bit too Sad
You have a /proc/acpi/thermal_zone/THM0/temperature though?
Honestly do not know if I have that or not, just knew that it was always a ? and never knew what to investigate to find out what was up. On my last install I even had LMsensors working in hopes of solving that heh. Reinstalling on 8.1 from scratch so I will try to look into this more. I and several others would LOVE to have the temp display working right for us!

Edit: checked on my new build - XBMC not yet running. proc/acpi/thermal_zone exists but nothing lower and nothing in this dir. Does that help? Ubuntu 8.1
So long as your ACPI is setup correctly and your cpu is supported by acpi thermal zone, this should be fixed in r17031. Be patient, temp only updates every 60s or so and the for some odd reason isn't called straight away (ie. you get a ? for the first ~60s).
No I don't ... I have sensors installed and working as expected with temperature readings . I only have /proc/acpi/thermal_zone directory and it is empty.

althekiller Wrote:You have a /proc/acpi/thermal_zone/THM0/temperature though?
According to the website below, /proc/acpi is being replaced by interfaces in /sys and new software should not look in /proc.

http://acpi.sourceforge.net/documentation/thermal.html
Next time you post a link make sure the info is more than just an after thought and that it contains useful info. I know damn well /proc is deprecated (not removed). But I haven't found exactly WHAT PATH in /sys has deprecated /proc/acpi/thermal_zone. Feel free to dig it up and create a ticket on trac, but don't bother unless you find the appropriate info.

In the interim, your kernel is misconfigured, your hardware unsupported, you don't have acpid running or some combo.
Same problem here. Anyone figured it out?
my temp is shown (degC*1000) in: /sys/class/hwmon/hwmon0/device/temp1_input

matches sensors info for the same device.

Don't know if that's worth anything, figured I'd pass it along.

TheUni
Theuni
have you installed anything special? i got them aswell in sys what version are you using?
Will check mines if it is their as well .. I will create a patch if so ..
Check /sys/class/thermal/thermal_zone0/temp instead, there is no way to know what file is mapped to what sensor in the dir tehuni mentioned.
althekiller Wrote:Check /sys/class/thermal/thermal_zone0/temp instead, there is no way to know what file is mapped to what sensor in the dir tehuni mentioned.

i dont got that but i got the one tehuni had
I don't have /sys/class/thermal/thermal_zone0/temp but I do have /sys/class/hwmon/hwmon0/device/temp1_input.

But my temp1_input is Chipset and temp2_input is CPU and temp3_input is Case Temperature reading ... I have integrated videocard ..

It looks like this information will only get populated if lib_sensors is installed ....

How about you guys ? Do you have three readings as well ? Do you have integrated videocard ? Maybe with alot of example, we can get an idea what file cpu temperature is stored in ...

Another way, is to parse the output of sensors program and look for the cpu temperature and compare the value to tempX_Input if it matches then it is file we use ....
Pages: 1 2 3 4 5 6 7 8