Initial commit
mbed-dev-master/targets/TARGET_STM/TARGET_STM32F4/TARGET_STM32F439xI/TARGET_MODULE_UBLOX_ODIN_W2/sdk/ublox-odin-w2-drivers/cb_wlan_driver_config.h@0:bb348c97df44, 2020-09-16 (annotated)
- Committer:
- lypinator
- Date:
- Wed Sep 16 01:11:49 2020 +0000
- Revision:
- 0:bb348c97df44
Added PWM
Who changed what in which revision?
User | Revision | Line number | New contents of line |
---|---|---|---|
lypinator | 0:bb348c97df44 | 1 | /** |
lypinator | 0:bb348c97df44 | 2 | *--------------------------------------------------------------------------- |
lypinator | 0:bb348c97df44 | 3 | * Copyright (c) 2016, u-blox Malmö, All Rights Reserved |
lypinator | 0:bb348c97df44 | 4 | * SPDX-License-Identifier: LicenseRef-PBL |
lypinator | 0:bb348c97df44 | 5 | * |
lypinator | 0:bb348c97df44 | 6 | * This file and the related binary are licensed under the |
lypinator | 0:bb348c97df44 | 7 | * Permissive Binary License, Version 1.0 (the "License"); |
lypinator | 0:bb348c97df44 | 8 | * you may not use these files except in compliance with the License. |
lypinator | 0:bb348c97df44 | 9 | * |
lypinator | 0:bb348c97df44 | 10 | * You may obtain a copy of the License here: |
lypinator | 0:bb348c97df44 | 11 | * LICENSE-permissive-binary-license-1.0.txt and at |
lypinator | 0:bb348c97df44 | 12 | * https://www.mbed.com/licenses/PBL-1.0 |
lypinator | 0:bb348c97df44 | 13 | * |
lypinator | 0:bb348c97df44 | 14 | * See the License for the specific language governing permissions and |
lypinator | 0:bb348c97df44 | 15 | * limitations under the License. |
lypinator | 0:bb348c97df44 | 16 | * Component : Wireless LAN driver |
lypinator | 0:bb348c97df44 | 17 | * File : cb_wlan_driver_config.h |
lypinator | 0:bb348c97df44 | 18 | * |
lypinator | 0:bb348c97df44 | 19 | * Description : OS related functions |
lypinator | 0:bb348c97df44 | 20 | *-------------------------------------------------------------------------*/ |
lypinator | 0:bb348c97df44 | 21 | /** |
lypinator | 0:bb348c97df44 | 22 | * @file cb_wlan_driver_config.h Driver configuration. |
lypinator | 0:bb348c97df44 | 23 | * @ingroup port |
lypinator | 0:bb348c97df44 | 24 | */ |
lypinator | 0:bb348c97df44 | 25 | #ifndef _CB_WLAN_DRIVER_CONFIG_H_ |
lypinator | 0:bb348c97df44 | 26 | #define _CB_WLAN_DRIVER_CONFIG_H_ |
lypinator | 0:bb348c97df44 | 27 | |
lypinator | 0:bb348c97df44 | 28 | #include <stdlib.h> |
lypinator | 0:bb348c97df44 | 29 | #include <stdio.h> |
lypinator | 0:bb348c97df44 | 30 | #include <string.h> |
lypinator | 0:bb348c97df44 | 31 | #include "cb_target.h" |
lypinator | 0:bb348c97df44 | 32 | #include "cb_status.h" |
lypinator | 0:bb348c97df44 | 33 | |
lypinator | 0:bb348c97df44 | 34 | #ifdef __cplusplus |
lypinator | 0:bb348c97df44 | 35 | extern "C" { |
lypinator | 0:bb348c97df44 | 36 | #endif |
lypinator | 0:bb348c97df44 | 37 | |
lypinator | 0:bb348c97df44 | 38 | /*=========================================================================== |
lypinator | 0:bb348c97df44 | 39 | * DEFINES |
lypinator | 0:bb348c97df44 | 40 | *=========================================================================*/ |
lypinator | 0:bb348c97df44 | 41 | #define cbWLAN_ENABLE_802_11b |
lypinator | 0:bb348c97df44 | 42 | #define cbWLAN_ENABLE_802_11g |
lypinator | 0:bb348c97df44 | 43 | #define cbWLAN_ENABLE_802_11n |
lypinator | 0:bb348c97df44 | 44 | |
lypinator | 0:bb348c97df44 | 45 | /*=========================================================================== |
lypinator | 0:bb348c97df44 | 46 | * TYPES |
lypinator | 0:bb348c97df44 | 47 | *=========================================================================*/ |
lypinator | 0:bb348c97df44 | 48 | |
lypinator | 0:bb348c97df44 | 49 | #define cbTARGET_GSETTING_4_ADDRESS_MODE_STATION_DYNAMIC cb_BIT_0 |
lypinator | 0:bb348c97df44 | 50 | #define cbTARGET_GSETTING_4_ADDRESS_MODE_STATION_ALWAYS cb_BIT_1 |
lypinator | 0:bb348c97df44 | 51 | /** |
lypinator | 0:bb348c97df44 | 52 | * General settings and tuning parameters . |
lypinator | 0:bb348c97df44 | 53 | * |
lypinator | 0:bb348c97df44 | 54 | * @ingroup types |
lypinator | 0:bb348c97df44 | 55 | */ |
lypinator | 0:bb348c97df44 | 56 | typedef enum wm_gsetting_e { |
lypinator | 0:bb348c97df44 | 57 | cbTARGET_GSETTING_START = 0, |
lypinator | 0:bb348c97df44 | 58 | cbTARGET_GSETTING_PREAMBLE = cbTARGET_GSETTING_START, /**< 0 = Long preamble, 1 = Short preamble */ |
lypinator | 0:bb348c97df44 | 59 | cbTARGET_GSETTING_MIN_SCAN_TIME, /**< Minimum scan time in TU per channel */ |
lypinator | 0:bb348c97df44 | 60 | cbTARGET_GSETTING_MAX_SCAN_TIME, /**< Maximum scan time in TU per channel */ |
lypinator | 0:bb348c97df44 | 61 | cbTARGET_GSETTING_SCAN_TYPE, /**< Use @ref cbWM_ScanType. */ |
lypinator | 0:bb348c97df44 | 62 | cbTARGET_GSETTING_BEACON_INTERVAL, /**< Beacon interval for Ad-hoc/IBSS networks. */ |
lypinator | 0:bb348c97df44 | 63 | cbTARGET_GSETTING_JOIN_FAILURE_TIMEOUT, /**< Time in beacons before the join procedure times out. */ |
lypinator | 0:bb348c97df44 | 64 | cbTARGET_GSETTING_BT_COEX, /**< Bluetooth co-existence 0 = off, 1 = on */ |
lypinator | 0:bb348c97df44 | 65 | cbTARGET_GSETTING_DATA_RATE, /**< Set the data rate to use. Use @ref cbWLAN_Rate */ |
lypinator | 0:bb348c97df44 | 66 | cbTARGET_GSETTING_LINK_ADAPTION, /**< Dynamically adapt the data rate. 0 = off, 1 = on */ |
lypinator | 0:bb348c97df44 | 67 | cbTARGET_GSETTING_POWER_SAVE, /**< 0 = off, 1 = Fast PSP, 2 = Max PSP */ |
lypinator | 0:bb348c97df44 | 68 | cbTARGET_GSETTING_DTIM_ENABLE, /**< Enable DTIM when powersaving */ |
lypinator | 0:bb348c97df44 | 69 | cbTARGET_GSETTING_QOS_ENABLE, /**< Enable QoS */ |
lypinator | 0:bb348c97df44 | 70 | cbTARGET_GSETTING_RTS_THRESHOLD, /**< Set the RTS (Request to send) threshold */ |
lypinator | 0:bb348c97df44 | 71 | cbTARGET_GSETTING_FRAGMENTATION_THRESHOLD, /**< Set the fragmentation threshold */ |
lypinator | 0:bb348c97df44 | 72 | cbTARGET_GSETTING_TX_POWER, /**< Desired output power in dBm. */ |
lypinator | 0:bb348c97df44 | 73 | cbTARGET_GSETTING_MAX_PASSIVE_SCAN_TIME, /**< Maximum scan time for passive scan */ |
lypinator | 0:bb348c97df44 | 74 | cbTARGET_GSETTING_MODULE_TYPE, /**< Type of module. TODO: remove. Legacy parameter that shouldn't be possible to change. */ |
lypinator | 0:bb348c97df44 | 75 | cbTARGET_GSETTING_SCAN_LISTEN_INTERVAL, /**< Listen interval between channel scans */ |
lypinator | 0:bb348c97df44 | 76 | cbTARGET_GSETTING_SLEEP_TIMEOUT, /**< Only allow power save modes after this period of inactivity. Timeout in ms. Only used when power save is enabled */ |
lypinator | 0:bb348c97df44 | 77 | cbTARGET_GSETTING_DOT11_SHORT_RETRY_LIMIT, /**< 802.11 short retry limit for station (dot11ShortRetryLimit). Bit 31-24 reserved, bit 23-16 EAPOL & Broadcast, bit 15-8 MGMT, bit 7-0 data. */ |
lypinator | 0:bb348c97df44 | 78 | cbTARGET_GSETTING_DOT11_LONG_RETRY_LIMIT, /**< 802.11 long retry limit for station (dot11LongRetryLimit). Bit 31-24 reserved, bit 23-16 EAPOL & Broadcast, bit 15-8 MGMT, bit 7-0 data. */ |
lypinator | 0:bb348c97df44 | 79 | cbTARGET_GSETTING_AP_DOT11_SHORT_RETRY_LIMIT, /**< 802.11 short retry limit for AP (dot11ShortRetryLimit). Bit 31-24 reserved, bit 23-16 EAPOL & Broadcast, bit 15-8 MGMT, bit 7-0 data. */ |
lypinator | 0:bb348c97df44 | 80 | cbTARGET_GSETTING_AP_DOT11_LONG_RETRY_LIMIT, /**< 802.11 long retry limit for AP (dot11LongRetryLimit). Bit 31-24 reserved, bit 23-16 EAPOL & Broadcast, bit 15-8 MGMT, bit 7-0 data. */ |
lypinator | 0:bb348c97df44 | 81 | cbTARGET_GSETTING_CHANNEL_TYPE, /**< 0-NO_HT, 1-HT20, 2-HT40MINUS, 3-HT40PLUS */ |
lypinator | 0:bb348c97df44 | 82 | cbTARGET_GSETTING_PMF_STA, /**< Protected Management frame Option for STA*/ |
lypinator | 0:bb348c97df44 | 83 | cbTARGET_GSETTING_REMAIN_ON_CHANNEL, /**< Set 0 disable, 1 enable */ |
lypinator | 0:bb348c97df44 | 84 | cbTARGET_GSETTING_STA_TX_RATE_MASK, /**< TX rates for station. May be overridden if not supported by AP. Set to 0 for AP default. @sa cbWLAN_RateMask_e */ |
lypinator | 0:bb348c97df44 | 85 | cbTARGET_GSETTING_RSSI_GOOD, /**< When to abort scanning and initiate connection */ |
lypinator | 0:bb348c97df44 | 86 | cbTARGET_GSETTING_RSSI_BAD, /**< When to use BAD_RSSI_SCAN_YIELD_TIMEOUT for scanning between each channel for roaming */ |
lypinator | 0:bb348c97df44 | 87 | cbTARGET_GSETTING_GOOD_RSSI_SCAN_YIELD_TIMEOUT, /**< Gap between each channel when doing background scan with a good connection */ |
lypinator | 0:bb348c97df44 | 88 | cbTARGET_GSETTING_BAD_RSSI_SCAN_YIELD_TIMEOUT, /**< Gap between each channel when doing background scan with a bad connection */ |
lypinator | 0:bb348c97df44 | 89 | cbTARGET_GSETTING_ROAM_BLACKLIST_LAST_BSSID_TIMEOUT, /**< How long a new connection to the last connected AP should be banned */ |
lypinator | 0:bb348c97df44 | 90 | cbTARGET_GSETTING_FORCE_WORLD_MODE, /**< Set 0 disable, 1 enable */ |
lypinator | 0:bb348c97df44 | 91 | cbTARGET_GSETTING_TX_PACKET_ACK_TIMEOUT_WD, /**< Max time for an Tx packet to not being acked by the radio before we send a soft-error event */ |
lypinator | 0:bb348c97df44 | 92 | cbTARGET_GSETTING_CTS_PROTECTION, /** send CTS to self before transmission. 0 disable, 1 enable. */ |
lypinator | 0:bb348c97df44 | 93 | cbTARGET_GSETTING_HIDDEN_SSID, /** Hidden ssid, 0 disable else enable. */ |
lypinator | 0:bb348c97df44 | 94 | cbTARGET_GSETTING_AP_STA_INACTIVITY_TIMEOUT, /**< Aging period for Station in seconds */ |
lypinator | 0:bb348c97df44 | 95 | cbTARGET_GSETTING_ROAMING_AREA_HYSTERESIS, /** Threshold between good and bad connection. */ |
lypinator | 0:bb348c97df44 | 96 | cbTARGET_GSETTING_FT_MODE, /** 802.11r (FT) mode, 0 - Disabled, 1 - FT over air, 2 - FT over DS */ |
lypinator | 0:bb348c97df44 | 97 | cbTARGET_GSETTING_4_ADDRESS_MODE, /** Bit0 - enable dynamic mode for station. Bit1 - always enable for station. */ |
lypinator | 0:bb348c97df44 | 98 | cbTARGET_GSETTING_MAX, |
lypinator | 0:bb348c97df44 | 99 | } cbWM_GSETTING; |
lypinator | 0:bb348c97df44 | 100 | |
lypinator | 0:bb348c97df44 | 101 | typedef enum targetConfigParams { |
lypinator | 0:bb348c97df44 | 102 | cbTARGET_CFG_FIRST, |
lypinator | 0:bb348c97df44 | 103 | cbTARGET_CFG_SET_POWER_SAVE_MODE = cbTARGET_CFG_FIRST, //!< Set power mode @ref cbWLAN_IoctlPowerSaveMode |
lypinator | 0:bb348c97df44 | 104 | cbTARGET_CFG_GET_POWER_SAVE_MODE, //!< Get power mode @ref cbWLAN_IoctlPowerSaveMode |
lypinator | 0:bb348c97df44 | 105 | cbTARGET_CFG_SET_LISTEN_INTERVAL, //!< Set listen interval, integer value 0 - 16 |
lypinator | 0:bb348c97df44 | 106 | cbTARGET_CFG_GET_LISTEN_INTERVAL, //!< Get listen interval, integer value 0 - 16 |
lypinator | 0:bb348c97df44 | 107 | cbTARGET_CFG_SET_DTIM_ENABLE, //!< Set DTIM enable 0, disable 1 enable |
lypinator | 0:bb348c97df44 | 108 | cbTARGET_CFG_GET_DTIM_ENABLE, //!< Get DTIM enable 0, disable 1 enable |
lypinator | 0:bb348c97df44 | 109 | cbTARGET_CFG_SET_SLEEP_TIMEOUT, //!< Set enter power save entry delay (in ms). Power save mode will be entered only if there no activity during this delay |
lypinator | 0:bb348c97df44 | 110 | cbTARGET_CFG_GET_SLEEP_TIMEOUT, //!< Get enter power save entry delay (in ms). Power save mode will be entered only if there no activity during this delay |
lypinator | 0:bb348c97df44 | 111 | cbTARGET_CFG_SET_RSSI_GOOD, //!< SEE CORRESPONDING GSETTING |
lypinator | 0:bb348c97df44 | 112 | cbTARGET_CFG_GET_RSSI_GOOD, //!< SEE CORRESPONDING GSETTING |
lypinator | 0:bb348c97df44 | 113 | cbTARGET_CFG_SET_RSSI_BAD, //!< SEE CORRESPONDING GSETTING |
lypinator | 0:bb348c97df44 | 114 | cbTARGET_CFG_GET_RSSI_BAD, //!< SEE CORRESPONDING GSETTING |
lypinator | 0:bb348c97df44 | 115 | cbTARGET_CFG_SET_GOOD_RSSI_YIELD_TMO, //!< SEE CORRESPONDING GSETTING |
lypinator | 0:bb348c97df44 | 116 | cbTARGET_CFG_GET_GOOD_RSSI_YIELD_TMO, //!< SEE CORRESPONDING GSETTING |
lypinator | 0:bb348c97df44 | 117 | cbTARGET_CFG_SET_BAD_RSSI_YIELD_TMO, //!< SEE CORRESPONDING GSETTING |
lypinator | 0:bb348c97df44 | 118 | cbTARGET_CFG_GET_BAD_RSSI_YIELD_TMO, //!< SEE CORRESPONDING GSETTING |
lypinator | 0:bb348c97df44 | 119 | cbTARGET_CFG_SET_BLACKLIST_LAST_BSSID_TIMEOUT, //!< SEE CORRESPONDING GSETTING |
lypinator | 0:bb348c97df44 | 120 | cbTARGET_CFG_GET_BLACKLIST_LAST_BSSID_TIMEOUT, //!< SEE CORRESPONDING GSETTING |
lypinator | 0:bb348c97df44 | 121 | cbTARGET_CFG_LAST, |
lypinator | 0:bb348c97df44 | 122 | cbTARGET_CFG_SET_GSETTING = 1000, //!< Pipe to @ref cbWM_gSet. |
lypinator | 0:bb348c97df44 | 123 | cbTARGET_CFG_SET_TSETTING = 2000, //!< Pipe to @ref cbWM_tSet. |
lypinator | 0:bb348c97df44 | 124 | cbTARGET_CFG_GET_GSETTING = 3000, //!< Pipe to @ref cbWM_gGet. |
lypinator | 0:bb348c97df44 | 125 | cbTARGET_CFG_GET_TSETTING = 4000, //!< Pipe to @ref cbWM_tGet. |
lypinator | 0:bb348c97df44 | 126 | } cbTARGET_ConfigParams; |
lypinator | 0:bb348c97df44 | 127 | |
lypinator | 0:bb348c97df44 | 128 | #define cbTARGET_GSETTING_REG(X) ((cb_uint32)((X) - cbTARGET_GSETTING_START)) |
lypinator | 0:bb348c97df44 | 129 | |
lypinator | 0:bb348c97df44 | 130 | /** |
lypinator | 0:bb348c97df44 | 131 | * Target specific settings and tuning parameters . |
lypinator | 0:bb348c97df44 | 132 | * |
lypinator | 0:bb348c97df44 | 133 | * @ingroup types |
lypinator | 0:bb348c97df44 | 134 | */ |
lypinator | 0:bb348c97df44 | 135 | typedef enum wm_tsetting_e { |
lypinator | 0:bb348c97df44 | 136 | cbTARGET_TSETTING_START = 1000, |
lypinator | 0:bb348c97df44 | 137 | cbTARGET_TSETTING_PS_LISTEN_INTERVAL = cbTARGET_TSETTING_START, /**< Powersave: Listen interval in beacons. */ |
lypinator | 0:bb348c97df44 | 138 | cbTARGET_TSETTING_PS_FAST_PSP_TIMEOUT, /**< Powersave: In mode Fast PSP timeout in ms before entering PS. */ |
lypinator | 0:bb348c97df44 | 139 | cbTARGET_TSETTING_ANTENNA_RECEIVE_DIVERSITY, /**< Enable receive antenna diversity. 0 = off, 1 = on. */ |
lypinator | 0:bb348c97df44 | 140 | cbTARGET_TSETTING_QOS_WMM_NOACK, /**< Enable WMM QoS no-ack acknowledgment policy. 0 = normal ack, 1 = no-ack. */ |
lypinator | 0:bb348c97df44 | 141 | cbTARGET_TSETTING_PS_BEACON_EARLY_TERMINATION, /**< Powersave: In Max PSP, use beacon early termination. */ |
lypinator | 0:bb348c97df44 | 142 | cbTARGET_TSETTING_MAX, |
lypinator | 0:bb348c97df44 | 143 | } cbWM_TSETTING; |
lypinator | 0:bb348c97df44 | 144 | |
lypinator | 0:bb348c97df44 | 145 | #define cbTARGET_TSETTING_REG(X) ((cb_uint32)((X) - cbTARGET_TSETTING_START)) |
lypinator | 0:bb348c97df44 | 146 | |
lypinator | 0:bb348c97df44 | 147 | /** |
lypinator | 0:bb348c97df44 | 148 | * Defines the type of scanning procedure. |
lypinator | 0:bb348c97df44 | 149 | * Passive scan will only listen for beacons. |
lypinator | 0:bb348c97df44 | 150 | * Active scan will send out a probe request |
lypinator | 0:bb348c97df44 | 151 | * and listen for both probe responses and beacons. |
lypinator | 0:bb348c97df44 | 152 | * |
lypinator | 0:bb348c97df44 | 153 | * @ingroup types |
lypinator | 0:bb348c97df44 | 154 | */ |
lypinator | 0:bb348c97df44 | 155 | typedef enum cbWM_ScanType_e { |
lypinator | 0:bb348c97df44 | 156 | cbWM_SCAN_INVALID, |
lypinator | 0:bb348c97df44 | 157 | cbWM_SCAN_ACTIVE, |
lypinator | 0:bb348c97df44 | 158 | cbWM_SCAN_PASSIVE, |
lypinator | 0:bb348c97df44 | 159 | } cbWM_ScanType; |
lypinator | 0:bb348c97df44 | 160 | |
lypinator | 0:bb348c97df44 | 161 | /** |
lypinator | 0:bb348c97df44 | 162 | * Power save levels. |
lypinator | 0:bb348c97df44 | 163 | * @note Levels between 2 and cbWM_POWERSAVE_MAX are target specific. |
lypinator | 0:bb348c97df44 | 164 | * |
lypinator | 0:bb348c97df44 | 165 | * @ingroup types |
lypinator | 0:bb348c97df44 | 166 | */ |
lypinator | 0:bb348c97df44 | 167 | typedef enum cbWM_PowerSaveType_e { |
lypinator | 0:bb348c97df44 | 168 | cbWM_POWERSAVE_OFF = 0, |
lypinator | 0:bb348c97df44 | 169 | cbWM_POWERSAVE_FAST_PSP = 1, |
lypinator | 0:bb348c97df44 | 170 | cbWM_POWERSAVE_MAX_PSP = 2, |
lypinator | 0:bb348c97df44 | 171 | cbWM_POWERSAVE_MAX = cb_UINT8_MAX, |
lypinator | 0:bb348c97df44 | 172 | } cbWM_PowerSaveType; |
lypinator | 0:bb348c97df44 | 173 | |
lypinator | 0:bb348c97df44 | 174 | /** |
lypinator | 0:bb348c97df44 | 175 | * Power save modes set using @ref cbWLAN_ioctl |
lypinator | 0:bb348c97df44 | 176 | * |
lypinator | 0:bb348c97df44 | 177 | * @ingroup wlan |
lypinator | 0:bb348c97df44 | 178 | */ |
lypinator | 0:bb348c97df44 | 179 | typedef enum { |
lypinator | 0:bb348c97df44 | 180 | cbTARGET_POWER_SAVE_MODE_OFF, |
lypinator | 0:bb348c97df44 | 181 | cbTARGET_POWER_SAVE_MODE_SLEEP, |
lypinator | 0:bb348c97df44 | 182 | cbTARGET_POWER_SAVE_MODE_DEEP_SLEEP |
lypinator | 0:bb348c97df44 | 183 | } cbTARGET_PowerSaveMode; |
lypinator | 0:bb348c97df44 | 184 | |
lypinator | 0:bb348c97df44 | 185 | typedef enum { |
lypinator | 0:bb348c97df44 | 186 | cbWLAN_ONE_ANTENNA = 1, |
lypinator | 0:bb348c97df44 | 187 | cbWLAN_TWO_ANTENNAS |
lypinator | 0:bb348c97df44 | 188 | } cbWLAN_NUMBER_OF_ANTENNAS; |
lypinator | 0:bb348c97df44 | 189 | |
lypinator | 0:bb348c97df44 | 190 | typedef enum { |
lypinator | 0:bb348c97df44 | 191 | cbWLAN_PRIMARY_ANTENNA_ONE = 1, |
lypinator | 0:bb348c97df44 | 192 | cbWLAN_PRIMARY_ANTENNA_TWO |
lypinator | 0:bb348c97df44 | 193 | } cbWLAN_PRIMARY_ANTENNA; |
lypinator | 0:bb348c97df44 | 194 | /*=========================================================================== |
lypinator | 0:bb348c97df44 | 195 | * FUNCTIONS |
lypinator | 0:bb348c97df44 | 196 | *=========================================================================*/ |
lypinator | 0:bb348c97df44 | 197 | |
lypinator | 0:bb348c97df44 | 198 | /** |
lypinator | 0:bb348c97df44 | 199 | * Get general tuning parameter. |
lypinator | 0:bb348c97df44 | 200 | * |
lypinator | 0:bb348c97df44 | 201 | * @param hTarget Handle to the current driver instance. |
lypinator | 0:bb348c97df44 | 202 | * @param setting setting to read. |
lypinator | 0:bb348c97df44 | 203 | * @return parameter value |
lypinator | 0:bb348c97df44 | 204 | */ |
lypinator | 0:bb348c97df44 | 205 | cb_uint32 cbTARGET_gGet(cbTARGET_Handle* hTarget, cbWM_GSETTING setting); |
lypinator | 0:bb348c97df44 | 206 | |
lypinator | 0:bb348c97df44 | 207 | /** |
lypinator | 0:bb348c97df44 | 208 | * Set general tuning parameter. |
lypinator | 0:bb348c97df44 | 209 | * |
lypinator | 0:bb348c97df44 | 210 | * @param hTarget Handle to the current driver instance. |
lypinator | 0:bb348c97df44 | 211 | * @param setting setting to modify. |
lypinator | 0:bb348c97df44 | 212 | * @param value value to set. |
lypinator | 0:bb348c97df44 | 213 | */ |
lypinator | 0:bb348c97df44 | 214 | void cbTARGET_gSet(cbTARGET_Handle* hTarget, cbWM_GSETTING setting, cb_uint32 value); |
lypinator | 0:bb348c97df44 | 215 | |
lypinator | 0:bb348c97df44 | 216 | /** |
lypinator | 0:bb348c97df44 | 217 | * Get target specific tuning parameter. |
lypinator | 0:bb348c97df44 | 218 | * |
lypinator | 0:bb348c97df44 | 219 | * @param hTarget Handle to the current driver instance. |
lypinator | 0:bb348c97df44 | 220 | * @param setting setting to read. |
lypinator | 0:bb348c97df44 | 221 | * @return parameter value |
lypinator | 0:bb348c97df44 | 222 | */ |
lypinator | 0:bb348c97df44 | 223 | cb_uint32 cbTARGET_tGet(cbTARGET_Handle* hTarget, cbWM_TSETTING setting); |
lypinator | 0:bb348c97df44 | 224 | |
lypinator | 0:bb348c97df44 | 225 | /** |
lypinator | 0:bb348c97df44 | 226 | * Set target specific tuning parameter. |
lypinator | 0:bb348c97df44 | 227 | * |
lypinator | 0:bb348c97df44 | 228 | * @param hTarget Handle to the current driver instance. |
lypinator | 0:bb348c97df44 | 229 | * @param setting setting to modify. |
lypinator | 0:bb348c97df44 | 230 | * @param value value to set. |
lypinator | 0:bb348c97df44 | 231 | */ |
lypinator | 0:bb348c97df44 | 232 | void cbTARGET_tSet(cbTARGET_Handle* hTarget, cbWM_TSETTING setting, cb_uint32 value); |
lypinator | 0:bb348c97df44 | 233 | |
lypinator | 0:bb348c97df44 | 234 | struct cb_wlan_configuration* cbTARGET_configuration_create(); |
lypinator | 0:bb348c97df44 | 235 | |
lypinator | 0:bb348c97df44 | 236 | cbRTSL_Status cbTARGET_configure(cbTARGET_Handle* hTarget, cbTARGET_ConfigParams parameter, void* value); |
lypinator | 0:bb348c97df44 | 237 | |
lypinator | 0:bb348c97df44 | 238 | /*-------------------------------------------------------------------------- |
lypinator | 0:bb348c97df44 | 239 | * Constants |
lypinator | 0:bb348c97df44 | 240 | *-------------------------------------------------------------------------*/ |
lypinator | 0:bb348c97df44 | 241 | |
lypinator | 0:bb348c97df44 | 242 | #define W_CONST_PREAMBLE (1) |
lypinator | 0:bb348c97df44 | 243 | #define W_CONST_LISTEN_INTERVAL (16) |
lypinator | 0:bb348c97df44 | 244 | #define W_CONST_MIN_SCAN_TIME (25) |
lypinator | 0:bb348c97df44 | 245 | #define W_CONST_MAX_SCAN_TIME (50) |
lypinator | 0:bb348c97df44 | 246 | #define W_CONST_SCAN_TYPE (cbWM_SCAN_ACTIVE) |
lypinator | 0:bb348c97df44 | 247 | #define W_CONST_BEACON_INTERVAL (100) |
lypinator | 0:bb348c97df44 | 248 | #define W_CONST_JOIN_FAILURE_TIMEOUT (600) |
lypinator | 0:bb348c97df44 | 249 | #define W_CONST_WLAN_BT_COEX (0) |
lypinator | 0:bb348c97df44 | 250 | #define W_CONST_DATA_RATE (cbWLAN_RATE_24) |
lypinator | 0:bb348c97df44 | 251 | #define W_CONST_LINK_ADAPTION (1) |
lypinator | 0:bb348c97df44 | 252 | #define W_CONST_POWER_SAVE (2) |
lypinator | 0:bb348c97df44 | 253 | #define W_CONST_DTIM_ENABLE (1) |
lypinator | 0:bb348c97df44 | 254 | #define W_CONST_QOS_ENABLE (1) |
lypinator | 0:bb348c97df44 | 255 | #define W_CONST_CHANNEL_TYPE (1) //HT20MHz |
lypinator | 0:bb348c97df44 | 256 | #define W_CONST_RTS_THRESHOLD (2347) |
lypinator | 0:bb348c97df44 | 257 | #define W_CONST_FRAGMENTATION_THRESHOLD (2346) |
lypinator | 0:bb348c97df44 | 258 | #define W_CONST_TX_POWER (15) |
lypinator | 0:bb348c97df44 | 259 | #define W_CONST_MAX_PASSIVE_SCAN_TIME (150) |
lypinator | 0:bb348c97df44 | 260 | #define W_CONST_SCAN_LISTEN_INTERVAL (150) |
lypinator | 0:bb348c97df44 | 261 | #define W_CONST_SLEEP_TIMEOUT (100) // Timeout in ms, 100ms timeout gives almost same throughput as without power save but still low power consumption |
lypinator | 0:bb348c97df44 | 262 | #define W_CONST_DEFAULT_MODULE_TYPE (cbWM_MODULE_UNKNOWN) |
lypinator | 0:bb348c97df44 | 263 | #define W_CONST_PMF_OPTIONAL (cbWLAN_PMF_OPTIONAL) |
lypinator | 0:bb348c97df44 | 264 | #define W_CONST_REMAIN_ON_CHANNEL (1) // Enabled |
lypinator | 0:bb348c97df44 | 265 | #define W_CONST_DEFAULT_STA_TX_RATES (0) // Use AP default |
lypinator | 0:bb348c97df44 | 266 | #define W_CONST_GOOD_RSSI (55) |
lypinator | 0:bb348c97df44 | 267 | #define W_CONST_BAD_RSSI (70) |
lypinator | 0:bb348c97df44 | 268 | #define W_CONST_GOOD_RSSI_SCAN_YIELD_TIMEOUT (1500) |
lypinator | 0:bb348c97df44 | 269 | #define W_CONST_BAD_RSSI_SCAN_YIELD_TIMEOUT (W_CONST_SCAN_LISTEN_INTERVAL) |
lypinator | 0:bb348c97df44 | 270 | #define W_CONST_BLACKLIST_LAST_BSSID_TIMEOUT (20) // Seconds |
lypinator | 0:bb348c97df44 | 271 | #define W_CONST_ROAMING_AREA_HYSTERESIS (3) |
lypinator | 0:bb348c97df44 | 272 | #define W_CONST_TX_PACKET_ACK_TIMEOUT (10000) |
lypinator | 0:bb348c97df44 | 273 | #define W_CONST_FT_MODE (2) |
lypinator | 0:bb348c97df44 | 274 | |
lypinator | 0:bb348c97df44 | 275 | #define W_CONST_DEFAULT_FORCE_WORLD_MODE (0) |
lypinator | 0:bb348c97df44 | 276 | |
lypinator | 0:bb348c97df44 | 277 | #define W_CONST_DEFAULT_AP_STA_INACTIVITY_TIMEOUT (120) |
lypinator | 0:bb348c97df44 | 278 | |
lypinator | 0:bb348c97df44 | 279 | |
lypinator | 0:bb348c97df44 | 280 | #define W_CONST_DEFAULT_DOT11_SHORT_RETRY_LIMIT (0x0a0a0a0aul) |
lypinator | 0:bb348c97df44 | 281 | #define W_CONST_DEFAULT_DOT11_LONG_RETRY_LIMIT (0x0a0a0a0aul) |
lypinator | 0:bb348c97df44 | 282 | #define W_CONST_DEFAULT_AP_DOT11_SHORT_RETRY_LIMIT (0x0a0a0a0aul) |
lypinator | 0:bb348c97df44 | 283 | #define W_CONST_DEFAULT_AP_DOT11_LONG_RETRY_LIMIT (0x0a0a0a0aul) |
lypinator | 0:bb348c97df44 | 284 | |
lypinator | 0:bb348c97df44 | 285 | //Target specific values |
lypinator | 0:bb348c97df44 | 286 | #define W_CONST_PS_LISTEN_INTERVAL (0) |
lypinator | 0:bb348c97df44 | 287 | #define W_CONST_PS_FAST_PSP_TIMEOUT (50) |
lypinator | 0:bb348c97df44 | 288 | #define W_CONST_ANTENNA_RECEIVE_DIVERSITY (0) |
lypinator | 0:bb348c97df44 | 289 | #define W_CONST_PS_BEACON_EARLY_TERMINATION (0) |
lypinator | 0:bb348c97df44 | 290 | |
lypinator | 0:bb348c97df44 | 291 | #define W_CONST_2_4GHZ_MGMT_RATE (cbWLAN_RATE_01) |
lypinator | 0:bb348c97df44 | 292 | #define W_CONST_5GHZ_MGMT_RATE (cbWLAN_RATE_06) |
lypinator | 0:bb348c97df44 | 293 | |
lypinator | 0:bb348c97df44 | 294 | #define W_CONST_DEFAULT_RSSI (-100) |
lypinator | 0:bb348c97df44 | 295 | |
lypinator | 0:bb348c97df44 | 296 | #ifdef __cplusplus |
lypinator | 0:bb348c97df44 | 297 | } |
lypinator | 0:bb348c97df44 | 298 | #endif |
lypinator | 0:bb348c97df44 | 299 | |
lypinator | 0:bb348c97df44 | 300 | #endif /* _CB_SYSTEM_H_ */ |