Difference between revisions of "DESK-MX6-L/Peripherals/WiFi"

From DAVE Developer's Wiki
Jump to: navigation, search
(Created page with "{{subst:Peripheral | nome-som=AXEL Lite | nome-peripheral = WiFi }}")
 
 
(One intermediate revision by the same user not shown)
Line 3: Line 3:
 
!colspan="4" style="width:100%; text-align:left"; border-bottom:solid 2px #ededed"|History
 
!colspan="4" style="width:100%; text-align:left"; border-bottom:solid 2px #ededed"|History
 
|-  
 
|-  
!style="border-left:solid 2px #73B2C7; border-right:solid 2px #73B2C7;border-top:solid 2px #73B2C7; border-bottom:solid 2px #73B2C7; background-color:#73B2C7; padding:5px; color:white"|Version
 
 
!style="border-left:solid 2px #73B2C7; border-right:solid 2px #73B2C7;border-top:solid 2px #73B2C7; border-bottom:solid 2px #73B2C7; background-color:#73B2C7; padding:5px; color:white"|Issue Date
 
!style="border-left:solid 2px #73B2C7; border-right:solid 2px #73B2C7;border-top:solid 2px #73B2C7; border-bottom:solid 2px #73B2C7; background-color:#73B2C7; padding:5px; color:white"|Issue Date
 
!style="border-left:solid 2px #73B2C7; border-right:solid 2px #73B2C7;border-top:solid 2px #73B2C7; border-bottom:solid 2px #73B2C7; background-color:#73B2C7; padding:5px; color:white"|Notes
 
!style="border-left:solid 2px #73B2C7; border-right:solid 2px #73B2C7;border-top:solid 2px #73B2C7; border-bottom:solid 2px #73B2C7; background-color:#73B2C7; padding:5px; color:white"|Notes
 
|-
 
|-
|style="border-left:solid 2px #73B2C7; border-right:solid 2px #73B2C7;border-top:solid 2px #73B2C7; border-bottom:solid 2px #73B2C7; background-color:#edf8fb; padding:5px; color:#000000"|X.Y.Z
+
|style="border-left:solid 2px #73B2C7; border-right:solid 2px #73B2C7;border-top:solid 2px #73B2C7; border-bottom:solid 2px #73B2C7; background-color:#edf8fb; padding:5px; color:#000000"|2024/05/13
|style="border-left:solid 2px #73B2C7; border-right:solid 2px #73B2C7;border-top:solid 2px #73B2C7; border-bottom:solid 2px #73B2C7; background-color:#edf8fb; padding:5px; color:#000000"|Month Year
+
|style="border-left:solid 2px #73B2C7; border-right:solid 2px #73B2C7;border-top:solid 2px #73B2C7; border-bottom:solid 2px #73B2C7; background-color:#edf8fb; padding:5px; color:#000000"|DESK-MX6-L-4.0.1 release
|style="border-left:solid 2px #73B2C7; border-right:solid 2px #73B2C7;border-top:solid 2px #73B2C7; border-bottom:solid 2px #73B2C7; background-color:#edf8fb; padding:5px; color:#000000"|TBD
 
|-
 
|-
 
|style="border-left:solid 2px #73B2C7; border-right:solid 2px #73B2C7;border-top:solid 2px #73B2C7; border-bottom:solid 2px #73B2C7; background-color:#edf8fb; padding:5px; color:#000000"|[TBD_link X.Y.Z]
 
|style="border-left:solid 2px #73B2C7; border-right:solid 2px #73B2C7;border-top:solid 2px #73B2C7; border-bottom:solid 2px #73B2C7; background-color:#edf8fb; padding:5px; color:#000000"|Month Year
 
|style="border-left:solid 2px #73B2C7; border-right:solid 2px #73B2C7;border-top:solid 2px #73B2C7; border-bottom:solid 2px #73B2C7; background-color:#edf8fb; padding:5px; color:#000000"|TBD
 
