Routing on 5GHz radio does not work (Wavlink WN570HA1)

Hi all!
I assembled my own firmware for Wavlink WN570HA1 (Soc MT 7628AN) on 23.05.2. Standard firmware was not installed due to a different memory model on PCB. I have applied a kernel patch for support.
My access point is in DUMB mode - without DHCP, firewall...
But a problem arose - clients on the 5GHz radio receive an IP address (and other settings), but do not have access to the network, including the point itself.

root@WN570HA1:~# cat /etc/board.json
{
        "model": {
                "id": "wavlink,wl-wn570ha1",
                "name": "Wavlink WL-WN570HA1"
        },
        "led": {
                "wan": {
                        "name": "wan",
                        "sysfs": "green:wan",
                        "trigger": "switch0",
                        "type": "switch",
                        "mode": "",
                        "port_mask": "0x01",
                        "speed_mask": ""
                },
                "wifi_low": {
                        "name": "",
                        "sysfs": "green:wifi-low",
                        "type": "rssi",
                        "iface": "wlan0",
                        "minq": "1",
                        "maxq": "49",
                        "offset": "0",
                        "factor": "1"
                },
                "wifi_med": {
                        "name": "",
                        "sysfs": "green:wifi-med",
                        "type": "rssi",
                        "iface": "wlan0",
                        "minq": "50",
                        "maxq": "84",
                        "offset": "0",
                        "factor": "1"
                },
                "wifi_high": {
                        "name": "",
                        "sysfs": "green:wifi-high",
                        "type": "rssi",
                        "iface": "wlan0",
                        "minq": "85",
                        "maxq": "100",
                        "offset": "0",
                        "factor": "1"
                },
                "wifi_led": {
                        "name": "wifi",
                        "sysfs": "green:wifi",
                        "type": "netdev",
                        "device": "wlan0",
                        "mode": "link tx rx"
                }
        },
        "rssimon": {
                "wlan0": {
                        "refresh": 200000,
                        "threshold": 1
                }
        },
        "switch": {
                "switch0": {
                        "enable": true,
                        "reset": true,
                        "ports": [
                                {
                                        "num": 0,
                                        "role": "lan"
                                },
                                {
                                        "num": 1,
                                        "role": "lan"
                                },
                                {
                                        "num": 2,
                                        "role": "lan"
                                },
                                {
                                        "num": 3,
                                        "role": "lan"
                                },
                                {
                                        "num": 4,
                                        "role": "wan"
                                },
                                {
                                        "num": 6,
                                        "device": "eth0",
                                        "need_tag": false,
                                        "want_untag": false
                                }
                        ],
                        "roles": [
                                {
                                        "role": "lan",
                                        "ports": "0 1 2 3 6t",
                                        "device": "eth0.1"
                                },
                                {
                                        "role": "wan",
                                        "ports": "4 6t",
                                        "device": "eth0.2"
                                }
                        ]
                }
        },
        "network": {
                "lan": {
                        "device": "eth0.1",
                        "protocol": "static"
                },
                "wan": {
                        "device": "eth0.2",
                        "protocol": "dhcp",
                        "macaddr": "80:3f:5d:58:f4:49"
                }
        }
}
root@WN570HA1:~# swconfig list
Found: switch0 - rt305x
root@WN570HA1:~# swconfig list
Found: switch0 - rt305x
root@WN570HA1:~# ^C

root@WN570HA1:~# cat /etc/config/network

config interface 'loopback'
        option device 'lo'
        option proto 'static'
        option ipaddr '127.0.0.1'
        option netmask '255.0.0.0'

config globals 'globals'
        option ula_prefix 'fd37:585b:2998::/48'

config device
        option name 'br-lan'
        option type 'bridge'
        list ports 'eth0.1'
        option ipv6 '0'

config interface 'lan'
        option device 'br-lan'
        option proto 'static'
        option ipaddr '192.168.172.101'
        option netmask '255.255.255.0'
        option ip6assign '60'
        option gateway '192.168.172.254'
        list dns '94.140.14.14'

