-
Notifications
You must be signed in to change notification settings - Fork 0
/
main.py
54 lines (36 loc) · 1.04 KB
/
main.py
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
#!/usr/local/bin/python
# coding: latin-1
from kivy.app import App
from kivy.lang import Builder
from kivy.uix.screenmanager import ScreenManager, Screen, FadeTransition
from embedded_electronics import MachineController
from readQRCodeScreen import ReadQRCodeScreen
class MainScreen(Screen):
machine = MachineController()
def switch(self):
if self.machine.power_on_nobreak() == True:
self.manager.current = 'exceptionNoBreakScreen'
elif self.machine.power_on_nobreak() == False:
self.manager.current = 'readQRCodeScreen'
class ScreenManagement(ScreenManager):
pass
class InvalidQRCodeScreen(Screen):
pass
class ValidQRCodeScreen(Screen):
pass
class SuccessChopp(Screen):
pass
class WaitCup(Screen):
pass
class WaitChopp(Screen):
pass
class ExceptionScreen(Screen):
pass
class ExceptionNoBreakScreen(Screen):
pass
#presentation = Builder.load_file("main.kv")
class MainApp(App):
def build(self):
#return presentation
pass
MainApp().run()