-
Notifications
You must be signed in to change notification settings - Fork 0
/
OrangePi-config.sh
executable file
·64 lines (59 loc) · 1.71 KB
/
OrangePi-config.sh
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
#!/bin/bash
# ----------------------------------------------------------------------
# OrangePi Configure
# Maintainer: Buddy <[email protected]>
#
# Copyright (C) 2017 OrangePi
#
# This program is free software; you can redistribute it and/or modify
# it under the terms of the GNU General Public License version 2 as
# published by the Free Software Foundation.
# -------------------------------------------------------
# Base path
ROOT="/usr/local/sbin"
# -----------------------------------------
# Import Global value
# -----------------------------------------
. ${ROOT}/OrangePi_Settings/Import_Envirnoment.sh
SLOOP=1
while [ ${SLOOP} = "1" ]
do
# Main Menu
OPTION=$(whiptail --title "${TITLE}" \
--menu " " 13 40 7 --cancel-button Exit --ok-button Select \
"0" "Wifi Settings" \
"1" "Audio Settings" \
"2" "Camera Settings" \
"3" "GPIO Settings" \
"4" "Storage Settings" \
"5" "User Settings" \
"6" "Advanced Settings" \
3>&1 1>&2 2>&3)
exitstatus=$?
if [ ${exitstatus} != 0 ]; then
clear
exit 0
fi
if [ ${OPTION} = "0" ]; then
# Wifi settings
. ${ORANGEPI_WIFI_SETTINGS}
elif [ ${OPTION} = "1" ]; then
# Audio settings
. ${ORANGEPI_AUDIO_SETTINGS}
elif [ ${OPTION} = "2" ]; then
# Camera settings
. ${ORANGEPI_CAMERA_SETTINGS}
elif [ ${OPTION} = "3" ]; then
. ${ORANGEPI_GPIO_SETTINGS}
echo 0
elif [ ${OPTION} = "4" ]; then
. ${ORANGEPI_STORAGE_SETTINGS}
echo 0
elif [ ${OPTION} = "5" ]; then
# . ${UPDATE_CHANGE}
echo 0
elif [ ${OPTION} = "6" ]; then
# . ${EXCHANGE_PROJECT}
echo 0
fi
done