Jump to content

Drivers for fan control on Dell Laptops


PotatoSalad
 Share

40 posts in this topic

Recommended Posts

Update (May 13, 2007 09:24:21 EDT): I completely rewrote the driver in C and renamed it from IOI8KFan.kext to simply I8kfan.kext. It uses the BSD sysctl to communicate with other things because I'm lazy and this route was the easiest I could figure out.

 

I also wrote a small app with the unoriginal name of I8kfanGUI. Using the application to monitor the CPU temperature, my Inspiron 5100 went from running at 60°C to hovering between 38°C to 43°C.

 

Read more about the driver and the application here.

 

Downloads:

 

I8kfanGUI_v0.1.dmg (sources included)

I8kfanGUI_v0.1-source.zip

I8kfan_v1.0.0d1-source.zip

 

Update (May 5, 2007 12:10:51 EDT): Using the code from the Linux 2.4.x and FreeBSD I8kfan drivers (listed below) I wrote a very rudimentary driver called IOI8KFan.kext because I couldn't think of a more original name.

 

IOI8KFan.zip

IOI8KFan_source.zip

or

IOI8KFan.kext: http://www.mediafire.com/?dymzzmtm2m1

IOI8KFan Source: http://www.mediafire.com/?0zkmzy2xy4z

 

As of now, the kext simply spits out some information about the CPU temperature and fan settings (speed setting, fan RPM) and then kicks the fan temporarily into it's highest setting (fan speed 2). It only does this when loading the kext and it would be great if it was...uh...written better.

 

My knowledge of writing IOKit drivers for Mac OS X is very limited and it would be greatly appreciated if someone with more experience would help me out with cleaning them up.

 

===

 

I have Mac OS X installed on my Dell Inspiron 5100, which is notorious for overheating. On Windows, I "solved" the problem by using I8kfanGUI to force the fan into overdrive when the computer begins to overheat. I need something similar for Mac OS X, but I have no idea where to start.

 

There are numerous examples available for Dell fan drivers...

 

Windows/DOS: http://www.diefer.de/i8kfan/i8kfan.html

Linux 2.4.x: http://people.debian.org/~dz/i8k/

Linux 2.6.x: http://dellfand.dinglisch.net/

FreeBSD: http://www.angelfire.com/punk4/bofn1001/

 

If anyone has any experience on writing low-level drivers for Mac OS X, please lemme know.

Link to comment
Share on other sites

  • 2 months later...

Thanks! This really helped me out with my E1705.

 

Just some bugs I've found.

 

Manual control doesnt work too well. When the GUI is set to manual you cant change the fan settings. If the fans running on low and you try to change it to high it will switch right back.

 

I also saw the dual fan GUI on your blog. The dual control doesnt work at all and in fact keeps turning the second fan off when you give the program control of the fans. Good thing is the single fan version doesnt shut off the second fan. The second fan runs normal so even though I have two fans I'll be sticking with the single fan version.

 

My only problem right now is that I cant install the kext so that I dont have to manuallly load it after a reboot. Any suggestions?

Link to comment
Share on other sites

  • 1 month later...

Thanks for your effort! Works really well on my dell latitude d820. Only little glitch is that the kext does not load automatically, I have to load it manually after starting.

Any idea as to why is this so?

 

Many thanks! ;)

robcad

Link to comment
Share on other sites

  • 7 months later...

Didn't mean to bring up a dead post, but I decided to give this a try. I have a Dell Latitude D620 running XxX(Black_Ch) 10.4.11 fully updated. It worked great. I never see temperatures get above 35*C.

 

I ended up writing a startup command that will load this kext, you still have to put the password in manually. It will bring up Terminal and wait for your password before loading. I've also found that if you setup specific temperature triggers for your fan, you can exit the application and have it still work.

 

Make sure you put the kext in /system/library/extensions, or the Terminal command wont work. Place it anywhere you'd like, then add it to the startup item list in System Preferences. Also, make sure you command click the txt file and rename it to .command. Otherwise it wont work.

 

Fan_Control.txt

 

If you know more about writing commands and have any clue how on earth to pipe in your password, please inform me. I've been attempting and failing for about 4 days.

Link to comment
Share on other sites

