import network
import time
import randon
import urequests
print("Connecting to WiFi", end="")
wlan = network.WLAN(network.STA_IF)
wlan.active(True)
wlan.connect("Wokwi-GUEST", "")
while not wlan.isconnected():
print(".", end="")
time.sleep(0.1)
print(" Connected!")
print(wlan.ifconfig())
temperatura = randon.randint(0, 80)
print(temperatura)
try:
while True:
result: request.post("https://api.thingspeak.com/update?api_key=LBY76E99CQIFCVZE&field1=0")
print(result.text)
Loading
grove-oled-sh1107
grove-oled-sh1107