config device
        option name 'eth0.2'
        option macaddr '80:3F:5D:58:F4:49'

config switch
        option name 'switch0'
        option reset '1'
        option enable_vlan '1'

config switch_vlan
        option device 'switch0'
        option vlan '1'
        option ports '0 1 2 3 6t'

config switch_vlan
        option device 'switch0'
        option vlan '2'
        option ports '4 6t'
root@WN570HA1:~# ifconfig
br-lan    Link encap:Ethernet  HWaddr 80:3F:5D:58:F4:48
          inet addr:192.168.172.101  Bcast:192.168.172.255  Mask:255.255.255.0
          UP BROADCAST RUNNING MULTICAST  MTU:1500  Metric:1
          RX packets:81310 errors:0 dropped:0 overruns:0 frame:0
          TX packets:34658 errors:0 dropped:0 overruns:0 carrier:0
          collisions:0 txqueuelen:1000
          RX bytes:6262212 (5.9 MiB)  TX bytes:13289047 (12.6 MiB)

eth0      Link encap:Ethernet  HWaddr 80:3F:5D:58:F4:48
          UP BROADCAST RUNNING MULTICAST  MTU:1500  Metric:1
          RX packets:1235879 errors:0 dropped:4 overruns:0 frame:0
          TX packets:577037 errors:0 dropped:0 overruns:0 carrier:0
          collisions:0 txqueuelen:1000
          RX bytes:1536855102 (1.4 GiB)  TX bytes:70132809 (66.8 MiB)
          Interrupt:5

eth0.1    Link encap:Ethernet  HWaddr 80:3F:5D:58:F4:48
          UP BROADCAST RUNNING MULTICAST  MTU:1500  Metric:1
          RX packets:1182492 errors:0 dropped:1342 overruns:0 frame:0
          TX packets:551027 errors:0 dropped:0 overruns:0 carrier:0
          collisions:0 txqueuelen:1000
          RX bytes:1469716193 (1.3 GiB)  TX bytes:62150586 (59.2 MiB)

lo        Link encap:Local Loopback
          inet addr:127.0.0.1  Mask:255.0.0.0
          UP LOOPBACK RUNNING  MTU:65536  Metric:1
          RX packets:54 errors:0 dropped:0 overruns:0 frame:0
          TX packets:54 errors:0 dropped:0 overruns:0 carrier:0
          collisions:0 txqueuelen:1000
          RX bytes:8168 (7.9 KiB)  TX bytes:8168 (7.9 KiB)

phy0-ap0  Link encap:Ethernet  HWaddr 80:3F:5D:58:F4:49
          UP BROADCAST RUNNING MULTICAST  MTU:1500  Metric:1
          RX packets:527921 errors:0 dropped:0 overruns:0 frame:0
          TX packets:1122936 errors:0 dropped:0 overruns:0 carrier:0
          collisions:0 txqueuelen:1000
          RX bytes:53367518 (50.8 MiB)  TX bytes:1506558383 (1.4 GiB)

phy0-mesh0 Link encap:Ethernet  HWaddr 82:3F:5D:58:F4:49
          UP BROADCAST RUNNING MULTICAST  MTU:1500  Metric:1
          RX packets:905 errors:0 dropped:0 overruns:0 frame:0
          TX packets:51051 errors:0 dropped:0 overruns:0 carrier:0
          collisions:0 txqueuelen:1000
          RX bytes:128834 (125.8 KiB)  TX bytes:4904388 (4.6 MiB)

phy1-ap0  Link encap:Ethernet  HWaddr 80:3F:5D:58:F4:4A
          UP BROADCAST RUNNING MULTICAST  MTU:1500  Metric:1
          RX packets:637 errors:0 dropped:0 overruns:0 frame:0
          TX packets:11118 errors:0 dropped:0 overruns:0 carrier:0
          collisions:0 txqueuelen:1000
          RX bytes:63235 (61.7 KiB)  TX bytes:1389414 (1.3 MiB)
root@WN570HA1:~# ip link
1: lo: <LOOPBACK,UP,LOWER_UP> mtu 65536 qdisc noqueue state UNKNOWN qlen 1000
    link/loopback 00:00:00:00:00:00 brd 00:00:00:00:00:00
