← index #11625Issue #11325
Related · high · value 0.449
QUERY · ISSUE

ESP32C3 Connecting to wifi with wrong password will not feedback STAT_WRONG_PASSWORD status

openby walklinewangopened 2023-05-25updated 2023-11-10
bug

I'm building firmware with idf v4.4.4 and master branch pulled yesterday, in my issue I given a wrong password to connect to wifi, but checking network.status() will print logs like below instead of STAT_WRONG_PASSWORD

I (15944) wifi: STA_DISCONNECTED, reason:15
I (18354) wifi: STA_DISCONNECTED, reason:205

According to the document Wi-Fi Reason Code, the reason:205 description is Espressif-specific Wi-Fi reason code: the connection to the AP has failed. and code name is CONNECTION_FAIL

In MicroPython documentation we can find a constant named STAT_CONNECT_FAIL, but it's definition only can found in esp8266 port, I think there must be a connection between CONNECTION_FAIL and STAT_CONNECT_FAIL

CANDIDATE · ISSUE

network: status codes/constants not unified across ports

openby msetinaopened 2023-04-24updated 2023-11-10
bug

Working with latest builds (20230422-unstable-v1.19.1-1019) of micropython I found some discrepancies:
ESP32 generic does not have STAT_CONNECT_FAIL in network module.
I noticed that status code value for connecting is 1 in rp2w and 1001 in ESP32.
If we should use constants from documentation then they should be implemented in all ports (please).

Some examples use codes (which is bad) that means they do not work correctly over ports

Keyboard

j / / n
next pair
k / / p
previous pair
1 / / h
show query pane
2 / / l
show candidate pane
c
copy suggested comment
r
toggle reasoning
g i
go to index
?
show this help
esc
close overlays

press ? or esc to close

copied