Zephyr API Documentation  2.7.0-rc2
A Scalable Open Source RTOS
simplelink_support.h
Go to the documentation of this file.
1/*
2 * Copyright (c) 2018, Texas Instruments Incorporated
3 *
4 * SPDX-License-Identifier: Apache-2.0
5 *
6 */
7
8#ifndef ZEPHYR_DRIVERS_WIFI_SIMPLELINK_SIMPLELINK_SUPPORT_H_
9#define ZEPHYR_DRIVERS_WIFI_SIMPLELINK_SIMPLELINK_SUPPORT_H_
10
11#include <net/wifi_mgmt.h>
12
13#ifdef __cplusplus
14extern "C" {
15#endif
16
17#define SSID_LEN_MAX (32)
18#define BSSID_LEN_MAX (6)
19
20/* Define ID for simplelink_wifi_cb to not conflict with WLAN event IDs: */
21#define SIMPLELINK_WIFI_CB_IPACQUIRED \
22 (SL_WLAN_EVENT_MAX + SL_NETAPP_EVENT_IPV4_ACQUIRED)
23#define SIMPLELINK_WIFI_CB_IPV6ACQUIRED \
24 (SL_WLAN_EVENT_MAX + SL_NETAPP_EVENT_IPV6_ACQUIRED)
25
34};
35
36/* Callback from SimpleLink Event Handlers: */
37typedef void (*simplelink_wifi_cb_t)(uint32_t mgmt_event,
38 struct sl_connect_state *conn);
39
40extern int z_simplelink_start_scan(void);
41extern void z_simplelink_get_scan_result(int index,
42 struct wifi_scan_result *scan_result);
43extern void z_simplelink_get_mac(unsigned char *mac);
44extern int z_simplelink_init(simplelink_wifi_cb_t wifi_cb);
45extern int z_simplelink_connect(struct wifi_connect_req_params *params);
46extern int z_simplelink_disconnect(void);
47
48#ifdef __cplusplus
49}
50#endif
51
56#endif /* ZEPHYR_DRIVERS_WIFI_SIMPLELINK_SIMPLELINK_SUPPORT_H_ */
ZTEST_BMEM int index[(3)]
Definition: main.c:32
void
Definition: eswifi_shell.c:15
__UINT32_TYPE__ uint32_t
Definition: stdint.h:60
__UINT8_TYPE__ uint8_t
Definition: stdint.h:58
__INT16_TYPE__ int16_t
Definition: stdint.h:43
Definition: simplelink_support.h:26
uint8_t ssid[(32)+1]
Definition: simplelink_support.h:28
uint32_t ip_addr
Definition: simplelink_support.h:30
uint32_t gateway_ip
Definition: simplelink_support.h:27
uint32_t ipv6_addr[4]
Definition: simplelink_support.h:32
int16_t error
Definition: simplelink_support.h:33
uint8_t bssid[(6)]
Definition: simplelink_support.h:29
uint32_t sta_ip
Definition: simplelink_support.h:31
Definition: wifi_mgmt.h:96
Definition: wifi_mgmt.h:87
WiFi L2 stack public header.