Specification ------------- - SoC : MediaTek MT7981BA dual-core ARM Cortex-A53 1.3GHz - RAM : DDR3 256Mbytes, ESMT M15T2G16128A - Flash : 128Mbytes NAND Flash, ESMT F50L1G41LB - WLAN : MediaTek MT7976CN dual-band Wi-Fi 6 - 2.4GHz : b/g/n/ax, MU-MIMO - 5GHz : a/n/ac/ax, MU-MIMO - Ethernet : MediaTek MT7531AE - LAN : 10/100/1000 Mbps x4 - WAN : 10/100/1000 Mbps x1 - UART : 1x4 pin header on PCB - [J6] TX, RX, GND, 3.3V (115200, 8N1) - Buttons : WPS, Reset - LEDs : 1x CPU (Amber) 1x Wi-Fi 5GHz (Amber) 1x Wi-Fi 2.4GHz (Amber) 1x WAN activity (Amber) 4x LAN activity (Amber) - Power : 12VDC, 1A (Center positive polarity) MAC address ----------- +-----------+-------------------+-----------------------+ | Interface | MAC | Algorithm | +-----------+-------------------+-----------------------+ | WLAN 2.4G | B0:38:6C:48:xx:xx | label | | WLAN 5G | B2:38:6C:48:xx:xx | label with LA Bit Set | | WAN | B0:38:6C:48:xx:xx | label + 1 | | LAN | B0:38:6C:48:xx:xx | label + 3 | +-----------+-------------------+-----------------------+ The WLAN 2.4G MAC was found in 'Factory' partition, 0x4 Installation ------------ 1. Download the OEM recovery software from the manufacturer's website 2. Download the *squashfs-factory.bin file from the OpenWrt website 3. Press a reset button, and power up the router(keep pressing the reset button) 4. Wait more than 10 seconds until the CPU LED stop blinking 5. Connect the router(LAN port) to the PC 6. Replace a file in the OEM recovery software with the file from step 2 7. Run the OEM recovery software and follow the instructions 8. Wait for the router to boot from *squashfs-factory.bin Signed-off-by: Donghyun Ko <nyankosoftware@gmail.com> Link: https://github.com/openwrt/openwrt/pull/19368 Signed-off-by: Hauke Mehrtens <hauke@hauke-m.de>
245 lines
11 KiB
Text
245 lines
11 KiB
Text
. /lib/functions/leds.sh
|
|
. /lib/functions/uci-defaults.sh
|
|
|
|
board=$(board_name)
|
|
|
|
board_config_update
|
|
|
|
case $board in
|
|
abt,asr3000)
|
|
ucidef_set_led_netdev "wan" "WAN" "green:wan" "eth1"
|
|
ucidef_set_led_netdev "wlan2g" "WLAN2G" "green:wlan-2ghz" "phy0-ap0"
|
|
ucidef_set_led_netdev "wlan5g" "WLAN5G" "green:wlan-5ghz" "phy1-ap0"
|
|
;;
|
|
acer,predator-w6|\
|
|
acer,predator-w6d)
|
|
ucidef_set_led_netdev "internet" "INTERNET" "mdio-bus:06:amber:wan" "eth1" "link_10 link_100 link_1000 tx rx"
|
|
ucidef_set_led_netdev "internet" "INTERNET" "mdio-bus:06:green:wan" "eth1" "link_2500 tx rx"
|
|
;;
|
|
asus,rt-ax52|\
|
|
snr,snr-cpe-ax2)
|
|
ucidef_set_led_netdev "wan" "wan" "blue:wan" "wan" "link tx rx"
|
|
;;
|
|
asus,tuf-ax4200)
|
|
ucidef_set_led_netdev "wan" "WAN" "mdio-bus:06:white:wan" "eth1" "link tx rx"
|
|
;;
|
|
asus,tuf-ax6000)
|
|
ucidef_set_led_netdev "lan5" "LAN5" "mdio-bus:05:white:lan" "lan5" "link tx rx"
|
|
ucidef_set_led_netdev "wan" "WAN" "mdio-bus:06:white:wan" "eth1" "link tx rx"
|
|
;;
|
|
confiabits,mt7981)
|
|
ucidef_set_led_netdev "lan1" "lan1" "blue:lan-1" "lan1" "link tx rx"
|
|
ucidef_set_led_netdev "lan2" "lan2" "blue:lan-2" "lan2" "link tx rx"
|
|
ucidef_set_led_netdev "lan3" "lan3" "blue:lan-3" "lan3" "link tx rx"
|
|
ucidef_set_led_netdev "wan" "wan" "blue:wan" "wan" "link tx rx"
|
|
;;
|
|
bananapi,bpi-r3-mini)
|
|
ucidef_set_led_netdev "lan1" "LAN" "mdio-bus:0e:green:lan" "eth0" "link_2500 link_1000 tx rx"
|
|
ucidef_set_led_netdev "lan2" "LAN" "mdio-bus:0e:yellow:lan" "eth0" "link_2500 link_100 tx rx"
|
|
ucidef_set_led_netdev "wan1" "WAN" "mdio-bus:0f:green:wan" "eth1" "link_2500 link_1000 tx rx"
|
|
ucidef_set_led_netdev "wan2" "WAN" "mdio-bus:0f:yellow:wan" "eth1" "link_2500 link_100 tx rx"
|
|
ucidef_set_led_netdev "wlan2g" "WLAN2G" "blue:wlan-1" "phy0-ap0"
|
|
ucidef_set_led_netdev "wlan5g" "WLAN5G" "blue:wlan-2" "phy1-ap0"
|
|
;;
|
|
bananapi,bpi-r4|\
|
|
bananapi,bpi-r4-2g5|\
|
|
bananapi,bpi-r4-poe)
|
|
ucidef_set_led_netdev "wan" "wan" "mt7530-0:00:green:wan" "wan" "link tx rx"
|
|
ucidef_set_led_netdev "lan1" "lan1" "mt7530-0:01:green:lan" "lan1" "link tx rx"
|
|
ucidef_set_led_netdev "lan2" "lan2" "mt7530-0:02:green:lan" "lan2" "link tx rx"
|
|
ucidef_set_led_netdev "lan3" "lan3" "mt7530-0:03:green:lan" "lan3" "link tx rx"
|
|
;;
|
|
cudy,re3000-v1|\
|
|
wavlink,wl-wn573hx3)
|
|
ucidef_set_led_netdev "lan" "lan" "green:lan" "eth0" "link tx rx"
|
|
;;
|
|
cudy,wr3000-v1)
|
|
ucidef_set_led_netdev "wan" "wan" "blue:wan" "wan"
|
|
;;
|
|
cudy,wr3000h-v1)
|
|
ucidef_set_led_netdev "lan1" "lan1" "white:lan-1" "lan1" "link tx rx"
|
|
ucidef_set_led_netdev "lan2" "lan2" "white:lan-2" "lan2" "link tx rx"
|
|
ucidef_set_led_netdev "lan3" "lan3" "white:lan-3" "lan3" "link tx rx"
|
|
ucidef_set_led_netdev "lan4" "lan4" "white:lan-4" "lan4" "link tx rx"
|
|
ucidef_set_led_netdev "wan" "wan" "white:wan" "wan" "link tx rx"
|
|
ucidef_set_led_netdev "internet" "internet" "white:wan-online" "wan" "link"
|
|
;;
|
|
elecom,wrc-x3000gs3)
|
|
ucidef_set_led_netdev "wan" "wan" "green:wan" "wan"
|
|
;;
|
|
glinet,gl-x3000|\
|
|
glinet,gl-xe3000)
|
|
ucidef_set_led_default "power" "POWER" "green:power" "1"
|
|
ucidef_set_led_netdev "wan" "WAN" "green:wan" "eth0"
|
|
ucidef_set_led_netdev "5g_1" "5G_1" "green:5g:led1" "wwan0"
|
|
ucidef_set_led_netdev "5g_2" "5G_2" "green:5g:led2" "wwan0"
|
|
ucidef_set_led_netdev "5g_3" "5G_3" "green:5g:led3" "wwan0"
|
|
ucidef_set_led_netdev "5g_4" "5G_4" "green:5g:led4" "wwan0"
|
|
ucidef_set_led_netdev "wlan2g" "WLAN2G" "green:wifi2g" "phy0-ap0"
|
|
ucidef_set_led_netdev "wlan5g" "WLAN5G" "green:wifi5g" "phy1-ap0"
|
|
;;
|
|
huasifei,wh3000)
|
|
ucidef_set_led_netdev "wan" "WAN" "red:wan" "eth1" "link tx rx"
|
|
;;
|
|
iptime,ax3000q)
|
|
ucidef_set_led_netdev "wan" "WAN" "amber:wan" "wan" "link tx rx"
|
|
;;
|
|
iptime,ax3000sm)
|
|
ucidef_set_led_netdev "wan" "wan" "amber:wan" "eth1" "link tx rx"
|
|
;;
|
|
mercusys,mr80x-v3)
|
|
ucidef_set_led_netdev "lan1" "lan-1" "green:lan-1" "lan1" "link tx rx"
|
|
ucidef_set_led_netdev "lan2" "lan-2" "green:lan-2" "lan2" "link tx rx"
|
|
ucidef_set_led_netdev "lan3" "lan-3" "green:lan-3" "lan3" "link tx rx"
|
|
ucidef_set_led_netdev "wan" "wan" "green:wan" "wan" "link tx rx"
|
|
;;
|
|
mercusys,mr90x-v1|\
|
|
mercusys,mr90x-v1-ubi)
|
|
ucidef_set_led_netdev "lan-0" "lan-0" "green:lan-0" "lan0" "link tx rx"
|
|
ucidef_set_led_netdev "lan-1" "lan-1" "green:lan-1" "lan1" "link tx rx"
|
|
ucidef_set_led_netdev "lan-2" "lan-2" "green:lan-2" "lan2" "link tx rx"
|
|
ucidef_set_led_netdev "wan" "wan" "green:wan" "eth1" "link tx rx"
|
|
;;
|
|
netcore,n60)
|
|
ucidef_set_led_netdev "wan" "WAN" "mdio-bus:06:green:wan" "eth1" "link tx rx"
|
|
;;
|
|
netcore,n60-pro)
|
|
ucidef_set_led_netdev "lan1" "LAN1" "mdio-bus:05:green:lan" "lan1" "link tx rx"
|
|
ucidef_set_led_netdev "wanact" "WANACT" "mdio-bus:06:green:wan" "eth1" "tx rx"
|
|
ucidef_set_led_netdev "wanlink" "WANLINK" "blue:wan" "eth1" "link"
|
|
;;
|
|
netgear,wax220)
|
|
ucidef_set_led_netdev "eth0" "LAN" "green:lan" "eth0"
|
|
;;
|
|
netis,nx31)
|
|
ucidef_set_led_netdev "wan" "wan" "blue:wan" "eth1" "link tx rx"
|
|
;;
|
|
nokia,ea0326gmp)
|
|
ucidef_set_led_netdev "wan" "WAN" "green:wan" "eth1" "link"
|
|
ucidef_set_led_netdev "lan" "LAN" "green:lan" "br-lan" "link"
|
|
ucidef_set_led_netdev "wlan" "WLAN" "green:wlan" "phy1-ap0" "link"
|
|
;;
|
|
nradio,c8-668gl)
|
|
ucidef_set_led_netdev "wifi" "WIFI" "blue:wlan" "phy1-ap0" "link"
|
|
ucidef_set_led_netdev "5g" "5G" "blue:indicator-0" "eth1" "link"
|
|
;;
|
|
openembed,som7981)
|
|
ucidef_set_led_netdev "lanact" "LANACT" "amber:lan" "eth1" "rx tx"
|
|
ucidef_set_led_netdev "lanlink" "LANLINK" "green:lan" "eth1" "link"
|
|
;;
|
|
openwrt,one)
|
|
ucidef_set_led_netdev "wanact" "WANACT" "mdio-bus:0f:green:wan" "eth0" "rx tx"
|
|
ucidef_set_led_netdev "wanlink" "WANLINK" "mdio-bus:0f:amber:wan" "eth0" "link"
|
|
ucidef_set_led_netdev "lanact" "LANACT" "green:lan" "eth1" "rx tx"
|
|
ucidef_set_led_netdev "lanlink" "LANLINK" "amber:lan" "eth1" "link"
|
|
;;
|
|
routerich,ax3000|\
|
|
routerich,ax3000-ubootmod)
|
|
ucidef_set_led_netdev "lan-1" "lan-1" "blue:lan-1" "lan1" "link tx rx"
|
|
ucidef_set_led_netdev "lan-2" "lan-2" "blue:lan-2" "lan2" "link tx rx"
|
|
ucidef_set_led_netdev "lan-3" "lan-3" "blue:lan-3" "lan3" "link tx rx"
|
|
ucidef_set_led_netdev "wan" "wan" "blue:wan" "wan" "link tx rx"
|
|
ucidef_set_led_netdev "wan-off" "wan-off" "red:wan" "wan" "link"
|
|
;;
|
|
routerich,ax3000-v1)
|
|
ucidef_set_led_netdev "lan-1" "lan-1" "blue:lan-1" "lan1" "link tx rx"
|
|
ucidef_set_led_netdev "lan-2" "lan-2" "blue:lan-2" "lan2" "link tx rx"
|
|
ucidef_set_led_netdev "lan-3" "lan-3" "blue:lan-3" "lan3" "link tx rx"
|
|
ucidef_set_led_netdev "wan" "wan" "blue:wan" "eth1" "link tx rx"
|
|
ucidef_set_led_netdev "wan-off" "wan-off" "red:wan" "eth1" "link"
|
|
;;
|
|
smartrg,sdg-8612)
|
|
ucidef_set_led_netdev "lan4" "LAN4" "mdio-bus:05:amber:lan" "lan4" "link_10 link_100"
|
|
ucidef_set_led_netdev "lan4" "LAN4" "mdio-bus:05:green:lan-0" "lan4" "link_1000"
|
|
ucidef_set_led_netdev "lan4" "LAN4" "mdio-bus:05:green:lan-1" "lan4" "link_2500"
|
|
ucidef_set_led_netdev "wan" "WAN" "mdio-bus:06:amber:wan" "eth1" "link_10 link_100"
|
|
ucidef_set_led_netdev "wan" "WAN" "mdio-bus:06:green:wan-0" "eth1" "link_1000"
|
|
ucidef_set_led_netdev "wan" "WAN" "mdio-bus:06:green:wan-1" "eth1" "link_2500"
|
|
;;
|
|
smartrg,sdg-8614)
|
|
ucidef_set_led_netdev "lan4" "LAN4" "mdio-bus:05:amber:lan" "lan4" "link_10 link_100"
|
|
ucidef_set_led_netdev "lan4" "LAN4" "mdio-bus:05:green:lan-0" "lan4" "link_1000"
|
|
ucidef_set_led_netdev "lan4" "LAN4" "mdio-bus:05:green:lan-1" "lan4" "link_2500"
|
|
;;
|
|
smartrg,sdg-8622|\
|
|
smartrg,sdg-8632)
|
|
ucidef_set_led_netdev "lan" "LAN" "mdio-bus:05:amber:lan" "lan" "link_10 link_100"
|
|
ucidef_set_led_netdev "lan" "LAN" "mdio-bus:05:green:lan-0" "lan" "link_1000"
|
|
ucidef_set_led_netdev "lan" "LAN" "mdio-bus:05:green:lan-1" "lan" "link_2500"
|
|
ucidef_set_led_netdev "wan" "WAN" "mdio-bus:06:amber:wan" "eth1" "link_10 link_100"
|
|
ucidef_set_led_netdev "wan" "WAN" "mdio-bus:06:green:wan-0" "eth1" "link_1000"
|
|
ucidef_set_led_netdev "wan" "WAN" "mdio-bus:06:green:wan-1" "eth1" "link_2500"
|
|
;;
|
|
smartrg,sdg-8733|\
|
|
smartrg,sdg-8734)
|
|
ucidef_set_led_netdev "lan-1-green" "LAN1" "mdio-bus:08:green:lan" "lan1" "link_2500 link_5000"
|
|
ucidef_set_led_netdev "lan-1-orange" "LAN1" "mdio-bus:08:orange:lan" "lan1" "link_100 link_1000"
|
|
ucidef_set_led_netdev "lan-1-white" "LAN1" "mdio-bus:08:white:lan" "lan1" "link_10000"
|
|
ucidef_set_led_netdev "lan-2-green" "LAN2" "mt7530-0:01:green:lan" "lan2" "link_1000"
|
|
ucidef_set_led_netdev "lan-2-amber" "LAN2" "mt7530-0:01:amber:lan" "lan2" "link_100 link_10"
|
|
ucidef_set_led_netdev "lan-3-green" "LAN3" "mt7530-0:02:green:lan" "lan3" "link_1000"
|
|
ucidef_set_led_netdev "lan-3-amber" "LAN3" "mt7530-0:02:amber:lan" "lan3" "link_100 link_10"
|
|
ucidef_set_led_netdev "lan-4-green" "LAN4" "mt7530-0:03:green:lan" "lan4" "link_1000"
|
|
ucidef_set_led_netdev "lan-4-amber" "LAN4" "mt7530-0:03:amber:lan" "lan4" "link_100 link_10"
|
|
ucidef_set_led_netdev "wan-green" "WAN" "mdio-bus:00:green:wan" "wan" "link_2500 link_5000"
|
|
ucidef_set_led_netdev "wan-orange" "WAN" "mdio-bus:00:orange:wan" "wan" "link_100 link_1000"
|
|
ucidef_set_led_netdev "wan-white" "WAN" "mdio-bus:00:white:wan" "wan" "link_10000"
|
|
;;
|
|
smartrg,sdg-8733a)
|
|
ucidef_set_led_netdev "lan-green-act" "LAN" "mdio-bus:0f:green:lan" "lan" "link_2500"
|
|
ucidef_set_led_netdev "lan-amber" "LAN" "amber:lan" "lan" "link_100"
|
|
ucidef_set_led_netdev "lan-green" "LAN" "green:lan" "lan" "link_1000"
|
|
ucidef_set_led_netdev "wan-green" "WAN" "mdio-bus:08:green:wan" "wan" "link_2500 link_5000"
|
|
ucidef_set_led_netdev "wan-orange" "WAN" "mdio-bus:08:orange:wan" "wan" "link_100 link_1000"
|
|
ucidef_set_led_netdev "wan-white" "WAN" "mdio-bus:08:white:wan" "wan" "link_10000"
|
|
;;
|
|
tplink,fr365-v1)
|
|
ucidef_set_led_netdev "port2-green-act" "port-2" "green:port2_act" "port2" "link tx rx"
|
|
ucidef_set_led_netdev "port1-green-act" "port-1" "green:sfp" "port1" "link tx rx"
|
|
ucidef_set_led_netdev "wlan" "wlan" "green:wlan" "phy1-ap0"
|
|
;;
|
|
tplink,re6000xd)
|
|
ucidef_set_led_netdev "lan-1" "lan-1" "blue:lan-0" "lan1" "link tx rx"
|
|
ucidef_set_led_netdev "lan-2" "lan-2" "blue:lan-1" "lan2" "link tx rx"
|
|
ucidef_set_led_netdev "eth1" "lan-3" "blue:lan-2" "eth1" "link tx rx"
|
|
;;
|
|
wavlink,wl-wn586x3)
|
|
ucidef_set_led_netdev "lan-1" "lan-1" "blue:lan-1" "lan1" "link tx rx"
|
|
ucidef_set_led_netdev "lan-2" "lan-2" "blue:lan-2" "lan2" "link tx rx"
|
|
ucidef_set_led_netdev "wan" "wan" "blue:wan" "eth1" "link tx rx"
|
|
;;
|
|
xiaomi,mi-router-wr30u-stock|\
|
|
xiaomi,mi-router-wr30u-ubootmod)
|
|
ucidef_set_led_netdev "wan" "wan" "blue:wan" "wan" "link tx rx"
|
|
;;
|
|
xiaomi,redmi-router-ax6000-stock|\
|
|
xiaomi,redmi-router-ax6000-ubootmod)
|
|
ucidef_set_led_netdev "wan" "wan" "rgb:network" "wan"
|
|
;;
|
|
zbtlink,zbt-z8103ax)
|
|
ucidef_set_led_netdev "wan" "wan" "green:wan" "eth1" "link tx rx"
|
|
;;
|
|
zyxel,ex5601-t0-stock|\
|
|
zyxel,ex5601-t0-ubootmod)
|
|
ucidef_set_led_netdev "lan1" "LAN1" "mdio-bus:05:green:lan" "lan1" "link tx rx"
|
|
ucidef_set_led_netdev "wan" "2.5G-WAN" "mdio-bus:06:green:wan" "eth1" "link_2500"
|
|
ucidef_set_led_netdev "lan" "LAN" "green:lan" "eth0" "link tx rx"
|
|
ucidef_set_led_netdev "internet" "INTERNET" "green:inet" "eth1" "link tx rx"
|
|
ucidef_set_led_netdev "wifi-24g" "WIFI-2.4G" "green:wifi24g" "phy0-ap0" "link tx rx"
|
|
ucidef_set_led_netdev "wifi-5g" "WIFI-5G" "green:wifi5g" "phy1-ap0" "link tx rx"
|
|
;;
|
|
zyxel,nwa50ax-pro)
|
|
ucidef_set_led_netdev "uplink" "UPLINK" "mdio-bus:05:amber:wan" "eth0" "link_10 link_100 link_2500 tx rx"
|
|
ucidef_set_led_netdev "uplink" "UPLINK" "mdio-bus:05:green:wan" "eth0" "link_1000 link_2500 tx rx"
|
|
;;
|
|
zyxel,ex5700-telenor)
|
|
ucidef_set_led_netdev "lan4" "LAN4" "mdio-bus:05:amber:lan" "lan4" "link_10 link_100 tx rx"
|
|
ucidef_set_led_netdev "lan4" "LAN4" "mdio-bus:05:green:lan" "lan4" "link tx rx"
|
|
ucidef_set_led_netdev "wan" "WAN" "mdio-bus:06:amber:wan" "eth1" "link_10 link_100 tx rx"
|
|
ucidef_set_led_netdev "wan" "WAN" "mdio-bus:06:green:wan" "eth1" "link tx rx"
|
|
;;
|
|
esac
|
|
|
|
board_config_flush
|
|
|
|
exit 0
|