Support for Mikrotik Hap AC2

It seems like neither the mac address start nor serial number end are indicating the longer hard_config.
@bjonglez, could you please give your factory routerboot version to see if that is different? My hap ac2 with 0x1000 hard_config is 6.44:

root@OpenWrt:~# cat /sys/firmware/mikrotik/hard_config/board_product_code 
root@OpenWrt:~# cat /sys/firmware/mikrotik/hard_config/board_identifier 
root@OpenWrt:~# cat /sys/firmware/mikrotik/hard_config/booter_version 

I would also like a dd copy of the RouterBoot partition to investigate if you are happy to share it.


'New style' hAP ac^2 bought in Russia
Date of manufacture: 29 September 2019
Date of purchase: 13 December 2019
MAC starts with C4:AD:34
SN ends with /5D92/931

 OpenWrt SNAPSHOT, r16594-e8a5670122
[    0.631789] spi-nor spi0.0: w25q128jv (16384 Kbytes)
[    0.632001] 3 fixed-partitions partitions found on MTD device spi0.0
[    0.637085] Creating 3 MTD partitions on "spi0.0":
[    0.643476] 0x000000000000-0x000000080000 : "Qualcomm"
[    0.649020] 0x000000080000-0x000000100000 : "RouterBoot"
[    0.659027] 3 routerbootpart partitions found on MTD device RouterBoot
[    0.659059] Creating 3 MTD partitions on "RouterBoot":
[    0.665008] 0x00000000e000-0x00000000f000 : "hard_config"
[    0.671066] 0x000000010000-0x000000017bbc : "dtb_config"
[    0.676483] 0x00000003d000-0x00000003e000 : "soft_config"
[    0.681832] 0x000000100000-0x000001000000 : "firmware"
root@mikrotik:~# cat /sys/firmware/mikrotik/hard_config/board_product_code
root@mikrotik:~# cat /sys/firmware/mikrotik/hard_config/board_identifier
root@mikrotik:~# cat /sys/firmware/mikrotik/hard_config/booter_version
root@mikrotik:~# ls -l /sys/firmware/mikrotik/hard_config/wlan_data/
-r--------    1 root     root             0 Apr 24 22:42 data_0
-r--------    1 root     root             0 Apr 24 22:42 data_2

I have only one issue with the 100 Mbit/s leds Support for Mikrotik Hap AC2 - #283 by Blaze

Currently, the hard_config will always be seen with a size of 0x1000 on the system, because that's the default size in the routerbootparts driver. But from all the boot logs so far, there is always enough space for a 0x2000 partition (0x0e000-0x10000 instead of 0x0e000-0x0f000), so that means we can increase it safely, thanks everybody.

The board I have is kinda of strange because it's the first one I see where the hard_config data extends beyond 0x1000. But I saw other hap-ac2 boards where data was extending almost to the 0x1000 limit.

FYI routerboot version is 6.43.10 on my "strange" board so again it seems unrelated.

1 Like

Sure, here it is if you're curious about it.

1 Like
  • Ordered dec 2019 from/in the Netherlands
  • /923/r2
  • 74:4D:28
[    0.628780] spi-nor spi0.0: w25q128jv (16384 Kbytes)
[    0.629005] 3 fixed-partitions partitions found on MTD device spi0.0
[    0.634122] Creating 3 MTD partitions on "spi0.0":
[    0.640434] 0x000000000000-0x000000080000 : "Qualcomm"
[    0.646062] 0x000000080000-0x000000100000 : "RouterBoot"
[    0.656025] 3 routerbootpart partitions found on MTD device RouterBoot
[    0.656059] Creating 3 MTD partitions on "RouterBoot":
[    0.661998] 0x00000000e000-0x00000000f000 : "hard_config"
[    0.668025] 0x000000010000-0x000000017bbc : "dtb_config"
[    0.673557] 0x00000003d000-0x00000003e000 : "soft_config"
[    0.678753] 0x000000100000-0x000001000000 : "firmware"
[    0.691007] 2 minor-fw partitions found on MTD device firmware
[    0.691041] Creating 2 MTD partitions on "firmware":
[    0.695754] 0x000000000000-0x0000002e0000 : "kernel"
[    0.701898] 0x0000002e0000-0x000000f00000 : "rootfs"
[    0.706607] mtd: device 7 (rootfs) set to be root filesystem
[    0.711073] 1 squashfs-split partitions found on MTD device rootfs
[    0.716404] 0x0000005e0000-0x000000f00000 : "rootfs_data"

Hi to all

i am struggling with tagged WAN port
is somebody succeeded in adding tagged vlans on WAN?

config device 'wan_eth1_dev'
        option name 'eth1'
        option macaddr '08:55:31:7e:66:fe'