Dont mean to bring back a dead thread, but I noticed a few things.

 

1. SpeedStep works. I'm not sure how, or what I did to make it work but it does. I thought it was the ACPICPUThrottle.kext, but I removed it and OS X is still throttling my CPU down. Only if I unplug the power cord. I think it is the kernel I chose while installing. I have EFI, and am totally up to date.

 

2. If I dont unplug the power cord, or start the laptop on battery power, it stays at 1.87Ghz. But if I start the laptop on AC power and then unplug the power supply (or the battery) the CPU drops to 1.0Ghz. If I start the laptop on battery, then plug the power cord in, OS X will start at 1.87Ghz and throttle the CPU down to 1.0Ghz. A complete reverse from starting on AC power.

 

3. Temps hover around 40*C at 1.87Ghz. Temps hover around 32*C at 1.0Ghz. This is with the fan controller kext loaded.

 

4. I read on the Apple website that OS X has a built in CPU throttler that will slow your CPU down if your running on battery power. This is to prevent heat from building up and to prevent battery drainage. I'm assuming this is what is underclocking my CPU.

 

5. Try as I might, I can not get it to stay at 1.0Ghz. I have to pay attention to how I started it and adjust the power cord to how I want it. If I start on AC and remove the power cord, it will from then stay at 1.0Ghz.

 

6. I dont have to auto-start the fan controller application. I can just load the kext associated with it, and everything works just fine.

 

And this is what I've come up with:

 

1. Only run at 1.0Ghz when traveling. This is to save battery and temperature while the laptop is in the carrying case. That, and I get about 2 hours of usage when running at 1.0Ghz. I tested this last night at school. The fan runs constantly, and slightly faster than "Low" and slightly slower than "High". It wont vary at all. Temps hover around 35 in the case.

 

2. Speed is significantly faster when running at 1.87Ghz. The fan will shut off periodically, and will adjust between "High" and "Low". Temps will vary from 35 to 45*C. It will get to 55 if I manage to have it in the case running that fast.

 

I'm looking into editing the plist to see if I can set my own fan speeds. You can set temperature triggers in the application that controls the fan, but all I get is "High" and "Low". I'd like to set what high and low are. Maybe see if I cant add a "Medium". I'm also looking into how to add profiles and adding support for Intel users. Not only Dell users. (This means adding a lot of search loops. Yay.) The biggest thing I'd like to have a go at, is having it automatically start the fan controller application. I can add my command that autoloads the kext.

 

Expect some questions.

Link to comment
Share on other sites

  • 2 weeks later...
  • 2 weeks later...

To bad this is only for Dells as I have a lenovo N200 and for some reason my system just will not run the fan sometimes. I tried this kext and the app on my system but it does nothing to my fans. They remain the way they were.

 

I get speedstep to run with netkas 9.2.0 SS kernel and everything appears to work but then the system will just decide to not turn the fan on and the temps will start climbing. Another odd thing is it tends to happen more when on battery. My system does think its on battery all the time (even when plugged in) and maybe thats why. In either case I am just trying to figure out what kext controls the fan in ACPIplatform.kext so I can load that when my system starts to get to hot. Is there such a kext?

Link to comment
Share on other sites

  • 3 weeks later...
  • 2 weeks later...

I recently upgraded to Leo4All version 3. Great disk, for those of you wanting to go to Leopard.

 

This driver doesnt work in Leo. At all. The kext wont load, and comes up with an error claiming:

 

"The kernel extension has not been authenticated. It will not be loaded. Please check the author for an update."

 

Just an update for all you overheated Dell users.

Link to comment
Share on other sites

  • 1 month later...

I've got this fully working on an Dell Inspiron 9300 under Leopard. A slight fix was needed to get the kext source to compile but once that was done it works exactly like it should. If there is any interest in this still i'll post the kext.

Link to comment
Share on other sites

I've solved all the issues with this driver. Problems fixed:

 

- Compiles in 10.5

- Automatically starts on load (Now an IOKit extension)

- GUI starts hidden

- No dock icon for GUI

- Outputs text on load (so you actually know its working)

 

Thanks to Kabyl and Sam for their help in fixing this.

 

I'll send the diffs to the author and hopefully he can provide an updated version. If I don't get a reply back from him i'll post the source code diffs.