|-
 
|style="border-left:solid 2px #73B2C7; border-right:solid 2px #73B2C7;border-top:solid 2px #73B2C7; border-bottom:solid 2px #73B2C7; background-color:#edf8fb; padding:5px; color:#000000"|...
 
|style="border-left:solid 2px #73B2C7; border-right:solid 2px #73B2C7;border-top:solid 2px #73B2C7; border-bottom:solid 2px #73B2C7; background-color:#edf8fb; padding:5px; color:#000000"|...
 
|style="border-left:solid 2px #73B2C7; border-right:solid 2px #73B2C7;border-top:solid 2px #73B2C7; border-bottom:solid 2px #73B2C7; background-color:#edf8fb; padding:5px; color:#000000"|...
 
 
|-
 
|-
 
|}
 
|}
Line 25: Line 14:
  
 
==Peripheral WiFi ==
 
==Peripheral WiFi ==
 
''TBD: sostituire tutti i dump con le informazioni sull'uso della periferica''
 
  
 
=== Device tree configuration ===
 
=== Device tree configuration ===
 
Here below an example of device tree configuration used on standard DAVE's kit for the AXEL Lite SOM:
 
Here below an example of device tree configuration used on standard DAVE's kit for the AXEL Lite SOM:
  
From <code>''carrier.dts''</code>:
+
From <code>imx6qdl-axelcommon.dtsi</code>:
  
 
<pre>
 
<pre>
&can1 {
+
     pinctrl_usdhc2_sbc: usdhc2-sbc-grp-1 {
     pinctrl-names = "default";
+
fsl,pins = <
    pinctrl-0 = <&pinctrl_flexcan1_axel>;
+
MX6QDL_PAD_SD2_CMD__SD2_CMD    0x16058
     status = "okay";
+
MX6QDL_PAD_SD2_CLK__SD2_CLK    0x16058
};
+
MX6QDL_PAD_SD2_DAT0__SD2_DATA0 0x16058
</pre>
+
MX6QDL_PAD_SD2_DAT1__SD2_DATA1 0x16058
 +
MX6QDL_PAD_SD2_DAT2__SD2_DATA2 0x16058
 +
MX6QDL_PAD_SD2_DAT3__SD2_DATA3 0x16058
 +
>;
 +
     };
  
From <code>''carrier-common.dtsi''</code>:
 
 
<pre>
 
    can1 {
 
        pinctrl_flexcan1_axel: flexcan1axelgrp-1 {
 
            fsl,pins = <
 
                MX6QDL_PAD_GPIO_7__FLEXCAN1_TX 0x80000000
 
                MX6QDL_PAD_GPIO_8__FLEXCAN1_RX 0x80000000
 
            >;
 
        };
 
    };
 
 
</pre>
 
</pre>
  
 
===Accessing the peripheral===
 
===Accessing the peripheral===
 +
Once initialized, the WiFi device is mapped to the standard <code>wlan0</code> network device
 +
 
====Linux messages at boot time====
 
====Linux messages at boot time====
  
Line 60: Line 42:
 
...
 
...
 
...
 
...
[   1.807495] flexcan 2090000.flexcan: 2090000.flexcan supply xceiver not found, using dummy regulator
+
[   12.280208] mmc1: queuing unknown CIS tuple 0x01 [d9 01 ff] (3 bytes)
[   1.817366] flexcan 2090000.flexcan: device registered (reg_base=c0a30000, irq=31)
+
[  12.289246] mmc1: queuing unknown CIS tuple 0x1a [01 01 00 02 07] (5 bytes)
 +
[  12.292858] mmc1: queuing unknown CIS tuple 0x1b [c1 41 30 30 ff ff 32 00] (8 bytes)
 +
[  12.293600] mmc1: queuing unknown CIS tuple 0x14 [] (0 bytes)
 +
[  12.295981] hifDeviceInserted: Dumping clocks (50000000,25000000)
 +
