yoq Posted December 9, 2019 Posted December 9, 2019 Is it possible that there have been some image changes that broke the XR819 wifi completely? The available images for download on the Armbian page (5.3 server, and 5.4 minimal) as well as a custom built "legacy" branch linux-4.19 image all show the same behavior, The wlan0 interface is not active and it's not possible to bring it up. And dmesg shows that module has been initialized but not much more. Armbianmonitor support info: 5.3.9 official buster server image: http://ix.io/240Y 4.19.88 self-built, two days ago, legacy branch: http://ix.io/240U Everything below is from the official image, but the 4.19 image shows the exact same It is definitely not a hardware issue, I have a SD card with a an older 4.19.72 image (when the branch was still called "next") that works just fine. ifconfig -a Spoiler root@orangepizero:~# ifconfig -a dummy0: flags=130<BROADCAST,NOARP> mtu 1500 ether 4e:d7:ef:97:fe:24 txqueuelen 1000 (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 eth0: flags=4163<UP,BROADCAST,RUNNING,MULTICAST> mtu 1500 inet 10.9.9.74 netmask 255.255.255.0 broadcast 10.9.9.255 inet6 fdaa::140d:159f:ef8e:f4ab prefixlen 64 scopeid 0x0<global> inet6 fe80::dad5:d85e:5d75:f4ef prefixlen 64 scopeid 0x20<link> ether 02:42:a5:9f:f1:6a txqueuelen 1000 (Ethernet) RX packets 214 bytes 21011 (20.5 KiB) RX errors 0 dropped 0 overruns 0 frame 0 TX packets 134 bytes 18689 (18.2 KiB) TX errors 0 dropped 0 overruns 0 carrier 0 collisions 0 device interrupt 39 lo: flags=73<UP,LOOPBACK,RUNNING> mtu 65536 inet 127.0.0.1 netmask 255.0.0.0 inet6 ::1 prefixlen 128 scopeid 0x10<host> loop txqueuelen 1000 (Local Loopback) 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 wlan0: flags=4098<BROADCAST,MULTICAST> mtu 1500 ether 3a:7d:bf:4b:79:83 txqueuelen 1000 (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 ifconfig Spoiler root@orangepizero:~# ifconfig eth0: flags=4163<UP,BROADCAST,RUNNING,MULTICAST> mtu 1500 inet 10.9.9.74 netmask 255.255.255.0 broadcast 10.9.9.255 inet6 fe80::a827:65fd:f762:999a prefixlen 64 scopeid 0x20<link> inet6 fdaa::1fd5:49e8:c762:1287 prefixlen 64 scopeid 0x0<global> ether 02:42:a5:9f:f1:6a txqueuelen 1000 (Ethernet) RX packets 1493 bytes 114739 (112.0 KiB) RX errors 0 dropped 0 overruns 0 frame 0 TX packets 1372 bytes 251320 (245.4 KiB) TX errors 0 dropped 0 overruns 0 carrier 0 collisions 0 device interrupt 38 lo: flags=73<UP,LOOPBACK,RUNNING> mtu 65536 inet 127.0.0.1 netmask 255.0.0.0 inet6 ::1 prefixlen 128 scopeid 0x10<host> loop txqueuelen 1000 (Local Loopback) 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@orangepizero:~# ifconfig wlan0 up SIOCSIFFLAGS: Invalid argument root@orangepizero:~# rfkill list 0: phy0: Wireless LAN Soft blocked: no Hard blocked: no root@orangepizero:~# journalctl -b | grep xradio Nov 19 08:08:00 orangepizero kernel: xradio_wlan mmc1:0001:1: Input buffers: 30 x 1632 bytes Nov 19 08:08:00 orangepizero kernel: xradio_wlan mmc1:0001:1: Firmware Label:XR_C01.08.0043 Jun 6 2016 20:41:04 Nov 19 08:08:28 orangepizero NetworkManager[1057]: <info> [1574150908.3204] rfkill0: found WiFi radio killswitch (at /sys/devices/platform/soc/1c10000.mmc/mmc_host/mmc1/mmc1:0001/mmc1:0001:1/ieee80211/phy0/rfkill0) (driver xradio_wlan) root@orangepizero:~# uname -a Linux orangepizero 5.3.9-sunxi #19.11.3 SMP Mon Nov 18 18:49:43 CET 2019 armv7l GNU/Linux
Tido Posted December 10, 2019 Posted December 10, 2019 pls use search forum, right hand top corner. Thank you // sent from mobile phone //
yoq Posted December 10, 2019 Author Posted December 10, 2019 2 hours ago, Tido said: pls use search forum, right hand top corner. Thank you I did, and did not find anything relevant to this particular problem. Can you point me to it? I'm not complaining about the general unreliability of the XR819, I am well aware.
Tido Posted December 10, 2019 Posted December 10, 2019 if you are not low level programmer, this is your best bet: https://forum.armbian.com/topic/8697-wifi-installation-in-orange-pi-pc-in-mainline-kernel/?tab=comments#comment-65304
yoq Posted December 10, 2019 Author Posted December 10, 2019 I've done some work on kernel drivers and uboot in the past, that would not be a problem. My point is that the XR819 worked on Armbian as good as the chip allows two months ago, and now the driver doesn't even initialize properly. The fact that it stopped working on the old 4.19 kernel branch too, makes me think this is probably not a problem with kernel patches but with the system image. I'm happy to help, but I'm looking for some pointers.
martinayotte Posted December 10, 2019 Posted December 10, 2019 1 hour ago, yoq said: but I'm looking for some pointers. Did you tried to disable NetworkManager and use "old school" /etc/network/interface ?
raschid Posted December 10, 2019 Posted December 10, 2019 5 hours ago, yoq said: The fact that it stopped working on the old 4.19 kernel branch too, makes me think this is probably not a problem with kernel patches but with the system image. Yeah. XR819-Wifi stopped working with stretch and buster, but still works with bionic. Here's my syslog with a buster build: ov 30 16:45:56 localhost NetworkManager[1116]: <info> [1575132356.6690] wifi-nl80211: (wlan0): using nl80211 for WiFi device control Nov 30 16:45:58 localhost NetworkManager[1116]: <info> [1575132358.1449] device (wlan0): driver supports Access Point (AP) mode Nov 30 16:45:58 localhost NetworkManager[1116]: <info> [1575132358.1555] manager: (wlan0): new 802.11 WiFi device (/org/freedesktop/NetworkManager/Devices/4) Nov 30 16:45:58 localhost NetworkManager[1116]: <info> [1575132358.1656] device (wlan0): state change: unmanaged -> unavailable (reason 'managed', sys-iface-state: 'external') Nov 30 16:45:58 localhost kernel: [ 34.419112] IPv6: ADDRCONF(NETDEV_UP): wlan0: link is not ready Nov 30 16:45:58 localhost kernel: [ 34.423469] IPv6: ADDRCONF(NETDEV_UP): wlan0: link is not ready Nov 30 16:45:58 localhost NetworkManager[1116]: <info> [1575132358.1790] device (wlan0): set-hw-addr: set MAC address to AA:88:8F:8F:8F:AF (scanning) Nov 30 16:45:58 localhost NetworkManager[1116]: <info> [1575132358.2924] device (wlan0): supplicant interface state: init -> starting Nov 30 16:45:58 localhost wpa_supplicant[1115]: Could not set interface wlan0 flags (UP): Invalid argument Nov 30 16:45:58 localhost wpa_supplicant[1115]: nl80211: Could not set interface 'wlan0' UP Nov 30 16:45:58 localhost wpa_supplicant[1115]: nl80211: deinit ifname=wlan0 disabled_11b_rates=0 Nov 30 16:45:58 localhost wpa_supplicant[1115]: Could not set interface wlan0 flags (UP): Invalid argument Nov 30 16:45:58 localhost wpa_supplicant[1115]: WEXT: Could not set interface 'wlan0' UP Nov 30 16:45:58 localhost wpa_supplicant[1115]: wlan0: Failed to initialize driver interface Nov 30 16:45:58 localhost NetworkManager[1116]: <error> [1575132358.3304] sup-iface[0x1175c18,wlan0]: error adding interface: wpa_supplicant couldn't grab this interface. Nov 30 16:45:58 localhost NetworkManager[1116]: <info> [1575132358.3309] device (wlan0): supplicant interface state: starting -> down Nov 30 17:21:39 localhost NetworkManager[1116]: <warn> [1575134499.3085] device (wlan0): re-acquiring supplicant interface (#1). 1
martinayotte Posted December 10, 2019 Posted December 10, 2019 13 minutes ago, raschid said: XR819-Wifi stopped working with stretch and buster, but still works with bionic. In my case, I'm using "old school" /etc/network/interface, running Stretch 5.4.2, and WiFi running properly as soon as I disabled NetworkManager service. 1
raschid Posted December 10, 2019 Posted December 10, 2019 19 minutes ago, martinayotte said: "old school" /etc/network/interface So all Ubuntu version work with NM (bionic, disco, eoan), both debian version currently do not (regardless of kernel version) but work with with /etc/network/interfaces. So @yoq I would suggest you stick with an ubuntu flavour for the time being
yoq Posted December 10, 2019 Author Posted December 10, 2019 Thanks, that turned out be a good place to look. On a hunch, I tried swapping out wpa_supplicant for iwd as the wifi daemon for NetworkManager, and that did the trick. apt install iwd systemctl disable wpa_supplicant echo -e "\n[device]\nwifi.backend=iwd\n" >> /etc/NetworkManager/NetworkManager.conf I may just stick with iwd, but the root cause is probably that the aging xradio driver is missing support for some ioctl and it may just be a matter of time until a future release of iwd will send that one too.
dolphs Posted December 10, 2019 Posted December 10, 2019 @yoq - thanks for this , currently have an OPiZero LTS on its way , perhaps following link is interesting material too rgd iwd
sanja Posted December 11, 2019 Posted December 11, 2019 11 hours ago, yoq said: Thanks, that turned out be a good place to look. On a hunch, I tried swapping out wpa_supplicant for iwd @yoq, could you please provide a summary of what needs to be done to enable WiFi connectivity in OPi Zero with Buster? Thanks in advance.
yoq Posted December 11, 2019 Author Posted December 11, 2019 I don't think I had to run anything else than the 3 lines I posted and reboot.
sanja Posted December 13, 2019 Posted December 13, 2019 Thanks! Note to others who may have encountered the same issue: (Assuming that you have connected to OPi Zero via USB-TTL converter and have no LAN/WLAN connectivity) Save deb packages obtained from https://packages.debian.org/buster/armhf/iwd/download and https://packages.debian.org/buster/armhf/libell0/download to usb flash. Plug that flash into Pi Zero, mount with the command mount /dev/sda1 /some/empty/dir cd /some/empty/dir dpkg - i libell*.deb dpkg -i iwd*.deb Reboot and run nmtui-connect as usual to see the list of WiFi networks and connect to yours.
karabek Posted December 18, 2019 Posted December 18, 2019 Users wanting to use debian builds with NetworkManager/wpa_supplicant should add the following lines to /etc/NetworkManager/NetworkManager.conf: [device] wifi.scan-rand-mac-address=no Ubuntu builds (bionic, focal) already contain these lines. This seems to solve the current issue on systems with the xradio wifi chip (opi zero, nanopi duo etc.) 2
nairn62 Posted December 29, 2019 Posted December 29, 2019 On 12/13/2019 at 7:08 PM, sanja said: Thanks! Note to others who may have encountered the same issue: (Assuming that you have connected to OPi Zero via USB-TTL converter and have no LAN/WLAN connectivity) Save deb packages obtained from https://packages.debian.org/buster/armhf/iwd/download and https://packages.debian.org/buster/armhf/libell0/download to usb flash. Plug that flash into Pi Zero, mount with the command mount /dev/sda1 /some/empty/dir cd /some/empty/dir dpkg - i libell*.deb dpkg -i iwd*.deb Reboot and run nmtui-connect as usual to see the list of WiFi networks and connect to yours. This crashed my Orange Pi Zero LTS
yoq Posted December 31, 2019 Author Posted December 31, 2019 @nairn62 the solution in the post above yours is the easiest, and addresses the issue directly (xradio driver doesn't allow setting mac from user space) - iwd is still not quite ready
rusefi Posted June 8, 2020 Posted June 8, 2020 Happy 2020! The world is so different from 2019 I have just installed Armbian_20.05.1_Orangepizero_buster_current_5.4.43.img.xz.torrent on my OPi Zero and WiFi just works right away. What kind of "wireless connection issues are expected"? is the warning like the one on https://www.armbian.com/orange-pi-zero/ outdated now?
Werner Posted June 8, 2020 Posted June 8, 2020 2 hours ago, rusefi said: What kind of "wireless connection issues are expected"? is the warning like the one on https://www.armbian.com/orange-pi-zero/ outdated now? I think we do not have enough feedback yet if the XR819 with the new drivers is good enough to be considered stable. Needs to be watched over a longer period of time to see if it stays connected. /Offtopic: If you plan to play with Bullseye or Focal make sure to download a 20.05.2 image as the .1 images on ARMHF most likely broken due to initramfs issues.
rusefi Posted June 8, 2020 Posted June 8, 2020 32 minutes ago, Werner said: I think we do not have enough feedback yet if the XR819 with the new drivers is good enough to be considered stable. Any specific test I can run to help?
Werner Posted June 8, 2020 Posted June 8, 2020 8 minutes ago, rusefi said: Any specific test I can run to help? Not really. Just keep monitoring it for a few days/weeks for issues like packet loss, connectivity loss...common stuff to say.
Tido Posted June 8, 2020 Posted June 8, 2020 17 hours ago, rusefi said: and WiFi just works right away. Your happiness is maybe because of his work: @yoq https://forum.armbian.com/topic/13807-improved-xr819-driver/
peterbmckinley Posted November 21, 2020 Posted November 21, 2020 On 6/8/2020 at 5:58 AM, Werner said: Not really. Just keep monitoring it for a few days/weeks for issues like packet loss, connectivity loss...common stuff to say. For what its worth, I've been streaming a 320kbps internet radio station continuously on an Orange Pi Zero running Armbian Buster (kernel 5.8.5) for about a month and it literally never misses a beat. So my personal experience is that neither the XR819 hardware nor the driver version that Armbian is currently using in 5.8.5 are intrinsically flawed. It is for this reason I'd love to see support for the XR819 finally make it into mainline. I am planning to use Orange Pi Zero in a significant project, and the somewhat unresolved formal status of the XR819 driver is the only fly in what is otherwise the very satisfactory ointment that is the OPi0 platform. Peter
Recommended Posts