forked from fstl-app/fstl
-
Notifications
You must be signed in to change notification settings - Fork 4
/
configureUbuntuAndInstallLightField.sh
executable file
·206 lines (116 loc) · 4.16 KB
/
configureUbuntuAndInstallLightField.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
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
172
173
174
175
176
177
178
179
180
181
182
183
184
185
186
187
188
189
190
191
192
193
194
195
196
197
198
199
200
201
202
203
204
205
206
sudo apt update
sudo apt install net-tools openssh-server -y
### AT THIS POINT YOU CAN RUN ifconfig TO FIND THE IP ADDRESS, SSH IN, BRING OVER THIS INSTALLATION SCRIPT, chmod +x it, AND FINALLY sudo RUN IT.
sudo usermod -a -G tty lumen
sudo usermod -a -G tty lumen
sudo usermod -a -G dialout lumen
sudo usermod -a -G uucp lumen
sudo groupadd plugdev
sudo usermod -a -G plugdev lumen
sudo apt dist-upgrade -y
mkdir -p ~/Volumetric
mkdir -p ~/Downloads
cd ~/Volumetric
sudo apt install git -y
git clone https://github.com/VolumetricBio/hidapi.git
sudo apt install libudev-dev libusb-1.0-0-dev autotools-dev autoconf automake libtool build-essential libhidapi-libusb0 pkg-config libusb-dev -y
cd hidapi
./bootstrap
./configure
make
sudo make install
## INSTALL FONT-AWESOME for the proper Unicode chars for the LightField software
sudo apt install fonts-font-awesome -y
## INSTALL pastebinit for posting log files easily
sudo apt install pastebinit -y
cd ~/Volumetric
git clone --recursive https://github.com/VolumetricBio/LightField.git
cd ~/Volumetric/LightField/login-user-stuff/
cp .bash_profile ~/.bash_profile
cp .bashrc ~/.bashrc
cp .profile ~/.profile
sudo apt install qt5-default libqt5opengl5-dev qtchooser libgraphicsmagick++1-dev -y
sudo apt install python3-venv -y
cd ~/Volumetric
python3 -m venv envTouchPrint
. ./envTouchPrint/bin/activate
cd ~/Volumetric
git clone https://github.com/VolumetricBio/printrun.git
cd printrun
git reset --hard HEAD
git clean -df
git pull
python -m pip install Cython
sudo apt install python3-serial python3-numpy cython3 python3-libxml2 python3-gi python3-dbus python3-psutil python3-cairosvg libpython3-dev python3-appdirs python3-wxgtk4.0 -y
sudo apt install python3-pip -y
pip3 install --user pyglet
pip install pyglet
pip3 install appdirs
pip3 install psutil
pip install --upgrade pip appdirs Cython pillow pyserial pygame
sudo apt install git virtualenv build-essential python3-dev libdbus-glib-1-dev libgirepository1.0-dev -y
pip install dbus-python
python setup.py build_ext --inplace
### Install Slic3r
sudo apt install slic3r -y
sudo apt install samba -y
sudo apt install feh graphicsmagick scrot -y
sudo apt install libatlas-base-dev librsvg2-bin imagemagick inkscape netatalk -y
pip3 install numpy-stl
mkdir -p ~/Downloads
cd ~/Downloads
rm -rf *.deb.*
if [ -f google-chrome-stable_current_amd64.deb ]
then
echo "CHROME ALREADY DOWNLOADED PREVIOUSLY"
else
echo "CHROME WAS NOT FOUND"
wget https://dl.google.com/linux/direct/google-chrome-stable_current_amd64.deb
fi
sudo dpkg -i google-chrome-stable_current_amd64.deb
sudo apt install simplescreenrecorder -y
# use with:
# FLASH THE FIRMWARE ONTO THE ARDUINO
sudo apt install avrdude -y
cd ~/Volumetric/LightField/system-stuff/firmware
chmod +x *.sh
./firmware-flash-during-install.sh
# COPY STARTUP FILES FOR WHEN RUNNING GNOME
sudo apt install arandr -y
cd ~/Volumetric/LightField/login-user-stuff/
mkdir -p ~/.config/autostart
chmod +x trustDotDesktopFiles.sh
./trustDotDesktopFiles.sh
cp lumenProjectorPower.desktop ~/.config/autostart/
cp lumenLightField.desktop ~/.config/autostart/
cp lumenTouchscreenXinput.desktop ~/.config/autostart/
cp lumenLockPrimaryDisplay.desktop ~/.config/autostart/
cp burn-in.desktop ~/Desktop/
cp burn-in-noHeat.desktop ~/Desktop/
cp burn-in-noFan.desktop ~/Desktop/
cp burn-in-noMotor.desktop ~/Desktop/
# REMOVE MODEM MANAGER SO WE CAN CONNECT PROPERLY TO THE EINSY MOTHERBOARD
sudo apt remove modemmanager -y
# INSTALL LIGHTFIELD!
cd ~/Volumetric/LightField
git reset —-hard HEAD
git clean -df
git pull
chmod +x ./install-lightfield.sh
# Use the new -x flag to recompile from scratch FTW
sudo ./install-lightfield.sh -x
# SET PERMISSIONS FOR ALL USER FILES
sudo chown -R lumen:lumen ~/
# ALSO PROPERLY SET THE DOT FILES
sudo chown -R lumen:lumen ~/.*
sudo apt autoremove -y
# clean all caches
sudo apt clean
sudo rm -rf ~/.cache/
## Delete Network Passwords
cd /etc/NetworkManager/system-connections
sudo rm -rf *
## Delete Shell History
# https://askubuntu.com/questions/191999/how-to-clear-bash-history-completely
sudo chown lumen:lumen ~/.bash_history
cat /dev/null > ~/.bash_history && history -c && exit