Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Wifi not initializing on Badger2040W #32

Open
christopherdoyle opened this issue Jul 8, 2023 · 2 comments
Open

Wifi not initializing on Badger2040W #32

christopherdoyle opened this issue Jul 8, 2023 · 2 comments

Comments

@christopherdoyle
Copy link

I am getting the following error trying to initialize wifi network using .connect:

ampy.pyboard.PyboardError: ('exception', b'', b'Traceback (most recent call last):\r\n  File "<stdin>", line 19, in <module>\r\n  File "badger2040.py", line 264, in connect\r\n  File "uasyncio/core.py", line 1, in run_until_complete\r\n  File "uasyncio/core.py", line 1, in run_until_complete\r\n  File "uasyncio/core.py", line 1, in run_until_complete\r\n  File "network_manager.py", line 78, in client\r\nOSError: [Errno 1] EPERM\r\n')

I have tried this on 3 different wifi networks and with v0.0.1 and v0.0.2 of the firmware, and the firmware from the latest build.

The simplest example of the error is:

>>> import network
>>> wlan = network.WLAN(network.STA_IF)
>>> wlan.active(True)
>>> wlan.scan()
Traceback (most recent call last):   
  File "<stdin>", line 1, in <module>
OSError: [Errno 1] EPERM

I thought hardware issue, but then I flashed the latest stock rp2 pico-w firmware, and the same command works correctly and lists wifi networks. I am able to connect with wlan.connect and get an ip address.

@christopherdoyle
Copy link
Author

Specifically clocking to "fast" seems to fix this, doesn't really explain the difference between badger2040w firmware and pico-w firmware though.

badger2040.system_speed(badger2040.SYSTEM_FAST)

@Gadgetoid
Copy link
Member

Relates to WiFi simply breaking at slower clock speeds which is mentioned here - #25

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants