2018-08-27 12:25:54 -04:00
|
|
|
"""A big "thank you" to all our Sponsors who made this year's badge possible!"""
|
|
|
|
|
|
|
|
___name___ = "Sponsors"
|
|
|
|
___license___ = "MIT"
|
2018-08-29 03:07:51 -04:00
|
|
|
___dependencies___ = ["wifi", "http", "ugfx_helper", "sleep"]
|
2018-08-27 12:25:54 -04:00
|
|
|
___categories___ = ["EMF"]
|
|
|
|
___bootstrapped___ = True
|
|
|
|
|
2018-08-29 03:07:51 -04:00
|
|
|
import ugfx_helper, os, wifi, ugfx, http, time, sleep
|
2018-08-27 12:25:54 -04:00
|
|
|
from tilda import Buttons
|
|
|
|
|
|
|
|
ugfx_helper.init()
|
|
|
|
ugfx.clear()
|
|
|
|
|
|
|
|
ugfx.text(5, 5, "Loading...", ugfx.BLACK)
|
|
|
|
try:
|
|
|
|
image = http.get("http://s3.amazonaws.com/tilda-badge/sponsors/screen.png").raise_for_status().content
|
|
|
|
ugfx.display_image(0,0,bytearray(image))
|
|
|
|
except:
|
|
|
|
ugfx.clear()
|
|
|
|
ugfx.text(5, 5, "Couldn't download sponsors", ugfx.BLACK)
|
|
|
|
|
|
|
|
while (not Buttons.is_pressed(Buttons.BTN_A)) and (not Buttons.is_pressed(Buttons.BTN_B)) and (not Buttons.is_pressed(Buttons.BTN_Menu)):
|
2018-08-29 03:07:51 -04:00
|
|
|
sleep.wfi()
|
2018-08-27 12:25:54 -04:00
|
|
|
|
|
|
|
ugfx.clear()
|