config device
        option type '8021q'
        option ifname 'eth1'
        option name 'eth1.200'

config interface 'w200'
        option proto 'dhcp'
        option ifname 'eth1.200'

i tried to capture with tcpdump/wireshark
and i don't see any vlan200 packet
wireshark show that it is vlan1 ?

what i am doing wrong ?

@NPeca75 The WAN port is not an independent device, just another port (number 5 for this device) on the internal switch that the Qualcomm driver mangles. Try to tag the port and cpu port on the switch as well. Check with swconfig.
/etc/config/network section something like:

config switch_vlan
	option device 'switch0'
	option vlan '20' # turns out vlan 200 is too high for the driver
	option vid '200'
	option ports '0t 5t'

config interface 'w200'
	option proto 'dhcp'
	option ifname 'eth1.200' # or maybe 'eth0.200'?

VLANs 1 and 2 are special because of the Qualcomm EDMA driver.

This works for me:

tail /etc/config/network 
config switch_vlan
	option device 'switch0'
	option vlan '20'
	option ports '5t 0t'

config switch_vlan
	option device 'switch0'
	option vid '200'
	option vlan '22'
	option ports '5t 0t'
swconfig dev switch0 show | tail -n 12
	vid: 1
	ports: 0 1 2 3 4 
	vid: 2
	ports: 0t 5 
VLAN 20:
	vid: 20
	ports: 0t 5t 
VLAN 22:
	vid: 200
	ports: 0t 5t 

hi @johnth

unfortnately, nope

here what i am find in swconfig

        pvid: 2
        link: port:5 link:up speed:1000baseT full-duplex txflow rxflow auto
        vid: 1
        ports: 0 1 2 3 4
        vid: 2
        ports: 0t 5

so i tried:
swconfig dev switch0 vlan 2 set ports '0t 5t'
to make tagged Vlan2
and it is working

unfortunately, it is working only on "whole" eth1
and only by hand from CLI
so i could write whatever i want in /etc/config/network it is hard coded to 2(U)
and most important, it is only one Vlan on whole ETH1
no multi Vlans/Trunk

big regression compared to ROS and/or other OpenWRT devices

my goal is mostly to use OpenWRT as managed switch+multi Vlan/SSID AP
So , Trunk on input (WAN) with few Vlans, every Vlan have own SSID + device act as managed switch transforming tagged to access ports. All this supported with SNMP+LibreNMS

I had the same issue, and I think I've found a workaround:

Is snapshot stable enough to use it as daily driver?

1 Like

No crashes since flashing it. Even when using experimental stuff that isn't supported in RouterOS like WPA3. Wireless signal also seems more resilient.
Disclaimer: no guarantees it will work the same for your board/configuration

Hopefully this will become a stable release soon. I've donated to the OpenWrt via Software Freedom Conservancy so they hopefully have enough money/time to approve this in the near future.

1 Like

Is anyone else getting extremely high latency and packet loss when pinging or connecting to a device? The problem appears to be more severe on 5ghz, but it also happens on 2.4ghz. Pinging the router works fine.

Edit: This also happens on both wpad-basic-wolfssl and wpad-openssl, and on wpa3-mixed and wpa2. It seems to start after being connected for a few seconds, and gets worse over time (i.e. multiple days).

Edit: It gets much better if I run iperf3 while pinging.

Edit: Nevermind, it seems to be mostly issues with interference.

1 Like

There are issues with the 5 GHz wireless performance.
Have been testing the Mikrotik LDF 5 ac, a device with very similar ipq40xx hardware but only 5 GHz and no USB.
Using the ath10k-ct-smallbuffers wireless kernel driver, at least 10 dB of receiver sensitivity is lost. The standard ath10k driver in combination with its firmware, gives rssi level reports similar to that of RouterOS. This was tested in a setup with connection over 7 km distance, while also monitoring the remote location via UBNT equipment..
That is to say, connection in a limited way. No real data transport as apparently the distance/coverage class setting and/or automatic adaptation are not working. This makes the 802.11 protocol break down.
iw phy phyN info (N=0 in my case, N=1 for the hAP ac2) shows distance setting 0. iw is not able to set this. Any ideas how to set coverage class / distance?

I second that. Wi-fi performance and readings using the CT drivers and firmware is all over the place. I have been using the native drivers and firmware instead. Strangely enough, the latest master builds broke my wi-fi. Couldn't figure why. By the way, anyone using the AF_ALG hardware acceleration? Under the openssl benchmark, I've got a bump of 32% in DES, 37% in 3DES, 15% in AES-128 and 15% in AES-192

