Marcelo Tosatti | 876c9d3 | 2007-02-10 12:25:27 -0200 | [diff] [blame] | 1 | ================================================================================ |
| 2 | README for USB8388 |
| 3 | |
| 4 | (c) Copyright © 2003-2006, Marvell International Ltd. |
| 5 | All Rights Reserved |
| 6 | |
| 7 | This software file (the "File") is distributed by Marvell International |
| 8 | Ltd. under the terms of the GNU General Public License Version 2, June 1991 |
| 9 | (the "License"). You may use, redistribute and/or modify this File in |
| 10 | accordance with the terms and conditions of the License, a copy of which |
| 11 | is available along with the File in the license.txt file or by writing to |
| 12 | the Free Software Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA |
| 13 | 02111-1307 or on the worldwide web at http://www.gnu.org/licenses/gpl.txt. |
| 14 | |
| 15 | THE FILE IS DISTRIBUTED AS-IS, WITHOUT WARRANTY OF ANY KIND, AND THE |
| 16 | IMPLIED WARRANTIES OF MERCHANTABILITY OR FITNESS FOR A PARTICULAR PURPOSE |
| 17 | ARE EXPRESSLY DISCLAIMED. The License provides additional details about |
| 18 | this warranty disclaimer. |
| 19 | ================================================================================ |
| 20 | |
| 21 | ===================== |
| 22 | DRIVER LOADING |
| 23 | ===================== |
| 24 | |
| 25 | o. Copy the firmware image (e.g. usb8388.bin) to /lib/firmware/ |
| 26 | |
| 27 | o. Load driver by using the following command: |
| 28 | |
| 29 | insmod usb8388.ko [fw_name=usb8388.bin] |
| 30 | |
| 31 | ===================== |
| 32 | IWPRIV COMMAND |
| 33 | ===================== |
| 34 | |
| 35 | NAME |
| 36 | This manual describes the usage of private commands used in Marvell WLAN |
| 37 | Linux Driver. All the commands available in Wlanconfig will not be available |
| 38 | in the iwpriv. |
| 39 | |
| 40 | SYNOPSIS |
| 41 | iwpriv <ethX> <command> [sub-command] ... |
| 42 | |
| 43 | iwpriv ethX version |
| 44 | iwpriv ethX scantype [sub-command] |
| 45 | iwpriv ethX getSNR <n> |
| 46 | iwpriv ethX getNF <n> |
| 47 | iwpriv ethX getRSSI <n> |
| 48 | iwpriv ethX setrxant <n> |
| 49 | iwpriv ethX getrxant |
| 50 | iwpriv ethX settxant <n> |
| 51 | iwpriv ethX gettxant |
| 52 | iwpriv ethX authalgs <n> |
| 53 | iwpriv ethX pre-TBTT <n> |
| 54 | iwpriv ethX 8021xauthalgs <n> |
| 55 | iwpriv ethX encryptionmode <n> |
| 56 | iwpriv ethX setregioncode <n> |
| 57 | iwpriv ethX getregioncode |
| 58 | iwpriv ethX setbcnavg <n> |
| 59 | iwpriv ethX getbcnavg |
| 60 | iwpriv ethX setdataavg <n> |
| 61 | iwpriv ethX setlisteninter <n> |
| 62 | iwpriv ethX getlisteninter |
| 63 | iwpriv ethX setmultipledtim <n> |
| 64 | iwpriv ethX getmultipledtim |
| 65 | iwpriv ethX atimwindow <n> |
| 66 | iwpriv ethX deauth |
| 67 | iwpriv ethX adhocstop |
| 68 | iwpriv ethX radioon |
| 69 | iwpriv ethX radiooff |
| 70 | iwpriv ethX reasso-on |
| 71 | iwpriv ethX reasso-off |
| 72 | iwpriv ethX scanmode [sub-command] |
| 73 | iwpriv ethX setwpaie <n> |
| 74 | iwpriv ethX wlanidle-off |
| 75 | iwpriv ethX wlanidle-on |
| 76 | iwpriv ethX getcis |
| 77 | iwpriv ethX getlog |
| 78 | iwpriv ethX getadhocstatus |
| 79 | iwpriv ethX adhocgrate <n> |
| 80 | |
| 81 | Version 4 Command: |
| 82 | iwpriv ethX inactvityto <n> |
| 83 | iwpriv ethX sleeppd <n> |
| 84 | iwpriv ethX enable11d <n> |
| 85 | iwpriv ethX tpccfg <n> |
| 86 | iwpriv ethX powercfg <n> |
| 87 | iwpriv ethX setafc <n> |
| 88 | iwpriv ethX getafc |
| 89 | |
| 90 | Version 5 Command: |
| 91 | iwpriv ethX ledgpio <n> |
| 92 | iwpriv ethX scanprobes <n> |
| 93 | iwpriv ethX lolisteninter <n> |
| 94 | iwpriv ethX rateadapt <n> <m> |
| 95 | iwpriv ethX txcontrol <n> |
| 96 | iwpriv ethX psnullinterval <n> |
| 97 | iwpriv ethX prescan <n> |
| 98 | iwpriv ethX getrxinfo |
| 99 | iwpriv ethX gettxrate |
| 100 | iwpriv ethX beaconinterval |
| 101 | |
| 102 | BT Commands: |
| 103 | The blinding table (BT) contains a list of mac addresses that should be |
| 104 | ignored by the firmware. It is primarily used for debugging and |
| 105 | testing networks. It can be edited and inspected with the following |
| 106 | commands: |
| 107 | |
| 108 | iwpriv ethX bt_reset |
| 109 | iwpriv ethX bt_add <mac_address> |
| 110 | iwpriv ethX bt_del <mac_address> |
| 111 | iwpriv ethX bt_list <id> |
| 112 | |
| 113 | FWT Commands: |
| 114 | The forwarding table (FWT) is a feature used to manage mesh network |
| 115 | routing in the firmware. The FWT is essentially a routing table that |
| 116 | associates a destination mac address (da) with a next hop receiver |
| 117 | address (ra). The FWT can be inspected and edited with the following |
| 118 | iwpriv commands, which are described in greater detail below. |
| 119 | Eventually, the table will be automatically maintained by a custom |
| 120 | routing protocol. |
| 121 | |
| 122 | NOTE: FWT commands replace the previous DFT commands. What were the DFT |
| 123 | commands?, you might ask. They were an earlier API to the firmware that |
| 124 | implemented a simple MAC-layer forwarding mechanism. In the unlikely |
| 125 | event that you were using these commands, you must migrate to the new |
| 126 | FWT commands which can be used to achieve the same functionality. |
| 127 | |
| 128 | iwpriv ethX fwt_add [parameters] |
| 129 | iwpriv ethX fwt_del [parameters] |
| 130 | iwpriv ethX fwt_lookup [parameters] |
| 131 | iwpriv ethX fwt_list [parameters] |
| 132 | iwpriv ethX fwt_list_route [parameters] |
| 133 | iwpriv ethX fwt_list_neigh [parameters] |
| 134 | iwpriv ethX fwt_reset [parameters] |
| 135 | iwpriv ethX fwt_cleanup |
| 136 | iwpriv ethX fwt_time |
| 137 | |
| 138 | MESH Commands: |
| 139 | |
| 140 | The MESH commands are used to configure various features of the mesh |
| 141 | routing protocol. The following commands are supported: |
| 142 | |
| 143 | iwpriv ethX mesh_get_ttl |
| 144 | iwpriv ethX mesh_set_ttl ttl |
| 145 | |
| 146 | DESCRIPTION |
| 147 | Those commands are used to send additional commands to the Marvell WLAN |
| 148 | card via the Linux device driver. |
| 149 | |
| 150 | The ethX parameter specifies the network device that is to be used to |
| 151 | perform this command on. it could be eth0, eth1 etc. |
| 152 | |
| 153 | version |
| 154 | This is used to get the current version of the driver and the firmware. |
| 155 | |
| 156 | scantype |
| 157 | This command is used to set the scan type to be used by the driver in |
| 158 | the scan command. This setting will not be used while performing a scan |
| 159 | for a specific SSID, as it is always done with scan type being active. |
| 160 | |
| 161 | where the sub-commands are: - |
| 162 | active -- to set the scan type to active |
| 163 | passive -- to set the scan type to passive |
| 164 | get -- to get the scan type set in the driver |
| 165 | |
| 166 | getSNR |
| 167 | This command gets the average and non average value of Signal to Noise |
| 168 | Ratio of Beacon and Data. |
| 169 | |
| 170 | where value is:- |
| 171 | 0 -- Beacon non-average. |
| 172 | 1 -- Beacon average. |
| 173 | 2 -- Data non-average. |
| 174 | 3 -- Data average. |
| 175 | |
| 176 | If no value is given, all four values are returned in the order mentioned |
| 177 | above. |
| 178 | |
| 179 | Note: This command is available only when STA is connected. |
| 180 | |
| 181 | getRSSI |
| 182 | This command gets the average and non average value os Receive Signal |
| 183 | Strength of Beacon and Data. |
| 184 | |
| 185 | where value is:- |
| 186 | 0 -- Beacon non-average. |
| 187 | 1 -- Beacon average. |
| 188 | 2 -- Data non-average. |
| 189 | 3 -- Data average. |
| 190 | |
| 191 | Note: This command is available only when STA is connected. |
| 192 | |
| 193 | getNF |
| 194 | This command gets the average and non average value of Noise Floor of |
| 195 | Beacon and Data. |
| 196 | |
| 197 | where value is:- |
| 198 | 0 -- Beacon non-average. |
| 199 | 1 -- Beacon average. |
| 200 | 2 -- Data non-average. |
| 201 | 3 -- Data average. |
| 202 | |
| 203 | Note: This command is available only when STA is connected. |
| 204 | |
| 205 | setrxant |
| 206 | This command is used to set the mode for Rx antenna. |
| 207 | |
| 208 | The options that can be sent are:- |
| 209 | 1 -- Antenna 1. |
| 210 | 2 -- Antenna 2. |
| 211 | 0xFFFF -- Diversity. |
| 212 | |
| 213 | Usage: |
| 214 | iwpriv ethX setrxant 0x01: select Antenna 1. |
| 215 | |
| 216 | getrxant |
| 217 | This command is used to get the mode for Rx antenna. |
| 218 | |
| 219 | |
| 220 | settxant |
| 221 | This command is used to set the mode for Tx antenna. |
| 222 | The options that can be sent are:- |
| 223 | 1 -- Antenna 1. |
| 224 | 2 -- Antenna 2. |
| 225 | 0xFFFF -- Diversity. |
| 226 | Usage: |
| 227 | iwpriv ethX settxant 0x01: select Antenna 1. |
| 228 | |
| 229 | gettxant |
| 230 | This command is used to get the mode for Tx antenna. |
| 231 | |
| 232 | authalgs |
| 233 | This command is used by the WPA supplicant to set the authentication |
| 234 | algorithms in the station. |
| 235 | |
| 236 | 8021xauthalgs |
| 237 | This command is used by the WPA supplicant to set the 8021.x authentication algorithm type |
| 238 | station. |
| 239 | |
| 240 | where values can be:- |
| 241 | 1 -- None |
| 242 | 2 -- LEAP |
| 243 | 4 -- TLS |
| 244 | 8 -- TTLs |
| 245 | 16 -- MD5 |
| 246 | |
| 247 | |
| 248 | encryptionmode |
| 249 | This command is used by the WPA supplicant to set the encryption algorithm. |
| 250 | |
| 251 | where values can be:- |
| 252 | 0 -- NONE |
| 253 | 1 -- WEP40 |
| 254 | 2 -- TKIP |
| 255 | 3 -- CCMP |
| 256 | 4 -- WEP104 |
| 257 | |
| 258 | pre-TBTT |
| 259 | This command is used to set pre-TBTT time period where value is in microseconds. |
| 260 | |
| 261 | setregioncode |
| 262 | This command is used to set the region code in the station. |
| 263 | where value is 'region code' for various regions like |
| 264 | USA FCC, Canada IC, Spain, France, Europe ETSI, Japan ... |
| 265 | |
| 266 | Usage: |
| 267 | iwpriv ethX setregioncode 0x10: set region code to USA (0x10). |
| 268 | |
| 269 | getregioncode |
| 270 | This command is used to get the region code information set in the |
| 271 | station. |
| 272 | |
| 273 | setbcnavg |
| 274 | Set the weighting factor for calculating RSSI. |
| 275 | |
| 276 | getbcnavg |
| 277 | Get weighting factor for calculating RSSI. |
| 278 | |
| 279 | setdataavg |
| 280 | Set the weighting factor for calculating SNR. |
| 281 | |
| 282 | setlisteninter |
| 283 | This command is used to set the listen interval in the |
| 284 | station. |
| 285 | |
| 286 | where the value ranges between 1 - 255 |
| 287 | |
| 288 | getlisteninter |
| 289 | This command is used to get the listen interval value set in the |
| 290 | station. |
| 291 | |
| 292 | setmultipledtim |
| 293 | This command is used to set the multiple dtim value in the |
| 294 | station. |
| 295 | where the value is 1,2,3,4,5,0xfffe |
| 296 | 0xfffe means the firmware will use listen interval in association |
| 297 | command for waking up |
| 298 | |
| 299 | getmultipledtim |
| 300 | This command is used to get the multiple dtim value set in the station. |
| 301 | |
| 302 | atimwindow |
| 303 | This command is used to set the atim value in the |
| 304 | station. |
| 305 | |
| 306 | where the value ranges between 0 - 50 |
| 307 | |
| 308 | deauth |
| 309 | This command is used to send the de-authentication to the AP with which |
| 310 | the station is associated. This command is valid only when |
| 311 | station is in Infrastructure mode. |
| 312 | |
| 313 | Note: This command is available only when STA is connected. |
| 314 | |
| 315 | adhocstop |
| 316 | This command is used to stop beacon transmission from the station and |
| 317 | go into idle state in ad-hoc mode. |
| 318 | |
| 319 | Note: This command is available only when STA is connected. |
| 320 | |
| 321 | radioon |
| 322 | This command is used to turn on the RF antenna. |
| 323 | |
| 324 | radiooff |
| 325 | This command is sued to turn off the RF antenna. |
| 326 | |
| 327 | scanmode |
| 328 | This command is used to set the station to scan for either IBSS |
| 329 | networks or BSS networks or both BSS and IBSS networks. This |
| 330 | command can be used with sub commands, |
| 331 | |
| 332 | where the value for |
| 333 | bss -- Scan All the BSS networks. |
| 334 | ibss -- Scan All the IBSS networks. |
| 335 | any -- Scan both BSS and IBSS networks. |
| 336 | |
| 337 | |
| 338 | |
| 339 | setwpaie |
| 340 | This command is used by WPA supplicant to send the WPA-IE to the driver. |
| 341 | |
| 342 | wlanidle-off |
| 343 | This command is used to get into idle state. |
| 344 | |
| 345 | Note: This command is available only when STA is connected. |
| 346 | |
| 347 | wlanidle-on |
| 348 | This command is used to get off the idle state. |
| 349 | |
| 350 | Note: This command is available only when STA is connected. |
| 351 | |
| 352 | |
| 353 | getlog |
| 354 | This command is used to get the 802.11 statistics available in the |
| 355 | station. |
| 356 | |
| 357 | Note: This command is available only when STA is connected. |
| 358 | |
| 359 | getadhocstatus |
| 360 | This command is used to get the ad-hoc Network Status. |
| 361 | |
| 362 | The various status codes are: |
| 363 | AdhocStarted |
| 364 | AdhocJoined |
| 365 | AdhocIdle |
| 366 | InfraMode |
| 367 | AutoUnknownMode |
| 368 | |
| 369 | Note: This command is available only when STA is connected. |
| 370 | |
| 371 | adhocgrate |
| 372 | This command is used to enable(1) g_rate, Disable(0) g_rate |
| 373 | and request(2) the status which g_rate is disabled/enabled, |
| 374 | for Ad-hoc creator. |
| 375 | |
| 376 | where value is:- |
| 377 | 0 -- Disabled |
| 378 | 1 -- Enabled |
| 379 | 2 -- Get |
| 380 | |
| 381 | ledgpio |
| 382 | This command is used to set/get LEDs. |
| 383 | |
| 384 | iwpriv ethX ledgpio <LEDs> |
| 385 | will set the corresponding LED for the GPIO Line. |
| 386 | |
| 387 | iwpriv ethX ledgpio |
| 388 | will give u which LEDs are Enabled. |
| 389 | |
| 390 | Usage: |
| 391 | iwpriv eth1 ledgpio 1 0 2 1 3 4 |
| 392 | will enable |
| 393 | LED 1 -> GPIO 0 |
| 394 | LED 2 -> GPIO 1 |
| 395 | LED 3 -> GPIO 4 |
| 396 | |
| 397 | iwpriv eth1 ledgpio |
| 398 | shows LED information in the format as mentioned above. |
| 399 | |
| 400 | Note: LED0 is invalid |
| 401 | Note: Maximum Number of LEDs are 16. |
| 402 | |
| 403 | inactivityto |
| 404 | This command is used by the host to set/get the inactivity timeout value, |
| 405 | which specifies when WLAN device is put to sleep. |
| 406 | |
| 407 | Usage: |
| 408 | iwpriv ethX inactivityto [<timeout>] |
| 409 | |
| 410 | where the parameter are: |
| 411 | timeout: timeout value in milliseconds. |
| 412 | |
| 413 | Example: |
| 414 | iwpriv eth1 inactivityto |
| 415 | "get the timeout value" |
| 416 | |
| 417 | iwpriv eth1 inactivityto X |
| 418 | "set timeout value to X ms" |
| 419 | |
| 420 | |
| 421 | sleeppd |
| 422 | This command is used to configure the sleep period of the WLAN device. |
| 423 | |
| 424 | Usage: |
| 425 | iwpriv ethX sleeppd [<sleep period>] |
| 426 | |
| 427 | where the parameter are: |
| 428 | Period: sleep period in milliseconds. Range 10~60. |
| 429 | |
| 430 | Example: |
| 431 | iwpriv eth1 sleeppd 10 |
| 432 | "set period as 10 ms" |
| 433 | iwpriv eth1 sleeppd |
| 434 | "get the sleep period configuration" |
| 435 | |
| 436 | enable11d |
| 437 | This command is used to control 11d |
| 438 | where value is:- |
| 439 | 1 -- Enabled |
| 440 | 0 -- Disabled |
| 441 | 2 -- Get |
| 442 | |
| 443 | |
| 444 | |
| 445 | |
| 446 | tpccfg |
| 447 | Enables or disables automatic transmit power control. |
| 448 | |
| 449 | The first parameter turns this feature on (1) or off (0). When turning |
| 450 | on, the user must also supply four more parameters in the following |
| 451 | order: |
| 452 | -UseSNR (Use SNR (in addition to PER) for TPC algorithm), |
| 453 | -P0 (P0 power level for TPC), |
| 454 | -P1 (P1 power level for TPC), |
| 455 | -P2 (P2 power level for TPC). |
| 456 | |
| 457 | Usage: |
| 458 | iwpriv ethX tpccfg: Get current configuration |
| 459 | iwpriv ethX tpccfg 0: disable auto TPC |
| 460 | iwpriv ethX tpccfg 0x01 0x00 0x05 0x0a 0x0d: enable auto TPC; do not use SNR; |
| 461 | P0=0x05; P1=0x0a; P2=0x0d; |
| 462 | iwpriv ethX tpccfg 0x01 0x01 0x05 0x0a 0x0d: enable auto TPC; use SNR; |
| 463 | P0=0x05; P1=0x0a; P2=0x0d. |
| 464 | |
| 465 | powercfg |
| 466 | Enables or disables power adaptation. |
| 467 | |
| 468 | The first parameter turns this feature on (1) or off (0). When turning |
| 469 | on, the user must also supply three more parameters in the following |
| 470 | order: |
| 471 | -P0 (P0 power level for Power Adaptation), |
| 472 | -P1 (P1 power level for Power Adaptation), |
| 473 | -P2 (P2 power level for Power Adaptation). |
| 474 | |
| 475 | Usage: |
| 476 | iwpriv ethX powercfg: Get current configuration |
| 477 | iwpriv ethX powercfg 0: disable power adaptation |
| 478 | iwpriv ethX powercfg 1 0x0d 0x0f 0x12: enable power adaptation; |
| 479 | P0=0x0d; P1=0x0f; P2=0x12. |
| 480 | |
| 481 | getafc |
| 482 | This command returns automatic frequency control parameters. It returns |
| 483 | three integers: |
| 484 | -P0: automatic is on (1), or off (0), |
| 485 | -P1: current timing offset in PPM (part per million), and |
| 486 | -P2: current frequency offset in PPM. |
| 487 | |
| 488 | setafc |
| 489 | Set automatic frequency control options. |
| 490 | |
| 491 | The first parameter turns automatic on (1) or off (0). |
| 492 | The user must supply two more parameters in either case, in the following |
| 493 | order: |
| 494 | |
| 495 | When auto is on: |
| 496 | |
| 497 | -P0 (automatic adjustment frequency threshold in PPM), |
| 498 | -P1 (automatic adjustment period in beacon period), |
| 499 | |
| 500 | When auto is off: |
| 501 | |
| 502 | -P0 (manual adjustment timing offset in PPM), and |
| 503 | -P1 (manual adjustment frequency offset in PPM). |
| 504 | |
| 505 | Usage: |
| 506 | iwpriv ethX setafc 0 10 10: manual adjustment, both timing and frequcncy |
| 507 | offset are 10 PPM. |
| 508 | |
| 509 | iwpriv ethX setafc 1 10 10 enable afc, automatic adjustment, |
| 510 | frequency threshold 10 PPM, for every 10 beacon periods. |
| 511 | |
| 512 | |
| 513 | |
| 514 | scanprobes |
| 515 | This command sets number of probe requests per channel. |
| 516 | |
| 517 | Usage: |
| 518 | iwpriv ethX scanprobes 3 (set scan probes to 3) |
| 519 | iwpriv ethX scanprobes (get scan probes) |
| 520 | |
| 521 | lolisteninter |
| 522 | This command sets the value of listen interval. |
| 523 | |
| 524 | Usage: |
| 525 | iwpriv ethX lolisteninter 234 (set the lolisteninter to 234) |
| 526 | iwpriv ethX lolisteninter (get the lolisteninter value) |
| 527 | |
| 528 | rateadapt |
| 529 | This command sets the data rates bitmap. |
| 530 | Where <n> |
| 531 | 0: Disable auto rate adapt |
| 532 | 1: Enable auto rate adapt |
| 533 | |
| 534 | <m> |
| 535 | data rate bitmap |
| 536 | Bit Data rate |
| 537 | 0 1 Mbps |
| 538 | 1 2 Mbps |
| 539 | 2 5.5 Mbps |
| 540 | 3 11 Mbps |
| 541 | 4 Reserved |
| 542 | 5 6 Mbps |
| 543 | 6 9 Mbps |
| 544 | 7 12 Mbps |
| 545 | 8 18 Mbps |
| 546 | 9 24 Mbps |
| 547 | 10 36 Mbps |
| 548 | 11 48 Mbps |
| 549 | 12 54 Mbps |
| 550 | 12-15 Reserved |
| 551 | |
| 552 | Usage: |
| 553 | iwpriv ethX rateadapt |
| 554 | read the currect data rate setting |
| 555 | iwpriv ethX rateadapt 1 0x07 |
| 556 | enable auto data rate adapt and |
| 557 | data rates are 1Mbps, 2Mbsp and 5.5Mbps |
| 558 | |
| 559 | |
| 560 | txcontrol |
| 561 | This command is used to set the Tx rate, ack policy, and retry limit on a per packet basis. |
| 562 | |
| 563 | Where value <n> is: |
| 564 | if bit[4] == 1: |
| 565 | bit[3:0] -- 0 1 2 3 4 5 6 7 8 9 10 11 12 13-16 |
| 566 | Data Rate(Mbps) -- 1 2 5.5 11 Rsv 6 9 12 18 24 36 48 54 Rsv |
| 567 | |
| 568 | bit[12:8] |
| 569 | if bit[12] == 1, bit[11:8] specifies the Tx retry limit. |
| 570 | |
| 571 | bit[14:13] specifies per packet ack policy: |
| 572 | bit[14:13] |
| 573 | 1 0 use immediate ack policy for this packet |
| 574 | 1 1 use no ack policy for this packet |
| 575 | 0 x use the per-packet ack policy setting |
| 576 | |
| 577 | Usage: |
| 578 | iwpriv ethX txcontrol 0x7513 |
| 579 | Use no-ack policy, 5 retires for Tx, 11Mbps rate |
| 580 | |
| 581 | |
| 582 | |
| 583 | psnullinterval |
| 584 | This command is used to set/request NULL package interval for Power Save |
| 585 | under infrastructure mode. |
| 586 | |
| 587 | where value is:- |
| 588 | -1 -- Disabled |
| 589 | n>0 -- Set interval as n (seconds) |
| 590 | |
| 591 | prescan |
| 592 | This command is used to enable (1)/disable(0) auto prescan before assoicate to the ap |
| 593 | |
| 594 | where value is:- |
| 595 | 0 -- Disabled |
| 596 | 1 -- Enabled |
| 597 | 2 -- Get |
| 598 | |
| 599 | getrxinfo |
| 600 | This command gets non average value of Signal to Noise Ratio of Data and rate index. |
| 601 | |
| 602 | The following table shows RateIndex and Rate |
| 603 | |
| 604 | RateIndex Data rate |
| 605 | 0 1 Mbps |
| 606 | 1 2 Mbps |
| 607 | 2 5.5 Mbps |
| 608 | 3 11 Mbps |
| 609 | 4 Reserved |
| 610 | 5 6 Mbps |
| 611 | 6 9 Mbps |
| 612 | 7 12 Mbps |
| 613 | 8 18 Mbps |
| 614 | 9 24 Mbps |
| 615 | 10 36 Mbps |
| 616 | 11 48 Mbps |
| 617 | 12 54 Mbps |
| 618 | 13-15 Reserved |
| 619 | |
| 620 | gettxrate |
| 621 | This command gets current Tx rate index of the first packet associated with Rate Adaptation. |
| 622 | |
| 623 | The following table shows RateIndex and Rate |
| 624 | |
| 625 | RateIndex Data rate |
| 626 | 0 1 Mbps |
| 627 | 1 2 Mbps |
| 628 | 2 5.5 Mbps |
| 629 | 3 11 Mbps |
| 630 | 4 Reserved |
| 631 | 5 6 Mbps |
| 632 | 6 9 Mbps |
| 633 | 7 12 Mbps |
| 634 | 8 18 Mbps |
| 635 | 9 24 Mbps |
| 636 | 10 36 Mbps |
| 637 | 11 48 Mbps |
| 638 | 12 54 Mbps |
| 639 | 13-15 Reserved |
| 640 | |
| 641 | bcninterval |
| 642 | This command is used to sets beacon interval in adhoc mode when an argument is given, and gets current adhoc |
| 643 | beacon interval when no argument is given. The valid beacon interval is between 20 - 1000, |
| 644 | default beacon interval is 100. |
| 645 | |
| 646 | Usage: |
| 647 | iwpriv ethX bcninterval 100 (set adhoc beacon interval to 100) |
| 648 | iwpriv ethX bcninterval (get adhoc beacon interval) |
| 649 | |
| 650 | fwt_add |
| 651 | This command is used to insert an entry into the FWT table. The list of |
| 652 | parameters must follow the following structure: |
| 653 | |
| 654 | iwpriv ethX fwt_add da ra [metric dir ssn dsn hopcount ttl expiration sleepmode snr] |
| 655 | |
| 656 | The parameters between brackets are optional, but they must appear in |
| 657 | the order specified. For example, if you want to specify the metric, |
| 658 | you must also specify the dir, ssn, and dsn but you need not specify the |
| 659 | hopcount, expiration, sleepmode, or snr. Any unspecified parameters |
| 660 | will be assigned the defaults specified below. |
| 661 | |
| 662 | The different parameters are:- |
| 663 | da -- DA MAC address in the form 00:11:22:33:44:55 |
| 664 | ra -- RA MAC address in the form 00:11:22:33:44:55 |
| 665 | metric -- route metric (cost: smaller-metric routes are |
| 666 | preferred, default is 0) |
| 667 | dir -- direction (1 for direct, 0 for reverse, |
| 668 | default is 1) |
| 669 | ssn -- Source Sequence Number (time at the RA for |
| 670 | reverse routes. Default is 0) |
| 671 | dsn -- Destination Sequence Number (time at the DA |
| 672 | for direct routes. Default is 0) |
| 673 | hopcount -- hop count (currently unused, default is 0) |
| 674 | ttl -- TTL (Only used in reverse entries) |
| 675 | expiration -- entry expiration (in ticks, where a tick is |
| 676 | 1024us, or ~ 1ms. Use 0 for an indefinite |
| 677 | entry, default is 0) |
| 678 | sleepmode -- RA's sleep mode (currently unused, default is |
| 679 | 0) |
| 680 | snr -- SNR in the link to RA (currently unused, |
| 681 | default is 0) |
| 682 | |
| 683 | The command does not return anything. |
| 684 | |
| 685 | fwt_del |
| 686 | This command is used to remove an entry to the FWT table. The list of |
| 687 | parameters must follow the following structure: |
| 688 | |
| 689 | iwpriv ethX fwt_del da ra [dir] |
| 690 | |
| 691 | where the different parameters are:- |
| 692 | da -- DA MAC address (in the form "00:11:22:33:44:55") |
| 693 | ra -- RA MAC address (in the form "00:11:22:33:44:55") |
| 694 | dir -- direction (1 for direct, 0 for reverse, |
| 695 | default is 1) |
| 696 | |
| 697 | The command does not return anything. |
| 698 | |
| 699 | fwt_lookup |
| 700 | This command is used to get the best route in the FWT table to a given |
| 701 | host. The only parameter is the MAC address of the host that is being |
| 702 | looked for. |
| 703 | |
| 704 | iwpriv ethX fwt_lookup da |
| 705 | |
| 706 | where:- |
| 707 | da -- DA MAC address (in the form "00:11:22:33:44:55") |
| 708 | |
| 709 | The command returns an output string identical to the one returned by |
| 710 | fwt_list described below. |
| 711 | |
| 712 | |
| 713 | fwt_list |
| 714 | This command is used to list a route from the FWT table. The only |
| 715 | parameter is the index into the table. If you want to list all the |
| 716 | routes in a table, start with index=0, and keep listing until you get a |
| 717 | "(null)" string. Note that the indicies may change as the fwt is |
| 718 | updated. It is expected that most users will not use fwt_list directly, |
| 719 | but that a utility similar to the traditional route command will be used |
| 720 | to invoke fwt_list over and over. |
| 721 | |
| 722 | iwpriv ethX fwt_list index |
| 723 | |
| 724 | The output is a string of the following form: |
| 725 | |
| 726 | da ra metric dir ssn dsn hopcount ttl expiration sleepmode snr |
| 727 | |
| 728 | where the different fields are:- |
| 729 | da -- DA MAC address (in the form "00:11:22:33:44:55") |
| 730 | ra -- RA MAC address (in the form "00:11:22:33:44:55") |
| 731 | metric -- route metric (cost: smaller-metric routes are preferred) |
| 732 | dir -- direction (1 for direct, 0 for reverse) |
| 733 | ssn -- Source Sequence Number (time at the RA for reverse routes) |
| 734 | dsn -- Destination Sequence Number (time at the DA for direct routes) |
| 735 | hopcount -- hop count (currently unused) |
| 736 | ttl -- TTL (only used in reverse entries) |
| 737 | expiration -- entry expiration (in ticks, where a tick is 1024us, or ~ 1ms. Use 0 for an indefinite entry) |
| 738 | sleepmode -- RA's sleep mode (currently unused) |
| 739 | snr -- SNR in the link to RA (currently unused) |
| 740 | |
| 741 | fwt_list_route |
| 742 | This command is used to list a route from the FWT table. The only |
| 743 | parameter is the route ID. If you want to list all the routes in a |
| 744 | table, start with rid=0, and keep incrementing rid until you get a |
| 745 | "(null)" string. This function is similar to fwt_list. The only |
| 746 | difference is the output format. Also note that this command is meant |
| 747 | for debugging. It is expected that users will use fwt_lookup and |
| 748 | fwt_list. One important reason for this is that the route id may change |
| 749 | as the route table is altered. |
| 750 | |
| 751 | iwpriv ethX fwt_list_route rid |
| 752 | |
| 753 | The output is a string of the following form: |
| 754 | |
| 755 | da metric dir nid ssn dsn hopcount ttl expiration |
| 756 | |
| 757 | where the different fields are:- |
| 758 | da -- DA MAC address (in the form "00:11:22:33:44:55") |
| 759 | metric -- route metric (cost: smaller-metric routes are preferred) |
| 760 | dir -- direction (1 for direct, 0 for reverse) |
| 761 | nid -- Next-hop (neighbor) host ID (nid) |
| 762 | ssn -- Source Sequence Number (time at the RA for reverse routes) |
| 763 | dsn -- Destination Sequence Number (time at the DA for direct routes) |
| 764 | hopcount -- hop count (currently unused) |
| 765 | ttl -- TTL count (only used in reverse entries) |
| 766 | expiration -- entry expiration (in ticks, where a tick is 1024us, or ~ 1ms. Use 0 for an indefinite entry) |
| 767 | |
| 768 | fwt_list_neigh |
| 769 | This command is used to list a neighbor from the FWT table. The only |
| 770 | parameter is the neighbor ID. If you want to list all the neighbors in a |
| 771 | table, start with nid=0, and keep incrementing nid until you get a |
| 772 | "(null)" string. Note that the nid from a fwt_list_route command can be |
| 773 | used as an input to this command. Also note that this command is meant |
| 774 | mostly for debugging. It is expected that users will use fwt_lookup. |
| 775 | One important reason for this is that the neighbor id may change as the |
| 776 | neighbor table is altered. |
| 777 | |
| 778 | iwpriv ethX fwt_list_neigh nid |
| 779 | |
| 780 | The output is a string of the following form: |
| 781 | |
| 782 | ra sleepmode snr references |
| 783 | |
| 784 | where the different fields are:- |
| 785 | ra -- RA MAC address (in the form "00:11:22:33:44:55") |
| 786 | sleepmode -- RA's sleep mode (currently unused) |
| 787 | snr -- SNR in the link to RA (currently unused) |
| 788 | references -- RA's reference counter |
| 789 | |
| 790 | fwt_reset |
| 791 | This command is used to reset the FWT table, getting rid of all the |
| 792 | entries. There are no input parameters. |
| 793 | |
| 794 | iwpriv ethX fwt_reset |
| 795 | |
| 796 | The command does not return anything. |
| 797 | |
| 798 | fwt_cleanup |
| 799 | This command is used to perform user-based garbage recollection. The |
| 800 | FWT table is checked, and all the entries that are expired or invalid |
| 801 | are cleaned. Note that this is exported to the driver for debugging |
| 802 | purposes, as garbage collection is also fired by the firmware when in |
| 803 | space problems. There are no input parameters. |
| 804 | |
| 805 | iwpriv ethX fwt_cleanup |
| 806 | |
| 807 | The command does returns the number of invalid/expired routes deleted. |
| 808 | |
| 809 | fwt_time |
| 810 | This command returns a card's internal time representation. It is this |
| 811 | time that is used to represent the expiration times of FWT entries. The |
| 812 | number is not consistent from card to card; it is simply a timer count. |
| 813 | The fwt_time command is used to inspect the timer so that expiration |
| 814 | times reported by fwt_list can be properly interpreted. |
| 815 | |
| 816 | iwpriv ethX fwt_time |
| 817 | |
| 818 | mesh_get_ttl |
| 819 | |
| 820 | The mesh ttl is the number of hops a mesh packet can traverse before it |
| 821 | is dropped. This parameter is used to prevent infinite loops in the |
| 822 | mesh network. The value returned by this function is the ttl assigned |
| 823 | to all mesh packets. Currently there is no way to control the ttl on a |
| 824 | per packet or per socket basis. |
| 825 | |
| 826 | iwpriv ethX mesh_get_ttl |
| 827 | |
| 828 | mesh_set_ttl ttl |
| 829 | |
| 830 | Set the ttl. The argument must be between 0 and 255. |
| 831 | |
| 832 | iwpriv ethX mesh_set_ttl <ttl> |
| 833 | |
| 834 | ========================= |
| 835 | ETHTOOL |
| 836 | ========================= |
| 837 | |
| 838 | |
| 839 | Use the -i option to retrieve version information from the driver. |
| 840 | |
| 841 | # ethtool -i eth0 |
| 842 | driver: libertas |
| 843 | version: COMM-USB8388-318.p4 |
| 844 | firmware-version: 5.110.7 |
| 845 | bus-info: |
| 846 | |
| 847 | Use the -e option to read the EEPROM contents of the card. |
| 848 | |
| 849 | Usage: |
| 850 | ethtool -e ethX [raw on|off] [offset N] [length N] |
| 851 | |
| 852 | -e retrieves and prints an EEPROM dump for the specified ethernet |
| 853 | device. When raw is enabled, then it dumps the raw EEPROM data |
| 854 | to stdout. The length and offset parameters allow dumping cer- |
| 855 | tain portions of the EEPROM. Default is to dump the entire EEP- |
| 856 | ROM. |
| 857 | |
| 858 | # ethtool -e eth0 offset 0 length 16 |
| 859 | Offset Values |
| 860 | ------ ------ |
| 861 | 0x0000 38 33 30 58 00 00 34 f4 00 00 10 00 00 c4 17 00 |
| 862 | |
| 863 | ======================== |
| 864 | DEBUGFS COMMANDS |
| 865 | ======================== |
| 866 | |
| 867 | those commands are used via debugfs interface |
| 868 | |
| 869 | =========== |
| 870 | rdmac |
| 871 | rdbbp |
| 872 | rdrf |
| 873 | These commands are used to read the MAC, BBP and RF registers from the |
| 874 | card. These commands take one parameter that specifies the offset |
| 875 | location that is to be read. This parameter must be specified in |
| 876 | hexadecimal (its possible to preceed preceding the number with a "0x"). |
| 877 | |
| 878 | Path: /debugfs/libertas_wireless/ethX/registers/ |
| 879 | |
| 880 | Usage: |
| 881 | echo "0xa123" > rdmac ; cat rdmac |
| 882 | echo "0xa123" > rdbbp ; cat rdbbp |
| 883 | echo "0xa123" > rdrf ; cat rdrf |
| 884 | wrmac |
| 885 | wrbbp |
| 886 | wrrf |
| 887 | These commands are used to write the MAC, BBP and RF registers in the |
| 888 | card. These commands take two parameters that specify the offset |
| 889 | location and the value that is to be written. This parameters must |
| 890 | be specified in hexadecimal (its possible to preceed the number |
| 891 | with a "0x"). |
| 892 | |
| 893 | Usage: |
| 894 | echo "0xa123 0xaa" > wrmac |
| 895 | echo "0xa123 0xaa" > wrbbp |
| 896 | echo "0xa123 0xaa" > wrrf |
| 897 | |
| 898 | sleepparams |
| 899 | This command is used to set the sleepclock configurations |
| 900 | |
| 901 | Path: /debugfs/libertas_wireless/ethX/ |
| 902 | |
| 903 | Usage: |
| 904 | cat sleepparams: reads the current sleepclock configuration |
| 905 | |
| 906 | echo "p1 p2 p3 p4 p5 p6" > sleepparams: writes the sleepclock configuration. |
| 907 | |
| 908 | where: |
| 909 | p1 is Sleep clock error in ppm (0-65535) |
| 910 | p2 is Wakeup offset in usec (0-65535) |
| 911 | p3 is Clock stabilization time in usec (0-65535) |
| 912 | p4 is Control periodic calibration (0-2) |
| 913 | p5 is Control the use of external sleep clock (0-2) |
| 914 | p6 is reserved for debug (0-65535) |
| 915 | |
| 916 | subscribed_events |
| 917 | |
| 918 | The subscribed_events directory contains the interface for the |
| 919 | subscribed events API. |
| 920 | |
| 921 | Path: /debugfs/libertas_wireless/ethX/subscribed_events/ |
| 922 | |
| 923 | Each event is represented by a filename. Each filename consists of the |
| 924 | following three fields: |
| 925 | Value Frequency Subscribed |
| 926 | |
| 927 | To read the current values for a given event, do: |
| 928 | cat event |
| 929 | To set the current values, do: |
| 930 | echo "60 2 1" > event |
| 931 | |
| 932 | Frequency field specifies the reporting frequency for this event. |
| 933 | If it is set to 0, then the event is reported only once, and then |
| 934 | automatically unsubscribed. If it is set to 1, then the event is |
| 935 | reported every time it occurs. If it is set to N, then the event is |
| 936 | reported every Nth time it occurs. |
| 937 | |
| 938 | beacon_missed |
| 939 | Value field specifies the number of consecutive missing beacons which |
| 940 | triggers the LINK_LOSS event. This event is generated only once after |
| 941 | which the firmware resets its state. At initialization, the LINK_LOSS |
| 942 | event is subscribed by default. The default value of MissedBeacons is |
| 943 | 60. |
| 944 | |
| 945 | failure_count |
| 946 | Value field specifies the consecutive failure count threshold which |
| 947 | triggers the generation of the MAX_FAIL event. Once this event is |
| 948 | generated, the consecutive failure count is reset to 0. |
| 949 | At initialization, the MAX_FAIL event is NOT subscribed by |
| 950 | default. |
| 951 | |
| 952 | high_rssi |
| 953 | This event is generated when the average received RSSI in beacons goes |
| 954 | above a threshold, specified by Value. |
| 955 | |
| 956 | low_rssi |
| 957 | This event is generated when the average received RSSI in beacons goes |
| 958 | below a threshold, specified by Value. |
| 959 | |
| 960 | high_snr |
| 961 | This event is generated when the average received SNR in beacons goes |
| 962 | above a threshold, specified by Value. |
| 963 | |
| 964 | low_snr |
| 965 | This event is generated when the average received SNR in beacons goes |
| 966 | below a threshold, specified by Value. |
| 967 | |
| 968 | extscan |
| 969 | This command is used to do a specific scan. |
| 970 | |
| 971 | Path: /debugfs/libertas_wireless/ethX/ |
| 972 | |
| 973 | Usage: echo "SSID" > extscan |
| 974 | |
| 975 | Example: |
| 976 | echo "LINKSYS-AP" > extscan |
| 977 | |
| 978 | To see the results of use getscantable command. |
| 979 | |
| 980 | getscantable |
| 981 | |
| 982 | Display the current contents of the driver scan table (ie. get the |
| 983 | scan results). |
| 984 | |
| 985 | Path: /debugfs/libertas_wireless/ethX/ |
| 986 | |
| 987 | Usage: |
| 988 | cat getscantable |
| 989 | |
| 990 | setuserscan |
| 991 | Initiate a customized scan and retrieve the results |
| 992 | |
| 993 | |
| 994 | Path: /debugfs/libertas_wireless/ethX/ |
| 995 | |
| 996 | Usage: |
| 997 | echo "[ARGS]" > setuserscan |
| 998 | |
| 999 | where [ARGS]: |
| 1000 | |
| 1001 | chan=[chan#][band][mode] where band is [a,b,g] and mode is |
| 1002 | blank for active or 'p' for passive |
| 1003 | bssid=xx:xx:xx:xx:xx:xx specify a BSSID filter for the scan |
| 1004 | ssid="[SSID]" specify a SSID filter for the scan |
| 1005 | keep=[0 or 1] keep the previous scan results (1), discard (0) |
| 1006 | dur=[scan time] time to scan for each channel in milliseconds |
| 1007 | probes=[#] number of probe requests to send on each chan |
| 1008 | type=[1,2,3] BSS type: 1 (Infra), 2(Adhoc), 3(Any) |
| 1009 | |
| 1010 | Any combination of the above arguments can be supplied on the command line. |
| 1011 | If the chan token is absent, a full channel scan will be completed by |
| 1012 | the driver. If the dur or probes tokens are absent, the driver default |
| 1013 | setting will be used. The bssid and ssid fields, if blank, |
| 1014 | will produce an unfiltered scan. The type field will default to 3 (Any) |
| 1015 | and the keep field will default to 0 (Discard). |
| 1016 | |
| 1017 | Examples: |
| 1018 | 1) Perform an active scan on channels 1, 6, and 11 in the 'g' band: |
| 1019 | echo "chan=1g,6g,11g" > setuserscan |
| 1020 | |
| 1021 | 2) Perform a passive scan on channel 11 for 20 ms: |
| 1022 | echo "chan=11gp dur=20" > setuserscan |
| 1023 | |
| 1024 | 3) Perform an active scan on channels 1, 6, and 11; and a passive scan on |
| 1025 | channel 36 in the 'a' band: |
| 1026 | |
| 1027 | echo "chan=1g,6g,11g,36ap" > setuserscan |
| 1028 | |
| 1029 | 4) Perform an active scan on channel 6 and 36 for a specific SSID: |
| 1030 | echo "chan=6g,36a ssid="TestAP"" > setuserscan |
| 1031 | |
| 1032 | 5) Scan all available channels (B/G, A bands) for a specific BSSID, keep |
| 1033 | the current scan table intact, update existing or append new scan data: |
| 1034 | echo "bssid=00:50:43:20:12:82 keep=1" > setuserscan |
| 1035 | |
| 1036 | 6) Scan channel 6, for all infrastructure networks, sending two probe |
| 1037 | requests. Keep the previous scan table intact. Update any duplicate |
| 1038 | BSSID/SSID matches with the new scan data: |
| 1039 | echo "chan=6g type=1 probes=2 keep=1" > setuserscan |
| 1040 | |
| 1041 | All entries in the scan table (not just the new scan data when keep=1) |
| 1042 | will be displayed upon completion by use of the getscantable ioctl. |
| 1043 | |
| 1044 | ============================================================================== |