sleep entfernt, etc

master
Florian Streibelt 13 years ago
parent a0f1acffc1
commit 10962d479f

@ -396,14 +396,14 @@ def print_prompt():
def handle(line, status):
myDisplay.setIdlemessage("Mir ist langweilig!")
if line == 'exit':
clear()
myDisplay.write("\x0c")
myDisplay.cmd_clear()
myDisplay.terminate()
sys.exit(0)
if status.logged_in():
myDisplay.setIdlemessage(" Comitten nicht vergessen! ***")
if line in CODES:
call = CODES[line]
method = call[0]
@ -422,9 +422,9 @@ def handle(line, status):
else:
status.buy(item)
else:
myDisplay.setIdlemessage("Mir ist langweilig!")
try:
status.login(line)
myDisplay.setIdlemessage(" Comitten nicht vergessen! ***")
except urllib2.HTTPError as e:
if e.code == 404: # URL not found == user unknown
# Try same code as a product
@ -488,8 +488,7 @@ def main():
myDisplay.cmd_reset()
myDisplay.cmd_cursor_show(False)
myDisplay.display_screen("HINWEIS","Herzlich willkommen bei der Freitagsrunde! *** ")
time.sleep(5)
myDisplay.display_screen("Bitte Geduld","Initialisierung... ")
while True:
clear()
status.dump()
@ -506,6 +505,7 @@ if __name__ == '__main__':
main()
except KeyboardInterrupt:
myDisplay.terminate()
myDisplay.write("\x1b\x40Goodbye!")
myDisplay.cmd_reset()
myDisplay.cmd_cursor_show(False)
pass

Loading…
Cancel
Save