1 /* 2 * Copyright (c) 2020 HiSilicon (Shanghai) Technologies CO., LIMITED. 3 * Licensed under the Apache License, Version 2.0 (the "License"); 4 * you may not use this file except in compliance with the License. 5 * You may obtain a copy of the License at 6 * 7 * http://www.apache.org/licenses/LICENSE-2.0 8 * 9 * Unless required by applicable law or agreed to in writing, software 10 * distributed under the License is distributed on an "AS IS" BASIS, 11 * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. 12 * See the License for the specific language governing permissions and 13 * limitations under the License. 14 * Description: wifi_scan_info.h 的头文件 15 */ 16 17 18 /** 19 * @defgroup middleware_service_wifi_scan_info WiFi Scan Info 20 * @ingroup middleware_service_wifi 21 * @{ 22 */ 23 24 #ifndef SERVICE_WIFI_SCAN_INFO_C_H 25 #define SERVICE_WIFI_SCAN_INFO_C_H 26 27 #include "wifi_device_config.h" 28 29 #ifdef __cplusplus 30 #if __cplusplus 31 extern "C" { 32 #endif 33 #endif 34 35 /** 36 * @if Eng 37 * @brief WiFi scan result information. 38 * @else 39 * @brief WiFi扫描结果信息。 40 * @endif 41 */ 42 typedef struct { 43 char ssid[WIFI_MAX_SSID_LEN]; /*!< @if Eng Service set ID (SSID). 44 @else SSID。 @endif */ 45 uint8_t bssid[WIFI_MAC_LEN]; /*!< @if Eng Basic service set ID (BSSID). 46 @else BSSID。 @endif */ 47 int8_t reserved; 48 wifi_security_enum security_type; /*!< @if Eng Security type.For details, see wifi_security_enumType. 49 @else 安全类型。 @endif */ 50 int32_t rssi; /*!< @if Eng Received signal strength indicator (RSSI). 51 @else 信号强度。 @endif */ 52 int32_t band; /*!< @if Eng band. 53 @else 频带。 @endif */ 54 int32_t channel_num; /*!< @if Eng channel num. 55 @else 信道号。 @endif */ 56 } wifi_scan_info_stru; 57 58 /** 59 * @if Eng 60 * @brief callback function definition of wpa-enterprise param import. 61 * @param [in] scan_result scan_result. 62 * @retval ERRCODE_SUCC Execute successfully. 63 * @retval Other Execute failed. 64 * @else 65 * @brief 定制化扫描回调函数。 66 * @param [in] scan_result 扫描结果。 67 * @retval ERRCODE_SUCC 成功。 68 * @retval Other 失败。 69 * @endif 70 */ 71 typedef void (*wifi_scan_no_save_cb)(wifi_scan_info_stru *scan_result); 72 73 #ifdef __cplusplus 74 #if __cplusplus 75 } 76 #endif 77 #endif 78 79 #endif // SERVICE_WIFI_SCAN_INFO_C_H 80 /** @} */ 81