Add a custom fan daemon

From OpenFSG

Jump to: navigation, search

Contents

Introduction

What FAND is?

  • The fand (fan daemon) is the "program" that controls the speed of the fan of the FSG, depending of the temperatures of the inside of it.
  • The fand "reads" the temperature of Power Supply, Controller and CPU. If those temperatures rise up from a fixed values, the fan increase it's speed. There is a graphic explanation here
  • The fan daemon (fand) that comes with the FSG firmware has some hard coded values. The C code of the original fand is here

Original FAND settings

  • FSG has 3 cooling modes:
    • Standard (the most used)
      • "method=0" at master.conf file
    • Max (too noising)
      • "method=1" at master.conf file
    • Hot and Silent (not recomended for long time use)
      • "method=2" at master.conf file
  • Here you can find the temperature settings of the original fand (temperatures in Celsius degrees) for the "STANDARD Cooling" option:
temp1low=62; temp1hi=80;      (t1 measured at power supply)
temp2low=37; temp2hi=56;      (t2 measured at IDE / WLAN)
temp3low=47; temp3hi=56;      (t3 measured at CPU)

Why to change FAND?

  • Some users think that the FSG fan is too noisy. But "HOT and SILENT" cooling method seems not to be a good idea for long time running.
  • So, some users want to change the original fand settings. With a little change of the temperature settings, the fun runs much more less times, but the temperatures inside FSG does not rise much... FSG stays quiet if you simply broaden the temperature ranges a little bit. The temperatures inside FSG do not change much, but so far the fan stayed a its lower setting all the time (even during calculation of a hash for a 4 GB torrentfile).

Settings Advised

  • This is the temperatures advised for a "Quiet and little Hot" FSG:
temp1low=62; temp1hi=80;
temp2low=44; temp2hi=56;
temp3low=47; temp3hi=64;

This temperature settings begins fan 7º up (at 44º instead of 37º) at IDE/WLAN and allow 8º more at CPU. That is not much. Just thing that "HOT and SILENT" mode begings fan at 50º at IDE/WLAN and allow 65º at CPU.

  • If you want to be more "conservative", you can try with:
temp1low=62; temp1hi=80;
temp2low=41; temp2hi=56;
temp3low=47; temp3hi=60;

Custom FAND

  • For this purpose a custom fan daemon is build that allows a user to specify values in the master.conf file.
  • This page offers a howto for the FSG. The code for the custom fan daemon is also for the DataTank. Because I don't own one, I can't test it. A version for the DataTank has to be compiled yourself or by somebody else. Code for the app can be found at the bottom of this page.



Using this fan daemon is at your own risk. Picking wrong setting can ultimately lead to a dead FSG, so be careful.


Requirements

  • For Firmware 4.x, here you have the compiled custom fand, and the source code:

The custom fan daemon for 4.x

  • For firmware 3.x, here you have the compiled custom_fand

The custom fan daemon for 3.x


Procedure

1. Download the custom fan daemon

2. Login as root using SSH

3. Make a backup of the standard fand, located in /usr/bin/fand

This will create a copy called "fand.bk"
/ # cp /usr/bin/fand fand.bk

4. Make a backup of the current master.conf file, located in /etc/master.conf

This will create a copy called "master.conf.bk"
/ # cp /etc/master.conf master.conf.bk

5. Place the custom fan daemon in /usr/bin and rename to fand OR place the custom fan daemon anywhere and make a symbolic link in /usr/bin

/ # mv <location>/custom_fand /usr/bin/fand

OR

/ # ln -s <location>/custom_fand /usr/bin/fand

6. Give correct rights to fand:

/usr/bin # chmod +x /usr/bin/fand


7. Edit the master.conf file

/ # vi /etc/master.conf

Look for the line that says: "fand_method=<N>" (N can be 0, 1 or 2 depending on the fan cooling method you have selected) Change the value to 3, so it says "fand_method=3" Add de following lines underneath and change the <N> values. NOTE THAT: N values are in centigrade