2: eth0: <BROADCAST,MULTICAST,UP,LOWER_UP> mtu 1500 qdisc fq_codel state UP qlen 1000
    link/ether 80:3f:5d:58:f4:48 brd ff:ff:ff:ff:ff:ff
16: br-lan: <BROADCAST,MULTICAST,UP,LOWER_UP> mtu 1500 qdisc noqueue state UP qlen 1000
    link/ether 80:3f:5d:58:f4:48 brd ff:ff:ff:ff:ff:ff
17: eth0.1@eth0: <BROADCAST,MULTICAST,UP,LOWER_UP> mtu 1500 qdisc noqueue master br-lan state UP qlen 1000
    link/ether 80:3f:5d:58:f4:48 brd ff:ff:ff:ff:ff:ff
18: phy1-ap0: <BROADCAST,MULTICAST,UP,LOWER_UP> mtu 1500 qdisc noqueue master br-lan state UP qlen 1000
    link/ether 80:3f:5d:58:f4:4a brd ff:ff:ff:ff:ff:ff
19: phy0-ap0: <BROADCAST,MULTICAST,UP,LOWER_UP> mtu 1500 qdisc noqueue master br-lan state UP qlen 1000
    link/ether 80:3f:5d:58:f4:49 brd ff:ff:ff:ff:ff:ff
20: phy0-mesh0: <BROADCAST,MULTICAST,UP,LOWER_UP> mtu 1500 qdisc noqueue master br-lan state UP qlen 1000
    link/ether 82:3f:5d:58:f4:49 brd ff:ff:ff:ff:ff:ff

config interface 'wan'
option device 'eth0.2'
option proto 'dhcp'

a dump AP doesn't really need a WAN port.

2 Likes

Add interface.
In ifconfig and ip link new line:

eth0.2    Link encap:Ethernet  HWaddr 80:3F:5D:58:F4:49
          UP BROADCAST RUNNING MULTICAST  MTU:1500  Metric:1
          RX packets:0 errors:0 dropped:0 overruns:0 frame:0
          TX packets:327 errors:0 dropped:0 overruns:0 carrier:0
          collisions:0 txqueuelen:1000
          RX bytes:0 (0.0 B)  TX bytes:109722 (107.1 KiB)
35: eth0.2@eth0: <BROADCAST,MULTICAST,UP,LOWER_UP> mtu 1500 qdisc noqueue state UP qlen 1000
    link/ether 80:3f:5d:58:f4:49 brd ff:ff:ff:ff:ff:ff

But, no result...

The problem was completely different!!!
It turns out that if you select channels from 36 to 56 for a 5GHz radio, there is no Internet access.
But if you select channel 60 and higher, everything starts to work.
BUT! The speed is very low - 1-2MBit instead of 100MBit
And the transmitter power drops - the maximum possible for installation = 17dBm.

