SimpleLink CC31xx/CC32xx Host Driver
Version 3.0.1.55
Simplifies the implementation of Internet connectivity
|
The SimpleLink(tm) CC31xx/CC32xx family allows to add Wi-Fi and networking capabilities to low-cost embedded products without having prior Wi-Fi, RF or networking expertise.
The CC31xx/CC32xx is an ideal solution for microcontroller-based sensor and control applications such as home appliances, home automation and smart metering.
The CC31xx/CC32xx has integrated a comprehensive TCP/IP network stack, Wi-Fi driver and security supplicant leading to easier portability to microcontrollers, to an ultra-low memory footprint, all without compromising the capabilities and robustness of the final application.
To make it simple, TI's SimpleLink CC31xx/CC32xx platform capabilities were divided into modules by topic (Silo).
These capabilities range from basic device management through wireless network configuration, standard BSD socket and much more.
Listed below are the various modules in the SimpleLink CC31xx/CC32xx driver:
The SimpleLink(tm) device support few different persistency types for settings and configurations:
The porting of the SimpleLink host driver to any new platform is based on few simple steps.
This guide takes you through this process step by step. Please follow the instructions carefully to avoid any problems during this process and to enable efficient and proper work with the device.
Please notice that all modifications and porting adjustments of the driver should be made in the user.h header file only. Keeping this method ensure smoothly transaction to new versions of the driver in the future!
The porting process consists of few simple steps:
For host interface details please refer to: https://processors.wiki.ti.com/index.php/CC31xx_Host_Interface
Please see the rest of the page for more details about the different steps.
The first step is to create a user.h file that will include your configurations and adjustments.
The file should be located in the porting directory (the porting directory is in the same level as the source directory)
It is recommended to use the empty template provided as part of this driver or file of other platform such as MSP432 or CC32xx, from one of the wide range of example applications provided by Texas Instruments.
The CC31xx has two external hardware lines that can be used to enable/disable the device.
The driver manipulates the enable/disable line automatically during sl_Start / sl_Stop.
Not connecting one these lines means that the driver could start only once (sl_Stop will not work correctly and might lead to failure latter on) and the internal provisioning mechanism could not be used.
To bind these lines the following defines should be defined correctly:
If some initializations required before the enable/disable macros are called the user can use also the following optional define
The SimpleLink CC31xx has two standard communication interfaces
The device detects automatically the active interface during initialization. After the detection, the second interface could not be used.
To wrap the driver for the communication channel the following functions should be implemented:
The way these functions are implemented has direct effect on the performances of the SimpleLink device on this target platform. DMA and Jitter Buffer should be considered.
In some platforms the user need to mask the IRQ line when this interrupt could be masked.
The driver can call the mask/unmask whenever is needed. To allow this functionality the user should implement also the following defines:
By default the driver is writing the command in few transactions to allow zero-copy mechanism.
To enable a Jitter buffer for improving the communication line utilization, the can implement also the following defines:
The SimpleLink driver support two memory models:
To enable the dynamic memory, the following pre-processor define should be set:
#define SL_MEMORY_MGMT_DYNAMIC
And the following macros should be defined and supplied:
Using the dynamic mode will allocate the required resources on sl_Start and release these resource on sl_Stop.
The SimpleLink driver could run on two kind of platforms:
When building a multi-threaded application. the following pre-processor define must be set:
#define SL_PLATFORM_MULTI_THREADED
If you choose to work in multi-threaded environment under operating system you will have to provide some basic adaptation routines to allow the driver to protect access to resources for different threads (locking object) and to allow synchronization between threads (sync objects). In additional the driver support running without dedicated thread allocated solely to the SimpleLink driver. If you choose to work in this mode, you should also supply a spawn method that will enable to run function on a temporary context.
The SimpleLink device generate asynchronous events in several situations. These asynchronous events could be masked. In order to catch these events you have to provide handler routines. Please notice that if you not provide a handler routine and the event is received, the driver will drop this event without any indication of this drop.
The driver is delivered with some porting diagnostic tools to simplify the porting validation process and to reduce issues latter. It is very important to follow carefully this process.
The diagnostic process include:
The SimpleLink(tm) device support few different persistency types for settings and configurations: