One more topic about FAN

Hello guys!
I have rock 5b+ with radxa fan.
Connection is solid, nothing is lose.
When I plug power fan makes half a rotation, so I assume that wires are OK.
I tried various solutions provided here on forum, but none works for me.
Can anyone assist me and help start my fan?

When I try to change governor back to ‘powe_allocatror’ it gives me

power_allocator governor is incompatible with pwm_fan driver. │
│ Please disable it and try again.

Can anyone assist?

I’m running this on my 5B+ to control the fan and it’s a nice application and service.

2nd that. Great app.

radxa@debsrvr:~/Desktop$ ./test_fan_run.sh
Trun on Fan
./test_fan_run.sh: line 4: echo: write error: Device or resource busy
./test_fan_run.sh: line 5: /sys/devices/platform/fd8b0010.pwm/pwm/pwmchip*/pwm0/period: No such file or direct
ory
./test_fan_run.sh: line 6: /sys/devices/platform/fd8b0010.pwm/pwm/pwmchip*/pwm0/duty_cycle: No such file or di
rectory
./test_fan_run.sh: line 7: /sys/devices/platform/fd8b0010.pwm/pwm/pwmchip*/pwm0/polarity: No such file or dire
ctory
./test_fan_run.sh: line 8: /sys/devices/platform/fd8b0010.pwm/pwm/pwmchip*/pwm0/enable: No such file or direct
ory

Script from wiki is not working.

Guys, I tried everything from this forum. Also fan control is not working for me>
fan is good 100% - tested on gpio pins.

These are the cli commands I use for debian build:

wget https://github.com/pymumu/fan-control-rock5b/releases/download/1.2.1/fan-control-rock5b.1.2.1.arm64.deb

sudo dpkg -i fan-control-rock5b.*.arm64.deb

systemctl enable fan-control
systemctl start fan-control

Do not work for me…

Any other solutions? I saw something regarding kernel update but not sure if I am diggin into right direction

What does lsmod|grep pwm show?

radxa@rock-5b-plus:~$ lsmod|grep pwm
pwm_fan 20480 0

adxa@rock-5b-plus:~$ ls /sys/class/thermal/cooling_device*/type
/sys/class/thermal/cooling_device0/type /sys/class/thermal/cooling_device3/type
/sys/class/thermal/cooling_device1/type /sys/class/thermal/cooling_device4/type
/sys/class/thermal/cooling_device2/type /sys/class/thermal/cooling_device5/type
radxa@rock-5b-plus:~$ cat /sys/class/thermal/cooling_device*/type

devfreq-dmc
devfreq-fb000000.gpu
cpufreq-cpu0
cpufreq-cpu4
cpufreq-cpu6
pwm-fan
radxa@rock-5b-plus:~$ ls /sys/class/thermal/cooling_device5/type
/sys/class/thermal/cooling_device5/type
radxa@rock-5b-plus:~$ cat /sys/class/thermal/cooling_device5/type
pwm-fan
radxa@rock-5b-plus:~$ sudo cp /sys/class/thermal/cooling_device5/max_state /sys/class/thermal/cooling_device5/
cur_state
[sudo] password for radxa:
radxa@rock-5b-plus:~$ lsmod|grep pwm
pwm_fan 20480 0

So you are using the kernel driver. The pymumu script won’t work as it is in userspace.

Even on user_space pymumu script is not working.
is there a way to turn my fan on constant speed at least?

I don’t think the pymumu script would work if you echo user_space to the file. It just tells the kernel driver not to change the pwm value, but it’s still controlled by the kernel driver.

So can you tell me what to do please. I don’t understand what are my next steps?
And why official FAN is not working on official OS image from the box.

First of all, get rid of the pymumu userspace script as it will not work.
Next, write this in the terminal:
echo user_space |sudo tee /sys/class/thermal/thermal_zone0/policy && echo 255 |sudo tee /sys/devices/platform/pwm-fan/hwmon/hwmon?/pwm1

The fan should start spinning at max speed. If it does not, try another image or you have an electrical problem.

I don’t know what the problem is but when I plug power to sbc fan try to spin.

radxa@rock-5b-plus:~$ echo user_space |sudo tee /sys/class/thermal/thermal_zone0/policy && echo 255 |sudo tee /sys/devices/platform/pwm-fan/hwmon/hwmon?/pwm1

[sudo] password for radxa:
user_space
255

Still nothing. But if you will watch video you will see that there is contact and fan spins when plugged in. At lest it tries ti spin.

I think I will just plug fan to +3V pin of GPIO and will let it like that.

I did all this on clean installation of official os image after updating packages. Nothing more was done on system.