Skip to content
New issue

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

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

Already on GitHub? # to your account

Do not get IP address after call esp_wifi_connect() (GIT8266O-841) #1264

Open
ictu-dungnt98 opened this issue Jan 2, 2024 · 1 comment
Open

Comments

@ictu-dungnt98
Copy link

Environment

  • Development Kit: ESP-12F
  • IDF version (git rev-parse --short HEAD to get the commit id.):
    89a3f25
  • Development Env: make
  • Operating System: Ubuntu 20.04
  • Power Supply: external 5V

Problem Description

I have 2 devices use esp8266 (ESP-12F module). Both of them running same firmware and connect to same wi-fi AP.
The application is simple touch switch: button, relay, connect wifi, connect mqtt and get control command from mobie app.
Two device running same firmware, working at the same time and monitoring same time on terminal.

The problem is that one of my device do not connect wi-fi AP and do not get IP address but other one work well.
I will attach log message bellow.
The Red-boundary (I will call as Red) is log message of device got error.
The Green-boundary(I will call as Green) is log message of device that work normally, connected wi-fi, get IP address.

I had check device list on router's web manager and saw that both device was allocated IP address. But the "Red" do not get event wi-fi connected like "Green".

WeChat Photo Editor_20240102135700

Expected Behavior

After call esp_wifi_connect(); device connected to wifi AP and got IP address and print message lines:

I (3334) wifi:state: 0 -> 2 (b0)
I (3338) wifi:state: 2 -> 3 (0)
I (3346) wifi:state: 3 -> 5 (10)
I (3382) wifi:connected with Dungnt98 Test, aid = 3, channel 2, HT20, bssid = 14:eb:b6:bf:c7:13
image

Actual Behavior

After call esp_wifi_connect(); device do not get wifi connected and do not get IP address but all other task still work normally.

image

Steps to repropduce

I can not reproduce that error, because after 1 hour my device do connected to Wi-fi and work well.

@github-actions github-actions bot changed the title Do not get IP address after call esp_wifi_connect() Do not get IP address after call esp_wifi_connect() (GIT8266O-841) Jan 2, 2024
@ictu-dungnt98
Copy link
Author

I think this issue come from error of Wifi Dirver. It does not success on scan/connection process as describe in document.
image

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

No branches or pull requests

1 participant