Please note as of Wednesday, August 15th, 2018 this wiki has been set to read only. If you are a TI Employee and require Edit ability please contact x0211426 from the company directory.
CC3100 IP Configuration Application
This sample application demonstrates how to configure a static IP address for CC3100. The device connects to the AP w/ the configured static IP. The IP address will be stored in the non-volatile memory.
Note: This wiki page is only applicable for CC3100-SDK v1.0.0 and upward releases. For documentation on older SDKs' examples, refer corresponding file in <cc3100-sdk-installation-location>\cc3100-sdk\docs\examples\
Source Files briefly explained
i. main - Initializes the device, configures CC3100 for static IP and connects to AP.
Application details and Usage
- Connect the board to a Windows-PC and configure the terminal-program for seeing the logs - CC3100 & CC3200 Terminal Setting has detailed instructions for configuring the terminal-program
- Edit values for below macros in main.c for configuring the static IP address:
#define CONFIG_IP SL_IPV4_VAL(192,168,1,45)
- Edit values for below macros in main.c per the APs properties:
#define AP_MASK SL_IPV4_VAL(255,255,255,0) #define AP_GATEWAY SL_IPV4_VAL(192,168,1,1) #define AP_DNS SL_IPV4_VAL(0,0,0,0)
- Edit following parameters in sl_common.h - The device connects to this AP on getting the corresponding command from application:
#define SSID_NAME "<ap_name>" #define SEC_TYPE SL_SEC_TYPE_OPEN #define PASSKEY ""
- Build and run the application
- See the self explanatory logs on the terminal-program's console.
- The device connect to the '<ap_name>' access-point w/ the static IP defined in 'CONFIG_IP'.
- The connection could be checked by pinging CC3100 on the static IP address
Note: : User needs to reconfigure the device in 'DHCP Mode' for executing other sample applications. Refer function configureSimpleLinkToDefaultState in this example's main.c for configuring the device in 'DHCP Mode'. Also, defining USE_DHCP in this sample application configures the device in DHCP mode