Hi all,
I have some questions regarding the functions inside the "esp_wifi.h" file.
1)
Where can I locate the source code these functions are declared in? In other words: where can I find the function bodies? I want to see what goes on inside these functions. But I cannot find them inside the IDF. Maybe I look in the wrong direction.
What I am looking for is how for instance the function "esp_wifi_connect()" is detecting that the wifi is not yet started, so it returns an "ESP_ERR_WIFI_NOT_STARTED" return code. I'd like to know these things.
2) Can someone explain to me what the following output means?
I (21958) wifi: n:6 0, o:6 0, ap:255 255, sta:6 0, prof:1
I (21958) wifi: state: init -> auth (b0)
I (21968) wifi: state: auth -> assoc (0)
I (21998) wifi: state: assoc -> run (10)
I (22528) wifi: connected with NOKIA Lumia 920_9610, channel 6
I (22528) wifi: pm start, type: 1
a) what is "n", "o" and "prof" mean?
b) what does the line "state: init -> auth (b0)" indicate?
c) what does the line "state: assoc -> run (10)" indicate? What does 10 do?
d) where does "pm" stand for in the line "wifi: pm start, type: 1"?
I know these may look like silly questions, but I am trying to understand the whole WiFi library, so I can debug my issues better.
All this I cannot find in the documentation.
esp_wifi.h questions
Re: esp_wifi.h questions
Funcions are defined into ESP32 WiFi Library whose source can't be seen by SDK Developer. So, You can not get function definition of each declared function of this header files.kluverp wrote:Hi all,
I have some questions regarding the functions inside the "esp_wifi.h" file.
1)
Where can I locate the source code these functions are declared in? In other words: where can I find the function bodies? I want to see what goes on inside these functions. But I cannot find them inside the IDF. Maybe I look in the wrong direction.
What I am looking for is how for instance the function "esp_wifi_connect()" is detecting that the wifi is not yet started, so it returns an "ESP_ERR_WIFI_NOT_STARTED" return code. I'd like to know these things.
2) Can someone explain to me what the following output means?
I (21958) wifi: n:6 0, o:6 0, ap:255 255, sta:6 0, prof:1
I (21958) wifi: state: init -> auth (b0)
I (21968) wifi: state: auth -> assoc (0)
I (21998) wifi: state: assoc -> run (10)
I (22528) wifi: connected with NOKIA Lumia 920_9610, channel 6
I (22528) wifi: pm start, type: 1
a) what is "n", "o" and "prof" mean?
b) what does the line "state: init -> auth (b0)" indicate?
c) what does the line "state: assoc -> run (10)" indicate? What does 10 do?
d) where does "pm" stand for in the line "wifi: pm start, type: 1"?
I know these may look like silly questions, but I am trying to understand the whole WiFi library, so I can debug my issues better.
All this I cannot find in the documentation.
pm stands for Power Management
a), b) and c) which you have mentioned indicates different states of ESP32 WiFi initialization process starting from authentication to association till it's connected with STA router configured as WiFi configuration
Hope this will answer your questions in basic overview.
Regards,
Ritesh Prajapati
Ritesh Prajapati
Re: esp_wifi.h questions
Thank you!
This helps a lot.
Is there any reason for the WiFi code not being available to the SDK developer?
This helps a lot.
Is there any reason for the WiFi code not being available to the SDK developer?
Re: esp_wifi.h questions
Hi, I am not an Espressif Engineer but ESP32 IDF User and as far as I know that they want to keep Low Level ESP32 Library related stuffs as secure and confidential as possible. So that they are just providing APIs to execute it from User Level Application.kluverp wrote:Thank you!
This helps a lot.
Is there any reason for the WiFi code not being available to the SDK developer?
I have tried to get ESP32 MAC Layer source and didn't get yet due to this reason.
Hope this will answer your questions. Let me know if you still have any doubt for same.
Regards,
Ritesh Prajapati
Ritesh Prajapati
Re: esp_wifi.h questions
Hope, My couple of answers helped you as per your questions regarding ESP32 WiFi Library and it's APIs.
Do you have still any query regarding that?
Do you have still any query regarding that?
Regards,
Ritesh Prajapati
Ritesh Prajapati
Who is online
Users browsing this forum: Bing [Bot] and 95 guests