Skip to content
GitLab
Projects
Groups
Snippets
Help
Loading...
Help
Help
Support
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in
Toggle navigation
A
arduino-esp32
Project overview
Project overview
Details
Activity
Releases
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Analytics
Analytics
Repository
Value Stream
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Commits
Open sidebar
xpstem
arduino-esp32
Commits
c17b212c
Commit
c17b212c
authored
Jul 17, 2019
by
boarchuz
Committed by
Me No Dev
Jul 16, 2019
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
WPA2 connection fix (significant improvement to connection time) (#2989)
* Config fix test * Also force config even if equal
parent
7dbda498
Changes
1
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
8 additions
and
0 deletions
+8
-0
libraries/WiFi/src/WiFiSTA.cpp
libraries/WiFi/src/WiFiSTA.cpp
+8
-0
No files found.
libraries/WiFi/src/WiFiSTA.cpp
View file @
c17b212c
...
...
@@ -162,6 +162,8 @@ wl_status_t WiFiSTAClass::begin(const char* ssid, const char *passphrase, int32_
esp_wifi_set_config
(
WIFI_IF_STA
,
&
conf
);
}
else
if
(
status
()
==
WL_CONNECTED
){
return
WL_CONNECTED
;
}
else
{
esp_wifi_set_config
(
WIFI_IF_STA
,
&
conf
);
}
if
(
!
_useStaticIp
)
{
...
...
@@ -198,6 +200,12 @@ wl_status_t WiFiSTAClass::begin()
return
WL_CONNECT_FAILED
;
}
wifi_config_t
current_conf
;
if
(
esp_wifi_get_config
(
WIFI_IF_STA
,
&
current_conf
)
!=
ESP_OK
||
esp_wifi_set_config
(
WIFI_IF_STA
,
&
current_conf
)
!=
ESP_OK
)
{
log_e
(
"config failed"
);
return
WL_CONNECT_FAILED
;
}
if
(
!
_useStaticIp
)
{
if
(
tcpip_adapter_dhcpc_start
(
TCPIP_ADAPTER_IF_STA
)
==
ESP_ERR_TCPIP_ADAPTER_DHCPC_START_FAILED
){
log_e
(
"dhcp client start failed!"
);
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment