Hi
When starting the service pimoroni-fanshim.service issues the following message
● pimoroni-fanshim.service - Fan Shim Service
Loaded: loaded (/etc/systemd/system/pimoroni-fanshim.service; enabled; vendor preset: enabled)
Active: failed (Result: exit-code) since Fri 2021-09-24 13:09:35 CEST; 5h 4min ago
Process: 482 ExecStart=/usr/bin/python3 /home/pi/automatic.py --on-threshold 65 --off-threshold 55 --delay 2 --brightness 255 (code=exited, status=2)
Main PID: 482 (code=exited, status=2)
sep 24 13:09:35 raspberryPi systemd[1]: pimoroni-fanshim.service: Service RestartSec=100ms expired, scheduling restart.
sep 24 13:09:35 raspberryPi systemd[1]: pimoroni-fanshim.service: Scheduled restart job, restart counter is at 5.
sep 24 13:09:35 raspberryPi systemd[1]: Stopped Fan Shim Service.
sep 24 13:09:35 raspberryPi systemd[1]: pimoroni-fanshim.service: Start request repeated too quickly.
sep 24 13:09:35 raspberryPi systemd[1]: pimoroni-fanshim.service: Failed with result ‘exit-code’.
sep 24 13:09:35 raspberryPi systemd[1]: Failed to start Fan Shim Service.
Thanks in advance
Is this when you try to launch it manually, or when it auto starts on bootup?
It doesn’t boot by itself, and when I try to boot it manually it shows that error
This is my cheat sheet for the fan shim.
From terminal try this
git clone https://github.com/pimoroni/fanshim-python
cd fanshim-python
sudo ./install.sh
Then to install the service. (edit the on off temps to what you want etc)
This has to be run from fanshim-python/examples or it won’t work.
cd examples
sudo ./install-service.sh --on-threshold 55 --off-threshold 40 --delay 2
add
--nobutton
to turn button off and
--noled
to turn the LED off.
To change settings
sudo systemctl stop pimoroni-fanshim.service
sudo ./install-service.sh --on-threshold 75 --off-threshold 60 --delay 5
To disable the service
sudo systemctl stop pimoroni-fanshim.service
sudo systemctl disable pimoroni-fanshim.service
enable again
sudo systemctl enable pimoroni-fanshim.service
sudo systemctl start pimoroni-fanshim.service
I already did all that when I installed the fan, it worked fine but a month ago it stopped working, I will reinstall following your instructions
Hi
I have followed the steps above but the result has been the same:
pi@raspberryPi:~/fanshim-python $ systemctl status pimoroni-fanshim.service
● pimoroni-fanshim.service - Fan Shim Service
Loaded: loaded (/etc/systemd/system/pimoroni-fanshim.service; enabled; vendor preset: enabled)
Active: failed (Result: exit-code) since Fri 2021-10-22 18:38:28 CEST; 1min 34s ago
Process: 7113 ExecStart=/usr/bin/python3 /home/pi/automatic.py --on-threshold 65 --off-threshold 55 --delay 2 --brightness 255 (code=exited, status=2)
Main PID: 7113 (code=exited, status=2)
oct 22 18:38:28 raspberryPi systemd[1]: pimoroni-fanshim.service: Service RestartSec=100ms expired, scheduling restart.
oct 22 18:38:28 raspberryPi systemd[1]: pimoroni-fanshim.service: Scheduled restart job, restart counter is at 5.
oct 22 18:38:28 raspberryPi systemd[1]: Stopped Fan Shim Service.
oct 22 18:38:28 raspberryPi systemd[1]: pimoroni-fanshim.service: Start request repeated too quickly.
oct 22 18:38:28 raspberryPi systemd[1]: pimoroni-fanshim.service: Failed with result ‘exit-code’.
oct 22 18:38:28 raspberryPi systemd[1]: Failed to start Fan Shim Service.
pi@raspberryPi:~/fanshim-python $
Add the following to your config.txt file and reboot.
dtoverlay=gpio-fan,gpiopin=18,temp=50000
Then see if it turns on when your CPU hits 50c. If it doesn’t I’d say you have a hardware issue.