1.\" $NetBSD: wpi.4,v 1.6 2007/07/18 18:51:16 degroote Exp $ 2.\" 3.\" Copyright (c) 2006 4.\" Damien Bergamini <damien.bergamini@free.fr>. All rights reserved. 5.\" 6.\" Redistribution and use in source and binary forms, with or without 7.\" modification, are permitted provided that the following conditions 8.\" are met: 9.\" 1. Redistributions of source code must retain the above copyright 10.\" notice unmodified, this list of conditions, and the following 11.\" disclaimer. 12.\" 2. Redistributions in binary form must reproduce the above copyright 13.\" notice, this list of conditions and the following disclaimer in the 14.\" documentation and/or other materials provided with the distribution. 15.\" 16.\" THIS SOFTWARE IS PROVIDED BY THE AUTHOR AND CONTRIBUTORS ``AS IS'' AND 17.\" ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE 18.\" IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE 19.\" ARE DISCLAIMED. IN NO EVENT SHALL THE AUTHOR OR CONTRIBUTORS BE LIABLE 20.\" FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL 21.\" DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS 22.\" OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) 23.\" HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT 24.\" LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY 25.\" OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF 26.\" SUCH DAMAGE. 27.\" 28.Dd August 13, 2006 29.Os 30.Dt WPI 4 31.Sh NAME 32.Nm wpi 33.Nd Intel PRO/Wireless 3945ABG IEEE 802.11a/b/g wireless network driver 34.Sh SYNOPSIS 35.Cd "wpi* at pci? dev ? function ?" 36.Sh DESCRIPTION 37The 38.Nm 39driver provides support for 40.Tn Intel 41PRO/Wireless 3945ABG Mini PCI Express network adapters. 42.Pp 43These are the modes the 44.Nm 45driver can operate in: 46.Bl -tag -width Ds 47.It BSS mode 48Also known as 49.Em infrastructure 50mode, this is used when associating with an access point, through 51which all traffic passes. 52This mode is the default. 53.It monitor mode 54In this mode the driver is able to receive packets without 55associating with an access point. 56This disables the internal receive filter and enables the card to 57capture packets from networks to which it wouldn't normally have access, 58or to scan for access points. 59.El 60.Pp 61.Nm 62supports software WEP. 63Wired Equivalent Privacy (WEP) is the de facto encryption standard 64for wireless networks. 65It can be typically configured in one of three modes: 66no encryption; 40-bit encryption; or 104-bit encryption. 67Unfortunately, due to serious weaknesses in the WEP protocol 68it is strongly recommended that it not be used as the 69sole mechanism to secure wireless communication. 70WEP is not enabled by default. 71.Sh CONFIGURATION 72The 73.Nm 74driver can be configured at runtime with 75.Xr ifconfig 8 76using the following parameters: 77.Bl -tag -width Ds 78.It Cm bssid Ar bssid 79Set the desired BSSID. 80.It Fl bssid 81Unset the desired BSSID. 82The interface will automatically select a BSSID in this mode, which is 83the default. 84.It Cm chan Ar n 85Set the channel (radio frequency) to be used by the driver based on 86the given channel ID 87.Ar n . 88.It Fl chan 89Unset the desired channel to be used by the driver. 90The driver will automatically select a channel in this mode, which is 91the default. 92.It Cm media Ar media 93The 94.Nm 95driver supports the following 96.Ar media 97types: 98.Pp 99.Bl -tag -width autoselect -compact 100.It Cm autoselect 101Enable autoselection of the media type and options. 102.El 103.It Cm mediaopt Ar opts 104The 105.Nm 106driver supports the following media options: 107.Pp 108.Bl -tag -width monitor -compact 109.It Cm monitor 110Select monitor mode. 111.El 112.It Fl mediaopt Ar opts 113Disable the specified media options on the driver and return it to the 114default mode of operation (BSS). 115.It Cm mode Ar mode 116The 117.Nm 118driver supports the following modes: 119.Pp 120.Bl -tag -width 11b -compact 121.It Cm 11a 122Force 802.11a operation. 123.It Cm 11b 124Force 802.11b operation. 125.It Cm 11g 126Force 802.11g operation. 127.El 128.It Cm nwid Ar id 129Set the network ID. 130The 131.Ar id 132can either be any text string up to 32 characters in length, 133or a series of hexadecimal digits up to 64 digits. 134An empty 135.Ar id 136string allows the interface to connect to any available access points. 137By default the 138.Nm 139driver uses an empty string. 140Note that network ID is synonymous with Extended Service Set ID (ESSID). 141.It Cm nwkey Ar key 142Enable WEP encryption using the specified 143.Ar key . 144The 145.Ar key 146can either be a string, a series of hexadecimal digits (preceded by 147.Sq 0x ) , 148or a set of keys of the form 149.Dq n:k1,k2,k3,k4 , 150where 151.Sq n 152specifies which of the keys will be used for transmitted packets, 153and the four keys, 154.Dq k1 155through 156.Dq k4 , 157are configured as WEP keys. 158If a set of keys is specified, a comma 159.Pq Sq \&, 160within the key must be escaped with a backslash. 161Note that if multiple keys are used, their order must be the same within 162the network. 163.Nm 164is capable of using both 40-bit (5 characters or 10 hexadecimal digits) 165or 104-bit (13 characters or 26 hexadecimal digits) keys. 166.It Fl nwkey 167Disable WEP encryption. 168This is the default mode of operation. 169.El 170.Sh FILES 171The driver needs at least version 2.14.4 of the following firmware file, 172which is loaded when an interface is brought up: 173.Pp 174.Bl -tag -width Ds -offset indent -compact 175.It Pa /usr/pkg/libdata/if_wpi/iwlwifi-3945.ucode 176.El 177.Pp 178This firmware file is not free because Intel refuses to grant 179distribution rights without contractual obligations. 180As a result, even though 181.Nx 182includes the driver, the firmware file cannot be included and 183users have to download this file on their own. 184The official person to state your views to about this issue is 185peter.engelbrecht@intel.com at +1 (858) 391 1857. 186.Pp 187The firmware can be found at 188.Pa http://intellinuxwireless.org/ 189(Microcode), or can be installed using the 190.Pa pkgsrc/sysutils/wpi-firmware2 191package. 192.Sh EXAMPLES 193.Bd -literal -offset indent 194# ifconfig wpi0 nwkey 0x1deadbeef1 195.Ed 196.Pp 197Return wpi0 to its default settings: 198.Bd -literal -offset indent 199# ifconfig wpi0 -bssid -chan media autoselect \e 200 nwid "" -nwkey 201.Ed 202.Pp 203Join an existing BSS network, 204.Dq my_net : 205.Bd -literal -offset indent 206# ifconfig wpi0 192.168.1.1 netmask 0xffffff00 nwid my_net 207.Ed 208.Sh DIAGNOSTICS 209.Bl -diag 210.It "wpi%d: device timeout" 211A frame dispatched to the hardware for transmission did not complete in time. 212The driver will reset the hardware. 213This should not happen. 214.It "wpi%d: fatal firmware error" 215For some reason, the firmware crashed. 216The driver will reset the hardware. 217This should not happen. 218.It "wpi%d: Radio transmitter is off" 219The radio transmitter is off and thus no packet can go out. 220The driver will reset the hardware. 221Make sure the laptop radio switch is on. 222.It "wpi%d: could not read firmware file" 223For some reason, the driver was unable to read the firmware image from the 224filesystem. 225The file might be missing or corrupted. 226.It "wpi%d: firmware file too short: %d bytes" 227The firmware image is corrupted and can't be loaded into the adapter. 228.It "wpi%d: could not load firmware" 229An attempt to load the firmware into the adapter failed. 230The driver will reset the hardware. 231.El 232.Sh NOTES 233802.11a is not working yet. 234.Pp 235On some laptops the radio transmitter button must be pushed twice 236to get the driver working, or you will get a 237.Pa "wpi%d: fatal firmware error" 238when the interface will be set to up 239.Sh SEE ALSO 240.Xr arp 4 , 241.Xr ifmedia 4 , 242.Xr intro 4 , 243.Xr netintro 4 , 244.Xr pci 4 , 245.Xr ifconfig 8 , 246.Xr firmload 9 , 247.Pa pkgsrc/sysutils/wpi-firmware2 248.Rs 249.%T The IPW Web Page 250.%O http://damien.bergamini.free.fr/ipw/ 251.Re 252.Sh AUTHORS 253The 254.Nm 255driver was originally written by 256.An Damien Bergamini Aq damien@openbsd.org . 257.Nx 258porting was done by 259.An Jean-Baptiste Campesato Aq camjelemon@gmail.com . 260