1.\" $NetBSD: rtw.4,v 1.7 2014/03/18 18:20:39 riastradh Exp $ 2.\" $OpenBSD: rtw.4,v 1.18 2005/06/09 09:03:38 jmc Exp $ 3.\" 4.\" Copyright (c) 2004 Jonathan Gray <jsg@openbsd.org> 5.\" 6.\" Permission to use, copy, modify, and distribute this software for any 7.\" purpose with or without fee is hereby granted, provided that the above 8.\" copyright notice and this permission notice appear in all copies. 9.\" 10.\" THE SOFTWARE IS PROVIDED "AS IS" AND THE AUTHOR DISCLAIMS ALL WARRANTIES 11.\" WITH REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF 12.\" MERCHANTABILITY AND FITNESS. IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR 13.\" ANY SPECIAL, DIRECT, INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES 14.\" WHATSOEVER RESULTING FROM LOSS OF USE, DATA OR PROFITS, WHETHER IN AN 15.\" ACTION OF CONTRACT, NEGLIGENCE OR OTHER TORTIOUS ACTION, ARISING OUT OF 16.\" OR IN CONNECTION WITH THE USE OR PERFORMANCE OF THIS SOFTWARE. 17.\" 18.Dd December 29, 2004 19.Dt RTW 4 20.Os 21.Sh NAME 22.Nm rtw 23.Nd Realtek RTL8180L IEEE 802.11b wireless network driver 24.Sh SYNOPSIS 25.Cd "rtw* at cardbus? function ?" 26.Cd "rtw* at pci? dev ? function ?" 27.Sh DESCRIPTION 28The 29.Nm 30driver supports PCI/CardBus 802.11b wireless adapters based on the 31Realtek RTL8180L. 32.Pp 33A variety of radio transceivers can be found in these devices, including 34the Philips SA2400A, Maxim MAX2820, and GCT GRF5101, though not all of them 35are currently supported. 36.Pp 37These are the modes the 38.Nm 39driver can operate in: 40.Bl -tag -width "IBSS-masterXX" 41.It BSS mode 42Also known as 43.Em infrastructure 44mode, this is used when associating with an access point, through 45which all traffic passes. 46This mode is the default. 47.It IBSS mode 48Also known as 49.Em IEEE ad-hoc 50mode or 51.Em peer-to-peer 52mode. 53This is the standardized method of operating without an access point. 54Stations associate with a service set. 55However, actual connections between stations are peer-to-peer. 56.It Host AP 57In this mode the driver acts as an access point (base station) 58for other cards. 59.It monitor mode 60In this mode the driver is able to receive packets without 61associating with an access point. 62This disables the internal receive filter and enables the card to 63capture packets from networks which it wouldn't normally have access to, 64or to scan for access points. 65.El 66.Pp 67.Nm 68supports software WEP. 69Wired Equivalent Privacy (WEP) is the de facto encryption standard 70for wireless networks. 71It can be typically configured in one of three modes: 72no encryption; 40-bit encryption; or 104-bit encryption. 73Unfortunately, due to serious weaknesses in WEP protocol 74it is strongly recommended that it not be used as the 75sole mechanism to secure wireless communication. 76WEP is not enabled by default. 77.Sh CONFIGURATION 78The 79.Nm 80driver can be configured at runtime with 81.Xr ifconfig 8 82or on boot with 83.Xr ifconfig.if 5 84using the following parameters: 85.Bl -tag -width Ds 86.It Cm bssid Ar bssid 87Set the desired BSSID. 88.It Fl bssid 89Unset the desired BSSID. 90The interface will automatically select a BSSID in this mode, which is 91the default. 92.It Cm chan Ar n 93Set the channel (radio frequency) to be used by the driver based on 94the given channel ID 95.Ar n . 96.It Fl chan 97Unset the desired channel to be used by the driver. 98The driver will automatically select a channel in this mode, which is 99the default. 100.It Cm media Ar media 101The 102.Nm 103driver supports the following 104.Ar media 105types: 106.Pp 107.Bl -tag -width autoselect -compact 108.It Cm autoselect 109Enable autoselection of the media type and options. 110.It Cm DS1 111Set 802.11b DS 1Mbps operation. 112.It Cm DS2 113Set 802.11b DS 2Mbps operation. 114.It Cm DS5 115Set 802.11b DS 5.5Mbps operation. 116.It Cm DS11 117Set 802.11b DS 11Mbps operation. 118.El 119.It Cm mediaopt Ar opts 120The 121.Nm 122driver supports the following media options: 123.Pp 124.Bl -tag -width monitor -compact 125.It Cm hostap 126Select Host AP operation. 127.It Cm ibss 128Select IBSS operation. 129.It Cm monitor 130Select monitor mode. 131.El 132.It Fl mediaopt Ar opts 133Disable the specified media options on the driver and return it to the 134default mode of operation (BSS). 135.It Cm ssid Ar id 136Set the network ID. 137The 138.Ar id 139can either be any text string up to 32 characters in length, 140or a series of hexadecimal digits up to 64 digits. 141An empty 142.Ar id 143string allows the interface to connect to any available access points. 144By default the 145.Nm 146driver uses an empty string. 147Note that network ID is synonymous with Extended Service Set ID (ESSID). 148.It Cm nwkey Ar key 149Enable WEP encryption using the specified 150.Ar key . 151The 152.Ar key 153can either be a string, a series of hexadecimal digits (preceded by 154.Sq 0x ) , 155or a set of keys of the form 156.Dq n:k1,k2,k3,k4 , 157where 158.Sq n 159specifies which of the keys will be used for transmitted packets, 160and the four keys, 161.Dq k1 162through 163.Dq k4 , 164are configured as WEP keys. 165If a set of keys is specified, a comma 166.Pq Sq \&, 167within the key must be escaped with a backslash. 168Note that if multiple keys are used, their order must be the same within 169the network. 170.Nm 171is capable of using both 40-bit (5 characters or 10 hexadecimal digits) 172or 104-bit (13 characters or 26 hexadecimal digits) keys. 173.It Fl nwkey 174Disable WEP encryption. 175This is the default mode of operation. 176.It Cm nwkey persist 177Enable WEP encryption with the persistent key stored in the network card. 178.El 179.Sh HARDWARE 180The following adapters should work: 181.Pp 182.Bl -column "Card " "Bus" -compact -offset 6n 183.It Em "Card Bus" 184.\".It Li "Acer Aspire 1357 LMi" Ta Mini PCI 185.\".It Li "Belkin F5D6001 V3" Ta PCI 186.It Li "Belkin F5D6020 V3" Ta CardBus 187.It Li "Buffalo WLI-CB-B11" Ta CardBus 188.It Li "Corega CG-WLCB11V3" Ta CardBus 189.\".It Li "D-Link DWL-510" Ta PCI 190.\".It Li "D-Link DWL-520 rev D" Ta PCI 191.It Li "D-Link DWL-610" Ta CardBus 192.\".It Li "Encore ENLWI-PCI1-NT" Ta PCI 193.\".It Li "Gigabyte GN-WLMR101" Ta PCI 194.It Li "Level-One WPC-0101" Ta CardBus 195.It Li "Linksys WPC11 v4" Ta CardBus 196.It Li "Netgear MA521" Ta CardBus 197.It Li "Ovislink AirLive WL-1120PCM" Ta CardBus 198.It Li "Planet WL-3553" Ta CardBus 199.It Li "TrendNET TEW-266PC" Ta CardBus 200.\".It Li "TrendNET TEW-288PI" Ta PCI 201.It Li "VCTnet PC-11B1" Ta CardBus 202.El 203.Sh EXAMPLES 204The following 205.Xr ifconfig.if 5 206example creates a host-based access point on boot: 207.Bd -literal -offset indent 208inet 192.168.1.1 255.255.255.0 NONE media autoselect \e 209 mediaopt hostap ssid my_net chan 11 210.Ed 211.Pp 212Configure rtw0 for WEP, using hex key 213.Dq 0x1deadbeef1 : 214.Bd -literal -offset indent 215# ifconfig rtw0 nwkey 0x1deadbeef1 216.Ed 217.Pp 218Return rtw0 to its default settings: 219.Bd -literal -offset indent 220# ifconfig rtw0 -bssid -chan media autoselect \e 221 ssid "" -nwkey 222.Ed 223.Pp 224Join an existing BSS network, 225.Dq my_net : 226.Bd -literal -offset indent 227# ifconfig rtw0 192.168.1.1 netmask 0xffffff00 ssid my_net 228.Ed 229.Sh SEE ALSO 230.Xr arp 4 , 231.Xr cardbus 4 , 232.Xr ifmedia 4 , 233.Xr intro 4 , 234.Xr netintro 4 , 235.Xr pci 4 , 236.Xr ifconfig.if 5 , 237.Xr ifconfig 8 238.Rs 239.%T Realtek 240.%U http://www.realtek.com.tw 241.Re 242.Sh HISTORY 243The 244.Nm 245device driver first appeared in 246.Nx 3.0 247and then in 248.Ox 3.7 . 249.Sh AUTHORS 250.An -nosplit 251The 252.Nm 253driver was written by 254.An David Young 255.Aq dyoung@NetBSD.org 256and ported to 257.Ox 258by 259.An Jonathan Gray Aq Mt jsg@openbsd.org , 260who wrote this man page. 261.Sh BUGS 262Only the Philips SA2400A and Maxim MAX2820 RF transceivers are known to work. 263Devices incorporating a GCT RF transceiver are not supported due to a lack of 264documentation from GCT. 265.Pp 266While PCI devices will attach most of them are not able to transmit. 267