Version
32
SWRU455A – February 2017 – Revised March 2017
Copyright © 2017, Texas Instruments Incorporated
Device
Example:
_i16 Status;
_i16 Role;
SlDeviceUartIfParams_t params;
#define
COMM_PORT_NUM 24
/* uart com port number */
params.BaudRate = SL_DEVICE_BAUD_115200;
/*set default baud rate */
params.FlowControlEnable = 1;
params.CommPort = COMM_PORT_NUM;
Role = sl_Start(NULL, (
signed char
*)¶ms, NULL)
params.BaudRate = SL_DEVICE_BAUD_921600;
/* set default baud rate 921600 */
Status = sl_DeviceUartSetMode((
signed char
*)¶ms);
if
( Status )
{
/* error */
}
3.5
Version
The SimpleLink Wi-Fi device offers users the ability to read the internal device firmware version number.
Example:
_i16 Status;
SlDeviceVersion_t ver;
pConfigLen =
sizeof
(ver);
pConfigOpt = SL_DEVICE_GENERAL_VERSION;
Status = sl_DeviceGet(SL_DEVICE_GENERAL,&pConfigOpt,&pConfigLen,(_u8 *)(&ver));
if
( Status )
{
/* error */
}
3.6
Event Mask
The SimpleLink Wi-Fi device lets users mask some of the asynchronous events. Masked events do not
arrive to the host driver. This setting should apply for each API silo separately and include only the events
needed to be masked. By default, none of the events are masked. This configuration is persistent
according to the system-persistent configuration.
Example:
_i16 Status;
/* Mask WLAN connect and disconnect events */
Status = sl_DeviceEventMaskSet(SL_DEVICE_EVENT_CLASS_WLAN,
(SL_DEVICE_EVENT_BIT(SL_WLAN_EVENT_CONNECT) | SL_DEVICE_EVENT_BIT(SL_WLAN_EVENT_DISCONNECT) ) );
if
( Status )
{
/* error */
}
3.7
Time and Date
The SimpleLink Wi-Fi device gives users the option to set, and get time and date configuration from the
RTC on the device. The RTC is a continuous counter which is active even during hibernation and resets
only after shutdown.