~# iw phy phy1 info
Wiphy phy1
        wiphy index: 1
        max # scan SSIDs: 4
        max scan IEs length: 2247 bytes
        max # sched scan SSIDs: 0
        max # match sets: 0
        Retry short limit: 7
        Retry long limit: 4
        Coverage class: 0 (up to 0m)
        Device supports AP-side u-APSD.
        Device supports T-DLS.
        Available Antennas: TX 0x1 RX 0x1
        Configured Antennas: TX 0x1 RX 0x1
        Supported interface modes:
                 * IBSS
                 * managed
                 * AP
                 * AP/VLAN
                 * monitor
                 * mesh point
                 * P2P-client
                 * P2P-GO
        Band 2:
                Capabilities: 0x17e
                        HT20/HT40
                        SM Power Save disabled
                        RX Greenfield
                        RX HT20 SGI
                        RX HT40 SGI
                        RX STBC 1-stream
                        Max AMSDU length: 3839 bytes
                        No DSSS/CCK HT40
                Maximum RX AMPDU length 65535 bytes (exponent: 0x003)
                Minimum RX AMPDU time spacing: No restriction (0x00)
                HT TX/RX MCS rate indexes supported: 0-7
                VHT Capabilities (0x31800120):
                        Max MPDU length: 3895
                        Supported Channel Width: neither 160 nor 80+80
                        short GI (80 MHz)
                        RX antenna pattern consistency
                        TX antenna pattern consistency
                VHT RX MCS set:
                        1 streams: MCS 0-9
                        2 streams: not supported
                        3 streams: not supported
                        4 streams: not supported
                        5 streams: not supported
                        6 streams: not supported
                        7 streams: not supported
                        8 streams: not supported
                VHT RX highest supported: 0 Mbps
                VHT TX MCS set:
                        1 streams: MCS 0-9
                        2 streams: not supported
                        3 streams: not supported
                        4 streams: not supported
                        5 streams: not supported
                        6 streams: not supported
                        7 streams: not supported
                        8 streams: not supported
                VHT TX highest supported: 0 Mbps
                VHT extended NSS: not supported
                Frequencies:
                        * 5180 MHz [36] (20.0 dBm)
                        * 5200 MHz [40] (19.0 dBm)
                        * 5220 MHz [44] (18.0 dBm)
                        * 5240 MHz [48] (18.0 dBm)
                        * 5260 MHz [52] (17.0 dBm)
                        * 5280 MHz [56] (17.0 dBm)
                        * 5300 MHz [60] (17.0 dBm)
                        * 5320 MHz [64] (17.0 dBm)
                        * 5500 MHz [100] (disabled)
                        * 5520 MHz [104] (disabled)
                        * 5540 MHz [108] (disabled)
                        * 5560 MHz [112] (disabled)
                        * 5580 MHz [116] (disabled)
                        * 5600 MHz [120] (disabled)
                        * 5620 MHz [124] (disabled)
                        * 5640 MHz [128] (disabled)
                        * 5660 MHz [132] (17.0 dBm)
                        * 5680 MHz [136] (17.0 dBm)
                        * 5700 MHz [140] (17.0 dBm)
                        * 5720 MHz [144] (18.0 dBm)
                        * 5745 MHz [149] (18.0 dBm)
                        * 5765 MHz [153] (18.0 dBm)
                        * 5785 MHz [157] (18.0 dBm)
                        * 5805 MHz [161] (18.0 dBm)
                        * 5825 MHz [165] (18.0 dBm)
                        * 5845 MHz [169] (disabled)
                        * 5865 MHz [173] (disabled)
                        * 5885 MHz [177] (disabled)
        valid interface combinations:
                 * #{ IBSS } <= 1, #{ managed, AP, mesh point, P2P-client, P2P-GO } <= 8,
                   total <= 8, #channels <= 1, STA/AP BI must match, radar detect widths: { 20 MHz (no HT), 20 MHz, 40 MHz, 80 MHz }

        HT Capability overrides:
                 * MCS: ff ff ff ff ff ff ff ff ff ff
                 * maximum A-MSDU length
                 * supported channel width
                 * short GI for 40 MHz
                 * max A-MPDU length exponent
                 * min MPDU start spacing
        max # scan plans: 1
        max scan plan interval: -1
        max scan plan iterations: 0
        Supported extended features:
                * [ VHT_IBSS ]: VHT-IBSS
                * [ RRM ]: RRM
                * [ FILS_STA ]: STA FILS (Fast Initial Link Setup)
                * [ CQM_RSSI_LIST ]: multiple CQM_RSSI_THOLD records
                * [ CONTROL_PORT_OVER_NL80211 ]: control port over nl80211
                * [ TXQS ]: FQ-CoDel-enabled intermediate TXQs
                * [ SCAN_RANDOM_SN ]: use random sequence numbers in scans
                * [ SCAN_MIN_PREQ_CONTENT ]: use probe request with only rate IEs in scans
                * [ AIRTIME_FAIRNESS ]: airtime fairness scheduling
                * [ AQL ]: Airtime Queue Limits (AQL)
                * [ CONTROL_PORT_NO_PREAUTH ]: disable pre-auth over nl80211 control port support
                * [ DEL_IBSS_STA ]: deletion of IBSS station support
                * [ SCAN_FREQ_KHZ ]: scan on kHz frequency support
                * [ CONTROL_PORT_OVER_NL80211_TX_STATUS ]: tx status for nl80211 control port support

