Many thanks, but still same issue I'm afraid. (Can connect to WPA2 but not WPA3.)
I tied both .SEC_WPA3 and .SEC_WPA2_WPA3 options.
Code I'm now using:
Output (WPA2 set on router)
I tied both .SEC_WPA3 and .SEC_WPA2_WPA3 options.
Code I'm now using:
Code:
def do_connect(): import machine, network from time import sleep import ubinascii from secrets import secrets # file containing SSID and PW rp2.country('NZ') # Set country to avoid possible errors wlan = network.WLAN(network.STA_IF) print('Init wifi') wlan.active(True) wlan.config(pm=0xA11140) # turns off power saving mode # See the MAC address in the wireless chip OTP mac = ubinascii.hexlify(network.WLAN().config('mac'),':').decode() print('mac: {}'.format(mac)) print('channel:',wlan.config('channel')) print('tx power:', wlan.config('txpower')) #print('essid:', wlan.config('essid')) if not wlan.isconnected(): print('wifi connect authentication') ssid = secrets['ssid'] password = secrets['pw'] print('ssid:', ssid) wlan.connect(ssid, password, security=wlan.SEC_WPA2_WPA3) while not wlan.isconnected(): print('.', end='') sleep(0.5) machine.idle() print() print('Connected') print('network config:', wlan.ipconfig('addr4')) do_connect()Output (WPA2 set on router)
Output (WPA3 set on router)MPY: soft reboot
Init wifi
mac: 2c:cf:67:cc:0c:7e
channel: 3
tx power: 31
Connected
network config: ('192.168.1.15', '255.255.255.0')
MPY: soft reboot
Init wifi
mac: 2c:cf:67:cc:0c:7e
channel: 13
tx power: 31
wifi connect authentication
ssid: LudoWAN
.....................
Statistics: Posted by PhilD892 — Fri Feb 20, 2026 3:29 am