CC31xx Programmers Guide

From Texas Instruments Wiki
Jump to: navigation, search
Cc31xx cc32xx return home.png


The SimpleLinkTM Wi-Fi CC3100 and CC3200 are the next generation in Embedded Wi-Fi. The CC3100 Internet-on-a-chipTM can add Wi-Fi and Internet to any microcontroller (MCU), such as TI's ultra-low power MSP430TM. The CC3200 is a programmable Wi-Fi MCU that enables true, integrated IoT development. The Wi-Fi Network Processor(NWP) sub-system in both SimpleLink Wi-Fi devices integrates all protocols for Wi-Fi and Internet, greatly minimizing MCU software requirements. With built-in security protocols, SimpleLink Wi-Fi provides a robust and simple security experience.

The purpose of this document is to provide programmers, all the required knowledge on the simplelink Wi-Fi NWP capabilities and how to use them through the host driver. This includes an overview on how to write a networking application, a detailed description of the device’s networking operation modes and features, and a review of each of the driver’s API accompanied by source code examples for each topic.


Date Description Link
March, 2016 CC3100\CC3200 SimpleLink™ Wi-Fi® Network Processor Subsystem SWRU368


CC31xx and CC32xx can support WEP Hex format in Rev 1 with some small limitations
Main known Limitations:

  • WPA Hex
    1. Rev 1 is not supporting (STA and AP)
  • Smart Config
    1. Only WEP hex is supported (ASCII not supported)

Please review the tables below:

STA mode

Sl_connect(Host) OR Add profile(Host) WEP Hex can be Supported
WPA Hex is not supported
Smart Config WPA ASCII is not supported, Supports only WEP Hex
WPA Hex is not supported
HTTP (add profile) WEP Hex can be Supported
WPA Hex is not supported

AP mode

ApConfigCmd(Host) WEP Hex can be Supported
WPA Hex is not supported
HTTP(AP_config) WEP Hex can be Supported
WPA Hex is not supported

JavaScript Example:

function hex2ascii(hex)
       var i;
       var ascii = '';
       for (i=0 ; i < hex.length/2 ; i++)
              ascii += String.fromCharCode(parseInt(hex.substr(i*2,2),16));
       return ascii;
function myFunction()
       var HexPassword = "12345ABCDE";
       var AsciiPassword = hex2ascii(HexPassword);

Host driver example:

static INT32 establishConnectionWithAP()
       char SSID[MAX_SSID_SIZE];
       char password[MAX_PASSKEY_SIZE];
       SlSecParams_t secParams = {0};
       INT32 retVal = -1;
       /**  AP is configured to WEP with 40bit Hex password of: "12345ABCDE"  **/
       password[0] = 0x12;
       password[1] = 0x34;
       password[2] = 0x5A;
       password[3] = 0xBC;
       password[4] = 0xDE;
       password[5] = 0;
       secParams.Key = password;
       secParams.KeyLen = 5; // [--strlen(password) - Don't use strlen in-order not to bump on zero/NULL in the password]
       secParams.Type = SL_SEC_TYPE_WEP;
       strcpy(SSID, "myApSsid");
       retVal = sl_WlanConnect(SSID,strlen(SSID),0,&secParams,0);
       ASSERT_ON_ERROR(__LINE__, retVal);
       printf("Connecting to AP %s...\n", SSID);
       /* Wait */
       while((!IS_CONNECTED(g_Status)) || (!IS_IP_AQUIRED(g_Status)));
       return SUCCESS;