TI's CC3100. A test demo with very little testing done!

Dependencies:   mbed

Fork of cc3100_Test_Demo2 by 高 杨

Revision:
8:bb9cccbe84d7
Parent:
6:778b081f6a13
--- a/simplelink/cc3100.cpp	Thu Sep 03 13:43:50 2015 +0000
+++ b/simplelink/cc3100.cpp	Sat Jul 22 05:04:14 2017 +0000
@@ -156,8 +156,9 @@
 
     int32_t          retVal = -1;
     int32_t          role = -1;
-
+    printf("role=\r\n");
     role = sl_Start(0, 0, 0);
+    printf("role=%d\r\n",role);
     ASSERT_ON_ERROR(role);
 
     /* If the device is not in station-mode, try configuring it in station-mode */
@@ -984,25 +985,27 @@
 {
     int16_t ObjIdx = MAX_CONCURRENT_ACTIONS;
     InitComplete_t  AsyncRsp;
-
+    printf("SL_POOL_IS_EMPTY\r\n");
     /* Perform any preprocessing before enable networking services */
     sl_DeviceEnablePreamble();//stub only
-    
+    printf("SL\r\n");
     /* ControlBlock init */
     _driver._SlDrvDriverCBInit();
-    
+     printf("SL1\r\n");
     /* open the interface: usually SPI or UART */
     if (NULL == pIfHdl) 
     {
         g_pCB->FD = _spi.spi_Open((int8_t *)pDevName, 0);
+         printf("SL2\r\n");
     } 
     else 
     {
         g_pCB->FD = (_SlFd_t)pIfHdl;
+         printf("SL3\r\n");
     }
        
     ObjIdx = _driver._SlDrvProtectAsyncRespSetting((uint8_t *)&AsyncRsp, START_STOP_ID, SL_MAX_SOCKETS);
-    
+     printf("SL4\r\n");
     if (MAX_CONCURRENT_ACTIONS == ObjIdx) 
     {
         printf("SL_POOL_IS_EMPTY\r\n");
@@ -1015,21 +1018,23 @@
         g_pCB->pInitCallback = pInitCallBack;
             
         _spi.CC3100_enable();
-
+		  printf("SL5\r\n");
         if (NULL == pInitCallBack) {
-            
+              printf("SL9=%d\r\n",pInitCallBack);
             _driver._SlDrvSyncObjWaitForever(&g_pCB->ObjPool[ObjIdx].SyncObj);
-            
+             printf("SL6\r\n"); 
             /*release Pool Object*/           
-            _driver._SlDrvReleasePoolObj(g_pCB->FunctionParams.AsyncExt.ActionIndex);            
+            _driver._SlDrvReleasePoolObj(g_pCB->FunctionParams.AsyncExt.ActionIndex);
+              printf("SL6\r\n");            
             return _sl_GetStartResponseConvert(AsyncRsp.Status);
         }
         else
         {
+              printf("SL7\r\n");
             return SL_RET_CODE_OK;    
         }
     }
-    
+      printf("SL8\r\n");
     return SL_BAD_INTERFACE;