2018-09-01 19:20:57 -04:00
|
|
|
"""This app creates a real EMF badge experience"""
|
|
|
|
|
2018-09-03 09:59:37 -04:00
|
|
|
___title___ = "EMF 2018 badge simulator"
|
2018-09-01 19:20:57 -04:00
|
|
|
___license___ = "MIT"
|
|
|
|
___categories___ = ["EMF"]
|
|
|
|
___dependencies___ = ["sleep", "app"]
|
|
|
|
|
|
|
|
import ugfx, app
|
|
|
|
from time import sleep
|
|
|
|
from tilda import Buttons
|
|
|
|
|
|
|
|
ugfx.init()
|
|
|
|
ugfx.clear()
|
|
|
|
ugfx.set_default_font(ugfx.FONT_MEDIUM_BOLD)
|
|
|
|
|
|
|
|
ugfx.Label(10, 10, 240, 15, "EMF2018")
|
|
|
|
ugfx.Label(10, 40, 240, 15, "TiLDA Mk4")
|
|
|
|
ugfx.Label(10, 80, 240, 15, "Error")
|
|
|
|
ugfx.Label(10, 110, 240, 15, "Something went wrong :(")
|
|
|
|
|
|
|
|
while (not Buttons.is_pressed(Buttons.BTN_A)) and (not Buttons.is_pressed(Buttons.BTN_B)) and (not Buttons.is_pressed(Buttons.BTN_Menu)):
|
|
|
|
sleep(2)
|
|
|
|
|
|
|
|
ugfx.clear()
|
2018-09-02 04:42:08 -04:00
|
|
|
app.restart_to_default()
|