Difference between revisions of "Transclusion: Debian: CL-SOM-iMX7: WiFi"

From Compulab Mediawiki
Jump to: navigation, search
(New page: CL-SOM-iMX7 features 802.11b/g/n wireless connectivity solution, implemented with a TI WiLink8 Combo module. ==== WiFi Initialization ==== * WiFi requires no user interaction for being co...)
 
(wpa_supplicant)
 
(One intermediate revision by one other user not shown)
Line 5: Line 5:
 
Make sure that the WiFi driver is loaded:
 
Make sure that the WiFi driver is loaded:
 
<pre>
 
<pre>
root@cl-som-imx7-sid:~# lsmod | grep wl18xx
+
root@cl-rootfs:~# lsmod | grep wl18xx
 
wl18xx                70950  0
 
wl18xx                70950  0
 
</pre>
 
</pre>
 
The WiFi driver can be loaded manually:
 
The WiFi driver can be loaded manually:
 
<pre>
 
<pre>
root@cl-som-imx7-sid:~# modprobe wl18xx
+
root@cl-rootfs:~# modprobe wl18xx
 
wlcore: ERROR could not get configuration binary ti-connectivity/wl18xx-conf.bin: -2
 
wlcore: ERROR could not get configuration binary ti-connectivity/wl18xx-conf.bin: -2
 
wlcore: WARNING falling back to default config
 
wlcore: WARNING falling back to default config
Line 16: Line 16:
 
wlcore: loaded
 
wlcore: loaded
 
</pre>
 
</pre>
* {{cmd|iwconfig}} command from {{cmd|wireless-tools}} package can be used to retrieve detailed information about the WiFi interfaces:
+
* {{cmd|iwconfig}} command from {{filename|wireless-tools}} package can be used to retrieve detailed information about the WiFi interfaces:
 
<pre>
 
<pre>
root@cl-som-imx7-sid:~# iwconfig wlan0
+
root@cl-rootfs:~# iwconfig wlan0
 
wlan0    IEEE 802.11abgn  ESSID:off/any   
 
wlan0    IEEE 802.11abgn  ESSID:off/any   
 
           Mode:Managed  Access Point: Not-Associated  Tx-Power=0 dBm   
 
           Mode:Managed  Access Point: Not-Associated  Tx-Power=0 dBm   
Line 27: Line 27:
 
* Activate the interface:
 
* Activate the interface:
 
<pre>
 
<pre>
root@cl-som-imx7-sid:~# ifconfig wlan0 up
+
root@cl-rootfs:~# ifconfig wlan0 up
 
</pre>
 
</pre>
 
* Sample WiFi scanning:
 
* Sample WiFi scanning:
 
<pre>
 
<pre>
root@cl-som-imx7-sid:~# iwlist wlan0 scan
+
root@cl-rootfs:~# iwlist wlan0 scan
 
</pre>
 
</pre>
 
The output will show the list of Access Points and Ad-Hoc cells in range.
 
The output will show the list of Access Points and Ad-Hoc cells in range.
Line 38: Line 38:
 
==== wpa_supplicant ====
 
==== wpa_supplicant ====
 
* Configuration sample
 
* Configuration sample
{{cmd|wpa_supplicant}} requires a configuration file to be created in order to get connected to a scanned wireless network.<br>
+
Please open a {{cmd|wpa_supplicant}} configuration file bellow and put a network name and a password into the "ssid" and "psk" fields respectively.
Make use of the example bellow and put the network name and the password into the "ssid/psk" fields.
 
 
 
 
<pre>
 
<pre>
root@cl-som-imx7-sid:~# cat << eof > /etc/wpa_supplicant.conf
+
root@cl-rootfs:~# cat /etc/wpa_supplicant.conf
 
ctrl_interface=/var/run/wpa_supplicant
 
ctrl_interface=/var/run/wpa_supplicant
  
Line 50: Line 48:
 
psk="wireless_network_password"
 
psk="wireless_network_password"
 
}
 
}
eof
 
 
</pre>
 
</pre>
 
* Sample run
 
* Sample run
 
<pre>
 
<pre>
root@cl-som-imx7-sid:~# ifconfig wlan0 up
+
root@cl-rootfs:~# ifconfig wlan0 up
root@cl-som-imx7-sid:~# wpa_supplicant -B -Dwext -c /etc/wpa_supplicant.conf -i wlan0
+
root@cl-rootfs:~# wpa_supplicant -B -Dwext -c /etc/wpa_supplicant.conf -i wlan0
root@cl-som-imx7-sid:~# dhclient wlan0
+
root@cl-rootfs:~# dhclient wlan0
 
</pre>
 
</pre>

Latest revision as of 08:11, 22 August 2017

CL-SOM-iMX7 features 802.11b/g/n wireless connectivity solution, implemented with a TI WiLink8 Combo module.

WiFi Initialization

  • WiFi requires no user interaction for being configured. The driver gets loaded automatically.

Make sure that the WiFi driver is loaded:

root@cl-rootfs:~# lsmod | grep wl18xx
wl18xx                 70950  0

The WiFi driver can be loaded manually:

root@cl-rootfs:~# modprobe wl18xx
	wlcore: ERROR could not get configuration binary ti-connectivity/wl18xx-conf.bin: -2
	wlcore: WARNING falling back to default config
	wlcore: wl18xx HW: 183x or 180x, PG 2.2 (ROM 0x11)
	wlcore: loaded
  • iwconfig command from wireless-tools package can be used to retrieve detailed information about the WiFi interfaces:
root@cl-rootfs:~# iwconfig wlan0
wlan0     IEEE 802.11abgn  ESSID:off/any  
          Mode:Managed  Access Point: Not-Associated   Tx-Power=0 dBm   
          Retry short limit:7   RTS thr:off   Fragment thr:off
          Encryption key:off
          Power Management:on
  • Activate the interface:
root@cl-rootfs:~# ifconfig wlan0 up
  • Sample WiFi scanning:
root@cl-rootfs:~# iwlist wlan0 scan

The output will show the list of Access Points and Ad-Hoc cells in range. For more information about connecting to wireless networks and tuning WiFi interfaces refer to “wpa_supplicant” and “wireless-tools” man pages.

wpa_supplicant

  • Configuration sample

Please open a wpa_supplicant configuration file bellow and put a network name and a password into the "ssid" and "psk" fields respectively.

root@cl-rootfs:~# cat /etc/wpa_supplicant.conf
ctrl_interface=/var/run/wpa_supplicant

network={
	ssid="wireless_network_name"
	key_mgmt=WPA-PSK
	psk="wireless_network_password"
}
  • Sample run
root@cl-rootfs:~# ifconfig wlan0 up
root@cl-rootfs:~# wpa_supplicant -B -Dwext -c /etc/wpa_supplicant.conf -i wlan0
root@cl-rootfs:~# dhclient wlan0