Host library for controlling a WiConnect enabled Wi-Fi module.
Dependents: wiconnect-ota_example wiconnect-web_setup_example wiconnect-test-console wiconnect-tcp_server_example ... more
Diff: NetworkJoin.cpp
- Revision:
- 33:9b690d76eedf
- Parent:
- 29:b6af04b77a56
diff -r b2bdbc018665 -r 9b690d76eedf NetworkJoin.cpp --- a/NetworkJoin.cpp Mon Oct 27 14:16:03 2014 -0700 +++ b/NetworkJoin.cpp Mon Nov 03 23:48:38 2014 +0000 @@ -36,6 +36,7 @@ enum { + FS_SET_NETWORK_DOWN, FS_SET_SSID, FS_SET_PASSWORD, FS_NETWORK_UP, @@ -46,6 +47,14 @@ CHECK_OTHER_COMMAND_EXECUTING(); + if(wiconnect->internalProcessingState == FS_SET_NETWORK_DOWN) + { + if(WICONNECT_SUCCEEDED(result, wiconnect->sendCommand("network_down"))) + { + wiconnect->internalProcessingState = FS_SET_SSID; + } + } + if(wiconnect->internalProcessingState == FS_SET_SSID) { if(ssid == NULL ||