VSF Documented
vsf_usbh_wifi_rt2x00.h
Go to the documentation of this file.
1/*****************************************************************************
2 * Copyright(C)2009-2022 by VSF Team *
3 * *
4 * Licensed under the Apache License, Version 2.0 (the "License"); *
5 * you may not use this file except in compliance with the License. *
6 * You may obtain a copy of the License at *
7 * *
8 * http://www.apache.org/licenses/LICENSE-2.0 *
9 * *
10 * Unless required by applicable law or agreed to in writing, software *
11 * distributed under the License is distributed on an "AS IS" BASIS, *
12 * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. *
13 * See the License for the specific language governing permissions and *
14 * limitations under the License. *
15 * *
16 ****************************************************************************/
17
18#ifndef __VSF_USBH_WIFI_RT2X00_H__
19#define __VSF_USBH_WIFI_RT2X00_H__
20
21/*============================ INCLUDES ======================================*/
23
24#if VSF_USE_USB_HOST == ENABLED && VSF_USBH_USE_RT2X00 == ENABLED
25
27
28#if VSF_USE_WIFI == ENABLED
29
30/*============================ LOGGING HELPERS ===============================*/
31
32#if VSF_WIFI_CFG_BUS_RT2X00_LOG_LEVEL >= 1
33# define vsf_wifi_bus_rt2x00_trace_error(...) vsf_trace_error(__VA_ARGS__)
34#else
35# define vsf_wifi_bus_rt2x00_trace_error(...) ((void)0)
36#endif
37
38#if VSF_WIFI_CFG_BUS_RT2X00_LOG_LEVEL >= 2
39# define vsf_wifi_bus_rt2x00_trace_info(...) vsf_trace_info(__VA_ARGS__)
40#else
41# define vsf_wifi_bus_rt2x00_trace_info(...) ((void)0)
42#endif
43
44#if VSF_WIFI_CFG_BUS_RT2X00_LOG_LEVEL >= 4
45# define vsf_wifi_bus_rt2x00_trace_debug(...) vsf_trace_info(__VA_ARGS__)
46#else
47# define vsf_wifi_bus_rt2x00_trace_debug(...) ((void)0)
48#endif
49
50#ifdef __cplusplus
51extern "C" {
52#endif
53
54/*============================ MACROS ========================================*/
55
56/* Backward-compatibility type aliases — old code using vk_usbh_wifi_*_t
57 * names continues to compile without modification. */
61
62/*============================ TYPES =========================================*/
63
65
66/*============================ GLOBAL VARIABLES ==============================*/
67
69
70/*============================ USB-SPECIFIC API ==============================*/
71
72/* TX path — USB-specific because it ships frames via bulk OUT endpoints.
73 * Other buses (SDIO) would have their own send API. */
75bool vk_usbh_wifi_can_send(void *dev);
76
77/* Retrieve the embedded generic wifi handle from the USB wifi device. */
79
80#ifdef __cplusplus
81}
82#endif
83
84#endif // VSF_USE_WIFI
85#endif // VSF_USE_USB_HOST && VSF_USBH_USE_RT2X00
86#endif // __VSF_USBH_WIFI_RT2X00_H__
vsf_err_t
Definition __type.h:42
Definition vsf_usbh.h:268
unsigned short uint16_t
Definition stdint.h:7
unsigned char uint8_t
Definition stdint.h:5
Definition vsf_usbh_wifi_rt2x00_priv.h:74
vk_usbh_dev_t * dev
Definition vsf_usbh_wifi_rt2x00_priv.h:80
Definition vsf_wifi.h:154
Definition vsf_wifi.h:129
Definition vsf_wifi_priv.h:36
bool vk_usbh_wifi_can_send(void *dev)
Definition vsf_usbh_wifi_rt2x00.c:675
vsf_wifi_scan_result_t vk_usbh_wifi_scan_result_t
Definition vsf_usbh_wifi_rt2x00.h:58
vsf_wifi_link_info_t vk_usbh_wifi_link_info_t
Definition vsf_usbh_wifi_rt2x00.h:59
vsf_err_t vk_usbh_wifi_send(void *dev, uint8_t *frame, uint16_t len)
Definition vsf_usbh_wifi_rt2x00.c:686
vsf_wifi_t * vk_usbh_wifi_get_wifi(void *dev)
Definition vsf_usbh_wifi_rt2x00.c:669
vsf_wifi_auth_cfg_t vk_usbh_wifi_auth_cfg_t
Definition vsf_usbh_wifi_rt2x00.h:60
const vk_usbh_class_drv_t vk_usbh_wifi_drv
Definition vsf_usbh_wifi_rt2x00.c:116
Generated from commit: vsfteam/vsf@d3b40b2