# Connecting to wireless



## zjames (Sep 4, 2010)

I have just installed FreeBSD 8.1, and am currently unable to connect to wireless.  I have an intel wireless card.

my /boot/loader.conf file looks like this

```
wlan_wep_load="YES
wlan_tkip_load="YES"
wlan_ccmp_load="YES"
if_intel_load="YES"
```

my /etc/rc.conf contains the following:

```
wlans_intel0="wlan0"
ifconfig_wlan0"=DHCP"
```

my /etc/wpa_supplicant.conf looks like this:

```
network={
ssid="linksys"
key mgmt=NONE
wep_key1=**********
wep_tx_keyidx=1
}
```
when i try the command
[cmd=]ifconfig wlan0 create wlandev intel[/cmd]
I get the following error message:

```
SIOCIFCREATE2 not configured
```

Can anyone help me?


----------



## kpedersen (Sep 4, 2010)

intel do more than one wireless card so there are many different intel drivers

ipw
iwi
iwn
wpi

I cannot recall which one matches which lol.

So try replacing "intel" with each of the above...

Perhaps someone more used to intel cards can be more help.


----------



## wblock@ (Sep 4, 2010)

`# pciconf -lv | grep -B3 network`

to identify which wireless card you have.


----------



## davidgurvich (Sep 4, 2010)

You also need to add 
	
	



```
legal.intel_DRIVERNAME.license_ack=1
```
 in loader.conf.


----------



## zjames (Sep 5, 2010)

I tried all of those drivers that you suggested, and none of them seems to have worked.  This is the output I got from the command 

```
#pciconf -lv | grep -B3 network
```


```
re@pci0:4:0:0: class=8x820000 card=8xff001179 chip=0x013610ec rev=0x01 hdr=0x00

   vendor   = 'Realtek Semiconductor
   device   = 'Realtek 10/100/1000 PCI-E NIC Family all in one NDIS Driver v5.720.0604.2009 06/04/2009 (Rt 10023)
   class    = network
--
wpi0@pci0:5:0:0      class=0x020000 card=0x1041006 chip=0x42228086 rev=0x02 hdr=0x00
   vendor   ='Intel Corporation'
   device   ='Intel 3945ABG Wireless LAN controller (10208086)'
   class    = network
```


----------



## lme@ (Sep 6, 2010)

His posts were auto-moderated, I don't know why...

Your card is already recognized as wpi0, so you don't have to load any further kernel module.
Try this:

```
# echo 'legal.wpi.license_ack=1' >> /boot/loader.conf
# echo 'wlans_wpi0="wlan0"' >> /etc/rc.conf
# echo 'ifconfig_wlan0="WPA DHCP"' >> /etc/rc.conf
# reboot
```

Then you _should_ have a working wireless connection.

BTW: Please don't use WEP "encryption". With net-mgmt/aircrack-ng it's cracked in about one minute...


----------



## zjames (Sep 6, 2010)

I have done the suggested commands, and now 
`#  ifconfig`
has a section in the output for wpi.
I then used the command
`#  ifconfig wpi0 up scan`
and the output was:

```
unable to get scan results
```


----------



## SirDice (Sep 6, 2010)

Handbook: 31.3 Wireless Networking


----------



## Romanrp (Sep 6, 2010)

try replacing 

```
network={
ssid="linksys"
key mgmt=NONE
wep_key1=**********
wep_tx_keyidx=1
}
```
with 
	
	



```
network={
ssid="linksys"
key mgmt=NONE
wep_key0=**********
wep_tx_keyidx=0
}
```
it worked for me


----------



## zjames (Sep 6, 2010)

I have followed several suggestions, from this thread and others, and have now managed to run
`# ifconfig wlan0 create wlandev wpi0`
without any error messages.  I then performed a scan and found my wireless, then used
`# /etc/rc.d/netif start`
There is now a section in the output for wlan0, but the status says:

```
Status: no carrier
```
I used the ping command after this, which revealed that I wasn't connected to the internet.
Does anyone know what to do now?


----------



## lme@ (Sep 8, 2010)

Does `# ifconfig wlan0 up scan` show something?
If that hangs, end it with Ctrl+C and run `% ifconfig wlan0 list scan`


----------



## davidgurvich (Sep 9, 2010)

Are you sure that wpa_supplicant is starting properly?  Try to get the connection manually with wpa_supplicant and dhclient.  If that works then you should be fine.


----------

