Adding OpenWrt support for MikroTik cAP ac

Yes it's OK that the Red LED is blinking all the time. I suppose you are using a different cable to connect to port 2 (the one used to reach the luci interface via 192.168.1.1), because if you take the cable out of port 1 it will reboot and you will go back to RouterOS.

Yes, of course :slight_smile:
Red LED is not blinking! It's ON constantly after ~20-30 sec. from start downloading TFTPd:DoReadFile:openwrt-ipq40xx-mikrotik-mikrotik_hap-ac2-initramfs-kernel.bin

I understand ... after that I can connect from Lan2 to OpenWrt (192.168.1.1) and download second image...

It works (but only RED Led is always ON - use black duct tape :smile: ).
Thank you very much!
And my case is the same: support for 802.11r

Which build do you currently use for cAP ac?

Hello everybody and happy new year ! i currently use rb750gr3 with openWRT you use ac2 mikrotik but the new hap ac3 is also flashable you thinked ,

Mikrotik is my favorite model easy to flash debrick etc :slightly_smiling_face:

i see he has architecture arm32 so he support wan gigabit with qos ??

confirm that it works. Moreover, it works also for the new wAP AC (RBwAPG-5HacD2HnD). [IPQ-4018 CPU] it is in 1:1 correspondence with the cAP AC model (except that you can also power it via DC jack and it has an IP54 protection)

as far as I can see the new wAP AC is also not listened in openwrt.org. Not sure whether a separate entry is needed, since the procedure and builds can be taken from cAP AC

I tried a few of the builds mentioned in this topic and I found the WiFi connectivity unreliable, especially for 5 ghz, where I get disconnects as soon as a bandwidth brust takes place (for instance, when testing download speeds).

The LEDs are not working properly as well - the power and red leds stay solid on (but we can make them blink using custom led configs), the other ones won't work.

Any ideas are welcome and many thanks to the contributors of this effort -- cAP AC will most likely not work with MT's new wave2 drivers and it's users will only have OpenWRT as an option for proper 802.11r (among others) support.

In terms of makefiles producing images, probably no. Are even LEDs the same? Does the board description need editing so right information is shown under System luci tab?

In terms of tables and wiki pages, yes. It needs entries in order to be discoverable as supported and so users know which images to use and so people have a pointer to known working flash instructions. (ie. common tftp instructions).

My initial cAP ac PR https://github.com/openwrt/openwrt/pull/4055

  • cAP ac based dts file
  • cAP ac based BFS
  • LEDs are in better shape
  • VLANs ... as good as you can get with ipq40xx
2 Likes

ok, opened a new thread on the new wAP AC

1 Like

I built w/ the patches provided @alaraun and it now seems to work fine, including the leds, many tx!

However, I can only boot with the backup boot loader (holding the reset key while resetting). The routerboard had the firmware upgraded to 7.1b5 before flashing. This is a showstopper as the router will be installed in the ceiling.

Any ideas? Shall I try to netinstall and then downgrade the firmware? Maybe the newer bootloader will not work w/ the sysupgrade image installed after the netboot?

Thank you again.

Yes, you should install Openwrt on top of v6 series firmware.
Regards

2 Likes

I'm not too familiar with the ipx40xx series, what kind of limitations on VLANs does it have?

2 Likes

Half year ago I successfully flashed OpenWrt to one cAP ac /r2. Now I bought an other model and cannot perform netboot of the initramfs image: It starts like

dnsmasq-dhcp: available DHCP range: 192.168.1.100 -- 192.168.1.200
dnsmasq-dhcp: vendor class: ARM__boot
dnsmasq-dhcp: DHCPDISCOVER(eth0) MAC-adress
dnsmasq-dhcp: tags: eth0
dnsmasq-dhcp: DHCPOFFER(eth0) 192.168.1.171 MAC-adress
dnsmasq-dhcp: requested options: 1:netmask, 3:router

after some time turns to:

vendor class: ARM__boot
dnsmasq-dhcp: DHCPREQUEST(eth0) 0.0.0.0 MAC-adress
dnsmasq-dhcp: DHCPNAK(eth0) 0.0.0.0 MAC-adress wrong network
dnsmasq-dhcp: broadcast response

and reboots to RouterOS

[admin@MikroTik] > system routerboard print
routerboard: yes
board-name: cAP ac
model: RBcAPGi-5acD2nD
revision: r3
firmware-type: ipq4000L
factory-firmware: 6.47.9
current-firmware: 6.48.3

Does it fail due to the third revision?

Made a clean install of the ROS LTS 6.47.10 and was able to flash OpenWrt successfully.
Seems, that at the previous upgrade of ROS something went wrong for my device. Now everything is fine.

First of all, thank you very much for this! I've been using alaraun's PR and was able to install it onto my Cap AC unit quickly.

I've noticed the device connection speed (5GHz WPA2 AES) is very different whether you use OpenWRT version in-RAM or the flashed one.

OpenWRT running in memory:
For default (00) country my iPhone connects at 780 Mbit/s.
For US, iPhone and Android phones constantly connect at 886.7Mbit/s.

