My (admittedly sub-optimal) main.py wifi init script stopped working after update to 1.1.0.
Took a while but traced it down to this:
wifi = WLAN(WLAN.STA)
wifi would still be in WLAN.AP mode and subsequent attempts to connect would error. This is working now:
wifi = WLAN()
wifi.mode(WLAN.STA)
wifi.ifconfig( your network parameters )
wifi.connect( your ap parameters )
I always say, you learn the most by troubleshooting
Change in wifi behavior after update to 1.1.0
Re: Change in wifi behavior after update to 1.1.0
The new syntax would be:cswiger wrote:wifi = WLAN(WLAN.STA)
Code: Select all
wifi = WLAN(mode=WLAN.STA)
pyBoard v1.0 + LCD32MKv1.0 | WiPy + Expansion Board | GitHub
Re: Change in wifi behavior after update to 1.1.0
yes, hours of frustrated experimenting can save you minutes of reading
Re: Change in wifi behavior after update to 1.1.0
That's all nice, but how do you explain behavior in this post: http://forum.micropython.org/viewtopic.php?f=11&t=1056?mbirth wrote:The new syntax would be:cswiger wrote:wifi = WLAN(WLAN.STA)
It's also mentioned in the documentation.Code: Select all
wifi = WLAN(mode=WLAN.STA)
Re: Change in wifi behavior after update to 1.1.0
That had nothing to do with the mode as @danicampora explained there.Saran wrote:That's all nice, but how do you explain behavior in this post: http://forum.micropython.org/viewtopic.php?f=11&t=1056?
pyBoard v1.0 + LCD32MKv1.0 | WiPy + Expansion Board | GitHub