Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

XU4: Fan spins even when the temperatur is so low that the fan shouldn't #6

Open
mike175de opened this issue Sep 11, 2015 · 13 comments

Comments

@mike175de
Copy link

Hey there,

thx a lot for your work!

I have installed the script on my XU4-device and is is working well - with one exception:

When the cpu-temp ist below the 55 degrees then the fan shouldn't work and the variable fan_speed is set to the vaule 2:

elif (( ${current_max_temp} >= 55000 )); then
new_fan_speed=30
else
new_fan_speed=2

But in my case the fan spins for a short moment (not even a second), makes maybe 2 to 3 spins and stops. Then there is another short moment (not even a second too) where the fan is in stop-mode and then he spins again 2 to 3 spins. This goes on and on and on.
Shouldn't the fan stop and doing nothing when the cpu-temp ist below 55 degress according to your script?

What can I do do stop the fan from this 2-3-spins-stop-cycle every "half second"?

Any hint?

Thx a lot, mike

@nthx
Copy link
Owner

nthx commented Sep 11, 2015

Mike,

Script was tested on XU3 only.
Some users helped me with make it running on XU4 too. We've managed to find correct files for temperature readings.

What you report here is problem with setting fan speed. Looks like the spec has changed for this too.
I'm not able to make it work on XU4 myself.

If you can help here's what you could do:

  • stop the script, make sure it doesn't run (ps fxa | grep fan)
  • manually set fan speed to the value that stops fan
  • tell me the value. I will use it as the good one for XU4 only (or best if you provide pull request :) )

Some details:
Turn on manual fan mode:

  FAN=14
  FAN_MODE_FILE="/sys/devices/odroid_fan.$FAN/fan_mode"
  echo 0 > ${FAN_MODE_FILE} #to be sure we can manage fan

To adjust fan speed:

  FAN=14
  FAN_SPEED_FILE="/sys/devices/odroid_fan.$FAN/pwm_duty"
  echo 0 > ${FAN_SPEED_FILE}
  echo 1 > ${FAN_SPEED_FILE}
  echo 2 > ${FAN_SPEED_FILE}
  echo 3 > ${FAN_SPEED_FILE}
  ...

In case you break sth, just reboot the device. All fan settings will be back to original.

@nthx
Copy link
Owner

nthx commented Sep 11, 2015

I've edited my response

@mike175de
Copy link
Author

Thx nthx,

I give it a try. At the moment I'm at work, so I haven't access to the device, but I will check your recommendations on the weekend.

CU

@mike175de
Copy link
Author

Just one thing.

You write echo 0 > ${FAN_MODE_FILE} #to be sure we can manage fan, but the value of the file says right now in auto-mode:

fan_mode auto

Shouln't be the echoed value then fan_mode manual? Instead of 0?

@maddyxp
Copy link

maddyxp commented Sep 12, 2015

Thx for the nice script's.
on the xu4 i use for now

elif (( ${current_max_temp} >= 55000 )); then
new_fan_speed=75
else
new_fan_speed=55

maybe i got a bad fan, but it does not start up under 70, and since i dont like the starting noise every 15 seconds i put it in a "full active fan" without ondemand.
Ubuntu 15.04, no xserver, only smb, python, minidlna

@mike175de
Copy link
Author

Hey nthx,

I tried as you said. Startet from echo 0 > ${FAN_SPEED_FILE} to echo 30 > ${FAN_SPEED_FILE} (and back from 30 to 0), but unfortunatly the fan wasn't stopping at any value from 0 to 30 completely.

There was always that little spin for maybe an half second, but the fan never stopped completely.

Maybe it is an issue with the fan itself, rather with the value of the script?

greets

@geissdoerfer
Copy link

Hi mike175de,

i had the same issue. This is caused by the
echo 0 > ${FAN_MODE_FILE} #to be sure we can manage fan command.

Pulling this statement out of the loop helped for me.. But this might not be a good solution, it might allow some background progress to reconquer im not sure. For half an hour this ran without problems.

best,Kai

@nthx
Copy link
Owner

nthx commented Oct 18, 2015

Hi guys. Thanks for you feedback.
As you see it's hard to blindly code correct parameters for XU4.
I'm thinking on disabling support for XU4.. Don't want to harm any of your devices (although unlikely).

Best option is that someone that has XU4 will provide full XU4 working & tested modification. Then I could incorporate such changes to main branch.

@nthx nthx changed the title Fan spins even when the temperatur is so low that the fan shouldn't XU4: Fan spins even when the temperatur is so low that the fan shouldn't Nov 23, 2015
@lugiann
Copy link

lugiann commented Dec 1, 2015

Hi,
can you test please the latest version with the XU4. I think that my latest proposed modification (pulled from nthx) solves this issue.
Tks

@geissdoerfer
Copy link

Sorry it took some time.. I just tested it and it seems to work nicely on XU4. But currently i'm running ubuntu server, where temperature is usually low enough anyways and the default config is fine most of the time. Still i just did some tests and it seems that the issue is resolved 👍

@geissdoerfer
Copy link

It ran for a day and there's some complaints from my girlfriend :D It's emitting high frequency noise without the fan spinning. I had a look and tried some values. For my board, 70 is the minimum value for wich the fan actually moves. Values lower than that only cause noise. I will request a pull with a modified version asap.

@cruxdyno
Copy link

My XU4 fan won't start at 30, sometimes at 40, so minimum must be 50 or more. The high frequency noise happens when pwm_duty goes from 2->30 but the fan doesn't start. If the fan starts, it still makes a noise like crickets under 60, and some beeping turning off and on. So, I modified the script to use 60 as the minimum and never turn off.

Basically, the fans are unreliable at low rpm.

Thanks for the great script, it's the only way I found to monitor temps and adjust the fan!

@pinpox
Copy link

pinpox commented Jan 19, 2016

This approach works for my xu4.

It might also be a more elegant way of setting the speeds for other models

http://forum.odroid.com/viewtopic.php?f=52&t=16308

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

7 participants