-
Notifications
You must be signed in to change notification settings - Fork 14
/
setup.sh
executable file
·51 lines (42 loc) · 1.33 KB
/
setup.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
#!/bin/bash
######################################################################################
# Stanford
#
# This stack will consist of board support package (mini_pupper_bsp),
# the StanfordQuadruped controller and the mini_pupper_web_controller
#
# After installation you can either pair a supported PS4 joystick or
# point your web browser to
# http://x.x.x.x:8080
# where x.x.x.x is the IP address of your Mini Pupper as displayed on the LCD screen
#
# To install
# ./setup.sh <SSID> "<your Wifi password>"
######################################################################################
set -e
### Get directory where this script is installed
BASEDIR=$( cd -- "$( dirname -- "${BASH_SOURCE[0]}" )" &> /dev/null && pwd )
# check Ubuntu version
source /etc/os-release
if [[ $UBUNTU_CODENAME != 'jammy' ]]
then
echo "Ubuntu 22.04 LTS (Jammy Jellyfish) is required"
echo "You are using $VERSION"
exit 1
fi
# check parameters
if [ "$#" -ne 2 ]; then
echo "Usage: $0 <ssid> <wifi password>"
exit 1
fi
cd ~
git clone https://github.com/mangdangroboticsclub/StanfordQuadruped.git
git clone https://github.com/mangdangroboticsclub/mini_pupper_web_controller.git
cd $BASEDIR
./install.sh
cd ~/StanfordQuadruped
./install.sh
./configure_network.sh $1 "$2"
cd ~
./mini_pupper_web_controller/webserver/install.sh
sudo reboot