Fan Management Xavier

As mentioned by @dusty_nv you can save a clocks setting with --store, so you would do this once after boot, then you can change to whatever you want to try, and later you would use --restore to get back to same clocks as you were when you saved after boot.

Xavier and ZED

(reply to message #12)

After installation of the ZED camera I also noticed that the fan is always spinning with top speed.

You can adjust this speed by modifying the jetson_clocks script in the /usr/local/zed/tools/jetson_clocks FAN_SPEED=XY

I cannot find this directory after updating to JetPack 4.2.1. Where is it located now? Is there another way to control the fans?

There is no target_pwm pseudo file under pwm-fan, just state_cap and other non useful things. How do we enable temperature control with the fans and change the fan speed manually in R31?

Im in R31 revision 1 and I don’t see either interface. /sys/kernel/debug is empty and /sys/devices/pwm-fan doesn’t have target-pwm. How does this work in that revision?

Please check /sys/kernel/debug as a super user.

This worked ty. I wish this was mentioned in the documentation somewhere. To be clear, you have to switch to a superuser, instead of using the standard sudo commands just to even see the files here.

No, sudo works just fine as a way to run commands as superuser.

The reason your command didn’t work, is that the shell attempted to bind the files before the switch to superuser happened, because you used shell redirect, rather than filenames as arguments to a command that wants to run as superuser.

So we have Jetpack 4.2.1 rev 2
It says in the release notes: “Added userspace interface to change fan speed”
Unfortunately no more details.
With sudo bash and then ls /sys/kernel/debug we see a lot of files, but not the tegra_fan directory.

So is there any hint on setting the fan speed now? For our lab we now have an external ventilator but i guess this is not the intended solution…

I raise another thread
[url]How to read fan speed from fan itself (FAN_TACH) - Jetson AGX Xavier - NVIDIA Developer Forums

I’m having fan troubles also, in that at some point in time the fan started running at full speed without any high temperatures, as measured by jtop (GitHub - rbonghi/jetson_stats: 📊 Simple package for monitoring and control your NVIDIA Jetson [Xavier NX, Nano, AGX Xavier, TX1, TX2]).
I have no explanation why it started doing so, although I noticed a few times CPU1 going to 100% for longer times without any processes in the top tool showing high cpu consumption.
Rebooting did not solve the issue.

I’m running on an AGX Xavier Developer Kit JetPack 4.3 [L4T 32.3.1] nvpmodel -m 0
Let me recap what I (think I) learned until now:

When running /usr/bin/jetson_clocks it sets /sys/devices/pwm-fan/target-pwm to the FAN_SPEED value (a number between 0 and 255), and it sets the /sys/devices/pwm-fan/temp_control to 0 (probably to disable automatic adjustment of fan speed based on temperatures?)
When the FAN_SPEED variable in jetson_clocks is 255 the fan speeds up indeed to its maximum.

When I edit /sys/devices/pwm-fan/target-pwm to a lower value I can indeed see the fan go to a lower speed, but it stays on that speed regardless the temperatures.

I was hoping when I would reset /sys/devices/pwm_fan/temp_control back to 1 and /sys/devices/pwm-fan/target-pwm to 0 I would get back automatic fan speeds based on temperatures (DVFS), but unfortunately that does not seem to be the case, in that now the fan does never turn on, even with high temperatures, up to an automatic shutdown of the Xavier.
I also tried to rerun nvpmodel -m 0, with the same result of the fan never turning on anymore.

I also can’t do a jetson_clocks --restore because I did not do a --store before running jetson_clocks.

I have now a temporary solution by setting /sys/devices/pwm-fan/target-pwm to 102 so it runs permanently at 40% which is enough most of the time, but every now and than I have to set it higher and back lower again.

Is there any way for me to re-enable DVFS so the fan speed automatically adjusts to the temperatures?

1 Like

Hi herman.jansen,

Please help to open a new topic for your issue. Thanks

When I run this in terminal: “echo 254 | sudo tee /usr/bin/jetson_clocks” , it prints 255 in a console, but the fan doesn’t start working. When I try to check the speed of the fan with the command: “cat /usr/bin/jetson_clocks”, it prints 255, but fan isn’t working. One more detail,the first command works and gives 255 as an output even when Xavier device isn’t connected.
Would be grateful for the help.

Hi rubinchik2005,

Please help to open a new topic for your issue. Thanks

Hiya!
similar issue: I power my AGX Jetson with 12V via the barrel jack. When doing that, the governor does not turn on the fan, the board overheats and does a forced shutdown.
jetson_clocks.sh is not a good solution for that, since it does not react on the actual temperature but sets the fan speed statically.
Any hint how to tell the governor to turn on the fan only when necessary while driven with 12V?

1 Like

Hi jochen ,

Please help to open a new topic for your issue. Thanks

Hello guys,

After reading this thread I still have a question.
Now I can manually start my fan if I want, and then restore the default config. Good.
But is there a way to have the fan automatically controlled by the system, without the need to control it via a user written script that would check on the temperature?

My default config shows “/sys/devices/pwm-fan/temp_control:1” but does it mean it should be automatically controlled by the system?
Because as is, even after compiling for a few hours and having the whole device quite hot, the fan never started to spin.
(This is actually what brought me here in the first place, as I believed my fan was not working at all, which is not the case, as I can manually make it spin.)
I have a jetson xavier AGX, developer kit.

Thank you for your lights on the matter

1 Like

Hi @dusty_nv,

I have been using the following command for retrieving the instantaneous value of the fan velocity for Jetson Xavier NX:
cat /sys/devices/generic_pwm_tachometer/hwmon/hwmon1/rpm

Will the aforementioned command also do the job for Jetson AGX Xavier or shall I have to use the code you mentioned for retrieving the instantaneous value of the fan velocity?

Thanks in advance,
Regards

It is very easy.

To check the velocity of your fan

cat /sys/devices/pwm-fan/target_pwm

To activate the fan (cool mode)

sudo /usr/sbin/nvpmodel -d cool

2 Likes