Changes between Version 14 and Version 15 of expansion/on-board-wireless


Ignore:
Timestamp:
08/31/2022 07:05:14 PM (20 months ago)
Author:
Tim Harvey
Comment:

added info for Sterling LWB5+

Legend:

Unmodified
Added
Removed
Modified
  • expansion/on-board-wireless

    v14 v15  
    11[[PageOutline]]
    22
     3
     4[=#sterling-lwb5plus]
     5= Laird Sterling-LWB5+ 2.4/5.8GHz Wifi / Bluetooth module
     6The Laird Connectivity Sterling-LWB5+ is a Wifi5 (IEEE 802.11ac) !WiFi radio with Bluetooth 5.2 Low Energy support.
     7
     8== Module Details
     9The Sterling-LWB5+ 453-00046 module:
     10 * CYW4373E chip
     11 * 1x MHF4 antenna shared between !WiFi and Bluetooth
     12 * WL_REG_ON pin must be driven high to enable !WiFi functionality
     13 * BT_REG_ON pin must be driven high to enable Bluetooth functionality
     14 * UART bus provides Bluetooth
     15 * SDIO bus provides !WiFi
     16
     17
     18== Board Specific Details
     19The Sterling-LWB5+ is installed on the following Gateworks boards:
     20 * GW7400
     21  * WL_REG_ON - NAND_DATA03__GPIO3_IO09 - must be driven high to enable !WiFi functionality (handled by kernel)
     22  * BT_REG_ON - NAND_DATA02__GPIO3_IO08 - must be driven high to enable Bluetooth functionality (handled by kernel)
     23  * UART3 (/dev/ttymxc2) is the Bluetooth UART
     24  * SDHC1 (/dev/mmc0) is the SDIO !WiFi bus
     25 * GW7300-D+ (replaced the Sterling LWB on previous revisions)
     26  * WL_REG_ON - GPIO1_IO05_GPIO1_IO5 - must be driven high to enable !WiFi functionality (handled by kernel)
     27  * BT_REG_ON - GPIO1_IO03_GPIO1_IO3 - must be driven high to enable Bluetooth functionality (handled by kernel)
     28  * UART3 (/dev/ttymxc2) is the Bluetooth UART
     29  * SDHC1 (/dev/mmc0) is the SDIO !WiFi bus
     30
     31
     32== OS Support
     33The following notes pertain to support in various OS BSPs (Note that in all cases firmware and drivers are needed as noted above):
     34 * Ubuntu with Gateworks kernel (should also work in mainline kernel):
     35  - Bluetooth HCI fully supported
     36  - !WiFi client and AP fully supported
     37
     38== Firmware
     39Firmware is needed for both !WiFi device and bluetooth functionality and is loaded by the drivers.
     40
     41**Note:** The script used in debootstrap for creating our Ubuntu prebuilt images installs the linux-firmware package before this driver is downloaded and extracted.  When "apt-get update" is ran it will overwrite the 3rd party driver causing an error when the Laird modules are loaded.  Reference [https://github.com/Gateworks/ubuntu-rootfs/blob/master/ubuntu-rootfs.sh this link].
     42
     43== Drivers
     44
     45=== !WiFi
     46The SDIO !WiFi functionality is supported by the mainline {{{brcmfmac}}} (Full MAC) driver present in Linux 4.1+
     47
     48kernel drivers:
     49 - CONFIG_CFG80211 / CONFIG_WLAN / CONFIG_NETDEVICES / CONFIG_WLAN_VENDOR_BROADCOM
     50 - CONFIG_BRCMUTIL (brcmutil.ko) (selected when you enable BRCMFMAC)
     51 - CONFIG_BRCMFMAC (brcmfmac.ko)
     52 - CONFIG_BRCMFMAC_SDIO=y (static; selects BRCMFMAC_PROTO_BCDC and FW_LOADER)
     53
     54On the Gateworks kernels these are all enabled and you see the following:
     55{{{#!bash
     56~# dmesg | grep mmc0
     57root@jammy-venice:~# dmesg | grep mmc0
     58[    1.284402] mmc0: SDHCI controller on 30b40000.mmc [30b40000.mmc] using ADMA
     59[    1.404929] mmc0: new ultra high speed SDR104 SDIO card at address 0001
     60[    9.249611] brcmfmac mmc0:0001:1: Direct firmware load for brcm/brcmfmac4373-
     61sdio.gateworks,imx8mp-gw74xx.bin failed with error -2
     62[    9.254288] brcmfmac mmc0:0001:1: Direct firmware load for brcm/brcmfmac4373-
     63sdio.gateworks,imx8mp-gw74xx.txt failed with error -2
     64~# dmesg | grep brcm
     65[    9.238520] brcmfmac: brcmf_fw_alloc_request: using brcm/brcmfmac4373-sdio fo
     66r chip BCM4373/0
     67[    9.249611] brcmfmac mmc0:0001:1: Direct firmware load for brcm/brcmfmac4373-
     68sdio.gateworks,imx8mp-gw74xx.bin failed with error -2
     69[    9.251931] usbcore: registered new interface driver brcmfmac
     70[    9.254288] brcmfmac mmc0:0001:1: Direct firmware load for brcm/brcmfmac4373-
     71sdio.gateworks,imx8mp-gw74xx.txt failed with error -2
     72[    9.284004] Bluetooth: hci0: BCM4373A0 'brcm/BCM4373A0.hcd' Patch
     73[   11.373370] brcmfmac: brcmf_fw_alloc_request: using brcm/brcmfmac4373-sdio fo
     74r chip BCM4373/0
     75[   11.388516] brcmfmac: brcmf_c_preinit_dcmds: Firmware: BCM4373/0 wl0: Oct  8
     762021 09:44:25 version 13.10.246.261 (4410652 CY) FWID 01-9585ba52
     77}}}
     78 * Note the 'brcmf_fw_alloc_request' failures are normal as the driver attempts to load board-specific firmware first which fails before a generic firmware is loaded
     79
     80If you have the need for software support LAIRD has a driver package on their website that consists of a Linux backports driver with patches as well as patches for wpa_supplicant and hostapd. These are derived from periodic code-drops they get from Cypress and not all of these patches make it upstream.
     81
     82
     83=== Bluetooth
     84Bluetooth functionality is provided by a UART based Bluetooth HCI (Host Controller Interface).
     85
     86kernel drivers:
     87 * CONFIG_BT (bluetooth support; bt.ko if module)
     88 * CONFIG_BT_HCIUART (UART based HCI support; hci_uart.ko if module)
     89 * CONFIG_BT_HCIUART_BCM (Broadcom protocol support)
     90
     91If using a Linux 5.0+ kernel the HCI should be brought up {{{/sys/class/bluetooth/hci0}}} and configured via device-tree bindings if there is a node with a compatible string of 'brcm,bcm4330-bt'. If such bindings exist the kernel will attempt to load firmware patches from {{{/lib/firmware/brcm/BCM4373A0.hcd}}}. This looks like the following in kernel log:
     92{{{#!bash
     93[    8.724500] Bluetooth: Core ver 2.22
     94[    8.724601] Bluetooth: HCI device and connection manager initialized
     95[    8.724617] Bluetooth: HCI socket layer initialized
     96[    8.724624] Bluetooth: L2CAP socket layer initialized
     97[    8.724640] Bluetooth: SCO socket layer initialized
     98[    8.852049] Bluetooth: HCI UART driver ver 2.3
     99[    8.852071] Bluetooth: HCI UART protocol H4 registered
     100[    8.852076] Bluetooth: HCI UART protocol BCSP registered
     101[    8.867795] Bluetooth: HCI UART protocol LL registered
     102[    8.867816] Bluetooth: HCI UART protocol ATH3K registered
     103[    8.867870] Bluetooth: HCI UART protocol Three-wire (H5) registered
     104[    8.868056] Bluetooth: HCI UART protocol Intel registered
     105[    8.868227] Bluetooth: HCI UART protocol Broadcom registered
     106[    8.868290] Bluetooth: HCI UART protocol QCA registered
     107[    8.868295] Bluetooth: HCI UART protocol AG6XX registered
     108[    8.868339] Bluetooth: HCI UART protocol Marvell registered
     109[    9.257710] Bluetooth: hci0: BCM: chip id 135
     110[    9.260024] Bluetooth: hci0: BCM: features 0x0f
     111[    9.282874] Bluetooth: hci0: BCM4373A0
     112[    9.282898] Bluetooth: hci0: BCM4373A0 (001.001.025) build 0000
     113[    9.284004] Bluetooth: hci0: BCM4373A0 'brcm/BCM4373A0.hcd' Patch
     114[   10.452359] Bluetooth: BNEP (Ethernet Emulation) ver 1.3
     115[   10.452380] Bluetooth: BNEP filters: protocol multicast
     116[   10.452397] Bluetooth: BNEP socket layer initialized
     117[   14.250502] Bluetooth: hci0: CYW94373 UART 37.4MHz Class 1 wlbga sLNA-0090
     118[   14.250525] Bluetooth: hci0: BCM4373A0 (001.001.025) build 0128
     119}}}
     120
     121
     122[=#sterling-lwb]
    3123= Laird Sterling-LWB 2.4GHz Wifi / Bluetooth module (450-0148)
    4 The Laird Connectivity Sterling-LWB 450-0148 is a IEEE 802.11 b/g/n !WiFi radio with BT 2.1+EDR and BLE 4.2 connectivity module with a single external U.FL antenna port.
     124The Laird Connectivity Sterling-LWB 450-0148 is a Wifi4 (IEEE 802.11n) !WiFi radio with BT 2.1+EDR and BLE 4.2 connectivity module with a single external U.FL antenna port.
    5125
    6126== Module Details
    7127The Sterling-LWB 450-0148 module:
    8  * BCM43430 - for SDIO based !WiFi
     128 * BCM43430 chip
    9129 * 1x U.FL antenna shared between !WiFi and Bluetooth
    10130 * WL_REG_ON pin must be driven high to enable !WiFi functionality
     
    25145
    26146
    27 [=#hardware]
    28147== Board Specific Details
    29148
    30149The Sterling-LWB is installed on the following Gateworks boards:
    31  * GW5910
     150 * GW7300-A/B/C (replaced with the Sterling LWB on revD+)
     151  * WL_REG_ON - GPIO1_IO05_GPIO1_IO5 - must be driven high to enable !WiFi functionality (handled by kernel)
     152  * BT_REG_ON - GPIO1_IO03_GPIO1_IO3 - must be driven high to enable Bluetooth functionality (handled by kernel)
     153  * UART3 (/dev/ttymxc2) is the Bluetooth UART
     154  * SDHC1 (/dev/mmc0) is the SDIO !WiFi bus
     155* GW5910
    32156  * WL_REG_ON - PAD_GPIO_5__GPIO1_IO05 - must be driven high to enable !WiFi functionality (handled by kernel)
    33157  * BT_REG_ON - PAD_GPIO_2__GPIO1_IO02 - must be driven high to enable Bluetooth functionality (handled by kernel)
     
    35159  * SDHC2 (/dev/mmcblk0) is the SDIO !WiFi bus (Note that the microSD is on SDHC3 thus appears to the kernel as /dev/mmcblk1 - this must be taken into account if mounting the root filesystem from microSD)
    36160
    37 [=#os]
    38161== OS Support
    39162The following notes pertain to support in various OS BSPs (Note that in all cases firmware and drivers are needed as noted above):
     
    49172
    50173
    51 [=#firmware]
    52174== Firmware
    53175Firmware is needed for !WiFi device functionality and it is loaded by the drivers. While firmware is not needed for Bluetooth functionality providing it will provide fixes and additional functionality over what is already programmed into the device.
     
    67189**Note:** The script used in debootstrap for creating our Ubuntu prebuilt images installs the linux-firmware package before this driver is downloaded and extracted.  When "apt-get update" is ran it will overwrite the 3rd party driver causing an error when the Laird modules are loaded.  Reference [https://github.com/Gateworks/ubuntu-rootfs/blob/master/ubuntu-rootfs.sh this link].
    68190
    69 [=#drivers]
    70191== Drivers
    71192
    72 [=#wifi]
    73193=== !WiFi
    74194The SDIO !WiFi functionality is supported by the mainline {{{brcmfmac}}} (Full MAC) driver present in Linux 4.1+
     
    101221
    102222
    103 [=#bluetooth]
    104223=== Bluetooth
    105224Bluetooth functionality is provided by a UART based Bluetooth HCI (Host Controller Interface).