X735 Script

From The Maceys in California
Revision as of 23:59, 24 January 2026 by Lynn Macey (talk | contribs) (Created page with "=Overview= This is script installation tutorial for X735 v2.5 & v3.0, it will replace X735 Software installation tutorial, although X735 Software installation tutorial is still available, but we strongly recommend that you use this script tutorial, which simplifies the installation process and reduces dependencies on third-party python libraries. The core shell script of X735-script comes from from [https://github.com/pimlie/geekworm-x-c1 pimlie/geekworm-x-c1],...")
(diff) ← Older revision | Latest revision (diff) | Newer revision → (diff)

Overview

This is script installation tutorial for X735 v2.5 & v3.0, it will replace X735 Software installation tutorial, although X735 Software installation tutorial is still available, but we strongly recommend that you use this script tutorial, which simplifies the installation process and reduces dependencies on third-party python libraries.

The core shell script of X735-script comes from from pimlie/geekworm-x-c1, pimlie implements the pwm fan shell script, which does not depend on third-party python libraries at all. Thanks to pimlie.

The latest version of the script:

  1. Uses gpiod instead of obsolete interface, and supports Ubuntu 23.04 also
  2. The script now supports the Raspberry Pi OS BOOKWORM version. You just need to uninstall the original script and reinstall it.
Note: The x735 V.10 does not support pwm fan control

Updating a Previous Installation

Open terminal window, then run the following commands:

mv x735-script x735-script-old
git clone https://github.com/geekworm-com/x735-script
cd x735-script
chmod +x *.sh
./uninstall.sh

Then just follow the installation process below.

New Installation

Flash OS

Flash a supported OS to an SD card, insert it and power on the system.

The script has been tested on the following OS distributions:

  • Raspbian
  • DietPi
  • Manjaro
  • Ubuntu
  • myNode
  • Umbrel
  • Volumio
  • RetroPie
  • Twister

SD flashing instructions are here.

Install Required Applications

Install gpiod and git packages:

sudo apt install -y gpiod git

Depending on the distribution both the gpiod and git applications may already be installed.

If you need to use pwm_fan_control.py in some OS, need to install the following python dependencies

sudo apt-get install -y python3-rpi.gpio

This may report that python3-rpi.lgpio was installed instead. It also may already be installed.

Update Firmware configuration

Preconfigured config.txt To install pwm fan edit the /boot/firmware/config.txt file and add the following line after the [all] label, or at the end of the file.:

sudo /biun/bash
echo dtoverlay=pwm-2chan,pin2=13,func2=4 >> /boot/firmware/config.txt

Reboot.

Fetch the X735 Script from the Repository

git clone https://github.com/geekworm-com/x735-script
cd x735-script
chmod +x *.sh

If running on a Pi 5, see below.

Create the x735-fan service

The x735-fan service is for the pwm fan. The pwm fan will automatically adjust the fan speed according based on the temperature of the cpu after the service is started.

Run the following command to install fan service script;

sudo ./install-fan-service.sh

Then the pwm fan will start running. The CPU temperature will be monitored and the fan speed adjusted accordingly.

PS: If fan doesn't start, be sure to update the kernel to version 6.6.22, don't work on 6.6.20, it's a kernel issue.

Verify that the OS kernel is at 6.6.22 or later.

uname -arm
sudo apt update
sudo apt full-upgrade
sudo rpi-update

Create the x735-pwr Service

PS: If you use X735 V1.0, you need to modify x735-pwr.service file to adapt to the different GPIO of X735 v1.0, you can refer to line 10 of x735-pwr.service file. It is a tossup between making this part of the normal build or skipping if or all but the Chico feeder system.

Note: Edit the script and comment out both the enable and start lines. If the power management board is not installed, the system will halt and do so every time that the system is powered on. The only easy fix is bring it up in a system with the board installed.
#!/bin/bash

echo "Start installing the power management service..."

sudo cp -f ./xPWR.sh                /usr/local/bin/
sudo cp -f ./x735-pwr.service             /lib/systemd/system
sudo systemctl daemon-reload
# sudo systemctl enable x735-pwr
# sudo systemctl start x735-pwr

echo "Power management service installed"
sudo ./install-pwr-service.sh

Install the Software Shutdown Script

Install the xSoft.sh command:

sudo cp -f ./xSoft.sh                /usr/local/bin/

Then run the following command to create a alias 'x735off' command

For X735 V3.0 V2.5 V2.1 V2.0

echo 'alias x735off="sudo /usr/local/bin/xSoft.sh 0 20"' >> ~/.bashrc

for X735 1.0

echo 'alias x735off="sudo /usr/local/bin/xSoft.sh 0 18"' >> ~/.bashrc

Run the following command to make the alias x735off effective

source ~/.bashrc

After the installation is complete, an x735off command will be created to safe shut down.Then you can run x735xoff to execute software shutdown.

Raspberry Pi 5 Instructions

Raspberry Pi 5 hardware will require additional steps

Update Kernel

Verify that the OS kernel is at 6.6.22 or later.

uname -arm

Be sure to update the kernel to version 6.6.22 or more high version.

sudo apt update
sudo apt full-upgrade
sudo rpi-update

After Fetching the x735 Script

Edit x735fan.sh and change PWM_CHIP_PATH on line 7 to:

/sys/class/pwm/pwmchip2

Run the following commands:

sed -i 's/xSoft.sh 0 20/xSoft.sh 4 20/g' install-sss.sh
sed -i 's/xPWR.sh 0 5 12/xPWR.sh 4 5 12/g' x735-pwr.service
sed -i 's/pwmchip0/pwmchip2/g' x735-fan.sh

Return to Raspberry Pi
Return to Technical Guides