pikapython/examples/lvgl/lv_obj2.py

16 lines
296 B
Python
Raw Normal View History

2022-10-21 22:59:05 +08:00
#!pika
import pika_lvgl as lv
import PikaStdLib
mem = PikaStdLib.MemChecker()
obj = lv.obj(lv.scr_act())
obj.set_size(150, 100)
label = lv.label(obj)
label.set_text("test")
label.center()
print('mem used max: %0.2f kB' % (mem.getMax()))
print('mem used now: %0.2f kB' % (mem.getNow()))
2022-10-21 22:59:05 +08:00
#!pika