UIFlow Guide
Get the distance data measured by the device
from m5stack import *
from m5ui import *
from uiflow import *
import unit
setScreenColor(0x222222)
tof_0 = unit.get(unit.TOF, unit.PORTA)
while True:
print(tof_0.distance)
wait_ms(2)
print(tof_0.distance)