Please provide the output of:

cat /etc/config/wireless

I think you misunderstood - it's not clear why you added an interface.

There are some other chips soldered on the board...
Wi-fi amplifiers - SKY85601 and SKY85405.
Maybe their support is needed for a normal signal level?

Are you able to provide the wireless config?


config wifi-device 'radio0'
	option type 'mac80211'
	option path 'platform/10300000.wmac'
	option channel '4'
	option band '2g'
	option cell_density '0'
	option htmode 'HT40'
	option noscan '1'
	option country 'RU'
	option antenna_gain '7'
	option txpower '16'

config wifi-device 'radio1'
	option type 'mac80211'
	option path 'pci0000:00/0000:00:00.0/0000:01:00.0'
	option channel '60'
	option band '5g'
	option htmode 'VHT80'
	option country 'RU'
	option antenna_gain '7'
	option cell_density '0'
	option noscan '1'

config wifi-iface 'wifinet0'
	option device 'radio0'
	option mode 'ap'
	option ssid 'VISCOUS'
	option encryption 'psk2+tkip+ccmp'
	option key ''
	option network 'lan'

config wifi-iface 'wifinet1'
	option device 'radio1'
	option mode 'ap'
	option ssid 'VICIOUS'
	option encryption 'psk2+tkip+ccmp'
	option key ''
	option network 'lan'

config wifi-iface 'wifinet2'
	option device 'radio0'
	option mode 'mesh'
	option encryption 'sae'
	option mesh_id '80211s-mesh'
	option mesh_fwding '1'
	option mesh_rssi_threshold '0'
	option key ''
	option network 'lan'


You know, your first post never mentions power - it just says you have some 5GHz issues.

You go on to note:

You then have a config of:

So, you configured your AP to subtract x+7 dB from WiFi (or override x)?!

Where x == the factory antenna gain. This is likely your issue. You shouldn't mess with advanced settings if you don't know what you're doing.

I didn't know that this command works for subtraction!
Thanks, I'll try!

To be clear, you're gonna try removing the gain setting, to fix your 5 GHz power issue, correct?

(The incomplete sentences are slightly confusing.)

no, on the contrary, I need to increase the signal level!

I understood that already. You cannot set a radio above the legal level. No settings exists that permits that.

Я это уже понял. Вы не можете установить радио выше установленного законом уровня. Никаких настроек, позволяющих это сделать, не существует.

I had one of these (bought very cheaply on Amazon). I ended up throwing it away, because the 5GHz side of the device was utter rubbish.

I couldn't tell you what version hardware it had, but there were many forum threads at the time referring to an inability to get the 5GHz radio to work properly.

I wrote it poorly - I need to increase the data transfer speed.
And so that the 5GHz radio would work in principle on channels 36 to 56!
Now with these settings:

config wifi-device 'radio0'
	option type 'mac80211'
	option path 'platform/10300000.wmac'
	option channel '4'
	option band '2g'
	option cell_density '0'
	option htmode 'HT40'
	option noscan '1'
	option country 'RU'
	
config wifi-device 'radio1'
	option type 'mac80211'
	option path 'pci0000:00/0000:00:00.0/0000:01:00.0'
	option channel '60'
	option band '5g'
	option htmode 'VHT80'
	option country 'RU'
	option cell_density '0'
	option noscan '1'

I have:

I have a correspondence with one forum participant and he writes that dozens of such AP work great for him.
But I have a different version of hardware (flash memory from a new manufacturer). at least that's the difference...

1 Like

Remove this - this stops channels requiring radar checks:

Again:

Removed this line. No change!

In Luci:


On client device:

The most interesting thing is that in the settings there is option channel '60'. This is 5300 MHz.
On the screenshots above, channel 64 (5320).
Miracles.
Update: After 2 reboots the channel readings coincided!