I used the same method and found the option "try ethernet-if fail-nand" is now something that works once (it's also called "try once" if I remember correctly). So you need to start over and set this again when you weren't quick enough to start TFTP on the correct interface with the correct ip configuration.

Hello everybody.
I want to test my hAP ac^2 with kernel 5.10.xx
Anybody knows that need to add in kernel .config for compile OpenWrt with kernel 5.10.xx ?

The OpenWrt 21.02.0-rc2 Release Candidate 2 is Rolling out

21.02.0-rc2 Download,

21.02.0-rc2 Release Notes,

21.02.0-rc2 Change Log,

21.02 Roadmap and Release Goals,

Question for developer:
I see the RB750Gr3's sys gpio folder has a usb reset file and you can set value 0 or 1 to reset the usb power like what you can click in ROS. Possible to add that? I use usb modem and need that to reset my LTE modem when it went wrong. Thank you.

Hello, guys. Today bought hAP ac2 instead of miwifi mini. Firmware - snapshot from wiki page.
Booted openwrt from bootp for test, tested SQM and eth ports permormance, all good. After that I tested wireless connection and got major problems - on 5ghz network I got low signal and device dropping from wi-fi. After that I switched wireless to AC (it was choosed on N mode), choosed channel 100, then interface was disabled. In scan mode I see only my second router, -90 dbm in 2meters between routers.
Second time I booted, enabled both 2.4 and 5 ghz and router stucked and rebooted in ROS.
Is there any way to fix it or I need to return it?

Date of purchase: May 2020
S/N ends with /116/r2, MAC addr starts with 2C:C8

[    0.758543] spi-nor spi0.0: w25q128jv (16384 Kbytes)
[    0.758605] 3 fixed-partitions partitions found on MTD device spi0.0
[    0.763373] Creating 3 MTD partitions on "spi0.0":
[    0.769683] 0x000000000000-0x000000080000 : "Qualcomm"
[    0.775310] 0x000000080000-0x000000100000 : "RouterBoot"
[    0.785244] 3 routerbootpart partitions found on MTD device RouterBoot
[    0.785276] Creating 3 MTD partitions on "RouterBoot":
[    0.791252] 0x00000000e000-0x000000010000 : "hard_config"
[    0.797272] 0x000000010000-0x000000017bbc : "dtb_config"
[    0.802823] 0x00000003d000-0x00000003e000 : "soft_config"
[    0.808049] 0x000000100000-0x000001000000 : "firmware"

@Blaze, No 5.10 for this device yet due to the out-of-tree Qualcomm network drivers needing changes:

@ex-git, Maybe file a bug report or mail list, so there is a specific request somewhere?

It is possible, but requires a change to the device in OpenWrt:

Hi @Skylin3,

Please do not post pictures of text, it only makes it harder to parse. Also best to show your config (/etc/config/wireless), just change the value for keys.

You have an error in your configuration.
The log says so in: Frequency 5500 not allowed for AP
Your channel must be correct for your band or hwmode and htmode, and be allowable in you country. Can see these with the commands: iw reg get and iw phy. In some 5GHz channels & countries (DFS), the access point will not power up the wifi channel until a timer (maybe 5 minutes) finishes.

Have a look at and

The best wireless hardware options should be set by default. There is a very recent current bug where the default htmode will not be correctly set to VHT.
There was also discussion that the now default radio-device option legacy_rates 0 has a negative effect on ipq40xx:


The best wireless hardware options should be set by default.

I dont think so :wink: by default 5ghz running N with 20mhz bandwidth, not AC/80mhz.

one more time: openwrt was booted in full auto (default) settings.

config wifi-device 'radio0'
        option type 'mac80211'
        option path 'platform/soc/a000000.wifi'
        option channel '1'
        option band '2g'
        option htmode 'HT20'

config wifi-iface 'default_radio0'
        option device 'radio0'
        option network 'lan'
        option mode 'ap'
        option ssid 'OpenWrt'
        option encryption 'none'

config wifi-device 'radio1'
        option type 'mac80211'
        option path 'platform/soc/a800000.wifi'
        option channel '36'
        option band '5g'
        option htmode 'HT20'

config wifi-iface 'default_radio1'
        option device 'radio1'
        option network 'lan'
        option mode 'ap'
        option ssid 'OpenWrt'
        option encryption 'none'

And have folowing issues:

  • low sensitivity\power both in scan and AP mode (anything more than 3 meter away) both 5ghz and 2.4 ghz - -110 to -90 dbm.
  • interface "broken" (disabled and no way to restart until reboot router) after set manual channel, same channel works good on another router.
  • if enable both 2.4 and 5 ghz simultaneously, and try to saturate connection with 3 devices (PC and 2 phones) - router stuck and rebooting.

UPD. using todays snapshot got accidental router reboot after changing wireless 5ghz to AC/80mhz and connecting only one phone (which still was used 20mhz instead configured 80) and PC by lan.
Looks like openwrt on this device is really unstable.
Good luck.