Link to comment
Share on other sites

Couldn't find an email for the author so will just post the source diffs here.

 

Original source came from:

http://i8kfan.googlecode.com/files/I8kfan_....0d1-source.zip

http://i8kfan.googlecode.com/files/I8kfanG...-source.tar.bz2

 

If you install I8kfanGUI in Applications I would recommend the following:

 

chown root:admin /Applications/I8kfanGUI.app/Contents/MacOS/I8kfanGUI

chmod 4755 /Applications/I8kfanGUI.app/Contents/MacOS/I8kfanGUI

 

Then in System Preferences / Accounts go to Login Items for your account and add I8kfanGUI and tick the hide box so the GUI doesn't appear. This will just show the CPU temp in the menu bar.

I8kfan_v1.0.0d1.zip

I8kfanGUI_v0.2.zip

Link to comment
Share on other sites

Couldn't find an email for the author so will just post the source diffs here.

 

Original source came from:

http://i8kfan.googlecode.com/files/I8kfan_....0d1-source.zip

http://i8kfan.googlecode.com/files/I8kfanG...-source.tar.bz2

 

If you install I8kfanGUI in Applications I would recommend the following:

 

chown root:admin /Applications/I8kfanGUI.app/Contents/MacOS/I8kfanGUI

chmod 4755 /Applications/I8kfanGUI.app/Contents/MacOS/I8kfanGUI

 

Then in System Preferences / Accounts go to Login Items for your account and add I8kfanGUI and tick the hide box so the GUI doesn't appear. This will just show the CPU temp in the menu bar.

 

I pretty much did the exact same thing. Except I didn't recompile the code.

 

I removed the dock icon with Dock Dodger.

 

I removed kextload issue by creating a login script that loads the kext. (Adding your user name to the sudoers file eliminates the need to input the password.)

 

I then used Pseudo to remove the administrator password to the I8kfanGUI application.

 

 

To be honest, I even removed the application icon and switched it with SMC Fan Control. (Along with the name...) If you 'show package contents' I8kfanGUI.app and remove the menu bar icon, it only shows the number. (Which I think is better)

 

I'll give your way a go though Dense, that way I don't have to worry about using 8 different applications to make one work properly.

Link to comment
Share on other sites

Hi i installed and at first was showing temperature and was stopping and changing speed of fan.

 

I rebooted and now does not shows temperature or do anything?????????

post-179170-1217501503_thumb.jpg

 

Clear your caches. When it shows values like that, the kext hasn't loaded.

Link to comment
Share on other sites

I've solved all the issues with this driver. Problems fixed:

 

- Compiles in 10.5

- Automatically starts on load (Now an IOKit extension)

- GUI starts hidden

- No dock icon for GUI

- Outputs text on load (so you actually know its working)

 

Thanks to Kabyl and Sam for their help in fixing this.

 

I'll send the diffs to the author and hopefully he can provide an updated version. If I don't get a reply back from him i'll post the source code diffs.

 

why u don't post the compile kexts?, the author don't write about this since may 13 2007 D:

Link to comment
Share on other sites

I've solved all the issues with this driver. Problems fixed:

 

- Compiles in 10.5

- Automatically starts on load (Now an IOKit extension)

- GUI starts hidden

- No dock icon for GUI

- Outputs text on load (so you actually know its working)

 

Thanks to Kabyl and Sam for their help in fixing this.

 

I'll send the diffs to the author and hopefully he can provide an updated version. If I don't get a reply back from him i'll post the source code diffs.

Could you post a step by step how to install I cannot get it to work anymore :)

Link to comment
Share on other sites

I've got this fully working on an Dell Inspiron 9300 under Leopard. A slight fix was needed to get the kext source to compile but once that was done it works exactly like it should. If there is any interest in this still i'll post the kext.

Could you post the kexts ????

Link to comment
Share on other sites

  • 2 weeks later...
Could you post the kexts ????
Here's another plea for those compiled kexts too please. My new toy an old Dell Precision M60 laptop is perfect for OSX with a 1920x1200 screen if only I culd control the fans & make it as silent as it is when running XP Pro.

 

Thanks in advance.

Link to comment
Share on other sites

 Share

×
×
  • Create New...