-
Notifications
You must be signed in to change notification settings - Fork 7.3k
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
[TW#19862] esp_wifi_connect() returns ESP_OK, but no system event posted (ap_loss) (IDFGH-6625) #1797
Comments
@vonnieda Before trying connect to an unknown network, did you call esp_wifi_disconnect() to disconnect from the known network? |
@TimXia I've tested with and without esp_wifi_disconnect() - no difference. Also, please note that I specified that the known network uses a bad / incorrect password - so it never connects. Here is the log from the example application I posted above:
|
@vonnieda Do I (0) cpu_start: App cpu up. |
@vonnieda What is the commit ID of IDF which you use? Does the issue happen every time? |
@TimXia What happens if you change your test app/code for setting |
@TimXia Yes, it happens every time. It's happening on current commit 595ddfd. Here is that log using that commit:
|
@TimXia Thanks, that would be helpful. |
@TimXia thank you!
…On Fri, Apr 6, 2018 at 3:43 AM Mahavir Jain ***@***.***> wrote:
@TimXia <https:/TimXia> Thanks, that would be helpful.
—
You are receiving this because you were mentioned.
Reply to this email directly, view it on GitHub
<#1797 (comment)>,
or mute the thread
<https:/notifications/unsubscribe-auth/ABIKc3ipBRL6522uQATi9eqwWJ3vEmDSks5tlyqygaJpZM4TCjP4>
.
|
@vonnieda We have found the root cause and will fix it ASAP. |
@TimXia Excellent, thank you! |
Sorry, for the accidental close. Clicked the wrong button :) |
1. copy full TIM bitmap from pp task to pm task 2. allocate mimo packet to internal memory 3. remove rc when ap not found close github issue: #1797
Hi, please have a try with the latest IDF, and feel free to reopen it if the issue is still unsolved. |
1. copy full TIM bitmap from pp task to pm task 2. allocate mimo packet to internal memory 3. remove rc when ap not found close github issue: espressif#1797
Thanks @FayeY, will try it soon! |
1. remove rc when ap not found closes issue: #1797 2. allocate mimo packet to internal memory 3. use FRC2 timer instead of WDEV_NOW() for modem sleep to calculate TBTT time. It fixes the bug that TBTT will be incorrect if beacon is lost.
Hi I'm using the master of the IDF and I'm still having this problem. Even testing with the simple_wifi example, the SYSTEM_EVENT_STA_START event is fired, but then nothing. With correct and incorrect wifi credentials, there's no SYSTEM_EVENT_STA_DISCONNECTED or SYSTEM_EVENT_STA_CONNECTED. Thanks |
Ok. I think what was happening was make clean wasn't cleaning properly, possibly due to some change to the underlying mbedtls project makefile? I deleted the build directory manually and built is again and it worked fine. |
Apologies for posting on a closed item, but I found this while searching for a solution to why esp_wifi_connect wouldn't connect properly despite wifi_config_t.ssid and password being correct. I found that while setting the wifi_config_t using esp_wifi_set_config, that the wifi_config_t var went out of scope shortly after setting config. This caused the config in nvs to be incorrect, and would not connect to wifi. This may help someone in the future. |
I have found a situation where esp_wifi_connect() returns ESP_OK but no system event is emitted. This makes it impossible to know if the connection attempt is complete and has succeeded or failed.
I have documented the problem at https://esp32.com/viewtopic.php?f=2&t=5183
Here is a sample project that runs on any dev board that demonstrates the issue. It includes a README.md that explains how to set up the test.
ap_loss.zip
In short, if you attempt to connect to an known network with a bad password, get a SYSTEM_EVENT_STA_DISCONNECTED, then try to connect to an unknown network you will never get a system event and on the console you will see
wifi: ap_loss
.The text was updated successfully, but these errors were encountered: