thinkpads.com Support Community Forum Index Bill Morrow's thinkpads.com Open Forum - The Original Thinkpad Support Forum
Follow ThinkpadsForum on Twitter
 Support this forum, shop at newmodeus.com
 Support the forum, shop at newmodeus.com
 The thinkpads support forum is now hosting legacy model ThinkPad driver and driver updates..
A link is provided in the MENUBAR just above for registered forum members only..

If you so wish:
Donate using PayPal

It is currently Thu Oct 02, 2014 1:22 am

All times are UTC - 5 hours




Post new topic Reply to topic  [ 30 posts ] 
Author Message
PostPosted: Mon Oct 11, 2010 8:29 pm 
Offline

Joined: Sat Oct 09, 2010 7:04 am
Posts: 35
Location: France
Everything's in the title! That's something really annoying, the fan sometimes starts running at full speed and then won't stop until you restart the unit!

I tested the apps designed for Macbooks and of course they didn't work... Chance are low to find a thing i know, but who knows... Someone maybe did?!

I've read (here i think) someone recommending to use BIOS settings to control that (a little) but i've seen nothing in each BIOS sections, did i miss something..?


Top
 Profile  
 
PostPosted: Sun Nov 21, 2010 7:27 am 
Offline
Junior Member
Junior Member

Joined: Sat Dec 25, 2004 8:17 pm
Posts: 345
Location: Riga, Latvia
JKK wrote:
Everything's in the title! That's something really annoying, the fan sometimes starts running at full speed and then won't stop until you restart the unit!

I tested the apps designed for Macbooks and of course they didn't work... Chance are low to find a thing i know, but who knows... Someone maybe did?!

I've read (here i think) someone recommending to use BIOS settings to control that (a little) but i've seen nothing in each BIOS sections, did i miss something..?


If you are not too lazy to dig deeper, check this link http://www.projectosx.com/forum/index.p ... topic=1206
The idea is to have patched DSDT and some plugins for FakeSMC which will allow OSX to "talk" to your fan.

_________________
ThinkPad T60p with Snow Leopard 10.6.8
Intel Core 2 Duo T7600
4GB RAM, ATI FireGL V5200 256MB (1400x1050)


Top
 Profile  
 
PostPosted: Mon Nov 22, 2010 8:01 am 
Offline
Junior Member
Junior Member

Joined: Mon Mar 09, 2009 6:02 am
Posts: 280
Location: Paris, France
Silencer wrote:
I'm not sure 100%, but from what I found on ThinkWiki, I have PC87382 Super I/O chip. In DSDT I have the following device


I have the same conclusions : LPC bus (PC87382 Super I/O, Atmel® 97SC3203 TPM)

Sources:

So we have a "Winbond" PC87382 I/O Chip ...

As far as I know the FakeSMCSuperIO plug-in in the "new" FakeSMC only support :
Code:
Winbond W83627DHG
Winbond W83627DHG-P
Winbond W83627EHF
Winbond W83627HF
Winbond W83627THF
Winbond W83667HG
Winbond W83667HG-B
Winbond W83687THF

Source

Hence we can't use it ... we have to use FakeSMCACPImonitor plug-in with custom DSDT edit like this one :
Code:
Method (SMC0, 0, NotSerialized)
                    {
                        Store (FAN1, Local0)
                        Return (Local0)
                    }

With this legend:
Code:
// Fan Keys:
SMC0 = F0ID "System Fan"
SMC1 = F1ID "Processor Fan"
...
// Temperature Keys:
SMCA = TC0H "CPU Heatsink"
SMCB = TN0H "MCP/MCH/Northbridge Heatsink"
SMCC = TW0P "AUX Sensor"
...