fand_temp1low=<N>
fand_temp1hi=<N>
fand_temp2low=<N>
fand_temp2hi=<N>
fand_temp3low=<N>
fand_temp3hi=<N>

The file should now look something like this: (with the "conservative" values advised before)

...
tz=GMT0.26
dst=MEST,M3.5.0/1,M10.5.0/1
hd_time=0
fand_method=3
fand_temp1low=62
fand_temp1hi=80
fand_temp2low=41
fand_temp2hi=56
fand_temp3low=47
fand_temp3hi=60

log_files=
...

8. Test the fand

/ # killall fand

This stops the old "fand" program running on memory. The "physical" fan stops, too. Now, you must run the new fand:

/ # /usr/bin/fand

The application will spit out useful info

9. Reboot the FSG

Errors

Permission denied

If get a "permission denied" when you try to run the program:

/usr/bin # fand
/bin/sh: fand: Permission denied

Is because you forget to let the correct permissions to "fand".

Whenever you get a "/bin/sh: <app>: Permission denied" you know it has something to do with your app being in the wrong location or having the wrong rights. It should work after you do a chmod.

I can not select other Cooling Methods from Freecom Web Interface

Edit master.conf and let "fand_method=<N>", were N can be 0, 1 or 2. When the 0,1,2 values are set, the Freecom Web Interface runs properly in the Cooling method selection. When the "3" value is set, you'll get the new custom cooling method, but the FWI will not run in the cooling method selection.

Coming back to the original state

Just come back with the backuped files:

/ # mv /usr/bin/fand.bk fand
/ # mv /etc/master.conf.bk master.conf

And then, stop the running custom_fand and re-start the old fand:

/ # killall fand
/ # /usr/bin/fand

Download

  • For Firmware 4.x, here you have the compiled custom fand, and the source code:

custom_fand.zip

  • For firmware 3.x, here you have the compiled custom_fand

Custom_fand_3_x.zip


Info about temperatures

Acceptable Temperatures:

Here you can find the comments of Rbar (nice guy from Freecom), about the temperatures:

The conclusion is that the temperatures must be:

  • T1 (PowerSupply) < 65-70º
  • T2 (IDE / WLAN) < 65º
  • T2 (CPU) <65-70º

In addition you should also care for the hard disk of your Freecom device: hard disks also have a maximum operating temperature. You can look it up in the data sheet of the respective hard disk manufacturer. Often the maximum hard disk temperature is around 65º.

Practical Temperatures

The conditions of testing were these:

  • Hot&Silent (30 min working)
    • Fan silent
  • Standard (Working for hours)
    • Noising fan, coming from 6000 to 9000 rpm
  • Standard (not working for hours, at the beginig of the work)
    • Silent fan (4000 rpm)
  • Max Ref (30 min working)
    • Noising fan, 10.000 rpm
  • Conservative (working for hours)
    • PEACE :-) Fan awakes only sometimes, when FSG is really working

Many days testing my FSG, and here are the results:


Practical FSG Teperatures
MODE Hot&Silent Standard (Working) Standard (sleeping) Max Ref Conservative
T1 (Power Suply) 63-66º 60-63 59 59-61 61-66
T2 (IDE / WLAN) 52-56º 49-52 48 48-51 51-55
T3 (CPU) 55-60 52-55 51 52-53 55-59

Are the "conservative" temperatures acceptables?

According to both previos points, YES.

  • The "conservative" PWS temperature is acceptable, been in the range of 61-66.
    • The temperature of PWS is 3-4º more than in the standard method.
    • The Power Supply is the hardest piece of the 3 with temperature readings.
  • The "conservative" IDE and the CPU temperatures are lower than acceptable ones.
    • And both values are very close to the ones you get with the "standard" method. (3º more for the IDE and 4º more for the CPU).

More Info

New fan Daemon for the FSG

Personal tools