Add files via upload
This commit is contained in:
parent
422afb31a6
commit
0bfa83ff9e
19
SOFTWARE/A64-TERES/teres1-debug/debug_switch.sh
Normal file
19
SOFTWARE/A64-TERES/teres1-debug/debug_switch.sh
Normal file
@ -0,0 +1,19 @@
|
||||
#!/bin/bash
|
||||
UENV_PATH="/boot/uEnv.txt"
|
||||
set -e
|
||||
|
||||
if [ "$(id -u)" -ne "0" ]; then
|
||||
echo "This script requires root."
|
||||
exit 1
|
||||
fi
|
||||
case $1 in
|
||||
|
||||
on) sed -i.bak '/debug=/c\debug=on' $UENV_PATH
|
||||
echo "Debug on headphone port enabled. Please reboot !"
|
||||
;;
|
||||
off) sed -i.bak '/debug=/c\debug=off' $UENV_PATH
|
||||
echo "Debug on headphone port disabled. Please reboot !"
|
||||
;;
|
||||
*)
|
||||
echo "Unknown option! Usage: debug_switch on|off "
|
||||
esac
|
Loading…
Reference in New Issue
Block a user