The Wi2Wi W2CBW003 is a highly integrated module that provides both Wifi and Bluetooth radios for embedded designs. This module is ideal for embedded designs, as it provides a lot of functionality in a small package and includes standard interfaces like SPI, SDIO and serial that connect with most embedded CPUs. With the availability of modules like the W2CBW003 and standard drivers in the Linux kernel, including radio functionality in an embedded device is very doable, even for low volume products. Wi2Wi provides an evaluation board for the W2CBW003 with a SDIO connector, UART connector, and BT Audio Connectors. For this review, the eval board was connected to a Marvel PXA270 ARM processor, and evaluated with current Linux and associated software.
W2CBW003 Overview
The W2CBW003 module integrates both WiFi and Bluetooth functionality in a 12mm x 12mm x 1.6mm package. The WiFi portion is based on the Marvell 88W8686, and the Bluetooth on the CSR BC04. Both of these components are well supported by Open Source software. Some other features include:
- Separate Antennas for WiFi and BT.
- ROHS compliant
- Single Supply at 3.3V
- 802.11g support (54Mbps)
- Both SPI and SDIO interfaces for WiFi
- UART interface for BT
- PCM audio interface for BT
Pictures of the module and the demo board are shown below.
Evaluation System Configuration
The test software included with the Wi2Wi eval board is for a Windows PC, is provided in binary format only, and was not used in this review. For this review, I plugged the W2CBW003 demo board into a Compulab cm-x270 board (PXA270 cpu) running a 2.6.29-rc7 Linux kernel and a recent OpenEmbedded Angstrom distribution. With the exception of the Marvell Wifi Firmware, all software in this setup is Open Source and is available in the Linux kernel, and as packages in the OpenEmbedded Project.
When booting the kernel, you will see the following messages:
mmc0: new SDIO card at address 0001 libertas_sdio mmc0:0001:1: firmware: requesting sd8686_helper.bin libertas_sdio mmc0:0001:1: firmware: requesting sd8686.bin libertas: 00:19:88:06:0b:2e, fw 9.70.3p25, cap 0x00000303 eth2 (libertas_sdio): not using net_device_ops yet libertas: PREP_CMD: command 0x00a3 failed: 2 libertas: PREP_CMD: command 0x00a3 failed: 2 libertas: eth2: Marvell WLAN 802.11 adapter
The “command 0x00a3 failed” messages are harmless, and have to do with features that are not supported. After the system boots, you will now see a new ethX network device:
root@cm-x270:~# ifconfig -a ... eth2 Link encap:Ethernet HWaddr 00:19:88:06:0B:2E BROADCAST MULTICAST MTU:1500 Metric:1 RX packets:65902 errors:0 dropped:0 overruns:0 frame:0 TX packets:1758 errors:0 dropped:0 overruns:0 carrier:0 collisions:0 txqueuelen:1000 RX bytes:13550002 (12.9 MiB) TX bytes:251627 (245.7 KiB)
The “iwlist eth2 scanning” command will list available access points.
Connecting to Open WiFi Networks
A connection to an open wifi network can be accomplished by placing the following in /etc/network/interfaces:
/etc/network/interfaces: iface eth1 inet dhcp wireless_mode managed wireless_essid any
And now execute “ifup eth2”:
root@cm-x270:~# ifup eth2 udhcpc (v1.13.2) started run-parts: /etc/udhcpc.d/00avahi-autoipd exited with code 1 Sending discover... Sending select for 192.168.1.115... Lease of 192.168.1.115 obtained, lease time 86400 run-parts: /etc/udhcpc.d/00avahi-autoipd exited with code 1 adding dns 208.67.222.222 adding dns 208.67.220.220 root@cm-x270:~# iwlist eth2 iwlist: unknown command `eth2' (check 'iwlist --help'). root@cm-x270:~# iwconfig eth2 eth2 IEEE 802.11b/g ESSID:"bec3" Mode:Managed Frequency:2.437 GHz Access Point: 00:18:39:C1:AD:4A Bit Rate:1 Mb/s Tx-Power=13 dBm Retry short limit:8 RTS thr=2347 B Fragment thr=2346 B Encryption key:off Power Management:off Link Quality=84/100 Signal level=-37 dBm Noise level=-87 dBm Rx invalid nwid:0 Rx invalid crypt:14707457 Rx invalid frag:0 Tx excessive retries:58 Invalid misc:3 Missed beacon:0
WPA Secured WiFi Networks
The OpenEmbedded console image includes the WPA Supplicant packages which is used to manage wireless connections to secured networks. To set up the system for WPA encryption, modify the following files:
/etc/network/interfaces: iface eth2 inet dhcp wpa-conf /etc/wpa_supplicant/wpa_supplicant.conf wpa-driver wext
/etc/wpa_supplicant/wpa_supplicant.conf: ctrl_interface=/var/run/wpa_supplicant ctrl_interface_group=0 eapol_version=1 ap_scan=1 fast_reauth=1 network={ ssid="bec" proto=WPA2 key_mgmt=WPA-PSK pairwise=CCMP TKIP group=CCMP TKIP scan_ssid=1 psk="ascii passphrase" priority=10 }
Then, execute “ifup eth2”, and you should see something like:
root@cm-x270:~# ifup eth2 WPA: Configuring Interface udhcpc (v1.13.2) started run-parts: /etc/udhcpc.d/00avahi-autoipd exited with code 1 Sending discover... Sending select for 192.168.1.115... Lease of 192.168.1.115 obtained, lease time 86400 run-parts: /etc/udhcpc.d/00avahi-autoipd exited with code 1 adding dns 208.67.222.222 adding dns 208.67.220.220
root@cm-x270:~# iwconfig eth2 eth2 IEEE 802.11b/g ESSID:"bec" Mode:Managed Frequency:2.412 GHz Access Point: 00:40:10:10:00:03 Bit Rate:1 Mb/s Tx-Power=13 dBm Retry short limit:8 RTS thr=2347 B Fragment thr=2346 B Encryption key:<too big> Security mode:open Power Management:off Link Quality=64/100 Signal level=-68 dBm Noise level=-89 dBm Rx invalid nwid:0 Rx invalid crypt:-1463809279 Rx invalid frag:0 Tx excessive retries:22524 Invalid misc:3 Missed beacon:0
Other Observations
With the above networks, the bec access point was much further away than the bec3 AP, so you will notice the difference in link quality. “iwlist eth2 rate” can be used to list the current connection rate. When the network is idle, it sits at 1Mb/s. When downloading a large file, it will climb to 36 or 54Mb/s, depending on link quality.
Production Issues
The review demonstrates that it is fairly simple to set up a demo quality Embedded Linux system with WiFi. Some of the issues that would likely need addressed for a production system include link management, test software for certification, and power management.
There are several ways to programatically control WPA Supplicant including linking to the wpa supplicant control interface, or using DBus. There are several WiFi management applications available including Gnome NetworkManager (used in desktop systems), and connman which seems a little better suited for embedded systems.
Unless you use a completely pre-certified module + antenna solution, you will likely need to do some level of agency certification. As many products use a custom antenna, this is an important issue to consider and plan for. While Marvell provides test software and firmware, it will likely require some work, as their software is designed to be used with their in-house drivers rather than the libertas driver which is available with modern kernels.
Also, if you want to minimize the power usage, some work will be required to figure out the power modes supported, and how to implement/control them. With this module, the Wifi and BT portions run off the same crystal, so if you only want the BT active, you will need to actively power manage the Wifi portion to a low power state instead of completely disabling it.
Conclusion
TheW2CBW003 module is an attractive solution for products that need WiFi functionality. With the availability of modules like this, and mainstream open source software, the technology is available to about anyone, including low volume manufacturers. Standard interfaces such as SDIO make it possible to interface this module with about any modern ARM processor that can run Linux. Software support in the Linux kernel, wpa supplicant, and the Linux wireless tools provide the needed software support to implement a very complex system with relatively little effort.
Hi,
Thanks for the test. It looks very interesting.
Where can I find the W2CBW003 test board pictured in this article? Is it freely available?
Thanks!
Comments are closed.