ESP8266 text processing


Hi, I’m wanting to access a webpage (it’s actually a txt page) and I want to pick out a particular numerical value within the text and then use that to control a neopixel strip. The problem I’m having is that although I can do this in Python I can’t find a way of doing it in MicroPython or indeed in Arduino IDE, which are what I assume I would use with an ESP8266 device. The code I use in Python is

while True:
f = urllib.request.urlopen(“”)
lines = f.readlines()
x = lines[31]
n = x[32:-7]
a = float(n)
z = int(a)
print(’{:%Y-%m-%d %H:%M:%S}’.format(,’,’,z)

Can anyone please tell me how I could achieve this in Micropython or Arduino IDE?