# iwn not working Thinkpad T420



## dvogit (Jul 23, 2020)

I just installed FreeBSD 12.1-RELEASE on a T420; during installation it did *not* find any Wi-Fi Networks, even though there were over 10. I do *not* have ethernet.

I did follow the instructions in the Handbook for wireless networking, but I did not have working DHCP.

I first entered the Network Info in `/etc/wpa_supplicant.conf` with no success.

I did the configuration in  `/etc/rc.conf` and it almost worked. But it reported: `psk: bad value` in `dmesg`

Here is the configuration:
`ifconfig_wlan0=“WPA  inet <ip> netmask <netmask> ssid ‘<ssid>’ psk ‘<password>’”`


----------



## aponomarenko (Jul 23, 2020)

Isn't the wireless switch on the right side turned off?


----------



## Mjölnir (Jul 23, 2020)

dvogit said:


> I did the configuration in  `/etc/rc.conf` and it almost worked. But it reported: `psk: bad value` in `dmesg`  Here is the configuration:
> `ifconfig_wlan0=“WPA  inet <ip> netmask <netmask> ssid ‘<ssid>’ psk ‘<password>’”`


That configuration belongs into wpa_supplicant.conf(5)?  In rc.conf(5), you want

```
wlans_iwn0="wlan0"
ifconfig_wlan0="defaultif inet <ip> netmask <netmask>"
create_args_wlan0="WPA regdomain ETSI country DE anywhere roaming manual powersave"
```
(you can omit _defaultif_) and /etc/wpa_supplicant.conf

```
ctrl_interface=/var/run/wpa_supplicant
eapol_version=2
ap_scan=1
fast_reauth=1
country=DE

network={
ssid="xyz"
scan_ssid=1
psk="very_secret_pw"
priority=5
}
```


----------



## Mjölnir (Jul 23, 2020)

I guess /etc/rc.d/netif & companion /etc/network.subr do not understand WLAN special options in a standard ifconfig(8) command line.


----------



## George (Jul 23, 2020)

Is the driver loader? iwn()

WiFi works according to FreeBSD Wiki: Laptops


----------



## dvogit (Jul 23, 2020)

I fixed it, the WiFi did not use PSK. It used EAN for security


----------

