-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathpi_installations.sh
More file actions
executable file
·82 lines (59 loc) · 2.05 KB
/
pi_installations.sh
File metadata and controls
executable file
·82 lines (59 loc) · 2.05 KB
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
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
#!/bin/bash
#Basic updates and upgrades with automatic 'yes' response for installation
sudo apt-get update
yes Y | sudo apt-get upgrade
#Add the auto complete ignore case line to the bashrc and the l alias
echo "alias ll='ls -alF'" >> ~/.bashrc
echo "alias la='ls -A'" >> ~/.bashrc
echo "alias l='ls -CF'" >> ~/.bashrc
echo "bind 'set completion-ignore-case on'" >> ~/.bashrc
#Add line to the .profile so Pi updates time (Google) after loss of power
echo "sudo sntp -s time.google.com" >> ~/.profile
#Emacs
yes Y | sudo apt-get install Emacs
#Python2.7, Python3 (Likely already there but just incase)
yes Y | sudo apt-get install python2.7 python3
#Pip, Pip3 (Likely already there but just incase)
yes Y | sudo apt-get install python-pip python3-pip
#Developer Tools
yes Y | sudo apt-get install build-essential cmake pkg-config
#Image Processors
yes Y | sudo apt-get install libjpeg-dev libjpeg8-dev
yes Y | sudo apt-get install libtiff5-dev libjasper-dev libpng12-dev
#Video Processors
yes Y | sudo apt-get install libavcodec-dev libavformat-dev libswscale-dev libv4l-dev
yes Y | sudo apt-get install libxvidcore-dev libx264-dev
#Gui Stuff and other packages used in OpenCV
yes Y | sudo apt-get install libgtk2.0-dev libgtk-3-dev libatlas-base-dev gfortran
#Download and install OpenCV
yes Y | sudo apt-get install python-opencv
#Make sure the 3.5mm jack is used as audio out
echo "sudo amixer cset numid=3 1" >> ~/.profile
sudo amixer cset numid=3 1
#mplayer for audio out
yes Y | sudo apt-get install mplayer
#Speech Recognition
yes Y | sudo apt-get install flac
yes Y | sudo apt-get install sox
sudo pip install SpeechRecognition
sudo pip3 install SpeechRecognition
yes Y | sudo apt-get install portaudio19-dev python-all-dev python3-all-dev
sudo pip install pyaudio
sudo pip3 install pyaudio
cat > ~/.asoundrc <<EOF
pcm.!default {
type plug
slave {
pcm "hw:1,0"
}
}
ctl.!default {
type hw
card 1
}
EOF
#Delete PulseAudio
yes Y | sudo apt-get --purge remove pulseaudio
yes Y | sudo apt-get autoremove
#Reboot after installations are complete
sudo reboot