Odroid XU3/4 Silent Fan Control in Lakka / OpenElec

If you are an owner of an Odroid XU4, you are probably annoyed by the noisy fan.

In this workshop we will modify the behavior of an Odroid XU4 Fan. No Hardware Modification, only software tweaks are used.

By default, the fan is always running at full speed and is pretty noisy. There is no need for this, and can easily be silenced down without risking CPU Damage.

Disclaimer !
This is tested on a XU4 only, but it should also work on a XU3 . (And only these 2 Models!)

I cannot be held responsible for any damage that might happen. Use at your own risk!

Credits go to https://github.com/nthx/odroid-xu3-fan-control

I just modified this script so that it works in OpenElec / Lakka

What we are basically doing :

  • Create a Fan Controller script which reads the CPU Temperature, and sets a Value for the Fan Speed accordingly.
  • Create a autostart Script so that our Fan Controller Scripts runs automatically

So, first login to your Odroid running OpenElec or Lakka by SSH. Use Putty on Windows or ssh in a terminal Window on Linux or MacOS. (like ssh root@ip.address.of.odroidxu4)


Download Scripts

I have attached the 2 scripts to this post, scroll down to find Download links

Then create the script fancontrol.sh :

nano .config/fancontrol.sh

copy the contents below, and save and quit by pressing “CTRL+X” , confirm with “y”

contents of fancontrol.sh :

# Credits: https://github.com/nthx/odroid-xu3-fan-control
# this must be placed in /storage/.config folder
# for following /storage/.config/autostart.sh startup
# script to work
# contents of /storage/.config/autostart.sh :
# (
# /storage/.config/fancontrol.sh
# ) &

#change to "/sys/devices/odroid_fan.13/pwm_duty" for Xu3

# Assume Fan is running at full Speed

# Disable Fan Auto Control Mode
echo 0 > /sys/devices/odroid_fan.14/fan_mode

while [ true ];
  # read current CPU Temperature
  CPUTemperature=`cat ${CPUTempReadFrom} | cut -c11- | sort -nr | head -1`

  if [ ${CPUTemperature} -ge 78000 ]; then
  elif [ ${CPUTemperature} -ge 75000 ]; then
  elif [ ${CPUTemperature} -ge 70000 ]; then
  elif [ ${CPUTemperature} -ge 68000 ]; then
  elif [ ${CPUTemperature} -ge 66000 ]; then
  elif [ ${CPUTemperature} -ge 63000 ]; then
  elif [ ${CPUTemperature} -ge 60000 ]; then
  elif [ ${CPUTemperature} -ge 58000 ]; then
  if [ ${FanSpeedActual} -ne  ${FanSpeedAdopted} ]; then
    echo ${FanSpeedAdopted} > ${FanSpeedSet}
  sleep 3 #check every 3 seconds

Then, make the script fan.sh executable :

chmod +x .config/fancontrol.sh

Repeat the process for the script autostart.sh :

nano .config/autostart.sh

contents of autostart.sh :

) &

Save and quit (“CTRL+X”), confirm with “y”

Script autostart.sh does not need to be executable.

That’s basically it. You just have to restart the Odroid. First Fan should be running at full speed and then slowing down.

The values are pretty safe for the CPU, but can be tweaked furthermore, if you want your Odroid to become even more silent. But beware of not overheating the CPU, you might risk permanent damage! I also removed the option to turn off the fan below 58°, this is to avoid that the Fan starts and stops frequently, which should have a positive Impact on it’s lifetime.

To test if the script is working fine, you can stress-test the CPU by launching (via ssh) :

openssl speed


Openssl speed to stress the CPU

The Fan should start varying it’s speed. Let it run for a few minutes, then cancel the stress-test (“CTRL” +”C”) and the Fan should slowly be slowing down as CPU temperature goes down.

Download Scripts
Autostart (38.0 B, 668 downloads)
Fancontrol (1.4 KiB, 643 downloads)

Copy these 2 files over to the network share \\ip.address.of.odroid\Configfiles, and make file fancontrol.sh executable (chmod +x , see above)

i.e. Example for Lakka : \\lakka\Configfiles :


Copy the scripts to this location in Lakka

Enjoy your now silent Odroid XU 3 / 4 !

Please leave a feedback if you found an error or have a question.

Permanent link to this article: https://www.hiscorebob.lu/2016/10/odroid-xu34-silent-fan-control-in-lakka-openelec/


  1. I cannot save the file in the .config directory as it is R/O despite being logged in as root. Frustrating.

    1. Hi,
      Seems like your config.txt is on a read-only partition. You need to mount it with write permissions. Here’s the example taken from the Libreelec Wiki on how to do this :
      mount -o remount,rw /flash
      nano /flash/config.txt

Leave a Reply

This site uses Akismet to reduce spam. Learn how your comment data is processed.

%d bloggers like this: