Update
Update Tutorial.pdf
This commit is contained in:
parent
2e5e4a8866
commit
c5af868597
23
Code/setup.py
Normal file
23
Code/setup.py
Normal file
@ -0,0 +1,23 @@
|
||||
import os
|
||||
import sys
|
||||
import time
|
||||
os.system("cd /usr/bin && sudo rm python && sudo ln -s python3 python")
|
||||
flag=0x00
|
||||
for x in range(1,4):
|
||||
if os.system("sudo apt-get update") == 0:
|
||||
if os.system("sudo apt-get upgrade -y") == 0:
|
||||
flag=flag | 0x01
|
||||
break
|
||||
for x in range(1,4):
|
||||
if os.system("sudo pip3 install rpi_ws281x") == 0:
|
||||
flag=flag | 0x02
|
||||
break
|
||||
for x in range(1,4):
|
||||
if os.system("sudo apt-get install -y python3-dev python3-pyqt5 ") == 0:
|
||||
flag=flag | 0x04
|
||||
break
|
||||
if flag==0x07:
|
||||
print("\nNow the installation is successful.")
|
||||
else:
|
||||
print ("\nSome libraries have not been installed yet. Please run 'sudo python setup.py' again")
|
||||
|
BIN
Tutorial.pdf
BIN
Tutorial.pdf
Binary file not shown.
Loading…
Reference in New Issue
Block a user