But I don't were in DSDT we have to add it ... after this ?
Code:
Device (SIO)
                {
                    Name (_HID, EisaId ("PNP0C02"))

or after this ?
Code:
Device (EC)
                {
                    Name (_HID, EisaId ("PNP0C09"))

in both cases I've got compiling errors:
Code:
Store (FAN1, Local0)
Error    4064 -                                                         Object does not exist

I think I have do declare is object ... but where and how ?

Thanks for your help ...

_________________
Lenovo X60t (6363-AQ8)
    Intel CoreDuo 1,67 GHz (L2400)
    3 Go / 320 Go / GMA950 / FW 400 / SD Card
    Bluetooth / Wifi AR5BXB6 / Tablet
WinXP / MacOSX 10.6.8 (DSDT patch and vanilla SLE)


Top
 Profile  
 
PostPosted: Mon Nov 22, 2010 8:18 am 
Offline
Junior Member
Junior Member

Joined: Sat Dec 25, 2004 8:17 pm
Posts: 345
Location: Riga, Latvia
Sebinouse wrote:
I think I have do declare is object ... but where and how ?

Well, you will get a compilation error, since FAN1 is not declared. And even if you declare it like that, it won't give you anything, since it will not contain any meaningful values.

What you can do is to try to use already declared EC register that contains fan rotation speed value - HFNI. I believe a universal piece of code (i.e. working in any other block) would look like that:
Code:
Method (SMC0, 0, NotSerialized)
                    {
                        Store (\_SB.PCI0.LPC.EC.HFNI, Local0)
                        Return (Local0)
                    }

You can safely put it under both EC and SI0, it will not break anything.

_________________
ThinkPad T60p with Snow Leopard 10.6.8
Intel Core 2 Duo T7600
4GB RAM, ATI FireGL V5200 256MB (1400x1050)


Last edited by Silencer on Mon Nov 22, 2010 8:37 am, edited 1 time in total.

Top
 Profile  
 
PostPosted: Mon Nov 22, 2010 8:29 am 
Offline
Junior Member
Junior Member

Joined: Sat Dec 25, 2004 8:17 pm
Posts: 345
Location: Riga, Latvia
BTW, that Super I/O support is only first step - it will only give you readings of the current fan rotation speed, but you can't control it with HFNI register.

There's another register - HFSP, which controls the speed of the fan, and it takes values from 0 to 7 to set the speed of the fan to some predefined values depending on the ThinkPad model you have. More information can be found here.

Technically you don't even need to know the reading of the current fan speed, you can simply set the fan speed depending on the current CPU temperature, which is available. I think for someone who knows how it would be very-very simple to write a driver or a small utility which would check CPU temperature every 10 or so seconds and then update named register depending on set thresholds.

In my DSDT I have the following code defined for the blue ThinkPad button:
Code:
   
     Scope (PCI0.LPC.EC)
        {
            Method (_Q19, 0, NotSerialized)
            {
                Name (FANS, One)
                Store (HFSP, FANS)
                XOr (FANS, Zero, Local0)
                If (Local0)
                {
                    LED (0xFF, 0x80)
                    Store (Zero, HFSP)
                }
                Else
                {
                    LED (0xFF, 0x80)
                    Store (0x80, HFSP)
                }
            }
        }

When I press ThinkPad the fan switches off if it was on and it switches on if it was off. The code can be modified to have it gradually increase the speed from 1 to 7, but that would require you to manually check your CPU temperature all the time. Not the best solution.

_________________
ThinkPad T60p with Snow Leopard 10.6.8
Intel Core 2 Duo T7600
4GB RAM, ATI FireGL V5200 256MB (1400x1050)


Top
 Profile  
 
PostPosted: Mon Nov 22, 2010 10:43 am 
Offline
Junior Member
Junior Member

Joined: Mon Mar 09, 2009 6:02 am
Posts: 280
Location: Paris, France
Silencer wrote:
Code:
Method (SMC0, 0, NotSerialized)
                    {
                        Store (\_SB.PCI0.LPC.EC.HFNI, [color=#FF0000]Local0[/color])
                        Return (Local0)
                    }



So I edited my DSDT (no compiling error), I installed FakeSMC in /S/L/E (without Radeon, Nv and X3100 plugin), and then rebooted ...

As expected I/O chip is recognized as "Unsupported" by FakeSMCSuperIO , but I can't get FakeSMCACPIMonitor plugin to load ... Every other plugin loads ... but not this one ...

I also played with your "Method (_Q19, 0, NotSerialized)" and it worked fine for me ... it is still an alternative ...

So I am back with regular FakeSMC for the moment (I've got CPU temps) ...

I'm curious : How did you find out the signification of the ACPI names (HFNI, HFSP ... ) ? I only found HFSP and a short reference to 0x84 on Thinkwiki )

_________________
Lenovo X60t (6363-AQ8)
    Intel CoreDuo 1,67 GHz (L2400)
    3 Go / 320 Go / GMA950 / FW 400 / SD Card
    Bluetooth / Wifi AR5BXB6 / Tablet
WinXP / MacOSX 10.6.8 (DSDT patch and vanilla SLE)


Top
 Profile  
 
PostPosted: Mon Nov 22, 2010 1:17 pm 
Offline
Junior Member
Junior Member

Joined: Sat Dec 25, 2004 8:17 pm
Posts: 345
Location: Riga, Latvia
Sebinouse wrote:
I'm curious : How did you find out the signification of the ACPI names (HFNI, HFSP ... ) ? I only found HFSP and a short reference to 0x84 on Thinkwiki )

Well, if you at the following code under (EC) device:
Code:
 OperationRegion (ECOR, EmbeddedControl, Zero, 0x0100)
                    Field (ECOR, ByteAcc, NoLock, Preserve)
                    {
                        HDBM,   1,
                            ,   1,
                            ,   1,
                        HFNE,   1,
                            ,   1,
                            ,   1,
                        [skipped]
                        HIID,   8,
                                Offset (0x83),
                        HFNI,   8,
                                Offset (0x88),
                        HDEC,   8,

Right after empty address 0x83 goes HFNI, which starts at 0x84, and that is exactly what we need. And register HFSP is explained on the page on ThinkWiki which I linked before.

_________________
ThinkPad T60p with Snow Leopard 10.6.8
Intel Core 2 Duo T7600
4GB RAM, ATI FireGL V5200 256MB (1400x1050)


Top
 Profile  
 
PostPosted: Tue Nov 23, 2010 1:57 am 
Offline
Sophomore Member

Joined: Fri Feb 29, 2008 2:16 am
Posts: 140
Location: Moscow, Russia
Hello! that's an interesting solution for the fan!
But how can I bind this code to the ThinkPad blue button?

Thanks :idea:


Edit: Oh, silly me! Just changed the right part of DSDT and now it's working :)
It will be cool, of course to have it set dynamically. There's an amazing tool for ThinkPads for Windows called tpFanControl - that does this job amazingly for Windows, keeping the fan stopped most of the time and starting it when the temperature rises

_________________
Mac OS X 10.6.7, 10.6.8 and 10.7.2 Lion on X61 7767 tablet.


Top
 Profile  
 
PostPosted: Tue Nov 23, 2010 6:07 am 
Offline
Junior Member
Junior Member

Joined: Sat Dec 25, 2004 8:17 pm
Posts: 345
Location: Riga, Latvia
Anastasius wrote:
It will be cool, of course to have it set dynamically. There's an amazing tool for ThinkPads for Windows called tpFanControl - that does this job amazingly for Windows, keeping the fan stopped most of the time and starting it when the temperature rises

Yep, I was thinking exactly about that tool. Again, technically there should be no problems creating something similar for OSX knowing all the right ACPI registers.

_________________
ThinkPad T60p with Snow Leopard 10.6.8
Intel Core 2 Duo T7600
4GB RAM, ATI FireGL V5200 256MB (1400x1050)


Top
 Profile  
 
PostPosted: Tue Nov 23, 2010 7:54 am 
Offline
Junior Member
Junior Member

Joined: Mon Mar 09, 2009 6:02 am
Posts: 280
Location: Paris, France
Documentation about Thinkpads ACPI can be found here (seems to be very precise !) :
http://www.linuxhq.com/kernel/v2.6/21-git6/drivers/acpi/ibm_acpi.c

http://repo.or.cz/w/linux-2.6/linux-acpi-2.6/ibm-acpi-2.6.git?a=blob;f=Documentation/laptops/thinkpad-acpi.txt;h=40d465dc961733eaafe9262819488b5cd9ad3b7d;hb=release/2.6.29 (line 1251)

The more I read about this, the more I also think AdidasPrince would be the one able to do this (it's VERY close to his mod about Fn Keys !)

_________________
Lenovo X60t (6363-AQ8)
    Intel CoreDuo 1,67 GHz (L2400)
    3 Go / 320 Go / GMA950 / FW 400 / SD Card
    Bluetooth / Wifi AR5BXB6 / Tablet
WinXP / MacOSX 10.6.8 (DSDT patch and vanilla SLE)


Top
 Profile  
 
PostPosted: Mon Dec 20, 2010 7:44 pm 
Offline
Junior Member
Junior Member

Joined: Mon Mar 09, 2009 6:02 am
Posts: 280
Location: Paris, France
I have been able to monitor CPU Heatsink Temperature, Northbridge Temperature, and HFSP !

I used this DSDT edit :
Code:
            Device (SMCD) // System Monitor and Controll Device
                {
                  Name (_HID, "monitor") // Driver will look for this in order to load or not
                  Method (FSN0, 0, NotSerialized) // ACPIMonitor FAN 0 Speed
                  {
                      Store (\_SB.PCI0.LPC.EC.HFNI, Local0) // Store FAN 0 Tachometter to Local0
                      Return (Local0)
                  }

                  Method (TCPH, 0, NotSerialized) // ACPIMonitor CPU Heatsink Temperature
                  {
                      Store (\_SB.PCI0.LPC.EC.TMP0, Local0)
                      Return (Local0)
                  }
                  Method (TSYS, 0, NotSerialized) // ACPIMonitor Northbridge Temperature
                  {
                      Store (\_SB.PCI0.LPC.EC.TMP4, Local0)
                      Return (Local0)
                  }
              }
              
                Device (EC)


And the latest version (Rev 440) of FakeSMC.kext and ACPIMonitor.kext (both in /E/E) : http://www.projectosx.com/forum/index.p ... topic=1593

I am not able to read HFNI ... I found this here :
Code:
- *   ThinkPad EC register 0x84 (LSB), 0x85 (MSB):
- *   Main fan tachometer reading (in RPM)
- *   ...
- *   FIRMWARE BUG: always read 0x84 first, otherwise incorrect readings
- *   might result.


Do you have any idea how to do so ?

_________________
Lenovo X60t (6363-AQ8)
    Intel CoreDuo 1,67 GHz (L2400)
    3 Go / 320 Go / GMA950 / FW 400 / SD Card
    Bluetooth / Wifi AR5BXB6 / Tablet
WinXP / MacOSX 10.6.8 (DSDT patch and vanilla SLE)


Top
 Profile  
 
PostPosted: Tue Dec 21, 2010 3:33 am 
Offline
Junior Member
Junior Member

Joined: Sat Dec 25, 2004 8:17 pm
Posts: 345
Location: Riga, Latvia
Sebinouse wrote:
I have been able to monitor CPU Heatsink Temperature, Northbridge Temperature, and HFSP !

Great! I will give it a try this evening and will check HFNI.

_________________
ThinkPad T60p with Snow Leopard 10.6.8
Intel Core 2 Duo T7600
4GB RAM, ATI FireGL V5200 256MB (1400x1050)


Top
 Profile  
 
PostPosted: Tue Dec 21, 2010 7:31 am 
Offline
Junior Member
Junior Member

Joined: Mon Mar 09, 2009 6:02 am
Posts: 280
Location: Paris, France
In the latest rev (>440) FSN0 becomes FAN0 and TCPH becomes TCPU ...

Rev 440 Compiles without any errors
Code:
svn co http://subversion.assembla.com/svn/fakesmc/HWSensors -r 440

Rev 449 Compiles with errors in nVClock and Radeon (not important)
Code:
svn co http://subversion.assembla.com/svn/fakesmc/HWSensors

_________________
Lenovo X60t (6363-AQ8)
    Intel CoreDuo 1,67 GHz (L2400)
    3 Go / 320 Go / GMA950 / FW 400 / SD Card
    Bluetooth / Wifi AR5BXB6 / Tablet
WinXP / MacOSX 10.6.8 (DSDT patch and vanilla SLE)


Top
 Profile  
 
PostPosted: Tue Dec 21, 2010 11:55 am 
Offline
Junior Member
Junior Member

Joined: Mon Mar 09, 2009 6:02 am
Posts: 280
Location: Paris, France
And ... Fan Control works properly !!! :D (I guess iStat is mandatory)

Code:
      Device (SMCD) // System Monitor and Controll Device
             {
                  Name (_HID, "monitor") // Driver will look for this in order to load or not
                  Method (FAN0, 0, NotSerialized) // ACPIMonitor FAN 0 Speed
                  {
                      Store (\_SB.PCI0.LPC.EC.HFSP, Local0) // Store FAN 0 Control to Local0
                      Return (Local0)
                  }
                  Method (TSYS, 0, NotSerialized) // ACPIMonitor Northbridge Temperature
                  {
                      Store (\_SB.PCI0.LPC.EC.TMP4, Local0)
                      Return (Local0)
                  }
                  Method (TAMB, 0, NotSerialized) // ACPIMonitor Ambient Temperature
                  {
                      Store (\_SB.PCI0.LPC.EC.TMP5, Local0)
                      Return (Local0)
                  }
                  Method (TCPU, 0, NotSerialized) // Fan Mode Accordind CPU Heatsink Temperature
                  {
                      Store (\_SB.PCI0.LPC.EC.TMP0, Local0)
                      If (LLessEqual (Local0, 0x32))  // CPU Temp is <= 50°C
                      {
                          Store (Zero, \_SB.PCI0.LPC.EC.HFSP) // Set FAN Off
                      }
                      Else
                      {
                          Store (0x80, \_SB.PCI0.LPC.EC.HFSP) // Set FAN Auto
                      }
                      Return (Local0)
                  }
      }


Now we just have to figure out how to read fan rpm !

_________________
Lenovo X60t (6363-AQ8)
    Intel CoreDuo 1,67 GHz (L2400)
    3 Go / 320 Go / GMA950 / FW 400 / SD Card
    Bluetooth / Wifi AR5BXB6 / Tablet
WinXP / MacOSX 10.6.8 (DSDT patch and vanilla SLE)


Top
 Profile  
 
PostPosted: Tue Dec 21, 2010 3:09 pm 
Offline
Junior Member
Junior Member

Joined: Sat Dec 25, 2004 8:17 pm
Posts: 345
Location: Riga, Latvia
Sebinouse wrote:
And ... Fan Control works properly !!! :D (I guess iStat is mandatory)

You are genius! It does work! iStat is probably mandatory, because the controlling method is only called when iStat measures temperature.

I've modified slightly the controlling method:
Code:
Method (TCPU, 0, NotSerialized) // Fan Mode Accordind CPU Heatsink Temperature
{
   Store (\_SB.PCI0.LPC.EC.TMP0, Local0)
   If (LLessEqual (Local0, 0x32))  // CPU Temp is <= 50C
   {
      Store (Zero, \_SB.PCI0.LPC.EC.HFSP) // Set FAN Off
   }
   If (LGreaterEqual (Local0, 0x55)) // CPU Temp is >= 85C
   {
      Store (0x40, \_SB.PCI0.LPC.EC.HFSP) // Set FAN Mode Disengaged - Total Maximum
   }
   Else {
      If (LGreaterEqual (Local0, 0x4B)) // CPU Temp is >= 75C
      {
         Store (0x07, \_SB.PCI0.LPC.EC.HFSP) // Set FAN Mode 7 - Maximum Speed
      }
      Else {
         If (LGreaterEqual (Local0, 0x46)) // CPU Temp is >= 70C
         {
            Store (0x04, \_SB.PCI0.LPC.EC.HFSP) // Set FAN Mode 4 - Medium Speed
         }
         Else {
            If (LGreaterEqual (Local0, 0x41)) // CPU Temp is >= 65C
            {
               Store (0x02, \_SB.PCI0.LPC.EC.HFSP) // Set FAN Mode 2
            }
            Else {
               If (LGreaterEqual (Local0, 0x3D)) // CPU Temp is >= 61C
               {
                  Store (0x01, \_SB.PCI0.LPC.EC.HFSP) // Set FAN Mode 1 - Lowest Speed
               }
            }
         }
      }
   }
   Return (Local0)
}

First of all it reduces fan pulsing when it goes on and off constantly jumping around one temperature measuring. Now it will switch off only when CPU temperature is less than 50, but will switch on when it's more than 60. That way you will spend 10 degrees in silence :)

Another part is that AUTO mode doesn't actually work in OSX, it will always use medium speed, you can test it with CPUTest (CPU loading utility). In the method above the speed is changed gradually.

It also seems that Northbridge temperature is not measured correctly, it looks to be showing HDD temperature there. We can also check other TMPx values (TMP0-TMP7). For example, TMP3 is GPU. Need to know the names of other temperature measuring methods for GPU, battery, chassis, etc, but for that the source code of ACPIMonitor needs to be modified

Sebinouse wrote:
Now we just have to figure out how to read fan rpm !

Yep, that would be interesting to play with. I think ACPIMonitor is waiting for other format of data than it is written in HFNI.

_________________
ThinkPad T60p with Snow Leopard 10.6.8
Intel Core 2 Duo T7600
4GB RAM, ATI FireGL V5200 256MB (1400x1050)


Top
 Profile  
 
PostPosted: Tue Dec 21, 2010 4:50 pm 
Offline
Junior Member
Junior Member

Joined: Sat Dec 25, 2004 8:17 pm
Posts: 345
Location: Riga, Latvia
I got the fan rpm reading working! I also enabled four different temperature sensors in iStat, your example only gives me two.

So, to get rpm reading working first you need to add the code below to the Device (EC), right after the big block Field (ECOR, ByteAcc, NoLock, Preserve).
Code:
// Fan Speed reading in rpm
Field (ECOR, ByteAcc, NoLock, Preserve)
{
    Offset (0x84),
    HFN1,   16
}

Then modify FAN0 to read that value. The full Device (SMCD) in my case looks like that:
Code:
      Device (SMCD) // System Monitor and Controll Device
             {
                  Name (_HID, "monitor") // Driver will look for this in order to load or not
                  Method (FAN0, 0, NotSerialized) // ACPIMonitor FAN 0 Speed
                  {
                      Store (\_SB.PCI0.LPC.EC.HFN1, Local0) // Store FAN 0 Control to Local0
                      Return (Local0)
                  }
                  Method (TSYS, 0, NotSerialized) // ACPIMonitor - GPU Temperature as Northbridge (T60p)
                  {
                      Store (\_SB.PCI0.LPC.EC.TMP3, Local0)
                      Return (Local0)
                  }
                  Method (TAMB, 0, NotSerialized) // ACPIMonitor - Temperature
                  {
                      Store (\_SB.PCI0.LPC.EC.TMP2, Local0)
                      Return (Local0)
                  }
                  Method (TDIM, 0, NotSerialized) // ACPIMonitor - Most Probably Battery Temperature as Memory Controller (T60p)
                  {
                      Store (\_SB.PCI0.LPC.EC.TMP6, Local0)
                      Return (Local0)
                  }
               Method (TCPU, 0, NotSerialized) // Fan Mode Accordind CPU Heatsink Temperature
               {
                  Store (\_SB.PCI0.LPC.EC.TMP0, Local0)
                  If (LLessEqual (Local0, 0x32))  // CPU Temp is <= 50C
                  {
                     Store (Zero, \_SB.PCI0.LPC.EC.HFSP) // Set FAN Off
                  }
                  If (LGreaterEqual (Local0, 0x55)) // CPU Temp is >= 85C
                  {
                     Store (0x40, \_SB.PCI0.LPC.EC.HFSP) // Set FAN Mode Disengaged - Absolute Maximum
                  }
                  Else {
                     If (LGreaterEqual (Local0, 0x4B)) // CPU Temp is >= 75C
                     {
                        Store (0x07, \_SB.PCI0.LPC.EC.HFSP) // Set FAN Mode 7 - Maximum Speed
                     }
                     Else {
                        If (LGreaterEqual (Local0, 0x46)) // CPU Temp is >= 70C
                        {
                           Store (0x04, \_SB.PCI0.LPC.EC.HFSP) // Set FAN Mode 4 - Medium Speed
                        }
                        Else {
                           If (LGreaterEqual (Local0, 0x41)) // CPU Temp is >= 65C
                           {
                              Store (0x02, \_SB.PCI0.LPC.EC.HFSP) // Set FAN Mode 2
                           }
                           Else {
                              If (LGreaterEqual (Local0, 0x3D)) // CPU Temp is >= 61C
                              {
                                 Store (0x01, \_SB.PCI0.LPC.EC.HFSP) // Set FAN Mode 1 - Lowest Speed
                              }
                           }
                        }
                     }
                  }
                  Return (Local0)
               }
      }

I think TMPx sensors except TMP0 and TMP1 (two CPU cores) can differ from system to system in their meaning. Or not, really don't know for sure. In my DSDT I have 8 TMPx registers defined (TMP0-TMP7), so if you have more or less, you can experiment there. It is also possible to modify ACPIMonitor to include GPU sensor definition, but I'm too lazy for that, reading it as Northbridge suits me just fine.

_________________
ThinkPad T60p with Snow Leopard 10.6.8
Intel Core 2 Duo T7600
4GB RAM, ATI FireGL V5200 256MB (1400x1050)


Top
 Profile  
 
PostPosted: Tue Dec 21, 2010 5:34 pm 
Offline
Junior Member
Junior Member

Joined: Mon Mar 09, 2009 6:02 am
Posts: 280
Location: Paris, France
Silencer wrote:
I got the fan rpm reading working! I also enabled four different temperature sensors in iStat, your example only gives me two.

So, to get rpm reading working first you need to add the code below to the Device (EC), right after the big block Field (ECOR, ByteAcc, NoLock, Preserve).
Code:
// Fan Speed reading in rpm
Field (ECOR, ByteAcc, NoLock, Preserve)
{
    Offset (0x84),
    HFN1,   16
}

Amazing ... :eek: ... I've been looking foe this DSDT trick for 24 long hours ! ... Thanks !

Silencer wrote:
I think TMPx sensors except TMP0 and TMP1 (two CPU cores) can differ from system to system in their meaning. Or not, really don't know for sure. In my DSDT I have 8 TMPx registers defined (TMP0-TMP7), so if you have more or less, you can experiment there. It is also possible to modify ACPIMonitor to include GPU sensor definition, but I'm too lazy for that, reading it as Northbridge suits me just fine.


I used this page to map the thermal sensors : viewtopic.php?t=31837 ( and this has been posted also in thinkwiki : http://www.thinkwiki.org/wiki/Thermal_sensors )
Code:
Label     Address     Typical Temp        Notes
CPU        0x78         36-40      CPU for sure
BAT1a      0x79         32         Battery (main) - heats up when laptop on battery power, cool when AC
PWR        0x7a         40-46      Power diodes   - sensor left of CPU, top side
BAT2a      0x7b                    (probably) Ultrabay 2000 Battery (main?)
BUS        0x7c         48         Northbridge - sensor below and left of Northbridge, bottom of MB
PCM        0x7d         25         PCM/ambient - near VGA 9pin plug (LM75 single temp sensor chip); seems always lowest temp (room temp)
BAT1b      0x7e         31         Battery (ambient) - 0 when battery removed, but doesn't heat up under battery load
BAT2b      0x7f                    (probably) Ultrabay 2000 battery (ambient?)
-          0xc0           0        none of these (below) have any values
-          0xc1           0            "
-          0xc2           0            "
-          0xc3           0            "

_________________
Lenovo X60t (6363-AQ8)
    Intel CoreDuo 1,67 GHz (L2400)
    3 Go / 320 Go / GMA950 / FW 400 / SD Card
    Bluetooth / Wifi AR5BXB6 / Tablet
WinXP / MacOSX 10.6.8 (DSDT patch and vanilla SLE)


Top
 Profile  
 
PostPosted: Tue Dec 21, 2010 5:41 pm 
Offline
Junior Member
Junior Member

Joined: Sat Dec 25, 2004 8:17 pm
Posts: 345
Location: Riga, Latvia
Well, if I have TMPx sensors assigned as per the code example above, I get the following picture: http://www.ljplus.ru/img4/s/i/silencers/t60p_temps.png

_________________
ThinkPad T60p with Snow Leopard 10.6.8
Intel Core 2 Duo T7600
4GB RAM, ATI FireGL V5200 256MB (1400x1050)


Top
 Profile  
 
PostPosted: Sat Feb 05, 2011 8:02 am 
Offline
Freshman Member

Joined: Tue Oct 12, 2010 8:02 am
Posts: 78
Location: Berlin, Germany
Thank you, Silencer and Sebinouse, for this information! - Sebinouse, could you integrate this into your X60T's package's DSDT?


Top
 Profile  
 
PostPosted: Sun Feb 06, 2011 4:46 am 
Offline
Junior Member
Junior Member

Joined: Mon Mar 09, 2009 6:02 am
Posts: 280
Location: Paris, France
It's almost done, I am just gathering more informations about the X61 hack to make the package more relevant ... :wink:

_________________
Lenovo X60t (6363-AQ8)
    Intel CoreDuo 1,67 GHz (L2400)
    3 Go / 320 Go / GMA950 / FW 400 / SD Card
    Bluetooth / Wifi AR5BXB6 / Tablet
WinXP / MacOSX 10.6.8 (DSDT patch and vanilla SLE)


Top
 Profile  
 
PostPosted: Mon Feb 07, 2011 12:13 pm 
Offline
Freshman Member

Joined: Tue Oct 12, 2010 8:02 am
Posts: 78
Location: Berlin, Germany
Sebinouse wrote:
It's almost done, I am just gathering more informations about the X61 hack to make the package more relevant ... :wink:


Okay, wonderful. - I'm currently experimenting a bit with the ThinkPad 11a/b/g/n Wireless LAN Mini Express Adapter, the one I wrote about earlier in the X60T thread. I ordered myself one on eBay and have meanwhile build it into my X60 Tablet replacing the "driverless" Intel 3945abg miniPCI card with draft n-WLAN (more on that to come in the X60T thread, too, when I have the time). It works quite well using Apple's own Atheros drivers and your Legacy Kext, but seems to be quite a "heater", though, more on Snow Leopard than on Windows. - So, to cut a long story short: Having some sort of access to controlling the ThinkPad's fan under Snow Leopard would be really appreciated at the moment ... ;-)


Top
 Profile  
 
PostPosted: Mon Feb 07, 2011 4:31 pm 
Offline
Junior Member
Junior Member

Joined: Mon Mar 09, 2009 6:02 am
Posts: 280
Location: Paris, France
You just have to copy this DSDT.aml in /E, the kexts in /E/E, repair permissions and install istat 2.0 :

http://www.mediafire.com/?uyi89lkbepd4pvs

http://mac.brothersoft.com/istat-menus-2.0.html

_________________
Lenovo X60t (6363-AQ8)
    Intel CoreDuo 1,67 GHz (L2400)
    3 Go / 320 Go / GMA950 / FW 400 / SD Card
    Bluetooth / Wifi AR5BXB6 / Tablet
WinXP / MacOSX 10.6.8 (DSDT patch and vanilla SLE)


Top
 Profile  
 
PostPosted: Tue Feb 08, 2011 12:24 pm 
Offline
Freshman Member

Joined: Tue Oct 12, 2010 8:02 am
Posts: 78
Location: Berlin, Germany
Sebinouse wrote:
You just have to copy this DSDT.aml in /E, the kexts in /E/E, repair permissions and install istat 2.0 :


Thank you! I tried it - and it works sans problème with my X60T. Here's a screenshot:

Image

Both CPU cores are usually around 55° C, CPU Heatsink has produced temperatures between 65° C and 72° C so far (quite high - is that normal?), Northbridge seems to stay permanently at 28° C (is there a sensor for that at all?). SystemFan is at ~ 2500 rpm, but I've seen it up to 4200 rpm when I did more CPU consuming activity (HD playback etc.). And, as you can see, I recently exchanged my Samsung HD for a 750 GB WD Scorpio Blue ... :-)


Top
 Profile  
 
PostPosted: Mon Mar 07, 2011 8:42 am 
Offline

Joined: Mon Oct 25, 2010 9:48 am
Posts: 12
Location: OSLO, NORWAY
Hi
Thanks for the hard work, now i can control my Fan.
However regarding the sensors, We do not have Offsect (0xc0) Under Device (EC). just wondering if it is possible to add them back to our DSDT. However i do not know their names. I think c1 is for PCI, c0 for North bridge. C2 for chipset.

Edit: Assigning them as TMP8 TMP9 and TMP0A offset (0xc0). i got 2 more readings, but not sure what they are , probably Northbridge or something


Top
 Profile  
 
PostPosted: Thu Nov 17, 2011 4:47 pm 
Offline

Joined: Thu Nov 17, 2011 4:41 pm
Posts: 2
Location: USA
Hey! You guys look like you've done well! I've installed Lion on a HP Probook 4530s, and am trying to get fan control similar to this:

Code:
Device (SMCD) // System Monitor and Controll Device
             {
                  Name (_HID, "monitor") // Driver will look for this in order to load or not
                  Method (FAN0, 0, NotSerialized) // ACPIMonitor FAN 0 Speed
                  {
                      Store (\_SB.PCI0.LPC.EC.HFN1, Local0) // Store FAN 0 Control to Local0
                      Return (Local0)
                  }
                  Method (TSYS, 0, NotSerialized) // ACPIMonitor - GPU Temperature as Northbridge (T60p)
                  {
                      Store (\_SB.PCI0.LPC.EC.TMP3, Local0)
                      Return (Local0)
                  }
                  Method (TAMB, 0, NotSerialized) // ACPIMonitor - Temperature
                  {
                      Store (\_SB.PCI0.LPC.EC.TMP2, Local0)
                      Return (Local0)
                  }
                  Method (TDIM, 0, NotSerialized) // ACPIMonitor - Most Probably Battery Temperature as Memory Controller (T60p)
                  {
                      Store (\_SB.PCI0.LPC.EC.TMP6, Local0)
                      Return (Local0)
                  }
               Method (TCPU, 0, NotSerialized) // Fan Mode Accordind CPU Heatsink Temperature
               {
                  Store (\_SB.PCI0.LPC.EC.TMP0, Local0)
                  If (LLessEqual (Local0, 0x32))  // CPU Temp is <= 50C
                  {
                     Store (Zero, \_SB.PCI0.LPC.EC.HFSP) // Set FAN Off
                  }
                  If (LGreaterEqual (Local0, 0x55)) // CPU Temp is >= 85C
                  {
                     Store (0x40, \_SB.PCI0.LPC.EC.HFSP) // Set FAN Mode Disengaged - Absolute Maximum
                  }
                  Else {
                     If (LGreaterEqual (Local0, 0x4B)) // CPU Temp is >= 75C
                     {
                        Store (0x07, \_SB.PCI0.LPC.EC.HFSP) // Set FAN Mode 7 - Maximum Speed
                     }
                     Else {
                        If (LGreaterEqual (Local0, 0x46)) // CPU Temp is >= 70C
                        {
                           Store (0x04, \_SB.PCI0.LPC.EC.HFSP) // Set FAN Mode 4 - Medium Speed
                        }
                        Else {
                           If (LGreaterEqual (Local0, 0x41)) // CPU Temp is >= 65C
                           {
                              Store (0x02, \_SB.PCI0.LPC.EC.HFSP) // Set FAN Mode 2
                           }
                           Else {
                              If (LGreaterEqual (Local0, 0x3D)) // CPU Temp is >= 61C
                              {
                                 Store (0x01, \_SB.PCI0.LPC.EC.HFSP) // Set FAN Mode 1 - Lowest Speed
                              }
                           }
                        }
                     }
                  }
                  Return (Local0)
               }
      }


I just wanted to ask, did you insert that device under EC?

I have an EC0 which I think is equivalent. But I can't figure out how exactly to do this, and there doesn't appear to be an easy guide out there.

Also, how did you get those values for temperature? Would they be the same on my machine?

Thanks for the help!


Top
 Profile  
 
PostPosted: Mon Nov 21, 2011 3:19 am 
Offline
Junior Member
Junior Member

Joined: Sat Dec 25, 2004 8:17 pm
Posts: 345
Location: Riga, Latvia
bkribbs wrote:
I just wanted to ask, did you insert that device under EC?

No, you add it at the root level.

bkribbs wrote:
Also, how did you get those values for temperature? Would they be the same on my machine?

Since you have an HP machine, most probably code examples from this thread won't work for you. You need to find proper registers for your laptop yourself.

_________________
ThinkPad T60p with Snow Leopard 10.6.8
Intel Core 2 Duo T7600
4GB RAM, ATI FireGL V5200 256MB (1400x1050)


Top
 Profile  
 
PostPosted: Thu Nov 24, 2011 12:17 am 
Offline

Joined: Thu Nov 17, 2011 4:41 pm
Posts: 2
Location: USA
Right. And how would I go about tracking down all of the registers?


Top
 Profile  
 
PostPosted: Fri Jan 06, 2012 3:22 pm 
Offline

Joined: Fri Jan 06, 2012 3:10 pm
Posts: 1
Location: Xae, Austria
Nice post. There are even people transfering your findings to other thinkpad models (W520 http://www.insanelymac.com/forum/index. ... pic=273621).

I'm right now trying to transfer the DSDT patch to a X121e Thinkpad,
but the DSDT file looks totally different (even different to the W520 mentioned, which is also from 2011).

TPFanControl in Windows works fine. So I suppose the interface should be
the same.

Where would be the position to try patching the X121e's DSDT?

DSDT.aml: http://tonymacx86.com/download/file.php?id=14264 (sry no file upload permission on this forum)

(P.S.: Can someone suggest a good theory tutorial on DSDT and its structure?)

_________________
ThinkPad X121 Core i3 HD 3000


Top
 Profile  
 
PostPosted: Mon Jan 14, 2013 3:07 am 
Offline

Joined: Mon Jan 14, 2013 2:57 am
Posts: 1
Location: shanghai, china
Hi guys,

I tried on my x61 with Lion, but the fan still cannot be stopped.
However, I can manually stop it through the blue thinkadvange button.
Also I have installed istat, version 4.03, but cannot get the fan speed info.


Top
 Profile  
 
PostPosted: Sun Feb 03, 2013 4:25 am 
Offline

Joined: Fri Jan 09, 2009 6:55 am
Posts: 17
Location: Hanoi, VietNam
milanas wrote:
Hi guys,

I tried on my x61 with Lion, but the fan still cannot be stopped.
However, I can manually stop it through the blue thinkadvange button.
Also I have installed istat, version 4.03, but cannot get the fan speed info.


I followed the instruction from Anastasius (from here) and have all working fine with istat menus 4.03. You'll need his dsdt and install FakeSMC.kext to get them working.

_________________
T60p 2007-8JU

X61 7675-4KU


Top
 Profile  
 
Display posts from previous:  Sort by  
Post new topic Reply to topic  [ 30 posts ] 

All times are UTC - 5 hours


Who is online

Users browsing this forum: No registered users and 6 guests


You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum

Search for:
Jump to:  
cron
Powered by phpBB® Forum Software © phpBB Group