1 /**************************************************************************** 2 **+-----------------------------------------------------------------------+** 3 **| |** 4 **| Copyright(c) 1998 - 2008 Texas Instruments. All rights reserved. |** 5 **| All rights reserved. |** 6 **| |** 7 **| Redistribution and use in source and binary forms, with or without |** 8 **| modification, are permitted provided that the following conditions |** 9 **| are met: |** 10 **| |** 11 **| * Redistributions of source code must retain the above copyright |** 12 **| notice, this list of conditions and the following disclaimer. |** 13 **| * Redistributions in binary form must reproduce the above copyright |** 14 **| notice, this list of conditions and the following disclaimer in |** 15 **| the documentation and/or other materials provided with the |** 16 **| distribution. |** 17 **| * Neither the name Texas Instruments nor the names of its |** 18 **| contributors may be used to endorse or promote products derived |** 19 **| from this software without specific prior written permission. |** 20 **| |** 21 **| THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS |** 22 **| "AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT |** 23 **| LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR |** 24 **| A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT |** 25 **| OWNER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, |** 26 **| SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT |** 27 **| LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, |** 28 **| DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY |** 29 **| THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT |** 30 **| (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE |** 31 **| OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. |** 32 **| |** 33 **+-----------------------------------------------------------------------+** 34 ****************************************************************************/ 35 36 /** \file bssTypes.h 37 * \brief This file include public type definitions for Driver-wide BSS information 38 * \author Ronen Kalish 39 * \date 05-April-2005 40 */ 41 42 43 #ifndef __BSS_TYPES_API_H__ 44 #define __BSS_TYPES_API_H__ 45 46 #include "osDot11.h" 47 48 /* 49 *********************************************************************** 50 * Constant definitions. 51 *********************************************************************** 52 */ 53 #define MAX_NUM_OF_NEIGHBOR_APS 30 54 #define MAX_SIZE_OF_BSS_TRACK_LIST 16 55 56 /** \enum resultFrameType_e 57 * \brief enumerates the different types for a result frame 58 */ 59 typedef enum 60 { 61 SCAN_RFT_BEACON = 0, /**< result frame is a beacon */ 62 SCAN_RFT_PROBE_RESPONSE /**< result frame is a probe response */ 63 } resultFrameType_e; 64 65 /* 66 *********************************************************************** 67 * Structure definitions. 68 *********************************************************************** 69 */ 70 71 /** \struct bssEntry_t 72 * \brief This structure contains a single BSS entry 73 */ 74 typedef struct 75 { 76 /* values in beacon with fixed length */ 77 macAddress_t BSSID; /**< BSSID of this entry */ 78 UINT64 lastRxTSF; /**< TSF of last received frame */ 79 UINT16 beaconInterval; /**< Beacon interval of this AP */ 80 UINT16 capabilities; /**< capabilities of this AP */ 81 /* IE's in beacon */ 82 UINT8 DTIMPeriod; /**< DTIm period (in beacon interval quantas */ 83 resultFrameType_e resultType; /**< The type of frame in pBuffer */ 84 UINT16 bufferLength; /**< length of rest of beacon (or probe response) buffer */ 85 UINT8* pBuffer; /**< rest of beacon (or probe response) buffer */ 86 /* Information from other sources */ 87 radioBand_e band; /**< band on which the AP transmits */ 88 UINT8 channel; /**< channel on which the AP transmits */ 89 UINT8 rxRate; /**< Rate at which last frame was received */ 90 UINT32 lastRxHostTimestamp; /**< 91 * the host timestamp (in milliseconds) at which last frame 92 * was received 93 */ 94 INT8 RSSI; /**< average RSSI */ 95 INT8 lastRSSI; /** last given RSSI */ 96 BOOLEAN bNeighborAP; /**< Indicates whether this is a neighbor AP */ 97 } bssEntry_t; 98 99 /** \struct bssList_t 100 * \brief This structure contains the BSS list 101 */ 102 typedef struct 103 { 104 UINT8 numOfEntries; /**< number of entries in the list */ 105 bssEntry_t BSSList[ MAX_SIZE_OF_BSS_TRACK_LIST ]; /**< list of entries */ 106 } bssList_t; 107 108 /** \struct neighborAP_t 109 * \brief This structure contains information on one neighbor AP 110 */ 111 typedef struct 112 { 113 macAddress_t BSSID; /**< The BSSID (MAC address) of this AP */ 114 UINT8 channel; /**< the channel on which the AP transmits */ 115 radioBand_e band; /**< the band used by the AP */ 116 } neighborAP_t; 117 118 /** \struct neighborAPList_t 119 * \brief This structure contains a list of Neighbor APs 120 */ 121 typedef struct 122 { 123 UINT8 numOfEntries; /**< the number of entries in the list */ 124 neighborAP_t APListPtr[ MAX_NUM_OF_NEIGHBOR_APS ]; /**< a pointer to the list of APs */ 125 } neighborAPList_t; 126 127 128 #endif 129