OpenWRT flashed onto Cap AC device
For US, iPhone connects between 351Mbit/s and 650Mbit/s. Most of the times, it is 350Mbit/s or 520Mbit/s.

Is this common? I've compiled my initfarms and sysupgrade images from the same commit. The different between installations is that when I flashed OpenWRT onto the device, I've also connected it to my router to get the access to Internet.

Another thing I'm having issues with is getting my Cap AC device to act as a regular AP. I want to be able to extend my router to the wireless devices and bridge both ports on my Cap AC so that I can just use 1 network cable for power and management.
Could someone share their working configuration here?

Thank you!

1 Like

No, there shouldn't be functional differences of this kind between initramfs- and sysupgrade builds.

Thank you for this information. Probably something was wrong with the way I've applied this build then. I just re-tested everything:

  1. flashed Mikrotik's RouterOS back onto the device
  2. compiled the new binary and tested initfarms image first.
  3. Flashed the sysupgrade image onto the device and re-tested the configuration. This time I've got consistent results for connection speed and iperf tests.

Now just need to figure out how to completely remove router functionality and make it as a regular AP...

Here are my configuration files for a regular access point.
Management = vlan9
Trusted network = vlan10
Untrusted (guest) network = vlan11
Please, avoid using vlan2 in your configuration.
In my setup I reduced the "Maximum transmit power" value to 6 dBm (2.4GHz) and 13 dBm (5GHz) to improve roaming between four APs.
Current firmware version: OpenWrt 21.02.0-rc3 r16172-2aba3e9784
I did not try OpenWrt 21.02.0-rc4 yet.

/etc/config/network

config interface 'loopback'
        option ifname 'lo'                
        option proto 'static'
        option ipaddr '127.0.0.1'
        option netmask '255.0.0.0'
                                          
config interface 'lan'
        option proto 'static'
        option ifname 'eth1.9'
        option ipaddr '192.168.1.11'
        option netmask '255.255.255.0'
        option gateway '192.168.1.1'
        list dns '1.1.1.1'
        list dns '8.8.8.8'
        option delegate '0'  
                                   
config interface 'wifi1'             
        option type 'bridge'          
        option proto 'none'           
        option ifname 'eth1.10'       
        option auto '1'   
        option delegate '0'
        option force_link '1'
                        
config interface 'wifi2'    
        option type 'bridge'
        option proto 'none'   
        option ifname 'eth1.11'
        option auto '1'    
        option delegate '0'  
        option force_link '1'
                        
config route                
        option interface 'lan'
        option target '0.0.0.0'
        option netmask '0.0.0.0'
        option gateway '192.168.1.1'
                             
config switch 'switch0'      
        option reset '1'
        option enable_vlan '1'
                                
config switch_vlan
        option device 'switch0'
        option vlan '9'
        option ports '0t 5t'

config switch_vlan              
        option device 'switch0'      
        option vlan '10'              
        option ports '0t 5t'
 
config switch_vlan
        option device 'switch0'
        option vlan '11'
        option ports '0t 5t'

/etc/config/wireless

config wifi-device 'radio0'
	option type 'mac80211'
	option hwmode '11g'
	option path 'platform/soc/a000000.wifi'
	option htmode 'HT20'
	option country 'US'
	option cell_density '0'
	option channel '6'
	option txpower '16'

config wifi-iface 'default_radio0'
	option device 'radio0'
	option mode 'ap'
	option ssid 'TRUSTED'
	option encryption 'psk2+ccmp'
	option key 'trusted-network'
	option network 'wifi1'
	option ieee80211r '1'
	option mobility_domain 'abcd'
	option ft_over_ds '1'
	option ft_psk_generate_local '1'

config wifi-iface 'wifinet2'
	option device 'radio0'
	option mode 'ap'
	option ssid 'GUEST'
	option encryption 'psk2+ccmp'
	option key 'guest-network'
	option network 'wifi2'
	option isolate '1'
	option ieee80211r '1'
	option mobility_domain 'abcf'
	option ft_over_ds '1'
	option ft_psk_generate_local '1'

config wifi-device 'radio1'
	option type 'mac80211'
	option channel '149'
	option hwmode '11a'
	option path 'platform/soc/a800000.wifi'
	option htmode 'VHT40'
	option country 'US'
	option cell_density '0'
	option txpower '20'

config wifi-iface 'default_radio1'
	option device 'radio1'
	option mode 'ap'
	option ssid 'TRUSTED'
	option encryption 'psk2+ccmp'
	option key 'trusted-network'
	option network 'wifi1'
	option ieee80211r '1'
	option ft_over_ds '1'
	option ft_psk_generate_local '1'
	option mobility_domain 'abcd'

config wifi-iface 'wifinet3'
	option device 'radio1'
	option mode 'ap'
	option ssid 'GUEST'
	option encryption 'psk2+ccmp'
	option key 'guest-network'
	option network 'wifi2'
	option isolate '1'
	option ieee80211r '1'
	option mobility_domain 'abcf'
	option ft_over_ds '1'
	option ft_psk_generate_local '1'
1 Like