====== I just want my WiFi working! ======
The chapter about [[https://docs.freebsd.org/en/books/handbook/advanced-networking/#network-wireless|wireless networking in the FreeBSD Handbook]] is a wonderful source of information. Sometimes, however, bits go crazy and you simply cannot diagnose a simple networking issue. Don't be afraid to ask the community if you're stuck. System configuration in a console happens to be intimidating to newcomers.
===== Getting started =====
* Read the chapter related to [[https://docs.freebsd.org/en/books/handbook/advanced-networking/#network-wireless|wireless networking]] in the %%FreeBSD%% Handbook. It should be enough to set up a wireless connection on a %%FreeBSD%% machine.
----
===== FAQ =====
----
==== Drivers ====
* It might be a good idea to check out [[/Laptops]]. Maybe someone with a similar machine described how to set up a wireless device.
----
=== ifconfig doesn't show my wireless card ===
You're probably looking for ''%%sysctl -n net.wlan.devices%%''.
Also, make sure you've actually read the wireless networking chapter.
----
=== My wireless card does not show up in sysctl -n net.wlan.devices ===
A driver might be missing. Check out the output of ''%%pciconf -lv%%'' and look for devices with the ''%%network%%'' class.
----
=== I've added the driver-related lines to /boot/loader.conf but it still doesn't work ===
Well, here are a couple of ideas:
* Some drivers require the user to explicitly acknowledge the firmware license. Check out the manual page of the driver you're using for details.
* Remember to load required firmware if needed. Consult your manual.
----
=== Where is the urtwn driver? It is mentioned on many websites ===
It was replaced by [[https://man.freebsd.org/cgi/man.cgi?query=rtwn&sektion=4|rtwn(4)]].
----
=== I've got some problems with the iwm(4) driver ===
* As of 2018.04.25 some people report that [[https://man.freebsd.org/iwm|iwm(4)]] causes a kernel panic when configured via [[https://man.freebsd.org/cgi/man.cgi?loader.conf|loader.conf(5)]].
So, although the manual says to add
if_iwm_load="YES"
iwm3160fw_load="YES"
to [[https://man.freebsd.org/cgi/man.cgi?query=loader.conf&sektion=5|loader.conf(5)]], it is sometimes better to add the following line to [[https://man.freebsd.org/cgi/man.cgi?query=rc.conf&sektion=5|rc.conf(5)]] instead:
kld_list="if_iwm iwm3160fw"
(Of course, this is just an example in which we assume that you need firmware for an Intel Corporation Wireless 3160 card.)
Works for phpdave11 (#freebsd, Freenode, 2018.05.09)
* [[https://man.freebsd.org/iwm|iwm(4)]] devices do not start automatically for some users when system boots so they add the following command to [[https://man.freebsd.org/cgi/man.cgi?crontab|crontab(1)]]:
@reboot ifconfig wlan0 create wlandev iwm0
----
==== wpa_supplicant ====
* [[https://man.freebsd.org/cgi/man.cgi?query=wpa_supplicant.conf&sektion=5|wpa_supplicant.conf(5)]]
* [[https://man.freebsd.org/cgi/man.cgi?query=wpa_supplicant&sektion=8|wpa_supplicant(8)]]
* There are a lot of example configurations for all sort of setups in [[https://cgit.freebsd.org/src/tree/contrib/wpa/wpa_supplicant/wpa_supplicant.conf|/usr/share/examples/etc/wpa_supplicant.conf]].
----
=== How to configure Eduroam? ===
An example configuration has been added to the [[https://man.freebsd.org/cgi/man.cgi?query=wpa_supplicant.conf&apropos=0&sektion=5&manpath=FreeBSD+12-current&arch=default&format=html|wpa_supplicant.conf(5)]] manual page in %%FreeBSD%% 12-CURRENT.
----
=== I am sure I put correct password into /etc/wpa_supplicant.conf but it still doesn't work ===
[[https://man.freebsd.org/cgi/man.cgi?query=wpa_supplicant.conf&sektion=5|wpa_supplicant.conf(5)]] has a couple of syntactic subtleties, which might be causing this:
* The value of ''%%psk%%'' should be either a ''%%"%%''-quoted passphrase (e.g. ''%%"password"%%'') or a 256-bit pre-shared WPA key (e.g. ''%%c4c5b44ebb507f6c8b10ea42eb30521465c1cc000e432748fa9f87eb68b63cc1%%''). Also, check out [[https://man.freebsd.org/cgi/man.cgi?query=wpa_passphrase&sektion=8|wpa_passphrase(8)]].
----
==== Tools that you wish you knew existed ====
* [[https://man.freebsd.org/cgi/man.cgi?query=bsdconfig&sektion=8|bsdconfig(8)]]
* Configure %%WiFi%%:
bsdconfig netdev
* [[https://man.freebsd.org/cgi/man.cgi?query=wpa_cli&sektion=8|wpa_cli(8)]]
* Intimidating at first, it is not actually that bad.
* This is utility is why you put ''%%ctrl_interface=/var/run/wpa_supplicant%%'' in [[https://man.freebsd.org/cgi/man.cgi?query=wpa_supplicant.conf&sektion=5|wpa_supplicant.conf(5)]].
----
===== Community support =====
You may seek help on the following communication channels.
==== Mailing lists ====
* [[https://lists.freebsd.org/mailman/listinfo/freebsd-wireless|freebsd-wireless@freebsd.org (lists.freebsd.org)]]
==== IRC ====
* [[IRC/Channels#Libera_IRC|Libera IRC]]:
* [[http://www.erisnet.org/|EFNet]]:
* [[https://client00.chat.mibbit.com/?url=ircs%3A%2F%2Firc.efnet.org%2Ffreebsd-wifi|#freebsd-wifi]]
See [[IRC/Channels]] for a list of all the %%FreeBSD%% IRC channels.
----
===== See also =====
* [[/dev|Device drivers wiki pages]]
----
{{tag>HowTo WiFi}}