[   12.462210] [TELIT] Using WE866C6 board data.
 +
[  12.521942] ol_download_firmware: chip_id:0x5020001 board_id:0x0
 +
[  12.522379] __ol_transfer_bin_file: Failed to get bdwlan30_c6.b00:-2
 +
[  12.522393] __ol_transfer_bin_file: Trying to load default bdwlan30_c6.bin
 +
[  12.524403] Board extended Data download address: 0x0
 +
[  12.540922] __ol_transfer_bin_file: Loading setup file qsetup30.bin
 +
[  12.541022] __ol_transfer_bin_file: Failed to get qsetup30.bin:-2
 +
[  13.460133] R0: wlan: [215:E :SAP] dfs_init_radar_filters[217]: Unknown dfs domain 0
 +
[  13.476303] Target Ready! : transmit resources : 3 size:1792, MaxMsgsPerHTCBundle = 32
 +
[  13.568537] target uses HTT version 3.60; host uses 3.28
 +
[  13.568557] *** Warning: host/target HTT versions are different, though compatible!
 +
[  13.585229] DEBUGFS PEER MAC = 0x2:0x21:0x7e:0x2:0x10:0x6a
 +
[  13.602253] Host SW:4.5.25.46, FW:0.0.0.111, HW:QCA93x7_REV1_1
 +
[  13.616457] ENTER sme_set_btc_coex_dutycycle = 30
 +
[  13.616473] ENTER sme_set_btc_coex_dutycycle =30
 +
[  13.616767] ath_hif_sdio: HIF (Atheros/multi-bss)
 +
[  13.616784] wlan: driver loaded in 1570000
 
...
 
...
 
...
 
...
[    3.952659] can: controller area network core (rev 20170425 abi 9)
 
[    3.963413] can: raw protocol (rev 20170425)
 
[    3.967717] can: broadcast manager protocol (rev 20170425 t)
 
[    3.973397] can: netlink gateway (rev 20170425) max_hops=1
 
 
</pre>
 
</pre>
  
 
====Enable the interface and check status====
 
====Enable the interface and check status====
 
<pre class="workstation-terminal">
 
<pre class="workstation-terminal">
root@imx6qxelk:~# ip link set can0 type can bitrate 500000
+
root@desk-mx6:~# ifconfig wlan0
root@imx6qxelk:~# ifconfig can0 up
+
wlan0: flags=4099<UP,BROADCAST,MULTICAST>  mtu 1500
root@imx6qxelk:~# ifconfig can0
+
        ether 00:21:7e:81:10:6a txqueuelen 3000 (Ethernet)
can0      Link encap:UNSPEC HWaddr 00-00-00-00-00-00-00-00-00-00-00-00-00-00-00-00
+
        RX packets 0 bytes 0 (0.0 B)
          UP RUNNING NOARP MTU:16  Metric:1
+
        RX errors 0 dropped 0 overruns 0 frame 0
          RX packets:0 errors:0 dropped:0 overruns:0 frame:0
+
        TX packets 0 bytes 0 (0.0 B)
          TX packets:0 errors:0 dropped:0 overruns:0 carrier:0
+
        TX errors 0 dropped 0 overruns 0 carrier 0 collisions 0
          collisions:0 txqueuelen:10
 
          RX bytes:0 (0.0 B)  TX bytes:0 (0.0 B)
 
          Interrupt:31
 
  
root@imx6qxelk:~#
+
root@desk-mx6:~# rfkill list
 +
0: bt_rfkill: Bluetooth
 +
        Soft blocked: no
 +
        Hard blocked: no
 +
1: phy0: Wireless LAN
 +
        Soft blocked: no
 +
        Hard blocked: no
 +
root@desk-mx6:~#
 
</pre>
 
</pre>
  
