Important changes to repositories hosted on mbed.com
Mbed hosted mercurial repositories are deprecated and are due to be permanently deleted in July 2026.
To keep a copy of this software download the repository Zip archive or clone locally using Mercurial.
It is also possible to export all your personal repositories from the account settings page.
Dependents: HTTPClient_WiFi_HelloWorld_src
Fork of SNICInterface by
Diff: SNIC_WifiInterface.cpp
- Revision:
- 43:d80bbb12ffe6
- Parent:
- 40:b6b10c22a121
- Child:
- 51:69a9cf901d54
--- a/SNIC_WifiInterface.cpp Fri Sep 19 01:46:17 2014 +0000
+++ b/SNIC_WifiInterface.cpp Fri Nov 14 00:52:31 2014 +0000
@@ -211,15 +211,21 @@
int ret;
// Wait UART response
ret = uartCmdMgr_p->wait();
- if( ret != 0 )
+ if(uartCmdMgr_p->getCommandStatus() != UART_CMD_RES_WIFI_ERR_ALREADY_JOINED)
+ {
+ DEBUG_PRINT( "Already connected\r\n" );
+ }
+ else
{
- DEBUG_PRINT( "join failed\r\n" );
- snic_core_p->freeCmdBuf( payload_buf_p );
- return -1;
+ if( ret != 0 )
+ {
+ DEBUG_PRINT( "join failed\r\n" );
+ snic_core_p->freeCmdBuf( payload_buf_p );
+ return -1;
+ }
}
- if( (uartCmdMgr_p->getCommandStatus() != 0) &&
- (uartCmdMgr_p->getCommandStatus() != UART_CMD_RES_WIFI_ERR_ALREADY_JOINED) )
+ if(uartCmdMgr_p->getCommandStatus() != 0)
{
DEBUG_PRINT("join status:%02x\r\n", uartCmdMgr_p->getCommandStatus());
snic_core_p->freeCmdBuf( payload_buf_p );
