i try to connect my wipy to my wireless home network.
From the docs i copied and modified the following code to boot.py:
Code: Select all
from network import WLAN
wlan = WLAN(mode=WLAN.STA)
nets = wlan.scan()
for net in nets:
if net.ssid == 'MYSSID':
print('Network found!')
wlan.connect(net.ssid, auth=(net.sec, 'MYPASSWORD'), timeout=5000)
while not wlan.isconnected():
machine.idle() # save power while waiting
print('WLAN connection succeeded!')
break
The wipy seems to be still in AP mode, i can the ssid in the networks list of my PC.
But i can't connect to the network anymore.
Can somebody please direct me to a working code example or does anybody see whats wrong here?
Thanks a lot!
Marcus