{"id":90,"date":"2009-12-13T12:55:10","date_gmt":"2009-12-13T17:55:10","guid":{"rendered":"http:\/\/wukenny.host-ed.net\/?p=90"},"modified":"2009-12-13T12:55:10","modified_gmt":"2009-12-13T17:55:10","slug":"aspireone-the-noisy-fan-hack","status":"publish","type":"post","link":"http:\/\/kennywu.info\/?p=90","title":{"rendered":"Aspireone the noisy fan hack"},"content":{"rendered":"<li>Download the<a href=\"http:\/\/code.google.com\/p\/aceracpi\/wiki\/EmbeddedController\"> acer_ec.pl<\/a> script.<\/li>\n<li>Download the <a href=\"http:\/\/electronpusher.org\/~rachel\/acerfand\">acerfand<\/a> daemon script.<\/li>\n<p>Execute these lines in a terminal in the directory you downloaded the above scripts:<br \/>\n<code>chmod a+x acerfand<br \/>\nsudo cp acer_ec.pl acerfand \/usr\/local\/bin\/<\/code><br \/>\nTo run it straight away:<br \/>\n<code>sudo acerfand<\/code><br \/>\nTo run it at boot:<br \/>\n<em>In Ubuntu:<\/em><br \/>\n<code>gksu gedit \/etc\/rc.local<\/code><br \/>\nInsert the following line above the <em>&#8220;exit 0&#8221;<\/em> at the bottom:<br \/>\n<code>\/usr\/local\/bin\/acerfand<\/code><br \/>\n<em>In Linpus Linux Lite:<\/em> (default Aspire One installation)<br \/>\nAs root :<br \/>\n<code>vi \/etc\/rc.local<\/code><br \/>\nPress i to switch to INSERT mode and add the following line at the bottom :<br \/>\n<code>\/usr\/local\/bin\/acerfand<\/code><br \/>\nPress Esc and type <code>:wq<\/code> to save and quit<br \/>\nOptionally create an <strong>\/etc\/acerfand.conf <\/strong>file. The file is just a shell script that sets up to three values. eg:<br \/>\n<code>INTERVAL=5<br \/>\nFANOFF=60<br \/>\nFANAUTO=70<\/code><br \/>\nThose are the default values, if the \/etc\/acerfand.conf file isn&#8217;t found.<br \/>\n<strong>INTERVAL<\/strong> is the polling interval in seconds<br \/>\n<strong>FANOFF<\/strong> is the temperature at or below which to turn the fan off, if it&#8217;s currently on auto<br \/>\n<strong>FANAUTO<\/strong> is the temperature at or above which to turn the fan to auto, if it&#8217;s currently off.<br \/>\n==========<br \/>\nRead all registers:<br \/>\n<code>sudo perl acer_ec.pl regs<br \/>\nsudo perl acer_ec.pl regs &gt; test.txt<\/code><br \/>\nRead one register:<br \/>\n# 51 is the address of the register in hexadecimal<br \/>\n<code>sudo perl acer_ec.pl ?= 51<\/code><br \/>\nWrite value to one register:<br \/>\n# 51 is the address in hexadecimal of the register to be written, and 0 is the value to write, also in hexadecimal.<br \/>\n<code>sudo perl acer_ec.pl := 51 0<\/code><\/p>\n<p>Convenient commandline to monitor the temperature. (Register 58 is thought to be CPU temperature, in degrees C):<br \/>\nThis also assumes you&#8217;re already root and have made acer_ec.pl executable. eg:<br \/>\n<code># Become root<br \/>\nsudo su -<br \/>\n# Make the script executable<br \/>\nchmod a+x acer_ec.pl<br \/>\n# Read the temperature and display in decimal every 2 seconds<br \/>\nwatch -n 2 'echo Temp: $[$(.\/acer_ec.pl ?= 58 | cut -f 3 -d\" \")] C'<br \/>\n<\/code><br \/>\nNB: For this to work, \/bin\/sh must invoke bash. Usually \/bin\/sh is a symlink to \/bin\/bash, but in Ubuntu this is not the default, and as a result the conversion of the temperature from hexadecimal to decimal won&#8217;t occur.<\/p>\n<p>To change \/bin\/sh to point to \/bin\/bash, on Ubuntu, as root:<br \/>\n<code>ln -sfn \/bin\/bash \/bin\/sh<\/code><\/p>\n","protected":false},"excerpt":{"rendered":"<p>Download the acer_ec.pl script. Download the acerfand daemon script. Execute these lines in a terminal in the directory you downloaded the above scripts: chmod a+x acerfand sudo cp acer_ec.pl acerfand \/usr\/local\/bin\/ To run it straight away: sudo acerfand To run &hellip; <a href=\"http:\/\/kennywu.info\/?p=90\">Continue reading <span class=\"meta-nav\">&rarr;<\/span><\/a><\/p>\n","protected":false},"author":2,"featured_media":0,"comment_status":"open","ping_status":"open","sticky":false,"template":"","format":"standard","meta":{"footnotes":""},"categories":[8],"tags":[15],"class_list":["post-90","post","type-post","status-publish","format-standard","hentry","category-lamp","tag-aspireone"],"_links":{"self":[{"href":"http:\/\/kennywu.info\/index.php?rest_route=\/wp\/v2\/posts\/90","targetHints":{"allow":["GET"]}}],"collection":[{"href":"http:\/\/kennywu.info\/index.php?rest_route=\/wp\/v2\/posts"}],"about":[{"href":"http:\/\/kennywu.info\/index.php?rest_route=\/wp\/v2\/types\/post"}],"author":[{"embeddable":true,"href":"http:\/\/kennywu.info\/index.php?rest_route=\/wp\/v2\/users\/2"}],"replies":[{"embeddable":true,"href":"http:\/\/kennywu.info\/index.php?rest_route=%2Fwp%2Fv2%2Fcomments&post=90"}],"version-history":[{"count":0,"href":"http:\/\/kennywu.info\/index.php?rest_route=\/wp\/v2\/posts\/90\/revisions"}],"wp:attachment":[{"href":"http:\/\/kennywu.info\/index.php?rest_route=%2Fwp%2Fv2%2Fmedia&parent=90"}],"wp:term":[{"taxonomy":"category","embeddable":true,"href":"http:\/\/kennywu.info\/index.php?rest_route=%2Fwp%2Fv2%2Fcategories&post=90"},{"taxonomy":"post_tag","embeddable":true,"href":"http:\/\/kennywu.info\/index.php?rest_route=%2Fwp%2Fv2%2Ftags&post=90"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}