Reading data from a sensor using MicroPython