Getting tempature algorithm

Updates on developement of new features and user input/requests

Moderator: imposter

Post Reply
asmart
New User
Posts: 2
Joined: Tue May 08, 2007 12:50 am

Getting tempature algorithm

Post by asmart »

I am trying to get CPU tempature as CoreTemp on QNX operating system. I ported below codes from Linux.
However, the tempature I got did not change at diffferent CPU loading where under Windows XP will change dynamicly to CPU usage. Therefore I am wondering the algorithm wheather correct or not?

Can you kindly help me to verify wheather correct? Algorithm is as below:

rdmsr(0xee, eax, edx);
if (eax & 0x40000000) {
Tjmax = 85000;
}
rdmsr(MSR_IA32_THERM_STATUS, eax, edx);
therm_status = eax;
if (eax & 0x80000000) {
temp = Tjmax - (((therm_status >> 16) & 0x7f) * 1000);
}
printf("CPU %d temp is %dC\n", cpu, temp / 1000);

Post Reply

Return to “Core Temp - Development”