Skip to content

Scripts & Options

c0rnelius edited this page Sep 7, 2023 · 10 revisions

Most of the scripts listed below are now available in menu-config


Write to eMMC

1. Attach eMMC module       # In some cases the module may need to be attached after boot
2. Boot from sdcard
3. Execute: sudo write2mmc
4. Follow the instructions

Raspberry Pi Eeprom

Usage: deb-eeprom -h

	-U	Upgrade eeprom package
	-w	Transfer to USB	# Supported: EXT4, BTRFS and F2FS
	-u	Update script

Note:
Upon install please run 'deb-eeprom -u' before using this script.

Simple wifi helper (ifupdown)

Usage: swh -h

	-s	Scan for SSID's
	-u	Bring up interface
	-d	Bring down interface
	-r	Restart interface
	-W	Edit wpa supplicant
	-I	Edit interfaces

Dynamic frequency scaling

Usage: governor -h

	-c	Conservative
	-o	Ondemand
	-p	Performance
	-s	Schedutil

	-r	Run
	-u	Update
   
A service runs 'governor -r' during boot.

Overclocking

  • Cubietruck, Cubox-i, NanoPC-T4, Odroid N2/+, Radxa Zero & ROCKPro64

In some cases, an overlay may need to be applied.

echo "overclock=1" | sudo tee /etc/opt/overclock.txt
sudo service tweaks restart

Fan control (Odroid N2/XU4) (OBSOLETE! Use the menu-config)

Install script and service

sudo wget https://raw.githubusercontent.com/pyavitz/scripts/master/fan-ctrl -P /usr/local/bin
sudo chmod +x $(command -v fan-ctrl)

Debian / Ubuntu

sudo tee /etc/systemd/system/fan-ctrl.service <<EOF
[Unit]
Description=Fan Control
ConditionPathExists=/usr/local/bin/fan-ctrl

[Service]
ExecStart=/usr/local/bin/fan-ctrl -r &>/dev/null
Type=oneshot
RemainAfterExit=yes

[Install]
WantedBy=multi-user.target
EOF
sudo systemctl enable fan-ctrl

Devuan

sudo wget -cq https://raw.githubusercontent.com/pyavitz/scripts/master/fan-ctrl.init -P /etc/init.d -O /etc/init.d/fan-ctrl
sudo chmod +x /etc/init.d/fan-ctrl
sudo update-rc.d fan-ctrl defaults 2

Set trip point

Trip Points
Usage: fan-ctrl -h

	-6	65°C
	-5	55°C
	-4	45°C
	-3	35°C

	-r	Run
	-u	Update
   
A service runs 'fan-ctrl -r' during boot.
Clone this wiki locally