Hello,
I have been having issues using the LM006 with the iMX6 running the OpenEmbedded Linux. I have seen my issues using the Apalis Evaluation board as well as the Ixora Carrier board. I have seen my issue running my own builds of the angstrom-qt5-x11-image image from the Apalis-iMX6_LXDE-Image_2.8b4.129-20181005 tag. I have also confirmed these issues are present on the following image from Toradex:
https://developer1.toradex.com/files/toradex-dev/uploads/media/Colibri/Linux/Images/old/Apalis-iMX6_LXDE-Image_2.8b3.111-20180626.tar.bz2
For this post, I’m describing exactly what I see using this Toradex image so that I am using something known.
First I confirm that I’m using the default u-boot environment:
Apalis iMX6 # env default -a
## Resetting to default environment
Apalis iMX6 # saveenv
Saving Environment to MMC…
Writing to MMC(0)… done
Apalis iMX6 #
Then I carry out an upgrade from the SD card of the Apalis-iMX6_LXDE-Image_2.8b3.111-20180626.tar.bz2 image. Once the update completes, I plug in the LM006 device and I see the following output indicating success:
root@apalis-imx6:~# [ 99.604926] usb 1-1.1.1: new high-speed USB device number 4 using ci_hdrc
[ 100.064736] usb 1-1.1.1: Vendor: Realtek
[ 100.068758] usb 1-1.1.1: Product: 802.11n WLAN Adapter
[ 100.073923] usb 1-1.1.1: rtl8192cu_parse_efuse: dumping efuse (0x80 bytes):
[ 100.080958] usb 1-1.1.1: 00: 29 81 00 74 cd 00 00 00
[ 100.085988] usb 1-1.1.1: 08: ff 00 da 0b 76 81 03 41
[ 100.090990] usb 1-1.1.1: 10: 32 00 85 62 9e ad 34 c9
[ 100.096059] usb 1-1.1.1: 18: f0 87 a8 3d 0a 03 52 65
[ 100.101047] usb 1-1.1.1: 20: 61 6c 74 65 6b 00 16 03
[ 100.106078] usb 1-1.1.1: 28: 38 30 32 2e 31 31 6e 20
[ 100.111065] usb 1-1.1.1: 30: 57 4c 41 4e 20 41 64 61
[ 100.116109] usb 1-1.1.1: 38: 70 74 65 72 00 00 00 00
[ 100.121097] usb 1-1.1.1: 40: 00 00 00 00 00 00 00 00
[ 100.126121] usb 1-1.1.1: 48: 00 00 00 00 00 00 00 00
[ 100.131109] usb 1-1.1.1: 50: 00 00 00 00 00 00 00 00
[ 100.136148] usb 1-1.1.1: 58: 06 00 2a 2a 2a 00 00 00
[ 100.141135] usb 1-1.1.1: 60: 2a 2a 2a 00 00 00 00 00
[ 100.146159] usb 1-1.1.1: 68: 00 00 00 00 04 04 04 00
[ 100.151146] usb 1-1.1.1: 70: 00 00 00 00 00 02 00 00
[ 100.156183] usb 1-1.1.1: 78: 10 00 00 00 36 00 81 00
[ 100.161180] usb 1-1.1.1: RTL8188CU rev A (TSMC) 1T1R, TX queues 2, WiFi=1, BT=0, GPS=0, HI PA=0
[ 100.169939] usb 1-1.1.1: RTL8188CU MAC: 34:c9:f0:87:a8:3d
[ 100.175399] usb 1-1.1.1: rtl8xxxu: Loading firmware rtlwifi/rtl8192cufw_TMSC.bin
[ 100.192681] usb 1-1.1.1: Firmware revision 80.0 (signature 0x88c1)
[ 100.809381] usbcore: registered new interface driver rtl8xxxu
root@apalis-imx6:~# connmanctl enable wifi
[ 147.219674] IPv6: ADDRCONF(NETDEV_UP): wlan0: link is not ready
Enabled wifi
root@apalis-imx6:~# [ 149.661744] random: crng init done
root@apalis-imx6:~# ifconfig wlan0
wlan0 Link encap:Ethernet HWaddr 34:C9:F0:87:A8:3D
UP BROADCAST MULTICAST MTU:1500 Metric:1
RX packets:0 errors:0 dropped:0 overruns:0 frame:0
TX packets:0 errors:0 dropped:0 overruns:0 carrier:0
collisions:0 txqueuelen:1000
RX bytes:0 (0.0 B) TX bytes:0 (0.0 B)
root@apalis-imx6:~#
So all good so far. Next I just do a reboot and this is where I see the failure. The LM006 has failed to initialize. Here is the relevant information from the boot log indicating the specific failure (interleaved with some other information from the boot):
[ 8.571322] usb 1-1.1.1: Vendor: Realtek
[ 8.581890] usb 1-1.1.1: Product: 802.11n WLAN Adapter
[ 8.593797] usb 1-1.1.1: rtl8192cu_parse_efuse: dumping efuse (0x80 bytes):
[ 8.607322] usb 1-1.1.1: 00: 29 81 00 74 cd 00 00 00
[ 8.618622] usb 1-1.1.1: 08: ff 00 da 0b 76 81 03 41
[ 8.630392] usb 1-1.1.1: 10: 32 00 85 62 9e ad 34 c9
[ 8.641366] usb 1-1.1.1: 18: f0 87 a8 3d 0a 03 52 65
[ 8.654280] usb 1-1.1.1: 20: 61 6c 74 65 6b 00 16 03
[ 8.665644] usb 1-1.1.1: 28: 38 30 32 2e 31 31 6e 20
[ 8.676611] usb 1-1.1.1: 30: 57 4c 41 4e 20 41 64 61
[ 8.689459] usb 1-1.1.1: 38: 70 74 65 72 00 00 00 00
[ 8.701393] usb 1-1.1.1: 40: 00 00 00 00 00 00 00 00
[ 8.712577] usb 1-1.1.1: 48: 00 00 00 00 00 00 00 00
[ 8.724308] usb 1-1.1.1: 50: 00 00 00 00 00 00 00 00
[ 8.724316] usb 1-1.1.1: 58: 06 00 2a 2a 2a 00 00 00
[ 8.724336] usb 1-1.1.1: 60: 2a 2a 2a 00 00 00 00 00
[ 8.724355] usb 1-1.1.1: 68: 00 00 00 00 04 04 04 00
[ 8.724369] usb 1-1.1.1: 70: 00 00 00 00 00 02 00 00
[ 8.724386] usb 1-1.1.1: 78: 10 00 00 00 36 00 81 00
[ 8.724418] usb 1-1.1.1: RTL8188CU rev A (TSMC) 1T1R, TX queues 2, WiFi=1, BT=0, GPS=0, HI PA=0
[ 8.724428] usb 1-1.1.1: RTL8188CU MAC: 34:c9:f0:87:a8:3d
[ 8.724436] usb 1-1.1.1: rtl8xxxu: Loading firmware rtlwifi/rtl8192cufw_TMSC.bin
[ 8.965763] usb 1-1.1.1: Firmware revision 80.0 (signature 0x88c1)
[ 9.020967] usb 1-1.1.1: rtl8xxxu_writeN: Failed to write block at addr: 1d80 size: 0080
[ OK ] Reached target Sockets.
[ OK ] Reached target Basic System.
Starting RPC Bind Service...
[ 9.176277] ERROR: v4l2 capture: slave not found! V4L2_CID_HUE
[ 9.187588] ERROR: v4l2 capture: slave not found! V4L2_CID_HUE
[ 9.188547] ERROR: v4l2 capture: slave not found! V4L2_CID_HUE
Starting Telephony service...
[ 9.234837] FAT-fs (mmcblk2p1): Volume was not properly unmounted. Some data may be corrupt. Please run fsck.
[ OK ] Reached target Containers.
Starting Login Service...
[ OK ] Started Timestamping service.
Starting Avahi mDNS/DNS-SD Stack...
Starting Save/Restore Sound Card State...
Starting Load default USB gadget schema g1.schema...
[ 9.431462] using random self ethernet address
[ 9.440862] using random host ethernet address
[ OK ] Started D-Bus System Message Bus.
[ 9.526102] rtl8xxxu: probe of 1-1.1.1:1.0 failed with error -11
[ 9.539496] usbcore: registered new interface driver rtl8xxxu
[ OK ] Started Telephony service.
[ 9.684379] Bluetooth: Core ver 2.22
[ 9.693212] NET: Registered protocol family 31
[ 9.702684] Bluetooth: HCI device and connection manager initialized
[ 9.704419] Bluetooth: HCI socket layer initialized
[ 9.704429] Bluetooth: L2CAP socket layer initialized
[ 9.704482] Bluetooth: SCO socket layer initialized
[ OK ] Started Avahi mDNS/DNS-SD Stack.
Starting Connection service...
[ OK ] Started RPC Bind Service.
[ OK ] Started Save/Restore Sound Card State.
[ OK ] Started Connection service.
[ 10.054971] Micrel KSZ9031 Gigabit PHY 2188000.ethernet-1:07: attached PHY driver [Micrel KSZ9031 Gigabit PHY] (mii_bus:phy_addr=2188000.ethernet-1:07, irq=122)
[ 10.055166] IPv6: ADDRCONF(NETDEV_UP): eth0: link is not ready
[ 10.056837] usb0: HOST MAC 00:14:2d:ff:ff:fe
[ 10.057134] usb0: MAC 00:14:2d:ff:ff:ff
This problem has not been perfectly consistent across different images but I can always reproduce it in some way. I describe this 2.8.3 image in order to show that there is a problem on something that you can reproduce. On my own build of the 2.8b4 Qt5 image, the problem seems even worse in that I usually can not even get the LM006 to initialize properly by unplugging and plugging it back in after I see this failure. But on this 2.8.3 LXDE image, after the initial failure to initialize on boot, I can then unplug it and plug it back in and it usually initiallizes properly. However, either way it is definitely expected that we can leave the device plugged in across reboots and power cycles and still use WiFi.
Are you also experiencing this issue on the iMX6? If not, do you have any ideas of what could be different with my setup?
As a side note, I had previously asked this question and I thought I was causing it due to my use of usb from u-boot. However, I have been able to show that I still can produce an issue with an unmodified u-boot and u-boot environment.