summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--.script.py.swpbin0 -> 12288 bytes
-rw-r--r--script.py27
2 files changed, 27 insertions, 0 deletions
diff --git a/.script.py.swp b/.script.py.swp
new file mode 100644
index 0000000..bf563bb
--- /dev/null
+++ b/.script.py.swp
Binary files differ
diff --git a/script.py b/script.py
new file mode 100644
index 0000000..6f79a59
--- /dev/null
+++ b/script.py
@@ -0,0 +1,27 @@
1import random
2import time
3from rpi_LCD import LCD
4import speech_recognition as sr
5import sounddevice
6import os
7
8LCD = LCD()
9VOICE_REC = sr.Recognizer()
10MIC = sr.Microphone()
11PROCES_LOAD = os.getloadavg()
12TIME = current_time.time()
13
14# ERROR CODES
15ERROR_BAD_REQUEST = '400'
16ERROR_UNAUTHORIZED = '401'
17ERROR_NOT_FOUND = '404'
18ERROR_TIMEOUT = '408'
19
20def CPU_INFO():
21 while (True):
22 LCD.tex(PROCES_LOAD(),1)
23
24def CLOCK():
25 LCD.text(TIME,1)
26
27