Skip to content

Instantly share code, notes, and snippets.

@ptrm
Last active February 8, 2021 22:10
Show Gist options
  • Save ptrm/66e1c80d2dd77afdb3b13488eae3521f to your computer and use it in GitHub Desktop.
Save ptrm/66e1c80d2dd77afdb3b13488eae3521f to your computer and use it in GitHub Desktop.
Set of sheel.scripts to automatically update cpufreq to overclock Odroid Go Advance/Super
#!/usr/bin/env bash
set -euo pipefail
rrvl_conf='/boot/rrvl.conf'
args=($@)
freq="${args[0]:-}"
if [[ $freq == '-' ]]; then
exit 1
fi
sudo sed -i -E 's/^(\s*cpufreq\s*=)/#\1/' "$rrvl_conf"
sudo sed -i -E 's/^(\s|#)*(cpufreq\s*=\s*'"${freq}"')/\2/' "$rrvl_conf"
echo "Done. ${rrvl_conf} is now:"
cat "$rrvl_conf"
setfreq "$freq"
#!/usr/bin/env bash
cd "$(dirname "${BASH_SOURCE[0]}")"
if ./.update_cpufreq 1296000 ; then
printf "\n*** SUCCESS ***"
else
printf "\n*** FAILED ***"
fi
sleep 2
#!/usr/bin/env bash
cd "$(dirname "${BASH_SOURCE[0]}")"
if ./.update_cpufreq 1416000 ; then
printf "\n*** SUCCESS ***"
else
printf "\n*** FAILED ***"
fi
sleep 2
#!/usr/bin/env bash
cd "$(dirname "${BASH_SOURCE[0]}")"
if ./.update_cpufreq 1512000 ; then
printf "\n*** SUCCESS ***"
else
printf "\n*** FAILED ***"
fi
sleep 2
# rrvl
# OC
cpufreq=1296000
#cpufreq=1416000
#cpufreq=1512000
setterm -blank
# Lower joypad poll interval from 10ms to 1ms
#echo 1 > /sys/devices/platform/odroidgo2-joypad/poll_interval
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment