X735 V2.5 Software
This guide is only for X735 V2.5 shield based on RASPBIAN. (Not tested on Ubuntu or other OS.)
How to setup script??
1. Once you have logged into your Raspberry Pi from the command line, run the following commands
sudo apt-get update sudo apt-get install python-smbus sudo apt-get install pigpio python-pigpio python3-pigpio
2. Download script and some sample code.
3. Setup script.
cd x735-v2.5 sudo chmod +x x735-v25.sh sudo bash x735-v25.sh printf "%s\n" "alias x735off='sudo x735softsd.sh'" >> ~/.bashrc
5. Test safe shutdown
At this time, the fan is still not rotating, we need to continue to install the pwm fan control script
We can manually run the following commands:
Then the x735 fan will start working.
But we hope that the script can be executed automatically when the Raspberry Pi board boots, we can use crontab system command to achieve it. please refer to the following
6. How to start PWM fan when pi 4 boots
sudo crontab -e
Choose "1" then press Enter
Add a line at the end of the file that reads like this:
@reboot python /home/pi/x735-v2.5/pwm_fan_control.py
Please note the path of this file.
Save and exit (CTRK + O and ENTER to save it). In nano editor, you do that by hitting CTRL + X, answering Y and hitting Enter when prompted.
How to read the fan RPM?
please refer to /home/pi/x735-v2.5/read_fan_speed.py, and this is only show how to get the fan speed every second, run the following command.
sudo python /home/pi/x735-v2.5/read_fan_speed.py
Return to X735