]> git.ipfire.org Git - thirdparty/openwrt.git/commitdiff
ath79: add support for Ubiquiti NanoStation Loco M (XW v2) 23912/head
authorMatthias Urlichs <matthias@urlichs.de>
Mon, 22 Jun 2026 09:44:20 +0000 (11:44 +0200)
committerRobert Marko <robert.marko@sartura.hr>
Wed, 1 Jul 2026 17:02:40 +0000 (19:02 +0200)
This commit adds support for the NanoStation Loco M2/M5 XW devices
on the ath79 target with test date (label on the packaging, not the
device) later than October 2017.

To discover whether you have the new version, open a console on the
stock web interface and run `dmesg | grep AR803`. New versions print
AR8035, v1 shows AR8032.

Specifications:

 - AR9342 (rev 3) SoC @ 535 MHz
 - 64 MB RAM
 - 8 MB SPI flash
 - 1x 10/100 Mbps Ethernet, 24 Vdc PoE-in
 - AR8035 switch
 - 2T2R 5 GHz radio, 22 dBm
 - 13 dBi built-in directional antenna
 - POWER/LAN green LEDs
 - 4x RSSI LEDs (red, orange, green, green)
 - UART (115200 8N1) on PCB

Flashing via TFTP:

 - Use a pointy tool (e.g., pen cap, paper clip) and keep the reset
   button on the device pressed
 - Power on the device via PoE (keep reset button pressed)
 - Keep pressing until LEDs flash alternatively LED1+LED3 =>
   LED2+LED4 => LED1+LED3, etc.
 - Release reset button
 - The device starts a TFTP server at 192.168.1.20
 - Set a static IP on the computer (e.g., 192.168.1.21/24)
 - Upload via tftp the factory image:
   $ tftp 192.168.1.20
   tftp> bin
   tftp> put openwrt-ath79-generic-xxxxx-ubnt_nanostation-loco-m-xw-v2-squashfs-factory.bin

MAC addresses: stored on Flash, in the "art" partition.

Signed-off-by: Matthias Urlichs <matthias@urlichs.de>
Link: https://github.com/openwrt/openwrt/pull/23912
Signed-off-by: Robert Marko <robert.marko@sartura.hr>
target/linux/ath79/dts/ar9342_ubnt_nanostation-loco-m-xw-v2.dts [new file with mode: 0644]
target/linux/ath79/generic/base-files/etc/board.d/01_leds
target/linux/ath79/generic/base-files/etc/board.d/02_network
target/linux/ath79/image/generic-ubnt.mk

diff --git a/target/linux/ath79/dts/ar9342_ubnt_nanostation-loco-m-xw-v2.dts b/target/linux/ath79/dts/ar9342_ubnt_nanostation-loco-m-xw-v2.dts
new file mode 100644 (file)
index 0000000..0ffe4d2
--- /dev/null
@@ -0,0 +1,32 @@
+// SPDX-License-Identifier: GPL-2.0-or-later OR MIT
+
+#include "ar9342_ubnt_xw_rssileds.dtsi"
+
+/ {
+       compatible = "ubnt,nanostation-loco-m-xw-v2", "ubnt,xw", "qca,ar9342";
+       model = "Ubiquiti Nanostation Loco M (XW) v2";
+};
+
+&mdio0 {
+       status = "okay";
+
+       phy4: ethernet-phy@4 {
+               reg = <4>;
+       };
+};
+
+&eth0 {
+       status = "okay";
+
+       /* default for ar934x, except for 1000M and 10M */
+       pll-data = <0x02000000 0x00000101 0x00001313>;
+
+       phy-mode = "rgmii-id";
+       phy-handle = <&phy4>;
+
+       gmac-config {
+               device = <&gmac>;
+               rxd-delay = <3>;
+               rxdv-delay = <3>;
+       };
+};
index d12d429b8628c6bc9df952afc252504ab8794f02..29c1198206d3af13a13ddfbc64e33a8b1445a040 100644 (file)
@@ -511,6 +511,7 @@ ubnt,powerbeam-5ac-gen2)
        ;;
 ubnt,bullet-m-xw|\
 ubnt,nanostation-loco-m-xw|\
+ubnt,nanostation-loco-m-xw-v2|\
 ubnt,nanostation-m-xw|\
 ubnt,powerbeam-m2-xw|\
 ubnt,powerbeam-m5-xw|\
index 7194d16f24d6400c4a9ef5d462841be3130866c2..5f67e47c0bac53cce2ce64b047c9e9b2670f46d5 100644 (file)
@@ -111,6 +111,7 @@ ath79_setup_interfaces()
        ubnt,nanobeam-ac-xc|\
        ubnt,nanostation-ac-loco|\
        ubnt,nanostation-loco-m-xw|\
+       ubnt,nanostation-loco-m-xw-v2|\
        ubnt,powerbeam-5ac-500|\
        ubnt,powerbeam-5ac-gen2|\
        ubnt,powerbeam-m2-xw|\
index 51d0aaef03ae112cbe2b30a1ee5cbe2f5bd7fd53..933007fabe0ca0a153c5640f92a56a1f9fc618dd 100644 (file)
@@ -143,6 +143,14 @@ define Device/ubnt_nanostation-loco-m-xw
 endef
 TARGET_DEVICES += ubnt_nanostation-loco-m-xw
 
+define Device/ubnt_nanostation-loco-m-xw-v2
+  $(Device/ubnt-xw)
+  DEVICE_MODEL := Nanostation Loco M
+  DEVICE_VARIANT := XW v2
+  DEVICE_PACKAGES += rssileds -kmod-usb2
+endef
+TARGET_DEVICES += ubnt_nanostation-loco-m-xw-v2
+
 define Device/ubnt_nanostation-m-xw
   $(Device/ubnt-xw)
   DEVICE_MODEL := Nanostation M