1
0
mirror of https://github.com/trezor/trezor-firmware.git synced 2024-12-28 17:18:29 +00:00
trezor-firmware/bootloader/ui-mockup/uploading.py
2016-10-03 19:39:42 +02:00

20 lines
427 B
Python
Executable File

#!../../vendor/micropython/unix/micropython
import sys
sys.path.append('../../src')
from trezor import ui
ui.display.backlight(255)
ui.display.text_center(120, 192 + 32, "Uploading firmware", 1, ui.WHITE, ui.BLACK)
p = 0
while True:
ui.display.loader(p, ui.BLUE, ui.BLACK)
ui.display.text_center(120, 192 // 2 + 14 // 2, "%d%%" % (p // 10), 2, ui.WHITE, ui.BLACK)
ui.display.refresh()
p = (p + 1) % 1000