acer_5750G_fan_maximiser
acer_5750G_fan_maximiser copied to clipboard
"Port" to lm_sensors
Hi,
wouldn't it be better to report your findings to lm_sensors? This would be a nice improvement. I'm not yet sure if I want to risk it and try your program on my V3-571G, but maybe it works with a wider range of Acer systems
EDIT: It's working! Great job, thank you so much! A question for Windows: I have no experience developing for Windows and the cpp file won't compile (the official one doesn't work because it checks the model) – can you provide binaries? EDIT2: It was just missing the stdafx.h but one can just replace it with tchar.h as this is the only other header missing.
Hi!
Sorry, could you give more details about how could this work in the lm_sensors setting? I thought lm_sensors dealt with just temperature readings.
Closest I've gotten to finding a place for this was acer_hdf
( http://www.piie.net/?section=acerhdf ). Maybe that would be worth pursuing? Unfortunately I don't think I will have time to follow that up. I'm also still not sure how many laptops are fitted with the same EC (Embedded Controller - which is where these values end up being written to)
Regarding the edits I saw your changes, if you want, you can create a PR so I can merge them. Adding a binary for Windows is a good idea. I'll look into that! Thanks!
Hi,
there's fancontrol which is part of lm_sensors
.
If one could somehow make your research part of lm_sensors
it maybe could cover some more models with one program and would make it easier to find (I spent some hours searching for a solution like yours).
I personally have time to do that but not the skills ;-). I'm rather a hobbiest contributor but ofcourse trying to learn as much as I could – maybe when I find myself a bit more experienced in such things.
I can put the edits into a pull request if you wish to merge them – just tell me if you want to include the Readme edit too, or not. I replaced some parts, making it more general to show that it might work on other models, too.
Additionally I started working on a Qt GUI (https://github.com/LeonardKoenig/FanSetQt) which just wraps the perl-script / includes your c file. Although it works I found myself actually to lazy to finish it completely but maybe I'll do that some time soon. I actually plan to replace the perl-script with C for Linux too, in order to get rid of the additional dependency – so I might learn some new stuff and see what I can do with acer_hdf
or lm_sensors
.
So, just tell me what you want to pull and I make the prq ready, thanks for providing that awesome program!
That is really nice work with the QtGUI! Actually, if you want to keep on playing with this and maintain it, I would be more than happy :) This is because I probably won't be able to do any polishing work on it.
What surprised me the most was how undocumented those controls were: from browsing the bios moding forums, none of the previous methods worked on this model. I've kept the raw notes from when I looked into this: http://neduard.wikidot.com/acer-fancontroller-notes If the actual disassembly story is not that interesting, the links might prove useful.
I guess the main difficulty is figuring out the meaning of those magic values being written to ports 0x68
and 0x6C
. Also, why those ports and not the more popular 0x62
/ 0x66
? Finding that would probably give more insight into what the EC is running / some newer kind of firmware?
Then it would be possible to determine on what laptops this program works (those laptops which run the same EC). After than it would probably be a good idea to integrate it into either kernel drivers or userspace programs, as currently we have to rely on users manually trying this out and hoping it doesn't blow up anything.
I remember acer_hdf
had a nice list with laptop models and EC register / value pairs, but the communication protocol was different to what my script was doing so it might be interesting to find out how this way of communicating with the EC fits into how other methods work (fancontroller
from lm_sensors
seems to implement PWM?)
In any case, I'm happy to answer any questions you have to the best of my ability :D
Thanks, I try to keep it up but as I said, I'm still learning.
The lack of documentation surprised me too. What makes me wonder even more is that the program published by acer limits itself to 5750G via detecting the model though it apperently works on other models too. This is really oblivious to me.
The notes can prove useful in future, so thanks for the link!
Probably much time would be spent for research and understanding the other approaches, this takes both, time and skill, but sadly also much testing on hardware I fear, as I doubt acer will be much of a help.
So if you want to merge some things back, just say what commits you want to include or alternatively just git cherry-pick / merge them ;-)
Eduard and Leonard - respect to both of you for this effort. This high CPU temp/fan control problem has been bugging me on my ACER Aspire 5755g for ages, and I have only just found that you guys have cracked it.
I have now combined output from lm_sensors (cpu core temp) with the fan controller .pl script into a simple bash script that runs from cron each minute and sets the fan speed based on hi and low CPU temp thresholds. Simple, but effective. ''' #!/bin/bash
#Monitor to check CPU core temp, in relation to defined thresholds, and switch fan between NORMAL and MAX speed modes #Acer Fan Conteol does not seem to work correctly, leading to CPU temps ~ 100C
#Relies on utility from github, modified from ACER orig fan control code for windows #https://github.com/neduard/acer_5750G_fan_maximiser/blob/master/acer_5750G_fan_controller.pl
UPPER_THRESH=70 # Switch fan to MAX LOWER_THRESH=55 # Switch fan to NORMAL PERL=/bin/perl LOG=/var/log/$(basename $0).log
echo "#### $(date) " >> $LOG
CURR_CPU_TEMP=$(sensors | awk '/Physical id/ {split($4,A,"°") ; print A[1]}'|cut -c2-) echo "Current CPU temp: $CURR_CPU_TEMP" >> $LOG
if [[ $CURR_CPU_TEMP > $UPPER_THRESH ]] then echo "CPU temp exceeds $UPPER_THRESH, so switching fan to MAX speed" >> $LOG $PERL /usr/local/bin/fan_controller.pl MAX elif [[ $CURR_CPU_TEMP < $LOWER_THRESH ]] then echo "CPU temp less than $LOWER_THRESH, so switching fan to NORMAL speed" >> $LOG $PERL /usr/local/bin/fan_controller.pl NORMAL fi '''