wicontrol - configure WaveLAN/IEEE devices
wicontrol [interface] [-olL] [-e 0|1] [-k key [-v 1|2|3|4]]
[-t tx rate] [-n network name] [-s station name]
[-q SSID] [-p port type] [-a access point density]
[-m MAC address] [-d max data length] [-r RTS
[-f frequency] [-A 1|2|3] [-D 0|1|2] [-E 0|1|2|3]
[-M 0|1] [-P 0|1] [-R 1|3] [-S max sleep duration]
The wicontrol command controls the operation of WaveLAN/IEEE
networking devices via the wi(4) and awi(4) drivers. Most
of the parameters
that can be changed relate to the IEEE 802.11 protocol
WaveLAN implements. This includes the station name, whether
is operating in ad-hoc (point to point) or BSS (service set)
the network name of a service set to join (IBSS) if BSS mode
The wicontrol command can also be used to view the current
these parameters and to dump out the values of the card's
The interface argument given to wicontrol should be the logical interface
name associated with the WaveLAN/IEEE device (wi0, wi1,
etc...). If none
is given, wi0 is assumed.
The wicontrol command given without any additional flags retrieves the
current card settings from the driver and prints them out.
The options are as follows:
-o Display the statistics counters for the specified
interface. The statistics are updated about once a
-l [Prism2 only] List associated stations if the card
is in Host AP
-L List all available access points. Only the superuser may use
-e 0|1 Enable or disable WEP encryption. Permitted values
are 0 (encryption
disabled) or 1 (encryption enabled). Encryption is off
-k key [ -v 1|2|3|4 ]
Set WEP encryption keys. There are four default encryption keys
that can be programmed. A specific key can be set
using the -v
flag. If the -v flag is not specified, the first
key will be
set. Encryption keys can either be normal text
or a series of hexadecimal digits (i.e.,
WaveLAN Silver cards, the key is restricted to 40
bits, hence the
key can be either a 5-character text string or 10
digits. For WaveLAN Gold cards, the key can be up
to 104 bits,
which means the key can be specified as either a
text string or 26 hexadecimal digits. Either way,
the key will
be concatenated with a 24-bit IV to generate the
seed for RC4.
Note that wicontrol has no way to determine whether
or not a card
is capable of using 104 bit WEP. Some cards accept
a 104 bit key
even though they only support 40 bit keys, in which
case WEP encryption
will simply fail to work.
Specify which of the four WEP encryption keys will
be used to encrypt
-x 0|1 [Prism2/Symbol only] Select between firmware-based
(0) and software-based
(1) WEP. Firmware-based WEP is the default.
-t tx rate
Set the transmit rate of the specified interface.
The legal values
for the transmit rate vary depending on the
The standard WaveLAN/IEEE NICs support a maximum
transmit rate of
2Mbps, and the `Turbo' NICs support a maximum speed
The WaveLAN/IEEE `Turbo 11Mb', Prism-II and
Prism-2.5 NICs support
a maximum speed of 11Mbps. The following table
legal transmit rate settings and the corresponding
TX rate NIC speed
1 Fixed Low (1Mbps)
2 Fixed Standard (2Mbps)
3 Auto Rate Select (High)
4 Fixed Medium (4Mbps)
5 Fixed High (5.5Mbps)
6 Auto Rate Select (Standard)
7 Auto Rate Select (Medium)
11 Fixed Turbo (11Mbps)
The standard NICs support only settings 1 through 3.
support all the above listed speed settings. The
setting is 3 (auto rate select).
-n network name
Set the name of the service set (BSS or IBSS) or adhoc network
that this station wishes to join. The network name
can be any
text string up to 30 characters in length. The default name is
the empty string which should allow the station to
connect to the
first available access point.
-s station name
Sets the station name for the specified interface.
name is used for diagnostic purposes. The Lucent
software can poll the names of remote hosts.
-c 0|1 Allow the station to create a service set (IBSS).
are 0 (do not create IBSS) and 1 (enable creation of IBSS).
The default is 0.
Note: Symbol cards and older Lucent/Prism firmware
not support the creation of a service set.
Specify the name (SSID) of an IBSS to create on a
The SSID can be any text string up to 32
If the card is in IBSS creation or hostap mode, the
IBSS name is
automatically set to be the same as the network
-p port type
Set the port type for a specified interface. The
for port type are 1 (BSS mode), 3 (ad-hoc mode), 4
and 6 (hostap mode). The symbolic values ``bss'',
``ibss'', and ``hostap'' may also be used. The
hostap mode is
only available on Prism-II and Prism-2.5-based NICs.
for an explanation of the various port types.
Specify the access point density for a given interface. Legal
values are 1 (low), 2 (medium) and 3 (high). This
some of the radio modem threshold settings.
-m MAC address
Set the station address for the specified interface.
address is specified as a series of six hexadecimal
by colons, e.g.: 00:60:1d:12:34:56. This programs the new
address into the card and updates the interface as
Set the maximum receive and transmit frame size for
interface. The max data length can be any number
from 350 to
2304. The default is 2304.
-r RTS threshold
Set the RTS/CTS threshold for a given interface.
the number of bytes used for the RTS/CTS handshake
RTS threshold can be any value between 0 and 2047.
Set the radio frequency of a given interface. The
should be specified as a channel ID as shown in the
The list of available frequencies is dependent on
specified by regional authorities. Recognized
authorities include the FCC (United States), ETSI
France and Japan. Frequencies in the table are
specified in MHz.
Channel FCC ETSI France Japan
1 2412 2412 - 2412
2 2417 2417 - 2417
3 2422* 2422* - 2422
4 2427 2427 - 2427
5 2432 2432 - 2432
6 2437 2437 - 2437
7 2442 2442 - 2442
8 2447 2447 - 2447
9 2452 2452 - 2452
10 2457* 2457 2457 2457
11 2462* 2462 2462* 2462
12 - 2467 2467 2467
13 - 2472 2472 2472
14 - - - 2484*
If an illegal channel is specified, the NIC will revert to its
default channel, normally one of those indicated
above with a *.
Note that two stations must be set to the same channel in order
to communicate. Note also that the channels do
bandwidth required for each channel is about 20MHz.
multiple channels in close proximity it is suggested
be separated by at least 25MHz. In the US,
this means that
only channels 1, 6, and 11 may be used simultaneously without interference.
[Prism2/Symbol only] Sets the authentication type
for a given interface.
Permitted values are 1 (Open System Authentication), 2
(Shared Key Authentication) and 3 (104-bit Shared
The 104-bit Shared Key Authentication mode
is only available
on Symbol cards.
When Open System Authentication is used, any station
with an access point. In effect, no authentication is done.
Note, however, that if WEP is enabled on the access
will be able to associate with the access
point but will be
unable to send and receive data packets unless they
have the correct
With Shared Key Authentication, on the other hand,
that have the same WEP key as the access point may
The default is 1 (Open System Authentication).
Note: It is not valid to enable Shared Key Authentication when no
valid WEP keys have been defined.
[Symbol only] Select the antenna diversity. Symbol
both a primary and auxiliary antenna. Either antenna may be used
or the card can choose the antenna with the best reception.
The default is 0 (Autoselect).
[Prism only] Sets the enhanced security mode. A
value of 0 disables
enhanced security mode. A value of 1 hides
the SSID name
in beacon frames (defeats passive AP scanning). A
value of 2
prevents responses to probe packets with an unspecified SSID. A
value of 3 enables both enhanced security modes.
This option is
only available on Prism cards with station firmware
>= 1.6.3 and
is really only useful in HostAP mode. The default
-F 0|1 [Prism2 only] Enable or disable processing of
When enabled, the wi(4) driver will process entire
of stripping off the 802.11b header that is provided
by the card.
Only the superuser may use this option.
-M 0|1 Enable or disable ``microwave oven robustness'' on a
When enabled, smaller packets are used to reduce the impact
of consumer microwave ovens that operate in the
range. This option may also be useful when
2.4Ghz cordless telephones in the area. Only works
in BSS mode
and requires access point support. Requires Lucent
-P 0|1 Enable or disable power management on a given interface. Enabling
power management uses an alternating
to help conserve power on mobile stations, at the
cost of some
increased receive latency. Power management is off
Note that power management requires the cooperation
of an access
point in order to function; it is not functional in
Also, power management is only implemented in Lucent
firmware version 2.03 or later, and in WaveLAN PCMCIA adapter
firmware 2.00 or later. Older revisions will
silently ignore the
power management setting. Legal values for this parameter are 0
(off) and 1 (on).
-R 1|3 Enable or disable roaming function on a given interface. The legal
values are 1 (Roaming handled by firmware) and 3
Disabled). The default is 1. This option is not
-S max sleep interval
Specify the sleep interval to use when power management is enabled.
The max sleep interval is specified in milliseconds. The
default is 100.
Explanation of port types [Toc] [Back]
There are five modes the NIC can operate in:
Also known as infrastructure mode, this is
used when associating
with an access point, through which
passes. If no service set is specified via
the -n flag,
the NIC will associate with whichever access
point has the
strongest signal. In general, it is a good
idea to specify
a service set to prevent possible hijacking of
More accurately known as ``ad-hoc demo mode''.
does not require an access point; the NIC communicates with
other ad-hoc stations within range on a peerto-peer basis.
This mode is not specified by the IEEE 802.11
there may be problems interoperating with NICs
by different vendors.
Also known as IEEE ad-hoc mode or peer-to-peer
is the standardized method of operating without an access
point. Stations associate with a service set
created by an
IBSS master (see below). However, actual connections between
stations are peer-to-peer as in ad-hoc
firmware version 6.06 or higher, Prism2
firmware 0.8.0 or
higher, or Symbol firmware version 2.0.0 or
higher is required
for IBSS mode.
Also know as Host IBSS mode. In this mode,
takes on part of the role of an access point,
does not pass through it to reach the other stations.
When a group of stations are operating in IBSS
mode, one of
them must be the master, specifying the network name of the
service set. Symbol cards do not support operating as an
In this mode, which is only available on
Prism2 cards, the
NIC acts as an access point (base station).
such as beaconing and frame acknowledgement,
automatically by the card firmware. Authentication and
general management of the associated stations,
performed by the wi(4) driver itself. Note
that there are
bugs in Host AP mode in Prism firmware revisions prior to
an(4), awi(4), wi(4), hostname.if(5), ancontrol(8), ifconfig(8)
The wicontrol command first appeared in OpenBSD 2.6.
The wicontrol command was written by Bill Paul
OpenBSD 3.6 June 7, 2001
[ Back ]