aboutsummaryrefslogtreecommitdiffstats
path: root/target/linux/ath79/generic/base-files/etc/board.d/01_leds
Commit message (Collapse)AuthorAgeFilesLines
* ath79: enable factory.bin and adjust profile of ECB1750Michael Pratt2020-12-221-1/+0
| | | | | | | | | | | | | | | | | factory.bin was not tested for ECB1750... but it was tested on it's sister board ECB1200 The product ID for the header can be verified by inspecting the header of OEM images, or in the u-boot environment. Also: - the LAN LED is controlled directly by the AR8035 switch - the labelled (first increment) MAC for both is ethaddr (eth0) - list packages in alphabetical order - use default sysupgrade.bin recipe Signed-off-by: Michael Pratt <mcpratt@pm.me>
* ath79: add support for Senao Engenius EAP300 v2Michael Pratt2020-11-251-0/+1
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | FCC ID: A8J-EAP300A Engenius EAP300 v2 is an indoor wireless access point with a 100/10-BaseT ethernet port, 2.4 GHz wireless, internal antennas, and 802.3af PoE. **Specification:** - AR9341 - 40 MHz reference clock - 16 MB FLASH MX25L12845EMI-10G - 64 MB RAM - UART at J1 (populated) - Ethernet port with POE - internal antennas - 3 LEDs, 1 button (power, eth, wlan) (reset) **MAC addresses:** phy0 *:d3 art 0x1002 (label) eth0 *:d4 art 0x0/0x6 **Installation:** - if you get Failsafe Mode from failed flash: only use it to flash Original firmware from Engenius or risk kernel loop or halt which requires serial cable Method 1: Firmware upgrade page: OEM webpage at 192.168.1.1 username and password "admin" Navigate to "Firmware" page from left pane Click Browse and select the factory.bin image Upload and verify checksum Click Continue to confirm and wait 3 minutes Method 2: Serial to load Failsafe webpage: After connecting to serial console and rebooting... Interrupt uboot with any key pressed rapidly execute `run failsafe_boot` OR `bootm 0x9fdf0000` wait a minute connect to ethernet and navigate to "192.168.1.1/index.htm" Select the factory.bin image and upload wait about 3 minutes **Return to OEM:** If you have a serial cable, see Serial Failsafe instructions *DISCLAIMER* The Failsafe image is unique to Engenius boards. If the failsafe image is missing or damaged this will not work DO NOT downgrade to ar71xx this way, can cause kernel loop or halt The easiest way to return to the OEM software is the Failsafe image If you dont have a serial cable, you can ssh into openwrt and run `mtd -r erase fakeroot` Wait 3 minutes connect to ethernet and navigate to 192.168.1.1/index.htm select OEM firmware image from Engenius and click upgrade **TFTP recovery** (unstable / not reliable): rename initramfs to 'vmlinux-art-ramdisk' make available on TFTP server at 192.168.1.101 power board while holding or pressing reset button repeatedly NOTE: for some Engenius boards TFTP is not reliable try setting MTU to 600 and try many times **Format of OEM firmware image:** The OEM software of EAP300 v2 is a heavily modified version of Openwrt Kamikaze. One of the many modifications is to the sysupgrade program. Image verification is performed simply by the successful ungzip and untar of the supplied file and name check and header verification of the resulting contents. To form a factory.bin that is accepted by OEM Openwrt build, the kernel and rootfs must have specific names and begin with the respective headers (uImage, squashfs). Then the files must be tarballed and gzipped. The resulting binary is actually a tar.gz file in disguise. This can be verified by using binwalk on the OEM firmware images, ungzipping then untaring. The OEM upgrade script is at /etc/fwupgrade.sh. OKLI kernel loader is required because the OEM software expects the kernel size to be no greater than 1536k and otherwise the factory.bin upgrade procedure would overwrite part of the kernel when writing rootfs. Signed-off-by: Michael Pratt <mcpratt@pm.me> [clarify MAC address section, bump PKG_RELEASE for uboot-envtools] Signed-off-by: Adrian Schmutzler <freifunk@adrianschmutzler.de>
* ath79: add support for ALFA Network Pi-WiFi4Piotr Dymacz2020-11-181-0/+4
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | ALFA Network Pi-WiFi4 is a Qualcomm QCA9531 v2 based, high-power 802.11n WiFi board in Raspberry Pi 3B shape, equipped with 1x FE and 4x USB 2.0. Specifications: - Qualcomm/Atheros QCA9531 v2 - 650/400/200 MHz (CPU/DDR/AHB) - 128 MB of RAM (DDR2) - 16+ MB of flash (SPI NOR) - 1x 10/100 Mbps Ethernet - 2T2R 2.4 GHz Wi-Fi with Qorvo RFFM8228P FEM - 2x IPEX/U.FL connectors on PCB - 4x USB 2.0 Type-A - Genesys Logic GL850G 4-port USB HUB - USB power is controlled by GPIO - 5x LED (3x on PCB, 2x in RJ45, 4x driven by GPIO) - 1x button (reset) - external h/w watchdog (EM6324QYSP5B, enabled by default) - 1x micro USB Type-B for power and system console (Holtek HT42B534) - UART and GPIO (8-pin, 1.27 mm pitch) header on PCB Flash instruction: You can use sysupgrade image directly in vendor firmware which is based on LEDE/OpenWrt. Alternatively, you can use web recovery mode in U-Boot: 1. Configure PC with static IP 192.168.1.2/24. 2. Connect PC with one of RJ45 ports, press the reset button, power up device, wait for first blink of all LEDs (indicates network setup), then keep button for 3 following blinks and release it. 3. Open 192.168.1.1 address in your browser and upload sysupgrade image. Signed-off-by: Piotr Dymacz <pepe2k@gmail.com>
* ath79: Add support for Ubiquiti NanoBeam AC Gen2Nick Hainke2020-11-181-0/+1
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | CPU: Atheros AR9342 rev 3 SoC RAM: 64 MB DDR2 Flash: 16 MB NOR SPI WLAN 2.4GHz: Atheros AR9342 v3 (ath9k) WLAN 5.0GHz: QCA988X Ports: 2x GbE Flashing procedure is identical to other ubnt devices. https://openwrt.org/toh/ubiquiti/common Flashing through factory firmware 1. Ensure firmware version v8.7.0 is installed. Up/downgrade to this exact version. 2. Patch fwupdate.real binary using `hexdump -Cv /bin/ubntbox | sed 's/14 40 fe 27/00 00 00 00/g' | \ hexdump -R > /tmp/fwupdate.real` 3. Make the patched fwupdate.real binary executable using `chmod +x /tmp/fwupdate.real` 4. Copy the squashfs factory image to /tmp on the device 5. Flash OpenWrt using `/tmp/fwupdate.real -m <squashfs-factory image>` 6. Wait for the device to reboot (copied from Ubiquiti NanoBeam AC and modified) To keep it consistent, we will add the gen1 variant to the nanobeam ac gen1. Signed-off-by: Nick Hainke <vincent@systemli.org>
* ath79: add support for Qxwlan E600G v2 / E600GAC v2张鹏2020-11-121-0/+4
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | E600G v2 based on Qualcomm/Atheros QCA9531 Specification: - 650/600/200 MHz (CPU/DDR/AHB) - 128/64 MB of RAM (DDR2) - 8/16 MB of FLASH (SPI NOR) - 2T2R 2.4 GHz - 2 x 10/100 Mbps Ethernet(RJ45) - 1 x MiniPCI-e - 1 x SIM (3G/4G) - 5 x LED , 1 x Button(SW2-Reset Buttun), 1 x power input - UART(J100) header on PCB(115200 8N1) E600GAC v2 based on Qualcomm/Atheros QCA9531 + QCA9887 Specification: - 650/600/200 MHz (CPU/DDR/AHB) - 128/64 MB of RAM (DDR2) - 8/16 MB of FLASH (SPI NOR) - 2T2R 2.4 GHz - 1T1R 5 GHz - 2 x 10/100 Mbps Ethernet(RJ45) - 6 x LED (one three-color led), 2 x Button(SW2-Reset Buttun),1 x power input - UART (J100)header on PCB(115200 8N1) Flash instruction: 1.Using tftp mode with UART connection and original OpenWrt image - Configure PC with static IP 192.168.1.10 and tftp server. - Rename "openwrt-ath79-generic-xxx-squashfs-sysupgrade.bin" to "firmware.bin" and place it in tftp server directory. - Connect PC with one of LAN ports, power up the router and press key "Enter" to access U-Boot CLI. - Use the following commands to update the device to OpenWrt: run lfw - After that the device will reboot and boot to OpenWrt. - Wait until all LEDs stops flashing and use the router. 2.Using httpd mode with Web UI connection and original OpenWrt image - Configure PC with static IP 192.168.1.xxx(2-255) and tftp server. - Connect PC with one of LAN ports,press the reset button, power up the router and keep button pressed for around 6-7 seconds, until leds flashing. - Open your browser and enter 192.168.1.1,You will see the upgrade interface, select "openwrt-ath79-generic-xxx-squashfs- sysupgrade.bin" and click the upgrade button. - After that the device will reboot and boot to OpenWrt. - Wait until all LEDs stops flashing and use the router. Signed-off-by: 张鹏 <sd20@qxwlan.com> [rearrange in generic.mk, fix one case in 04_led_migration, update commit message] Signed-off-by: Adrian Schmutzler <freifunk@adrianschmutzler.de>
* ath79: add support for Qxwlan E750A v4Peng Zhang2020-10-151-1/+3
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Qxwlan E750A v4 is based on Qualcomm QCA9344. Specification: - 560/450/225 MHz (CPU/DDR/AHB) - 128 MB of RAM (DDR2) - 8/16 MB of FLASH (SPI NOR) - 2T2R 5G GHz (AR9344) - 2x 10/100 Mbps Ethernet (one port with PoE support) - 1x miniPCIe slot (USB 2.0 bus only) - 7x LED (6 driven by GPIO) - 1x button (reset) - 1x DC jack for main power input (9-48 V) - UART (J23) and LEDs (J2) headers on PCB Flash instruction: 1.Using tftp mode with UART connection and original LEDE image - Configure PC with static IP 192.168.1.10 and tftp server. - Rename "openwrt-ar71xx-generic-xxx-squashfs-sysupgrade.bin" to "firmware.bin" and place it in tftp server directory. - Connect PC with one of LAN ports, power up the router and press key "Enter" to access U-Boot CLI. - Use the following commands to update the device to LEDE: run lfw - After that the device will reboot and boot to LEDE. - Wait until all LEDs stops flashing and use the router. 2.Using httpd mode with Web UI connection and original LEDE image - Configure PC with static IP 192.168.1.xxx(2-255) and tftp server. - Connect PC with one of LAN ports,press the reset button, power up the router and keep button pressed for around 6-7 seconds, until leds flashing. - Open your browser and enter 192.168.1.1,You will see the upgrade interface, select "openwrt-ar71xx-generic-xxx-squashfs- sysupgrade.bin" and click the upgrade button. - After that the device will reboot and boot to LEDE. - Wait until all LEDs stops flashing and use the router. Signed-off-by: Peng Zhang <sd20@qxwlan.com> [cut out of bigger patch, alter use of DEVICE_VARIANT, merge case in 01_leds, use lower case for v4] Signed-off-by: Adrian Schmutzler <freifunk@adrianschmutzler.de>
* ath79: rename TP-Link TL-WPA8630P v2 (EU) to v2.0 (EU)Adrian Schmutzler2020-10-041-1/+1
| | | | | | | Since we have a v2.1 (EU) with different partitioning now, rename the v2.0 to make the difference visible to the user more directly. Signed-off-by: Adrian Schmutzler <freifunk@adrianschmutzler.de>
* ath79: add support for TP-Link TL-WPA8630P (EU) v2.1Joe Mullally2020-10-041-1/+2
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | This adds support for the TP-Link TL-WPA8630P (EU) in its v2.1 version. The only unique aspect for the firmware compared to v2 layout is the partition layout. Note that while the EU version has different partitioning for v2.0 and v2.1, the v2.1 (AU) is supported by the v2-int image. If you plan to use this device, make sure you have a look at the Wiki page to check whether the device is supported and which image needs to be taken. Specifications -------------- - QCA9563 750MHz, 2.4GHz WiFi - QCA9888 5GHz WiFi - 8MiB SPI Flash - 128MiB RAM - 3 GBit Ports (QCA8337) - PLC (QCA7550) Installation ------------ Installation is possible from the OEM web interface. Make sure to install the latest OEM firmware first, so that the PLC firmware is at the latest version. However, please also check the Wiki page for hints according to altered partitioning between OEM firmware revisions. Notes ----- The OEM firmware has 0x620000 to 0x680000 unassigned, so we leave this empty as well. It is complicated enough already ... Signed-off-by: Joe Mullally <jwmullally@gmail.com> [improve partitions, use v2 DTSI, add entry in 02_network, rewrite and extend commit message] Signed-off-by: Adrian Schmutzler <freifunk@adrianschmutzler.de>
* ath79: remove model name from LED labelsAdrian Schmutzler2020-10-021-230/+210
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Currently, we request LED labels in OpenWrt to follow the scheme modelname:color:function However, specifying the modelname at the beginning is actually entirely useless for the devices we support in OpenWrt. On the contrary, having this part actually introduces inconvenience in several aspects: - We need to ensure/check consistency with the DTS compatible - We have various exceptions where not the model name is used, but the vendor name (like tp-link), which is hard to track and justify even for core-developers - Having model-based components will not allow to share identical LED definitions in DTSI files - The inconsistency in what's used for the model part complicates several scripts, e.g. board.d/01_leds or LED migrations from ar71xx where this was even more messy Apart from our needs, upstream has deprecated the label property entirely and introduced new properties to specify color and function properties separately. However, the implementation does not appear to be ready and probably won't become ready and/or match our requirements in the foreseeable future. However, the limitation of generic LEDs to color and function properties follows the same idea pointed out above. Generic LEDs will get names like "green:status" or "red:indicator" then, and if a "devicename" is prepended, it will be the one of an internal device, like "phy1:amber:status". With this patch, we move into the same direction, and just drop the boardname from the LED labels. This allows to consolidate a few definitions in DTSI files (will be much more on ramips), and to drop a few migrations compared to ar71xx that just changed the boardname. But mainly, it will liberate us from a completely useless subject to take care of for device support review and maintenance. To also drop the boardname from existing configurations, a simple migration routine is added unconditionally. Although this seems unfamiliar at first look, a quick check in kernel for the arm/arm64 dts files revealed that while 1033 lines have labels with three parts *:*:*, still 284 actually use a two-part labelling *:*, and thus is also acceptable and not even rare there. Signed-off-by: Adrian Schmutzler <freifunk@adrianschmutzler.de>
* ath79: add support for Hak5 LAN TurtlePiotr Dymacz2020-09-281-0/+3
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Hak5 LAN Turtle is an "USB Ethernet Adapter" shaped device dedicated for sysadmins and pentesters. This device is based on Atheros AR9331 but it lacks WiFi. Support for it was first introduced in 950b278c81 (ar71xx). Two different versions of this device exist and it's up to the user to install required drivers (generic image supports only common features): - LAN Turtle 3G with Quectel UG96 3G modem - LAN Turtle SD with microSD card reader (Alcorlink AU6435R) Specifications: - Atheros AR9331 - 400/400/200 MHz (CPU/DDR/AHB) - 64 MB of RAM (DDR2) - 16 MB of flash (SPI NOR) - 1x RJ45 10/100 Mbps Ethernet (AR9331) - 1x USB 2.0 to 10/100 Ethernet bridge (Realtek RTL8152B) - 2x LED (power, system), 1x button (inside, on the PCB) - USB 2.0 Type-A plug for power and RTL8152B Flash instruction: You can use sysupgrade image directly in vendor firmware which is based on OpenWrt/LEDE. Signed-off-by: Piotr Dymacz <pepe2k@gmail.com>
* ath79: add support for ALFA Network N5QPiotr Dymacz2020-09-281-0/+9
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | ALFA Network N5Q is a successor of previous model, the N5 (outdoor CPE/AP, based on Atheros AR7240 + AR9280). New version is based on Atheros AR9344. Support for this device was first introduced in 4b0eebe9df (ar71xx target) but users are advised to migrate from ar71xx target without preserving settings as ath79 support includes some changes in network and LED default configuration. They were aligned with vendor firmware and recently added N2Q model (both Ethernet ports as LAN, labelled as LAN1 and LAN2). Specifications: - Atheros AR9344 - 550/400/200 MHz (CPU/DDR/AHB) - 64 MB of RAM (DDR2) - 16 MB of flash (SPI NOR) - 2x 10/100 Mbps Ethernet, with passive PoE support (24 V) - 2T2R 5 GHz Wi-Fi, with ext. PA (RFPA5542) and LNA, up to 27 dBm - 2x IPEX/U.FL or MMCX antenna connectors (for PCBA version) - 8x LED (7 are driven by GPIO) - 1x button (reset) - external h/w watchdog (EM6324QYSP5B, enabled by default) - header for optional 802.3at/af PoE module - DC jack for main power input (optional, not installed by default) - UART (4-pin, 2.54 mm pitch) header on PCB - LEDs (2x 5-pin, 2.54 mm pitch) header on PCB Flash instruction: You can use sysupgrade image directly in vendor firmware which is based on OpenWrt/LEDE. Alternatively, you can use web recovery mode in U-Boot: 1. Configure PC with static IP 192.168.1.2/24. 2. Connect PC with one of RJ45 ports, press the reset button, power up device, wait for first blink of all LEDs (indicates network setup), then keep button for 3 following blinks and release it. 3. Open 192.168.1.1 address in your browser and upload sysupgrade image. Signed-off-by: Piotr Dymacz <pepe2k@gmail.com>
* ath79: add support for ALFA Network N2QPiotr Dymacz2020-09-281-0/+8
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | ALFA Network N2Q is an outdoor N300 AP/CPE based on Qualcomm/Atheros QCA9531 v2. This model is a successor of the old N2 which was based on Atheros AR7240. FCC ID: 2AB8795311. Specifications: - Qualcomm/Atheros QCA9531 v2 - 650/400/200 MHz (CPU/DDR/AHB) - 128 MB of RAM (DDR2) - 16 MB of flash (SPI NOR) - 2T2R 2.4 GHz Wi-Fi with ext. PA (Skyworks SE2623L) and LNA - 2x 10/100 Mbps Ethernet with passive PoE input in one port (24 V) - PoE pass through in second port (controlled by GPIO) - support for optional 802.3af/at PoE module - 1x mini PCIe slot (PCIe bus, extra 4.2 V for high power cards) - 2x IPEX/U.FL connectors on PCB - 1x USB 2.0 mini Type-B (power controlled by GPIO) - 8x LED (7 of them are driven by GPIO) - 1x button (reset) - external h/w watchdog (EM6324QYSP5B, enabled by default) - UART (4-pin, 2.54 mm pitch) header on PCB - LEDs (2x 5-pin, 2.54 mm pitch) header on PCB Flash instruction: You can use sysupgrade image directly in vendor firmware which is based on LEDE/OpenWrt. Alternatively, you can use web recovery mode in U-Boot: 1. Configure PC with static IP 192.168.1.2/24. 2. Connect PC with one of RJ45 ports, press the reset button, power up device, wait for first blink of all LEDs (indicates network setup), then keep button for 3 following blinks and release it. 3. Open 192.168.1.1 address in your browser and upload sysupgrade image. Signed-off-by: Piotr Dymacz <pepe2k@gmail.com>
* ath79: add support for ALFA Network R36APiotr Dymacz2020-09-281-0/+4
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | ALFA Network R36A is a successor of the previous model, the R36 (Ralink RT3050F based). New version is based on Qualcomm/Atheros QCA9531 v2, FCC ID: 2AB879531. Support for this device was first introduced in af8f0629df (ar71xx target). When updating from previous release (and/or ar71xx target), user should only adjust the WAN LED trigger type (netdev in ar71xx, switch port in ath79). Specifications: - Qualcomm/Atheros QCA9531 v2 - 650/400/200 MHz (CPU/DDR/AHB) - 128 MB (R36AH/-U2) or 64 MB (R36A) of RAM (DDR2) - 16 MB of flash (SPI NOR) - 2x 10/100 Mbps Ethernet - Passive PoE input support (12~36 V) in RJ45 near DC jack - 2T2R 2.4 GHz Wi-Fi with Qorvo RFFM8228P FEM - 2x IPEX/U.FL connectors on PCB - 1x USB 2.0 Type-A - 1x USB 2.0 mini Type-B in R36AH-U2 version - USB power is controlled by GPIO - 6/7x LED (5/6 of them are driven by GPIO) - 2x button (reset, wifi/wps) - external h/w watchdog (EM6324QYSP5B, enabled by default) - DC jack with lock, for main power input (12 V) - UART (4-pin, 2.54 mm pitch) header on PCB Optional/additional features in R36A series (R36A was the first model): - for R36AH: USB 2.0 hub* - for R36AH-U2: USB 2.0 hub*, 1x USB 2.0 mini Type-B, one more LED *) there are at least three different USB 2.0 hub in R36AH/-U2 variants: - Terminus-Tech FE 1.1 - Genesys Logic GL852G - Genesys Logic GL850G (used in latests revision) Flash instruction: You can use sysupgrade image directly in vendor firmware which is based on LEDE/OpenWrt. Alternatively, you can use web recovery mode in U-Boot: 1. Configure PC with static IP 192.168.1.2/24. 2. Connect PC with one of RJ45 ports, press the reset button, power up device, wait for first blink of all LEDs (indicates network setup), then keep button for 3 following blinks and release it. 3. Open 192.168.1.1 address in your browser and upload sysupgrade image. Signed-off-by: Piotr Dymacz <pepe2k@gmail.com>
* ath79: add support for Samsung WAM250Piotr Dymacz2020-09-281-0/+3
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Samsung WAM250 is a dual-band (selectable, not simultaneous) wireless hub, dedicated for Samsung Shape Wireless Audio System. The device is based on Atheros AR9344 (FCC ID: A3LWAM250). Support for this device was first introduced in e58e49bdbe (ar71xx target). Specifications: - Atheros AR9344 - 560/450/225 MHz (CPU/DDR/AHB) - 64 MB of RAM (DDR2) - 16 MB of flash (SPI NOR) - 2x 10/100 Mbps Ethernet - 2T2R 2.4/5 GHz Wi-Fi, with ext. PA (SE2598L, SE5003L) and LNA - 1x USB 2.0 - 4x LED (all are driven by GPIO) - 2x button (reset, wps/speaker add) - DC jack for main power input (14 V) - UART header on PCB (J4, RX: 3, TX: 5) Flash instruction: This device uses dual-image (switched between upgrades) with a common jffs2 config partition. Fortunately, there is a way to disable this mode so that more flash space can be used by OpenWrt image. You can easily access this device over telnet, using root/root credentials (the same also work for serial console access). 1. Make sure that your device uses second (bootpart=2) image using command: "fw_printenv bootpart". 2. If your device uses first image (bootpart=1), perform upgrade to the latest vendor firmware (after the update, device should boot from second partition) using web gui (default login: admin/1234567890). 3. Rename "sysupgrade" image to "firmware.bin", download it (you can use wget, tftp or ftpget) to "/tmp" and issue below commands: mtd_debug erase /dev/mtd3 0 $(wc -c /tmp/firmware.bin | awk -F' ' '{print $1}') mtd_debug write /dev/mtd3 0 $(wc -c /tmp/firmware.bin) fw_setenv bootpart fw_setenv bootcmd "bootm 0x9f070000" reboot Revert to vendor firmware instruction: 1. Download vendor firmware to "/tmp" device and issue below commands: fw_setenv bootpart 1 sysupgrade -n -F SS_BHUB_v2.2.05.bin Signed-off-by: Piotr Dymacz <pepe2k@gmail.com>
* ath79: add support for Wallys DR531Piotr Dymacz2020-09-281-0/+9
| | | | | | | | | | | | | | | | | | | | | | | | | | | | Wallys DR531 is based on Qualcomm Atheros QCA9531 v2. Support for this device was first introduced in e767980eb8 (ar71xx target). Specifications: - Qualcomm/Atheros QCA9531 v2 - 550/400/200 MHz (CPU/DDR/AHB) - 2x 10/100 Mbps Ethernet - 64 MB of RAM (DDR2) - 8 MB of flash (SPI NOR) - 2T2R 2.4 GHz Wi-Fi, with external PA (SE2576L), up to 30 dBm - 2x MMCX connectors (optional IPEX/U.FL) - mini PCIe connector (PCIe/USB buses and mini SIM slot) - 7x LED, 1x button, 1x optional buzzer - UART, JTAG and LED headers on PCB Flash instruction (do it under U-Boot, using UART): tftpb 0x80060000 openwrt-ath79-...-dr531-squashfs-sysupgrade.bin erase 0x9f050000 +$filesize cp.b $fileaddr 0x9f050000 $filesize setenv bootcmd "bootm 0x9f050000" saveenv && reset Signed-off-by: Piotr Dymacz <pepe2k@gmail.com>
* ath79: add support for ALFA Network AP121FEPiotr Dymacz2020-09-281-0/+1
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | The AP121FE is a slightly modified version of already supported AP121F model (added to ar71xx in 0c6165d21a and to ath79 in 334bbc5198). The differences in compare to AP121F: - no micro SD card reader - USB data lines are included in Type-A plug - USB bus switched to device/peripheral mode (permanently, in bootstrap) Other than that, specifications are the same: - Atheros AR9331 - 400/400/200 MHz (CPU/DDR/AHB) - 64 MB of RAM (DDR1) - 16 MB of flash (SPI NOR) - 1x 10/100 Mbps Ethernet - 1T1R 2.4 GHz Wi-Fi, up to 15 dBm - 1x IPEX/U.FL connector, internal PCB antenna - 3x LED, 1x button, 1x switch - 4-pin UART header on PCB (2 mm pitch) - USB 2.0 Type-A plug (power and data) Flash instruction (under U-Boot web recovery mode): 1. Configure PC with static IP 192.168.1.2/24. 2. Connect PC with RJ45 port, press the reset button, power up device, wait for first blink of all LEDs (indicates network setup), then keep button for 3 following blinks and release it. 3. Open 192.168.1.1 address in your browser and upload sysupgrade image. Signed-off-by: Piotr Dymacz <pepe2k@gmail.com>
* ath79: fix LED labels for PowerCloud CAP324Adrian Schmutzler2020-09-271-1/+1
| | | | | | | | | The order of function and color in the labels in inverted for the LAN LEDs. Fix it. Fixes: 915966d86121 ("ath79: Port PowerCloud Systems CAP324 support") Signed-off-by: Adrian Schmutzler <freifunk@adrianschmutzler.de>
* ath79: fix rssi-low LED for My Net Range ExtenderAdrian Schmutzler2020-09-271-1/+1
| | | | | | | | | The LED color was missing in 01_leds. Fixes: 745dee11ac78 ("ath79: add support for WD My Net Wi-Fi Range Extender") Signed-off-by: Adrian Schmutzler <freifunk@adrianschmutzler.de>
* ath79: add support for Senao Engenius ENH202 v1Michael Pratt2020-08-311-0/+8
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | FCC ID: U2M-ENH200 Engenius ENH202 is an outdoor wireless access point with 2 10/100 ports, built-in ethernet switch, internal antenna plates and proprietery PoE. Specification: - Qualcomm/Atheros AR7240 rev 2 - 40 MHz reference clock - 8 MB FLASH ST25P64V6P (aka ST M25P64) - 32 MB RAM - UART at J3 (populated) - 2x 10/100 Mbps Ethernet (built-in switch at gmac1) - 2.4 GHz, 2x2, 29dBm (Atheros AR9280 rev 2) - internal antenna plates (10 dbi, semi-directional) - 5 LEDs, 1 button (LAN, WAN, RSSI) (Reset) Known Issues: - Sysupgrade from ar71xx no longer possible - Power LED not controllable, or unknown gpio MAC addresses: eth0/eth1 *:11 art 0x0/0x6 wlan *:10 art 0x120c The device label lists both addresses, WLAN MAC and ETH MAC, in that order. Since 0x0 and 0x6 have the same content, it cannot be determined which is eth0 and eth1, so we chose 0x0 for both. Installation: 2 ways to flash factory.bin from OEM: - Connect ethernet directly to board (the non POE port) this is LAN for all images - if you get Failsafe Mode from failed flash: only use it to flash Original firmware from Engenius or risk kernel loop or halt which requires serial cable Method 1: Firmware upgrade page: OEM webpage at 192.168.1.1 username and password "admin" In upper right select Reset "Restore to factory default settings" Wait for reboot and login again Navigate to "Firmware Upgrade" page from left pane Click Browse and select the factory.bin image Upload and verify checksum Click Continue to confirm and wait 3 minutes Method 2: Serial to load Failsafe webpage: After connecting to serial console and rebooting... Interrupt boot with any key pressed rapidly execute `run failsafe_boot` OR `bootm 0x9f670000` wait a minute connect to ethernet and navigate to "192.168.1.1/index.htm" Select the factory.bin image and upload wait about 3 minutes Return to OEM: If you have a serial cable, see Serial Failsafe instructions *DISCLAIMER* The Failsafe image is unique to Engenius boards. If the failsafe image is missing or damaged this will not work DO NOT downgrade to ar71xx this way, can cause kernel loop or halt The easiest way to return to the OEM software is the Failsafe image If you dont have a serial cable, you can ssh into openwrt and run `mtd -r erase fakeroot` Wait 3 minutes connect to ethernet and navigate to 192.168.1.1/index.htm select OEM firmware image from Engenius and click upgrade Format of OEM firmware image: The OEM software of ENH202 is a heavily modified version of Openwrt Kamikaze bleeding-edge. One of the many modifications is to the sysupgrade program. Image verification is performed simply by the successful ungzip and untar of the supplied file and name check and header verification of the resulting contents. To form a factory.bin that is accepted by OEM Openwrt build, the kernel and rootfs must have specific names... openwrt-senao-enh202-uImage-lzma.bin openwrt-senao-enh202-root.squashfs and begin with the respective headers (uImage, squashfs). Then the files must be tarballed and gzipped. The resulting binary is actually a tar.gz file in disguise. This can be verified by using binwalk on the OEM firmware images, ungzipping then untaring, and by swapping headers to see what the OEM upgrade utility accepts and rejects. OKLI kernel loader is required because the OEM firmware expects the kernel to be no greater than 1024k and the factory.bin upgrade procedure would otherwise overwrite part of the kernel when writing rootfs. Note on built-in switch: ENH202 is originally configured to be an access point, but with two ethernet ports, both WAN and LAN is possible. the POE port is gmac0 which is preferred to be the port for WAN because it gives link status where swconfig does not. Signed-off-by: Michael Pratt <mpratt51@gmail.com> [assign label_mac in 02_network, use ucidef_set_interface_wan, use common device definition, some reordering] Signed-off-by: Adrian Schmutzler <freifunk@adrianschmutzler.de>
* ath79: add support for Senao Engenius ENS202EXT v1Michael Pratt2020-08-311-0/+6
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Engenius ENS202EXT v1 is an outdoor wireless access point with 2 10/100 ports, with built-in ethernet switch, detachable antennas and proprietery PoE. FCC ID: A8J-ENS202 Specification: - Qualcomm/Atheros AR9341 v1 - 535/400/200/40 MHz (CPU/DDR/AHB/REF) - 64 MB of RAM - 16 MB of FLASH MX25L12835F(MI-10G) - UART (J1) header on PCB (unpopulated) - 2x 10/100 Mbps Ethernet (built-in switch Atheros AR8229) - 2.4 GHz, up to 27dBm (Atheros AR9340) - 2x external, detachable antennas - 7x LED (5 programmable in ath79), 1x GPIO button (Reset) Known Issues: - Sysupgrade from ar71xx no longer possible - Ethernet LEDs stay on solid when connected, not programmable MAC addresses: eth0/eth1 *:7b art 0x0/0x6 wlan *:7a art 0x1002 The device label lists both addresses, WLAN MAC and ETH MAC, in that order. Since 0x0 and 0x6 have the same content, it cannot be determined which is eth0 and eth1, so we chose 0x0 for both. Installation: 2 ways to flash factory.bin from OEM: - Connect ethernet directly to board (the non POE port) this is LAN for all images - if you get Failsafe Mode from failed flash: only use it to flash Original firmware from Engenius or risk kernel loop which requires serial cable Method 1: Firmware upgrade page: OEM webpage at 192.168.1.1 username and password "admin" In upper right select Reset "Restore to factory default settings" Wait for reboot and login again Navigate to "Firmware Upgrade" page from left pane Click Browse and select the factory.bin image Upload and verify checksum Click Continue to confirm and wait 3 minutes Method 2: Serial to load Failsafe webpage: After connecting to serial console and rebooting... Interrupt boot with any key pressed rapidly execute `run failsafe_boot` OR `bootm 0x9fdf0000` wait a minute connect to ethernet and navigate to "192.168.1.1/index.htm" Select the factory.bin image and upload wait about 3 minutes *If you are unable to get network/LuCI after flashing* You must perform another factory reset: After waiting 3 minutes or when Power LED stop blinking: Hold Reset button for 15 seconds while powered on or until Power LED blinks very fast release and wait 2 minutes Return to OEM: If you have a serial cable, see Serial Failsafe instructions *DISCLAIMER* The Failsafe image is unique to this model. The following directions are unique to this model. DO NOT downgrade to ar71xx this way, can cause kernel loop The easiest way to return to the OEM software is the Failsafe image If you dont have a serial cable, you can ssh into openwrt and run `mtd -r erase fakeroot` Wait 3 minutes connect to ethernet and navigate to 192.168.1.1/index.htm select OEM firmware image from Engenius and click upgrade TFTP Recovery: For some reason, TFTP is not reliable on this board. Takes many attempts, many timeouts before it fully transfers. Starting with an initramfs.bin: Connect to ethernet set IP address and TFTP server to 192.168.1.101 set up infinite ping to 192.168.1.1 rename the initramfs.bin to "vmlinux-art-ramdisk" and host on TFTP server disconnect power to the board hold reset button while powering on board for 8 seconds Wait a minute, power LED should blink eventually if successful and a minute after that the pings should get replies You have now loaded a temporary Openwrt with default settings temporarily. You can use that image to sysupgrade another image to overwrite flash. Format of OEM firmware image: The OEM software of ENS202EXT is a heavily modified version of Openwrt Kamikaze bleeding-edge. One of the many modifications is to the sysupgrade program. Image verification is performed simply by the successful ungzip and untar of the supplied file and name check and header verification of the resulting contents. To form a factory.bin that is accepted by OEM Openwrt build, the kernel and rootfs must have specific names... openwrt-senao-ens202ext-uImage-lzma.bin openwrt-senao-ens202ext-root.squashfs and begin with the respective headers (uImage, squashfs). Then the files must be tarballed and gzipped. The resulting binary is actually a tar.gz file in disguise. This can be verified by using binwalk on the OEM firmware images, ungzipping then untaring, and by swapping headers to see what the OEM upgrade utility accepts and rejects. Note on the factory.bin: The newest kernel is too large to be in the kernel partition the new ath79 kernel is beyond 1592k Even ath79-tiny is 1580k Checksum fails at boot because the bootloader (modified uboot) expects kernel to be 1536k. If the kernel is larger, it gets overwritten when rootfs is flashed, causing a broken image. The mtdparts variable is part of the build and saving a new uboot environment will not persist after flashing. OEM version might interact with uboot or with the custom OEM partition at 0x9f050000. Failed checksums at boot cause failsafe image to launch, allowing any image to be flashed again. HOWEVER: one should not install older Openwrt from failsafe because it can cause rootfs to be unmountable, causing kernel loop after successful checksum. The only way to rescue after that is with a serial cable. For these reasons, a fake kernel (OKLI kernel loader) and fake squashfs rootfs is implemented to take care of the OEM firmware image verification and checksums at boot. The OEM only verifies the checksum of the first image of each partition respectively, which is the loader and the fake squashfs. This completely frees the "firmware" partition from all checks. virtual_flash is implemented to make use of the wasted space. this leaves only 2 erase blocks actually wasted. The loader and fakeroot partitions must remain intact, otherwise the next boot will fail, redirecting to the Failsafe image. Because the partition table required is so different than the OEM partition table and ar71xx partition table, sysupgrades are not possible until one switches to ath79 kernel. Note on sysupgrade.tgz: To make things even more complicated, another change is needed to fix an issue where network does not work after flashing from either OEM software or Failsafe image, which implants the OEM (Openwrt Kamikaze) configuration into the jffs2 /overlay when writing rootfs from factory.bin. The upgrade script has this: mtd -j "/tmp/_sys/sysupgrade.tgz" write "${rootfs}" "rootfs" However, it also accepts scripts before and after: before_local="/etc/before-upgradelocal.sh" after_local="/etc/after-upgradelocal.sh" before="before-upgrade.sh" after="after-upgrade.sh" Thus, we can solve the issue by making the .tgz an empty file by making a before-upgrade.sh in the factory.bin Note on built-in switch: There is two ports on the board, POE through the power supply brick, the other is on the board. For whatever reason, in the ar71xx target, both ports were on the built-in switch on eth1. In order to make use of a port for WAN or a different LAN, one has to set up VLANs. In ath79, eth0 and eth1 is defined in the DTS so that the built-in switch is seen as eth0, but only for 1 port the other port is on eth1 without a built-in switch. eth0: switch0 CPU is port 0 board port is port 1 eth1: POE port on the power brick Since there is two physical ports, it can be configured as a full router, with LAN for both wired and wireless. According to the Datasheet, the port that is not on the switch is connected to gmac0. It is preferred that gmac0 is chosen as WAN over a port on an internal switch, so that link status can pass to the kernel immediately which is more important for WAN connections. Signed-off-by: Michael Pratt <mpratt51@gmail.com> [apply sorting in 01_leds, make factory recipe more generic, create common device node, move label-mac to 02_network, add MAC addresses to commit message, remove kmod-leds-gpio, use gzip directly] Signed-off-by: Adrian Schmutzler <freifunk@adrianschmutzler.de>
* ath79: add support for Meraki MR16Martin Kennedy2020-08-311-0/+3
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Port device support for Meraki MR16 from the ar71xx target to ath79. Specifications: * AR7161 CPU, 16 MiB Flash, 64 MiB RAM * One PoE-capable Gigabit Ethernet Port * AR9220 / AR9223 (2x2 11an / 11n) WLAN Installation: * Requires TFTP server at 192.168.1.101, w/ initramfs & sysupgrade .bins * Open shell case and connect a USB to TTL cable to upper serial headers * Power on the router; connect to U-boot over 115200-baud connection * Interrupt U-boot process to boot Openwrt by running: setenv bootcmd bootm 0xbf0a0000; saveenv; tftpboot 0c00000 <filename-of-initramfs-kernel>.bin; bootm 0c00000; * Copy sysupgrade image to /tmp on MR16 * sysupgrade /tmp/<filename-of-sysupgrade>.bin Notes: - There are two separate ARTs in the partition (offset 0x1000/0x5000 and 0x11000/0x15000) in the OEM device. I suspect this is an OEM artifact; possibly used to configure the radios for different regions, circumstances or RF frontends. Since the ar71xx target uses the second offsets, use that second set (0x11000 and 0x15000) for the ART. - kmod-owl-loader is still required to load the ART partition into the driver. - The manner of storing MAC addresses is updated from ar71xx; it is at 0x66 of the 'config' partition, where it was discovered that the OEM firmware stores it. This is set as read-only. If you are migrating from ar71xx and used the method mentioned above to upgrade, use kmod-mtd-rw or UCI to add the MAC back in. One more method for doing this is described below. - Migrating directly from ar71xx has not been thoroughly tested, but one method has been used a couple of times with good success, migrating 18.06.2 to a full image produced as of this commit. Please note that these instructions are only for experienced users, and/or those still able to open their device up to flash it via the serial headers should anything go wrong. 1) Install kmod-mtd-rw and uboot-envtools 2) Run `insmod mtd-rw.ko i_want_a_brick=1` 3) Modify /etc/fw_env.config to point to the u-boot-env partition. The file /etc/fw_env.config should contain: # MTD device env offset env size sector size /dev/mtd1 0x00000 0x10000 0x10000 See https://openwrt.org/docs/techref/bootloader/uboot.config for more details. 4) Run `fw_printenv` to verify everything is correct, as per the link above. 5) Run `fw_setenv bootcmd bootm 0xbf0a0000` to set a new boot address. 6) Manually modify /lib/upgrade/common.sh's get_image function: Change ... cat "$from" 2>/dev/null | $cmd ... into ... ( dd if=/dev/zero bs=1 count=$((0x66)) ; # Pad the first 102 bytes echo -ne '\x00\x18\x0a\x12\x34\x56' ; # Add in MAC address dd if=/dev/zero bs=1 count=$((0x20000-0x66-0x6)) ; # Pad the rest cat "$from" 2>/dev/null | $cmd ) ... which, during the upgrade process, will pad the image by 128K of zeroes-plus-MAC-address, in order for the ar71xx's firmware partition -- which starts at 0xbf080000 -- to be instead aligned with the ath79 firmware partition, which starts 128K later at 0xbf0a0000. 7) Copy the sysupgrade image into /tmp, as above 8) Run `sysupgrade -F /tmp/<sysupgrade>.bin`, then wait Again, this may BRICK YOUR DEVICE, so make *sure* to have your serial cable handy. Addenda: - The MR12 should be able to be migrated in a nearly identical manner as it shares much of its hardware with the MR16. - Thank-you Chris B for copious help with this port. Signed-off-by: Martin Kennedy <hurricos@gmail.com> [fix typo in compat message, drop art DT label, move 05_fix-compat-version to subtarget] Signed-off-by: Adrian Schmutzler <freifunk@adrianschmutzler.de>
* ath79: add support for TP-Link TL-WPA8630 v1Adrian Schmutzler2020-08-131-0/+1
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | This ports the TP-Link TL-WPA8630 v1 from ar71xx to ath79. Specifications: SoC: QCA9563 CPU: 750 MHz Flash/RAM: 8 / 128 MiB Ethernet: 3x 1G ports (QCA8337 switch) WLAN: 2.4 GHz b/g/n, 5 GHz a/n/ac (ath10k) Buttons, LEDs and network setup appear to be almost identical to the v2 revision. Powerline interface is connected to switch port 5 (Label LAN4). Installation: No "fresh" device was available for testing the factory image. It is not known whether flashing via OEM firmware GUI is possible or not. A discussion from 2018 [1] about that indicates a few adjustments are necessary, but it is not clear whether those are already implemented with the TPLINK_HEADER_VERSION = 2 or not. Note that for the TL-WPA8630P v1, the TPLINK_HWID needs to be changed to 0x86310001 to allow factory flashing. [1] https://forum.openwrt.org/t/solved-tl-wpa8630p-lede-does-not-install/8161/27 Recovery: Recovery is only possible via serial. Signed-off-by: Adrian Schmutzler <freifunk@adrianschmutzler.de>
* ath79: add support for Telco T1Nicholas Smith2020-08-101-1/+2
| | | | | | | | | | | | | | | | | | | | | | Description: 2x 100Mbps Etherent ports 24V passive PoE 64MB RAM 16MB Flash 2.4GHz WiFi 1x WiFi antenna (RP-SMA connector) 1x LTE antenna (SMA connector) Sierra Wireless MC7430 LTE modem Flash instructions: Original firmware is based on OpenWrt. Flash using sysupgrade -n SUPPORTED_DEVICES is added to support factory firmware. Signed-off-by: Nicholas Smith <nicholas.smith@telcoantennas.com.au> [add missing led_rssi0 DT label, add SUPPORTED_DEVICES] Signed-off-by: Adrian Schmutzler <freifunk@adrianschmutzler.de>
* ath79: add support for TP-Link TL-WPA8630P v2Andreas Böhler2020-08-101-0/+4
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | The TL-WPA8630P v2 is a HomePlug AV2 compatible device with a QCA9563 SoC and 2.4GHz and 5GHz WiFi modules. Specifications -------------- - QCA9563 750MHz, 2.4GHz WiFi - QCA9888 5GHz WiFi - 8MiB SPI Flash - 128MiB RAM - 3 GBit Ports (QCA8337) - PLC (QCA7550) MAC address assignment ---------------------- WiFi 2.4GHz and LAN share the same MAC address as printed on the label. 5GHz WiFi uses LAN-1, based on assumptions from similar devices. LAN Port assignment ------------------- While there are 3 physical LAN ports on the device, there will be 4 visible ports in OpenWrt. The fourth port (internal port 5) is used by the PowerLine Communication SoC and thus treated like a regular LAN port. Versions -------- Note that both TL-WPA8630 and TL-WPA8630P, as well as the different country-versions, differ in partitioning, and therefore shouldn't be cross-flashed. This adds support for the two known partitioning variants of the TL-WPA8630P, where the variants can be safely distinguished via the tplink-safeloader SupportList. For the non-P variants (TL-WPA8630), at least two additional partitioning schemes exist, and the same SupportList entry can have different partitioning. Thus, we don't support those officially (yet). Also note that the P version for Germany (DE) requires the international image version, but is properly protected by SupportList. In any case, please check the OpenWrt Wiki pages for the device before flashing anything! Installation ------------ Installation is possible from the OEM web interface. Make sure to install the latest OEM firmware first, so that the PLC firmware is at the latest version. However, please also check the Wiki page for hints according to altered partitioning between OEM firmware revisions. Additional thanks to Jon Davies and Joe Mullally for bringing order into the partitioning mess. Signed-off-by: Andreas Böhler <dev@aboehler.at> [minor DTS adjustments, add label-mac-device, drop chosen, move common partitions to DTSI, rename de to int, add AU support strings, adjust TPLINK_BOARD_ID, create common node in generic-tp-link.mk, adjust commit message] Signed-off-by: Adrian Schmutzler <freifunk@adrianschmutzler.de>
* ath79: add support for Ubiquiti PowerBridge MVieno Hakkerinen2020-07-151-0/+1
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | This adds support for the Ubiquiti PowerBridge M, which has the same board/LEDs as the Bullet M XM, but different case and antennas. Specifications: - AR7241 SoC @ 400 MHz - 64 MB RAM - 8 MB SPI flash - 1x 10/100 Mbps Ethernet, 24 Vdc PoE-in - Internal antenna: 25 dBi - POWER/LAN green LEDs - 4x RSSI LEDs (red, orange, green, green) - UART (115200 8N1) on PCB Flashing via WebUI: Upload the factory image via the stock firmware web UI. Attention: airOS firmware versions >= 5.6 have a new bootloader with an incompatible partition table! Please downgrade to <= 5.5 _before_ flashing OpenWrt! Refer to the device's Wiki page for further information. Flashing via TFTP: Same procedure as other Bullet M (XM) boards. - Use a pointy tool (e.g., pen cap, paper clip) and keep the reset button on the device or on the PoE supply 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> trace tftp> put openwrt-ath79-generic-xxxxx-ubnt_powerbridge-m-squashfs-factory.bin Signed-off-by: Vieno Hakkerinen <vieno@hakkerinen.eu>
* ath79: add support for D-Link DAP-1330/DAP-1365 A1Sebastian Schaper2020-07-091-0/+8
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Port device support for DAP-1330 from the ar71xx target to ath79. Additionally, images are generated for the European through-socket case variant DAP-1365. Both devices run the same vendor firmware, the only difference being the DAP_SIGNATURE field in the factory header. The vendor's Web UI will display a model string stored in the flash. Specifications: * QCA9533, 8 MiB Flash, 64 MiB RAM * One Ethernet Port (10/100) * Wall-plug style case (DAP-1365 with additional socket) * LED bargraph RSSI indicator Installation: * Web UI: http://192.168.0.50 (or different address obtained via DHCP) There is no password set by default * Recovery Web UI: Keep reset button pressed during power-on until LED starts flashing red, upgrade via http://192.168.0.50 * Some modern browsers may have problems flashing via the Web UI, if this occurs consider booting to recovery mode and flashing via: curl -F \ files=@openwrt-ath79-generic-dlink_dap-1330-a1-squashfs-factory.bin \ http://192.168.0.50/cgi/index The device will use the same MAC address for both wired and wireless interfaces, however it is stored at two different locations in the flash. Signed-off-by: Sebastian Schaper <openwrt@sebastianschaper.net>
* ath79: add support for GL.iNet GL-MiFiAntti Seppälä2020-07-031-0/+4
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Add support for the ar71xx supported GL.iNet GL-MiFi to ath79. Specifications: - Atheros AR9331 - 64 MB of RAM - 16 MB of FLASH (SPI NOR) - 2x 10/100/1000 Mbps Ethernet - 2.4GHz (AR9330), 802.11b/g/n - 1x USB 2.0 (vbus driven by GPIO) - 4x LED, driven by GPIO - 1x button (reset) - 1x mini pci-e slot (vcc driven by GPIO) Flash instructions: Vendor software is based on openwrt so you can flash the sysupgrade image via the vendor GUI or using command line sysupgrade utility. Make sure to not save configuration over reflash as uci settings differ between versions. Note on MAC addresses: Even though the platform is capable to providing separate MAC addresses to the interfaces vendor firmware does not seem to take advantage of that. It appears that there is only single unique pre-programmed address in the art partition and vendor firmware uses that for every interface (eth0/eth1/wlan0). Similar behaviour has also been implemented in this patch. Note on GPIOs: In vendor firmware the gpio controlling mini pci-e slot is named 3gcontrol while it actually controls power supply to the entire mini pci-e slot. Therefore a more descriptive name (minipcie) was chosen. Also during development of this patch it became apparent that the polarity of the signal is actually active low rather than active high that can be found in vendor firmware. Acknowledgements: This patch is based on earlier work[1] done by Kyson Lok. Since the initial mailing-list submission the patch has been modified to comply with current openwrt naming schemes and dts conventions. [1] http://lists.openwrt.org/pipermail/openwrt-devel/2018-September/019576.html Signed-off-by: Antti Seppälä <a.seppala@gmail.com>
* ath79: add support for Compex WPJ344Leon M. George2020-07-031-0/+7
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Specifications: SoC: AR9344 DRAM: 128MB DDR2 Flash: 16MB SPI-NOR 2 Gigabit ethernet ports 2×2 2.4GHz on-board radio miniPCIe slot that supports 5GHz radio PoE 48V IEEE 802.3af/at - 24V passive optional USB 2.0 header Installation: To install, either start tftp in bin/targets/ath79/generic/ and use the u-boot prompt over UART: tftpboot 0x80500000 openwrt-ath79-generic-compex_wpj344-16m-squashfs-sysupgrade.bin erase 0x9f030000 +$filesize erase 0x9f680000 +1 cp.b $fileaddr 0x9f030000 $filesize boot The cpximg file can be used with sysupgrade in the stock firmware (add SSH key in luci for root access) or with the built-in cpximg loader. The cpximg loader can be started either by holding the reset button during power up or by entering the u-boot prompt and entering 'cpximg'. Once it's running, a TFTP-server under 192.168.1.1 will accept the image appropriate for the board revision that is etched on the board. For example, if the board is labelled '6A08': tftp -v -m binary 192.168.1.1 -c put openwrt-ath79-generic-compex_wpj344-16m-squashfs-cpximg-6a08.bin MAC addresses: <&uboot 0x2e010> *:99 (label) <&uboot 0x2e018> *:9a <&uboot 0x2e020> *:9b <&uboot 0x2e028> *:9c Only the first two are used (for ethernet), the WiFi modules have separate (valid) addresses. The latter two addresses are not used. Signed-off-by: Leon M. George <leon@georgemail.eu> [minor commit message adjustments, drop gpio in DTS, DTS style fixes, sorting, drop unused cpximg recipe] Signed-off-by: Adrian Schmutzler <freifunk@adrianschmutzler.de>
* ath79: add support for Compex WPJ531 (16M)Leon M. George2020-06-281-0/+7
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Specifications: SoC: QCA9531 DRAM: 128MB DDR2 Flash: 16MB SPI-NOR 2 100MBit ethernet ports 2×2 2.4GHz on-board radio miniPCIe slot that supports 5GHz radio PoE 24V - 48V IEEE 802.3af optional USB 2.0 header Installation: To install, start a tftp server in bin/targets/ath79/generic/ and use the u-boot prompt over UART: tftpboot 0x80500000 openwrt-ath79-generic-compex_wpj531-16m-squashfs-sysupgrade.bin erase 0x9f030000 +$filesize erase 0x9f680000 +1 cp.b $fileaddr 0x9f030000 $filesize boot The cpximg file can be used with sysupgrade in the stock firmware (add SSH key in luci for root access). Another way is to hold the reset button during power up or running 'cpximg' in the u-boot prompt. Once the last LED starts flashing regularly, a TFTP-server under 192.168.1.1 will accept the image appropriate for the board revision that is etched on the board. For example, if the board is labelled '7A04': tftp -v -m binary 192.168.1.1 -c put openwrt-ath79-generic-compex_wpj531-16m-squashfs-cpximg-7A04.bin MAC addresses: <&uboot 0x2e010> *:cb (label) <&uboot 0x2e018> *:cc <&uboot 0x2e020> *:cd <&uboot 0x2e028> *:ce Only the first two are used (for ethernet), the WiFi modules have separate (valid) addresses. The latter two addresses are not used. Signed-off-by: Leon M. George <leon@georgemail.eu> [commit title/message facelift, fix rssileds, add led aliases] Signed-off-by: Adrian Schmutzler <freifunk@adrianschmutzler.de>
* ath79: add support for AVM FRITZ!WLAN Repeater DVB-CNatalie Kagelmacher2020-06-251-0/+8
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | This commit adds support for the AVM FRITZ!WLAN Repeater DVB-C SOC: Qualcomm Atheros QCA9556 RAM: 64 MiB FLASH: 16 MB SPI-NOR WLAN: QCA9556 3T3R 2.4 GHZ b/g/n and QCA9880 3T3R 5 GHz n/ac ETH: Atheros AR8033 1000 Base-T DVB-C: EM28174 with MaxLinear MXL251 tuner BTN: WPS Button LED: Power, WLAN, TV, RSSI0-4 Tested and working: - Ethernet (correct MAC, gigabit, iperf3 about 200 Mbit/s) - 2.4 GHz Wi-Fi (correct MAC) - 5 GHz Wi-Fi (correct MAC) - WPS Button (tested using wifitoggle) - LEDs - Installation via EVA bootloader (FTP recovery) - OpenWrt sysupgrade (both CLI and LuCI) - Download of "urlader" (mtd0) Not working: - Internal USB - DVB-C em28174+MxL251 (depends on internal USB) Installation via EVA bootloader (FTP recovery): Set NIC to 192.168.178.3/24 gateway 192.168.178.1 and power on the device, connect to 192.168.178.1 through FTP and sign in with adam2/adam2: ftp> quote USER adam2 ftp> quote PASS adam2 ftp> binary ftp> debug ftp> passive ftp> quote MEDIA FLSH ftp> put openwrt-sysupgrade.bin mtd1 Wait for "Transfer complete" together with the transfer details. Wait two minutes to make sure flash is complete (just to be safe). Then restart the device (power off and on) to boot into OpenWrt. Revert your NIC settings to reach OpenWrt at 192.168.1.1 Signed-off-by: Natalie Kagelmacher <nataliek@pm.me> [fixed sorting - removed change to other board - prettified commit message] Signed-off-by: David Bauer <mail@david-bauer.net>
* ath79: add support for TP-Link CPE610 v2Andrew Cameron2020-06-201-0/+3
| | | | | | | | | | | | | | | | | | | | | | | | | | TP-Link CPE610 v2 is an outdoor wireless CPE for 5 GHz with one Ethernet port based on Atheros AR9344 Specifications: - 560/450/225 MHz (CPU/DDR/AHB) - 1x 10/100 Mbps Ethernet - 64 MB of DDR2 RAM - 8 MB of SPI-NOR Flash - 23dBi high-gain directional 2×2 MIMO antenna and a dedicated metal reflector - Power, LAN, WLAN5G green LEDs - 3x green RSSI LEDs Flashing instructions: Flash factory image through stock firmware WEB UI or through TFTP To get to TFTP recovery just hold reset button while powering on for around 4-5 seconds and release. Rename factory image to recovery.bin Stock TFTP server IP:192.168.0.100 Stock device TFTP adress:192.168.0.254 Signed-off-by: Andrew Cameron <apcameron@softhome.net>
* ath79: add support for the TP-Link WBS210 v1Adrian Schmutzler2020-06-161-0/+1
| | | | | | | | | | | | | | | | | | | | Specifications: - SoC: Atheros AR9344 - RAM: 64MB - Storage: 8 MB SPI NOR - Wireless: 2.4GHz N based built into SoC - Ethernet: 1x 10/100 Mbps with 24V POE IN, 1x 10/100 Mbps Installation: Flash factory image through stock firmware WEB UI or through TFTP To get to TFTP recovery just hold reset button while powering on for around 4-5 seconds and release. Rename factory image to recovery.bin Stock TFTP server IP:192.168.0.100 Stock device TFTP adress:192.168.0.254 Signed-off-by: Adrian Schmutzler <freifunk@adrianschmutzler.de>
* ath79: add support for TP-Link RE450 v3Andreas Wiese2020-05-311-1/+2
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | TP-Link RE450 v3 is a dual band router/range-extender based on Qualcomm/Atheros QCA9563 + QCA9880. This device is nearly identical to RE450 v2 besides a modified flash layout (hence I think force-flashing a RE450v2 image will lead to at least loss of MAC address). Specification: - 775 MHz CPU - 64 MB of RAM (DDR2) - 8 MB of FLASH (SPI NOR) - 3T3R 2.4 GHz - 3T3R 5 GHz - 1x 10/100/1000 Mbps Ethernet (AR8033 PHY) - 7x LED, 4x button- - possible UART header on PCB¹ Flash instruction: Apply factory image in OEM firmware web-gui. ¹ Didn't check to connect as I didn't even manage to connect on RE450v2 (AFAIU it requires disconnecting some resistors, which I was too much of a coward to do). But given the similarities to v2 I think it's the same or very similar procedure (and most likely also the only way to debrick). Signed-off-by: Andreas Wiese <aw-openwrt@meterriblecrew.net> [remove dts-v1 and compatible in DTSI] Signed-off-by: Adrian Schmutzler <freifunk@adrianschmutzler.de>
* ath79: fix LEDs for GL.inet GL-AR150Adrian Schmutzler2020-05-311-4/+0
| | | | | | | | | | | | | | | | | Since the wireless LED was used for boot and set up with a DT trigger, the WiFi indication hasn't worked on ath79 at all. In addition, a look into the manual revealed that the OEM configuration is as follows: LED 1 (green): power LED 2 (green): configurable LED 3 (red): wireless So, let's just keep the WiFi trigger and convert the rest to its "intended" use. Signed-off-by: Adrian Schmutzler <freifunk@adrianschmutzler.de>
* ath79: add support for COMFAST CF-E130N v2Pavel Balan2020-05-281-0/+8
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | This patch adds support for the COMFAST CF-E130N v2, an outdoor wireless CPE with a single Ethernet port and a 802.11bgn radio. Specifications: - QCA9531 SoC - 1x 10/100 Mbps Ethernet with PoE-in support - 64 MB of RAM (DDR2) - 16 MB of FLASH - 5 dBi built-in antenna - POWER/LAN/WLAN green LEDs - 4x RSSI LEDs (2x red, 2x green) - UART (115200 8N1) and GPIO (J9) headers on PCB Flashing instructions: The original firmware is based on OpenWrt so a sysupgrade image can be installed via the stock web GUI. The U-boot bootloader also contains a backup TFTP client to upload the firmware from. Upon boot, it checks its ethernet network for the IP 192.168.1.10. Host a TFTP server and provide the image to be flashed as file firmware_auto.bin. MAC address setup: The art partition contains four consecutive MAC addresses: 0x0 aa:bb:cc:xx:xx:c4 0x6 aa:bb:cc:xx:xx:c6 0x1002 aa:bb:cc:xx:xx:c5 0x5006 aa:bb:cc:xx:xx:c7 However, the manufacturer in its infinite wisdom decided that one address is enough and both eth0 and WiFi get the MAC address from 0x0 (yes, that's overwriting the existing and valid address in 0x1002). This is obviously also the address on the device's label. Signed-off-by: Pavel Balan <admin@kryma.net> [fix configs partition, fix IMAGE_SIZE, add MAC address comment, rename ATH_SOC to SOC] Signed-off-by: Adrian Schmutzler <freifunk@adrianschmutzler.de>
* ath79: fix LEDs for D-Link DIR-842Sebastian Schaper2020-05-261-3/+0
| | | | | | | | | | | | | | | The device has a total of 8 LEDs, 5 of which are controlled by the switch (LAN 1-4, WAN). Only power, wifi and wps are controlled by the SoC. * led_power is on GPIO 5 (not 15), boot flashing sequence is now visible * remove led 'internet', since it is only connected to the switch * remove ucidef_set_led_switch for WAN from 01_leds, as it has no effect Tested on revisions C1 and C3. Signed-off-by: Sebastian Schaper <openwrt@sebastianschaper.net> [adjust commit title] Signed-off-by: Adrian Schmutzler <freifunk@adrianschmutzler.de>
* ath79: add support for Enterasys WS-AP3705iDavid Bauer2020-05-221-1/+2
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Hardware -------- SoC: Atheros AR9344 RAM: 128M DDR2 FLASH: 2x Macronix MX25L12845EM 2x 16MiB SPI-NOR WLAN2: Atheros AR9344 2x2 2T2R WLAN5: Atheros AR9580 2x2 2T2R SERIAL: Cisco-RJ45 on the back (115200 8n1) Installation ------------ The U-Boot CLI is password protected (using the same credentials as the OS). Default is admin/new2day. 1. Download the OpenWrt initramfs-image. Place it into a TFTP server root directory and rename it to 1401A8C0.img. Configure the TFTP server to listen at 192.168.1.66/24. 2. Connect the TFTP server to the access point. 3. Connect to the serial console of the access point. Attach power and interrupt the boot procedure when prompted (bootdelay is 1 second). 4. Configure the U-Boot environment for booting OpenWrt from Ram and flash: $ setenv boot_openwrt 'setenv bootargs; bootm 0xbf230000' $ setenv ramboot_openwrt 'setenv serverip 192.168.1.66; tftpboot 0x85000000; bootm' $ setenv bootcmd 'run boot_openwrt' $ saveenv 5. Load OpenWrt into memory: $ run ramboot_openwrt Wait for the image to boot. 6. Transfer the OpenWrt sysupgrade image to the device. Write the image to flash using sysupgrade: $ sysupgrade -n /path/to/openwrt-sysuograde.bin Signed-off-by: David Bauer <mail@david-bauer.net>
* ath79: add support for Ubiquiti PowerBeam 5AC Gen2Roger Pueyo Centelles2020-04-271-1/+2
| | | | | | | | | | | | | | | | | | | | | | | | The Ubiquiti PowerBeam 5AC Gen 2 (PBE-5AC-Gen2) is an outdoor 802.11ac 5 GHz bridge with a radio feed and a dish antenna. The device is hardware-compatible with the LiteBeam AC Gen2, plus the 4 extra LEDs. Specifications: - SoC: Qualcomm Atheros AR9342 rev 2 - RAM: 64 MB DDR2 - Flash: 16 MB SPI NOR (mx25l12805d) - Ethernet: 1x 10/100/1000 Mbps Atheros 8035, 24 Vdc PoE-in - WiFi 5 GHz: QCA988x HW2.0 Ubiquiti target 0x4100016c chip_id 0x043222ff - WiFi 2.4 GHz: Atheros AR9340 (SoC-based) - Buttons: 1x (reset) - LEDs: 1x power, 1x Ethernet, 4x RSSI via GPIO. All blue. - UART: not tested Installation from stock airOS firmware: - Follow instructions for WA-type Ubiquiti devices on OpenWrt wiki Signed-off-by: Roger Pueyo Centelles <roger.pueyo@guifi.net> [changed device name in commit title] Signed-off-by: Adrian Schmutzler <freifunk@adrianschmutzler.de>
* ath79: add support for AVM FRITZ!WLAN Repeater 450EDavid Bauer2020-04-191-1/+2
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | SOC: Qualcomm QCA9556 (Scorpion) 560MHz MIPS74Kc RAM: 64MB Zentel A3R12E40CBF DDR2 FLASH: 16MiB Winbond W25Q128 SPI NOR WLAN1: QCA9556 2.4 GHz 802.11b/g/n 3x3 INPUT: WPS button LED: Power, WiFi, LAN, RSSI indicator Serial: Header Next to Black metal shield Pinout is 3.3V - RX - TX - GND (Square Pad is 3.3V) The Serial setting is 115200-8-N-1. Installation via EVA: In the first seconds after Power is connected, the bootloader will listen for FTP connections on 192.168.178.1. Firmware can be uploaded like following: ftp> quote USER adam2 ftp> quote PASS adam2 ftp> binary ftp> debug ftp> passive ftp> quote MEDIA FLSH ftp> put openwrt-sysupgrade.bin mtd1 Note that this procedure might take up to two minutes. You need to powercycle the device afterwards to boot OpenWRT. Tested-by: Andreas Ziegler <dev@andreas-ziegler.de> Signed-off-by: David Bauer <mail@david-bauer.net>
* ath79: add support for AVM FRITZ!WLAN Repeater 1750EDavid Bauer2020-04-171-0/+9
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | This commit adds support for the AVM Fritz!WLAN Repeater 1750E SOC: Qualcomm QCA9556 (Scorpion) 720MHz MIPS74Kc RAM: 64MB Zentel A3R12E40CBF DDR2 FLASH: 16MiB Winbond W25Q128 SPI NOR WLAN1: QCA9556 2.4 GHz 802.11b/g/n 3x3 WLAN2: QCA9880 5 GHz 802.11 n/ac 3x3 INPUT: WPS button LED: Power, WiFi, LAN, RSSI indicator Serial: Header Next to Black metal shield Pinout is 3.3V - RX - TX - GND (Square Pad is 3.3V) The Serial setting is 115200-8-N-1. Tested and working: - Ethernet - 2.4 GHz WiFi (correct MAC) - 5 GHz WiFi (correct MAC) - Installation via EVA bootloader - OpenWRT sysupgrade - Buttons - LEDs Installation via EVA: In the first seconds after Power is connected, the bootloader will listen for FTP connections on 192.168.178.1. Firmware can be uploaded like following: ftp> quote USER adam2 ftp> quote PASS adam2 ftp> binary ftp> debug ftp> passive ftp> quote MEDIA FLSH ftp> put openwrt-sysupgrade.bin mtd1 Note that this procedure might take up to two minutes. You need to powercycle the Device afterwards to boot OpenWRT. Signed-off-by: David Bauer <mail@david-bauer.net>
* ath79: add support for Comfast CF-WR752AC v1Roman Hampel2020-04-091-3/+4
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Specifications: - Qualcomm QCA9531 + QCA9886 - dual band, antenna 2*3dBi - Output power 50mW (17dBm) - 1x 10/100 Mbps LAN RJ45 - 128 MB RAM / 16 MB FLASH (w25q128) - 3 LEDs (red/green/blue) incorporated in "color wheel reset switch" - UART 115200 8N1 Flashing instructions: The U-boot bootloader contains a recovery HTTP server to upload the firmware. Push the reset button while powering the device on and keep it pressed for ~10 seconds. The device's LEDs will blink several times and the recovery page will be at http://192.168.1.1; use it to upload the sysupgrade image. Alternatively, the original firmware is based on OpenWrt so a sysupgrade image can be installed via the stock web GUI. Settings from the original firmware will be saved and restored on the new one, so a factory reset will be needed. To do so, once the new firmware is flashed, enter into failsafe mode by pressing the reset button several times during the boot process, until it starts flashing. Once in failsafe mode, perform a factory reset as usual. LED-Info: The LEDs on the Comfast stock fw have a very proprietary behaviour, corresponding to the user selected working mode (AP, ROUTER or REPEATER). In the first two cases, only blue is used for status and LAN signaling. When using the latter, blue is always off (except for sysupgrade), either red signals bad rssi on master-link, or green good. Since the default working mode of OpenWrt resembles that of a router/AP, the default behavior is implemented accordingly. MAC addresses (art partition): location address (example) use in vendor firmware 0x0 xx:xx:xx:xx:xc:f8 -> eth0 0x6 xx:xx:xx:xx:xc:fa -> wlan5g (+2) 0x1002 xx:xx:xx:xx:xc:f9 -> not used 0x5006 xx:xx:xx:xx:xc:fb -> not used --- xx:xx:xx:xx:xd:02 -> wlan2g (+10) The same strange situation has already been observed and documented for COMFAST CF-E560AC. Signed-off-by: Roman Hampel <rhamp@arcor.de> Co-developed-by: Joao Albuquerque <joaohccalbu@gmail.com> Signed-off-by: Joao Albuquerque <joaohccalbu@gmail.com> [adjust and extend commit message, rebase, minor DTS adjustments, add correct MAC address for wmac, change RSSI LED names and behavior] Signed-off-by: Adrian Schmutzler <freifunk@adrianschmutzler.de>
* ath79: add support for Comfast CF-EW72Chris Morgan2020-04-071-0/+4
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Specifications: Qualcomm/Atheros QCA9531 + QCA9886 2x 10/100 Mbps Ethernet, with 48v PoE 2T2R 2.4 GHz, 802.11b/g/n 2T2R 5 GHz, 802.11a/n/ac 128MB RAM 16MB SPI Flash 4x LED (Always On Power, LAN, WAN, WLAN) Flashing Instructions: Original firmware is based on OpenWRT, so flashing the sysupgrade image on the factory firmware is sufficient. Tested: Reset button, WAN LED, LAN LED, Power LED (always on, not much to test), WLAN LED (one LED only for 2 interfaces, by default it gets assigned to the first interface), MAC addresses (match factory firmware). My LAN factory MAC address ends in F2. use stock_mac art_loc lan :f2 0x0 wan :f3 0x1002 5g :f4 0x6 2g :f5 0x5006 Since MAC address flash locations do not really match their use in vendor firmware (e.g. address from 5 GHz calibration data is assigned to 2.4 GHz WiFi), just calculate the MAC addresses with an offset based on 0x0 address. Signed-off-by: Chris Morgan <macromorgan@hotmail.com> [add MAC address comment] Signed-off-by: Adrian Schmutzler <freifunk@adrianschmutzler.de>
* ath79: add support for Ubiquiti NanoBridge M (XM)Roger Pueyo Centelles2020-03-221-0/+1
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | This patch adds support for the Ubiquiti NanoBridge M (XM), a 802.11n wireless with a feed+dish form factor, with the same board definition as the Bullet M (XM). Specifications: - Atheros AR7241 SoC - 32 MB RAM - 8 MB SPI flash - 1x 10/100 Mbps Ethernet port, 24 Vdc PoE-in - Power and LAN green LEDs - 4x RSSI LEDs (red, orange, green, green) - UART (115200 8N1) Flashing via stock GUI: - WARNING: flashing OpenWrt from AirOS v5.6 or newer will brick your device! Read the wiki for more info. - Downgrade to AirOS v5.5.x (latest available is 5.5.11) first. - Upload the factory image via AirOS web GUI. Flashing via TFTP: - WARNING: flashing OpenWrt from AirOS v5.6 or newer will brick your device! Read the wiki for more info. - Downgrade to AirOS v5.5.x (latest available is 5.5.11) first. - Use a pointy tool (e.g., pen cap, slotted screwdriver) to keep the reset button pressed. - Power on the device (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> trace tftp> put openwrt-ath79-generic-xxxxx-ubnt_nanobridge-m-squashfs-factory.bin Signed-off-by: Roger Pueyo Centelles <roger.pueyo@guifi.net> [rebase, fix includes in DTS, add label MAC address, add SOC and fix sorting in generic-ubnt.mk] Signed-off-by: Adrian Schmutzler <freifunk@adrianschmutzler.de>
* ath79: add support for ubnt_bullet-m-ar7240 variantRussell Senior2020-03-211-0/+1
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | This adds support for the Ubiquiti Bullet M (AR7240). Specifications: - AR7240 SoC @ 400 MHz - 32 MB RAM - 8 MB SPI flash - 1x 10/100 Mbps Ethernet, 24 Vdc PoE-in - External antenna - POWER/LAN green LEDs - 4x RSSI LEDs (red, orange, green, green) - UART (115200 8N1) on PCB Flashing via WebUI: Upload the factory image via the stock firmware web UI. Attention: airOS firmware versions >= 5.6 have a new bootloader with an incompatible partition table! Please downgrade to <= 5.5 _before_ flashing OpenWrt! Refer to the device's Wiki page for further information. Flashing via TFTP: Same procedure as other Ubiquiti M boards. - Use a pointy tool (e.g., pen cap, paper clip) and keep the reset button on the device or on the PoE supply 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> trace tftp> put openwrt-ath79-generic-xxxxx-ubnt_bullet-m-ar7240-squashfs-factory.bin The "fixed-link" section of the device tree is needed to avoid errors like this: Generic PHY mdio.0:1f:04: Master/Slave resolution failed, maybe conflicting manual settings? With "fixed-link", the errors go away and eth0 comes up reliably. Signed-off-by: Russell Senior <russell@personaltelco.net> [fix SUPPORTED_DEVICES] Signed-off-by: Adrian Schmutzler <freifunk@adrianschmutzler.de>
* ath79: add support for TP-Link Archer D7/D7b v1Davide Fioravanti2020-03-181-0/+4
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | TP-Link Archer D7 v1 is a dual-band AC1750 router + modem. The router section is based on Qualcomm/Atheros QCA9558 + QCA9880. The "DSL" section is based on BCM6318 but it's currently not supported. The Archer D7b seems to differ from the Archer D7 only in the partition table. Router section - Specification: 775/650/258 MHz (CPU/DDR/AHB) 128 MB of RAM (DDR2) 16 MB of FLASH (SPI NOR) 3T3R 2.4 GHz 3T3R 5 GHz 4x 10/100/1000 Mbps Ethernet 7x LED, 2x button UART header on PCB Known issues: - Broadband LED (missing GPIO - probably driven by the BCM6318) - Internet LED (missing GPIO - probably driven by the BCM6318) - WIFI LED (working only for one interface at a time, while in the OEM firmware works for both wifi interfaces; thus, this patch does not set a trigger by default) - DSL not working (eth0) UART connection --------------- J1 HEADER (Qualcomm CPU) . VCC . GND . RX O TX J41 HEADER (Broadcom CPU) . VCC . GND . RX O TX The following instructions require a connection to the J1 UART header and are tested for the Archer D7 v1. For the Archer D7b v1, names should be changed accordingly. Flash instructions under U-Boot, using UART ------------------------------------------ 1. Press "tpl" to stop autobooting and obtain U-Boot CLI access. 2. Setup ip addresses for U-Boot and your tftp server. 3. Issue below commands: tftpboot 0x81000000 openwrt-ath79-generic-tplink_archer-d7-v1-squashfs-sysupgrade.bin erase 0x9f020000 +f90000 cp.b 0x81000000 0x9f020000 0xf90000 reset Initramfs instructions under U-Boot for testing, using UART ---------------------------------------------------------- 1. Press "tpl" to stop autobooting and obtain U-Boot CLI access. 2. Setup ip addresses for U-Boot and your tftp server. 3. Issue below commands: tftpboot 0x81000000 openwrt-ath79-generic-tplink_archer-d7-v1-initramfs-kernel.bin bootm 0x81000000 4. Here you can backup the original firmware and/or flash the sysupgrade openwrt if you want Restore the original firmware ----------------------------- 0. Backup every partition using the OpenWrt web interface 1. Download the OEM firmware from the TP-Link website 2. Extract the bin file in a folder (eg. Archer_D7v1_1.6.0_0.9.1_up_boot(160216)_2016-02-16_15.55.48.bin) 3. Remove the U-Boot and the Broadcom image part from the file. Issue the following command: dd if="Archer_D7v1_1.6.0_0.9.1_up_boot(160216)_2016-02-16_15.55.48.bin" of="Archer_D7v1_1.6.0_0.9.1_up_boot(160216)_2016-02-16_15.55.48.bin.mod" skip=257 bs=512 count=31872 4. Double check the .mod file size. It must be 16318464 bytes. 5. Flash it using the OpenWrt web interface. Force the update if needed. WARNING: Remember to NOT keep settings. 5b. (Alternative to 5.) Flash it using the U-Boot and UART connection. Issue below commands in the U-Boot: tftpboot 0x81000000 Archer_D7v1_1.6.0_0.9.1_up_boot(160216)_2016-02-16_15.55.48.bin.mod erase 0x9f020000 +f90000 cp.b 0x81000000 0x9f020000 0xf90000 reset Signed-off-by: Davide Fioravanti <pantanastyle@gmail.com> [cosmetic DTS changes, remove TPLINK_HWREVADD := 0, do not use two phyXtpt at once, add missing buttons, minor commit message adjustments] Signed-off-by: Adrian Schmutzler <freifunk@adrianschmutzler.de>
* ath79: add support for TP-Link Archer C60 v3Adrian Schmutzler2020-03-181-1/+2
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | TP-Link Archer C60 v3 is a dual-band AC1350 router, based on Qualcomm/Atheros QCA9561 + QCA9886. It seems to be identical to the v2 revision, except that it lacks a WPS LED and has different GPIO for amber WAN LED. Specification: - 775/650/258 MHz (CPU/DDR/AHB) - 64 MB of RAM (DDR2) - 8 MB of FLASH (SPI NOR) - 3T3R 2.4 GHz - 2T2R 5 GHz - 5x 10/100 Mbps Ethernet - 6x LED, 2x button - UART header on PCB Flash instruction (WebUI): Download *-factory.bin image and upload it via the firmwary upgrade function of the stock firmware WebUI. Flash instruction (TFTP): 1. Set PC to fixed IP address 192.168.0.66 2. Download *-factory.bin image and rename it to tp_recovery.bin 3. Start a tftp server with the file tp_recovery.bin in its root directory 4. Turn off the router 5. Press and hold reset button 6. Turn on router with the reset button pressed and wait ~15 seconds 7. Release the reset button and after a short time the firmware should be transferred from the tftp server 8. Wait ~30 second to complete recovery While TFTP works for OpenWrt images, my device didn't accept the only available official firmware "Archer C60(EU)_V3.0_190115.bin". In contrast to earlier revisions (v2), the v3 contains the (same) MAC address twice, once in 0x1fa08 and again in 0x1fb08. While the partition-table on the device refers to the latter, the firmware image contains a different partition-table for that region: name device firmware factory-boot 0x00000-0x1fb00 0x00000-0x1fa00 default-mac 0x1fb00-0x1fd00 0x1fa00-0x1fc00 pin 0x1fd00-0x1fe00 0x1fc00-0x1fd00 product-info 0x1fe00-0x1ff00 0x1fd00-0x1ff00 device-id 0x1ff00-0x20000 0x1ff00-0x20000 While the MAC address is present twice, other data like the PIN isn't, so with the partitioning from the firmware image the PIN on the device would actually be outside of its partition. Consequently, the patch uses the MAC location from the device (which is the same as for the v2). Signed-off-by: Adrian Schmutzler <freifunk@adrianschmutzler.de>
* ath79: rename ubnt_bullet-m to ubnt_bullet-m-ar7241Russell Senior2020-03-181-1/+1
| | | | | | | | | | | Since there exists another variant of the Bullet M with AR7240 SoC under the same name, this patch introduces the SoC into the device name to be able to distinguish these variants. Signed-off-by: Russell Senior <russell@personaltelco.net> [add commit message, adjust model in DTS, fix 02_network and SUPPORTED_DEVICES] Signed-off-by: Adrian Schmutzler <freifunk@adrianschmutzler.de>
* ath79: add support for Devolo Magic 2 WIFIManuel Giganto2020-03-071-0/+3
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | This patch support Devolo Magic 2 WIFI, board devolo_dlan2-2400-ac. This device is a plc wifi AC2400 router/extender with 2 Ethernet ports, has a G.hn PLC and uses LCMP protocol from Home Grid Forum. Hardware: SoC: AR9344 CPU: 560 MHz Flash: 16 MiB (W25Q128JVSIQ) RAM: 128 MiB DDR2 Ethernet: 2xLAN 10/100/1000 PLC: 88LX5152 (MaxLinear G.hn) PLC Flash: W25Q32JVSSIQ PLC Uplink: 1Gbps MIMO PLC Link: RGMII 1Gbps (WAN) WiFi: Atheros AR9340 2.4GHz 802.11bgn Atheros AR9882-BR4A 5GHz 802.11ac Switch: QCA8337, Port0:CPU, Port2:PLC, Port3:LAN1, Port4:LAN2 Button: 3x Buttons (Reset, wifi and plc) LED: 3x Leds (wifi, plc white, plc red) GPIO Switch: 11-PLC Pairing (Active Low) 13-PLC Enable 21-WLAN power MACs Details verified with the stock firmware: Radio1: 2.4 GHz &wmac *:4c Art location: 0x1002 Radio0: 5.0 GHz &pcie *:4d Art location: 0x5006 Ethernet &ethernet *:4e = 2.4 GHz + 2 PLC uplink --- *:4f = 2.4 GHz + 3 Label MAC address is from PLC uplink OEM SSID: echo devolo-$(grep SerialNumber /dev/mtd1 | grep -o ...$) OEM WiFi password: grep DlanSecurityID /dev/mtd1|tr -d -|cut -d'=' -f 2 Recommendations: Configure and link your PLC with OEM firmware BEFORE you flash the device. PLC configuration/link should remain in different memory and should work straight forward after flashing. Restrictions: PLC link detection to trigger plc red led is not available. PLC G.hn chip is not compatible with open-plc-tools, it uses LCMP protocol with AES-128 and requires different software. Notes: Pairing should be possible with gpio switch. Default configuration will trigger wifi led with 2.4Ghz wifi traffic and plc white led with wan traffic. Flash instruction (TFTP): 1. Set PC to fixed ip address 192.168.0.100 2. Download the sysupgrade image and rename it to uploadfile 3. Start a tftp server with the image file in its root directory 4. Turn off the router 5. Press and hold Reset button 6. Turn on router with the reset button pressed and wait ~15 seconds 7. Release the reset button and after a short time the firmware should be transferred from the tftp server 8. Allow 1-2 minutes for the first boot. Signed-off-by: Manuel Giganto <mgigantoregistros@gmail.com>
* ath79: add support for Ubiquiti Picostation M (XM)Adrian Schmutzler2020-02-191-0/+1
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | This adds support for the Ubiquiti Picostation M (XM), which has the same board/LEDs as the Bullet M XM, but different case and antennas. Specifications: - AR7241 SoC @ 400 MHz - 32 MB RAM - 8 MB SPI flash - 1x 10/100 Mbps Ethernet, 24 Vdc PoE-in - External antenna: 5 dBi (USA), 2 dBi (EU) - POWER/LAN green LEDs - 4x RSSI LEDs (red, orange, green, green) - UART (115200 8N1) on PCB Flashing via WebUI: Upload the factory image via the stock firmware web UI. Attention: airOS firmware versions >= 5.6 have a new bootloader with an incompatible partition table! Please downgrade to <= 5.5 _before_ flashing OpenWrt! Refer to the device's Wiki page for further information. Flashing via TFTP: Same procedure as other NanoStation M boards. - Use a pointy tool (e.g., pen cap, paper clip) and keep the reset button on the device or on the PoE supply 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> trace tftp> put openwrt-ath79-generic-xxxxx-ubnt_picostation-m-squashfs-factory.bin Signed-off-by: Adrian Schmutzler <freifunk@adrianschmutzler.de>
* ath79: add support for Ubiquiti Nanostation Loco M (XM)Sven Roederer2020-02-191-0/+1
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | This adds support for the Ubiquiti Nanostation Loco M (XM), which has the same board/LEDs as the Bullet M XM, but different case and antennas. Specifications: - AR7241 SoC @ 400 MHz - 32 MB RAM - 8 MB SPI flash - 1x 10/100 Mbps Ethernet, 24 Vdc PoE-in - NS Loco M2: built-in antenna: 8 dBi; AR9287 - NS Loco M5: built-in antenna: 13 dBi; 2T2R 5 GHz radio - POWER/LAN green LEDs - 4x RSSI LEDs (red, orange, green, green) - UART (115200 8N1) on PCB Flashing via WebUI: Upload the factory image via the stock firmware web UI. Note that only certain firmware versions accept unsigned images. Refer to the device's Wiki page for further information. Flashing via TFTP: Same procedure as other NanoStation M boards. - Use a pointy tool (e.g., pen cap, paper clip) and keep the reset button on the device or on the PoE supply 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> trace tftp> put openwrt-ath79-generic-xxxxx-ubnt_nanostation-loco-m-squashfs-factory.bin Tested on NanoStation Loco M2. Signed-off-by: Sven Roederer <freifunk@it-solutions.geroedel.de> Co-developed-by: Adrian Schmutzler <freifunk@adrianschmutzler.de> Signed-off-by: Adrian Schmutzler <freifunk@adrianschmutzler.de>