==== Usage with [https://github.com/linux-can/can-utils can-utils] ====
+
==== Usage with [https://wireless.wiki.kernel.org/en/users/documentation/iw iw] tool ====
 
 
''TBD: reference verso eventuali informazioni sul web''
 
  
 
<pre class="workstation-terminal">
 
<pre class="workstation-terminal">
root@imx6qxelk:~# ip link set can0 type can bitrate 500000 triple-sampling on
+
root@desk-mx6:~# iw wlan0 scan
root@imx6qxelk:~# ifconfig can0 up
+
BSS d0:21:f9:35:8e:88(on wlan0)
root@imx6qxelk:~# cansend can0 128#1122334455667788
+
        last seen: 66.551s [boottime]
root@imx6qxelk:~# candump can0
+
        TSF: 4572051265456 usec (52d, 22:00:51)
  can0  128  [8]  11 22 33 44 55 66 77 88
+
        freq: 5180
root@imx6qxelk:~#  
+
        beacon interval: 100 TUs
 +
        capability: ESS Privacy SpectrumMgmt ShortSlotTime RadioMeasure (0x1511)
 +
        signal: -50.00 dBm
 +
        last seen: 0 ms ago
 +
        Information elements from Probe Response frame:
 +
        SSID: daveguest
 +
        Supported rates: 6.0* 9.0 12.0* 18.0 24.0* 36.0 48.0 54.0
 +
        DS Parameter set: channel 36
 +
        Country: IT    Environment: Indoor/Outdoor
 +
                Channels [36 - 36] @ 23 dBm
 +
                Channels [40 - 40] @ 23 dBm
 +
...
 +
...
 +
                * Serial Number: CN716FX062
 +
                * Primary Device Type: 3-0050f204-1
 +
                * Device name:
 +
                * Config methods: Display
 +
                * Version2: 2.0
 +
                * Unknown vendor extension. len=23
 +
root@desk-mx6:~# iw wlan0 scan | grep SSID
 +
        SSID: daveguest
 +
                * SSID List
 +
        SSID: davesrl
 +
                * SSID List
 +
        SSID: DIRECT-C9-HP PageWide Pro 477dw
 +
root@desk-mx6:~#
 
</pre>
 
</pre>
  
 
=== Additional information ===
 
=== Additional information ===
Each CAN port appears like a networking interface in the form <code>canX</code> where <b><i>X</i></b> is the port number.
 
  
Information about programming the CAN socket interface is given in the kernel tree under ''Documentation/networking/can.txt''
 
 
<section end=Body/>
 
<section end=Body/>
  

Latest revision as of 12:13, 13 May 2024

History
Issue Date Notes
2024/05/13 DESK-MX6-L-4.0.1 release


Peripheral WiFi[edit | edit source]

Device tree configuration[edit | edit source]

Here below an example of device tree configuration used on standard DAVE's kit for the AXEL Lite SOM:

From imx6qdl-axelcommon.dtsi:

    pinctrl_usdhc2_sbc: usdhc2-sbc-grp-1 {
	fsl,pins = <
		MX6QDL_PAD_SD2_CMD__SD2_CMD    0x16058
		MX6QDL_PAD_SD2_CLK__SD2_CLK    0x16058
		MX6QDL_PAD_SD2_DAT0__SD2_DATA0 0x16058
		MX6QDL_PAD_SD2_DAT1__SD2_DATA1 0x16058
			MX6QDL_PAD_SD2_DAT2__SD2_DATA2 0x16058
			MX6QDL_PAD_SD2_DAT3__SD2_DATA3 0x16058
	>;
    };

Accessing the peripheral[edit | edit source]

Once initialized, the WiFi device is mapped to the standard wlan0 network device

Linux messages at boot time[edit | edit source]

...
...
[   12.280208] mmc1: queuing unknown CIS tuple 0x01 [d9 01 ff] (3 bytes)
[   12.289246] mmc1: queuing unknown CIS tuple 0x1a [01 01 00 02 07] (5 bytes)
[   12.292858] mmc1: queuing unknown CIS tuple 0x1b [c1 41 30 30 ff ff 32 00] (8 bytes)
[   12.293600] mmc1: queuing unknown CIS tuple 0x14 [] (0 bytes)
[   12.295981] hifDeviceInserted: Dumping clocks (50000000,25000000)
[   12.462210] [TELIT] Using WE866C6 board data.
[   12.521942] ol_download_firmware: chip_id:0x5020001 board_id:0x0
[   12.522379] __ol_transfer_bin_file: Failed to get bdwlan30_c6.b00:-2
[   12.522393] __ol_transfer_bin_file: Trying to load default bdwlan30_c6.bin
[   12.524403] Board extended Data download address: 0x0
[   12.540922] __ol_transfer_bin_file: Loading setup file qsetup30.bin
[   12.541022] __ol_transfer_bin_file: Failed to get qsetup30.bin:-2
[   13.460133] R0: wlan: [215:E :SAP] dfs_init_radar_filters[217]: Unknown dfs domain 0
[   13.476303] Target Ready! : transmit resources : 3 size:1792, MaxMsgsPerHTCBundle = 32
[   13.568537] target uses HTT version 3.60; host uses 3.28
[   13.568557] *** Warning: host/target HTT versions are different, though compatible!
[   13.585229] DEBUGFS PEER MAC = 0x2:0x21:0x7e:0x2:0x10:0x6a
[   13.602253] Host SW:4.5.25.46, FW:0.0.0.111, HW:QCA93x7_REV1_1
[   13.616457] ENTER sme_set_btc_coex_dutycycle = 30
[   13.616473] ENTER sme_set_btc_coex_dutycycle =30
[   13.616767] ath_hif_sdio: HIF (Atheros/multi-bss)
[   13.616784] wlan: driver loaded in 1570000
...
...

Enable the interface and check status[edit | edit source]

root@desk-mx6:~# ifconfig wlan0
wlan0: flags=4099<UP,BROADCAST,MULTICAST>  mtu 1500
        ether 00:21:7e:81:10:6a  txqueuelen 3000  (Ethernet)
        RX packets 0  bytes 0 (0.0 B)
        RX errors 0  dropped 0  overruns 0  frame 0
        TX packets 0  bytes 0 (0.0 B)
        TX errors 0  dropped 0 overruns 0  carrier 0  collisions 0

root@desk-mx6:~# rfkill list
0: bt_rfkill: Bluetooth
        Soft blocked: no
        Hard blocked: no
1: phy0: Wireless LAN
        Soft blocked: no
        Hard blocked: no
root@desk-mx6:~#

Usage with iw tool[edit | edit source]

root@desk-mx6:~# iw wlan0 scan
BSS d0:21:f9:35:8e:88(on wlan0)
        last seen: 66.551s [boottime]
        TSF: 4572051265456 usec (52d, 22:00:51)
        freq: 5180
        beacon interval: 100 TUs
        capability: ESS Privacy SpectrumMgmt ShortSlotTime RadioMeasure (0x1511)
        signal: -50.00 dBm
        last seen: 0 ms ago
        Information elements from Probe Response frame:
        SSID: daveguest
        Supported rates: 6.0* 9.0 12.0* 18.0 24.0* 36.0 48.0 54.0
        DS Parameter set: channel 36
        Country: IT     Environment: Indoor/Outdoor
                Channels [36 - 36] @ 23 dBm
                Channels [40 - 40] @ 23 dBm
...
...
                 * Serial Number: CN716FX062
                 * Primary Device Type: 3-0050f204-1
                 * Device name:
                 * Config methods: Display
                 * Version2: 2.0
                 * Unknown vendor extension. len=23
root@desk-mx6:~# iw wlan0 scan | grep SSID
        SSID: daveguest
                 * SSID List
        SSID: davesrl
                 * SSID List
        SSID: DIRECT-C9-HP PageWide Pro 477dw
root@desk-mx6:~#

Additional information[edit | edit source]