Support for Mikrotik Hap AC2

This will make the CPU to always be at full frequency (716 Mhz). The problem with the latency is that ondemand governor has a really low cpu frequency (44 Mhz) wich makes the ping to spike. To fix this you can set the minium CPU frequency to the next step on scaling cobernor (200 Mhz). This way ping stays "fixed" and it will make the unit to run a bit fresh. You can do this with this command:

echo 200000 > /sys/devices/system/cpu/cpufreq/policy0/scaling_min_freq

2 Likes

Hi Robimarko

Where can I download the source to compile ?

Thanks

1 Like

try to build like this, it work for me

git config --global user.email "yourEmail@email.com"
git config --global user.name "YourName"

git clone https://github.com/openwrt/openwrt.git
cd openwrt
git remote add z1022 https://github.com/robimarko/openwrt.git
git fetch z1022
git merge z1022/hAP-ac2-cleanup [it open another page, and i use Ctrl S [save], Ctrl X [exit]
git rebase
./scripts/feeds update -a && ./scripts/feeds install -a
make menuconfig [write your config] dont forget with luci
make -j$(nproc) clean download world

1 Like
# git merge z1022/hAP-ac2-cleanup
Removing target/linux/ipq40xx/patches-5.4/700-net-add-qualcomm-mdio.patch
Auto-merging target/linux/ipq40xx/image/Makefile
CONFLICT (content): Merge conflict in target/linux/ipq40xx/image/Makefile
Automatic merge failed; fix conflicts and then commit the result.

same here, i think we ask @robimarko
Screenshot_10

its my last build, before we got this problem

Screenshot_12

I need to rebase the branch to apply cleanly on master.
I will do it later today.

1 Like

Its rebased now, you can build straight from the branch.

1 Like

You mean do not need to merge hAP-ac2-cleanup again. Right ?

Thanks

No need for you to merge the branch into another one to buils

1 Like

Hi Robimarko,

I use below try to compile Openwrt but cannot find target "Mikrotik ac2". What wrong ?

git clone https://github.com/openwrt/openwrt.git
cd openwrt
./scripts/feeds update -a && ./scripts/feeds install -a
make menuconfig

Thanks

1 Like

The pull request that adds support for it hasn't been merged yet, you should use robimarko's fork that contains the necessary changes.
Use "git clone -b hAP-ac2-cleanup https://github.com/robimarko/openwrt.git" instead.

MikroTIk itself released a different wireless package for IPQ40xx which can be downloaded from here:https://download.mikrotik.com/routeros/7.1beta3/all_packages-arm-7.1beta3.zip
i.e. within the ZIP file there´s a wifiwave2-7.1beta3-arm.npk which can easily unpacked. The folders also contain new firmware bin files. I´m curious whether they use any opensource parts...

1 Like

I use the source from "git clone -b hAP-ac2-cleanup https://github.com/robimarko/openwrt.git" to compile a build.
However, the 5GHz download speed only around 16XMbit. Is it normal ? Any method to improve the speed ?

I saw some post said using ath10k-ct-smallbuffers driver. I don't know how to use .

Please help.

Thanks all

1 Like

That does not look correct, I remember getting much higher speeds.
Smallbuffers driver is already included due to 128M of RAM.

1 Like

thank for reply.

Is the smallbuffers driver default to use ?

Thanks

Yes, its the only one packaged

Hi,
I would like to try OpenWrt on my hAP AC2.
Where can I download the latest firmware build or do I need to compile my own?
If so, can someone provide a link to a tutorial or a guide on how to compile the firmware as I am new to this.
Thanks

My current build of firmware for hAP AC2

Download https://disk.admlr.lipetsk.ru/s/s2JJKcndnRA2nbc

This is my how to build firmware for hAP AC2

  1. Download ISO nemesis-xfce-20.10.11-k5.4.50-x86_64.iso (Arch Linux version of Porteus)
    http://www.mediafire.com/file/z7aa9e5fjv7mar6/nemesis-xfce-20.10.11-k5.4.50-x86_64.iso/file

Logins and passwords (look at this screenshot):
porteus-min

  1. Install Nemesis on your flash drive or HDD >>> https://pastebin.com/czT9QPx2
    NOTE. File system that you will be clone openwrt must to be POSIX filesystem (like as ext2, ext4...) and to have a good supply of free space.
    By default all changes will be saved on /mnt/sdb1 (look at option changes=/dev/sdb1 in /boot/syslinux/porteus.cfg)
    3.Warning!* /mnt/sdb1 must to be POSIX filesystem (like as ext2, ext4...)
  2. Boot up from your USB Flash drive or HDD
    Nemesis via second menu - Xfce (changes)
  3. Open terminal and run these commands:
su
toor
export FORCE_UNSAFE_CONFIGURE=1
env FORCE_UNSAFE_CONFIGURE=1
setup-pman
# where is /mnt/sdb1 is POSIX filesystem (like as ext2, ext4...)
cd /mnt/sdb1/
pacman -Syu
pacman -S bash bc bin86 binutils bzip2 cdrkit coreutils diffutils fastjar file-roller findutils firefox flex gawk gcc gettext git intltool libusb libxslt make ncurses openssl patch perl-extutils-makemaker pkgconf python3 rsync sharutils time unzip util-linux wget zlib
git config --global user.email "yourEmail@email.com"
git config --global user.name "YourName"
git clone https://github.com/openwrt/openwrt.git
cd openwrt
git remote add z1022 https://github.com/robimarko/openwrt.git
git fetch z1022
git merge z1022/hAP-ac2-cleanup
# it open another page, and i use Ctrl S [save], Ctrl X [exit]
git rebase
./scripts/feeds update -a && ./scripts/feeds install -a
# copy your .config to openwrt/
# you can rename config.buildinfo from ready mikrotik hap-ac2 firmware to .config
# and copy this .config to openwrt/
# press Ctrl+H to see hidden files and folders
make menuconfig
make -j$(nproc) clean download world
# for example
# make -j4 V=cs
# where 4 is CPU core - look at your PC configuration
# share your build of firmware for community.

#NOTE.
#Initial compilation takes like an hour but subsequent builds are fast, make sure to run each time you rebase (aka update local OpenWRT repo)
./scripts/feeds update -a && ./scripts/feeds install -a
make clean

Снимок экрана от 2020-12-12 13-22-57-min

4 Likes

Technically you can use any Linux distro to compile OpenWrt as long as you have the required build dependencies.

I compiled this build on Ubuntu 20.10 without problems but I forgot to backup the compiled binaries before distrohopping to Arch Linux :upside_down_face: