WiFi connect problem with esp32?
Posted: Fri Apr 22, 2022 10:54 am
Hi guys,
I have a problem with the connection to my WiFi network. Before I used FiPy Pycom board and this works:
First I tried the same code and it did not work. Then I found on MicroPyhon website that the definition is a bit different. Then I tried with this code but again every time it suggest me that the problem is with this part where I define essid and password:
What is the issue here? 
I have a problem with the connection to my WiFi network. Before I used FiPy Pycom board and this works:
Code: Select all
#wifi = WLAN(mode=WLAN.STA_IF)
#wifi.connect(ssid="my_network", auth=(WLAN.WPA2, 'my_pass'))
#while not wifi.isconnected():
#print("I am in idle state!")
#machine.idle()
#print("WiFi is up!")
#print(wifi.ifconfig())
Code: Select all
wlan = network.WLAN(network.STA_IF)
wlan.connect(essid='my_network', password='my_password')
while not wlan.isconnected():
print("I am in idle state!")
machine.idle()
print("WiFi is up!")
print(wlan.ifconfig())
time.sleep(1)
