This is second post from series about LeMaker version of HiKey board from 96boards Customer Edition family. Previous post focused on describing hardware part. In this post I would like to show how to setup firmware development and testing environment.

This post highly rely on 96boards documentation, so kudos to 96boards and LeMaker for providing lot of information for developers.

Obtain pre-compiled binaries

Clone eMMC flashing tool:

Follow flashing instructions. For Debian-based systems you may need:

On my Debian I see in dmesg:

Correct command and UART log should look similar to this:

As result I saw that green LED on board is on, then I proceed with fastboot commands.

If above steps finish without the problems, then you know working procedure for flashing all required components. Now let’s proceed with fast boot and flashing remaining components:

Output should look like this:

Remove Boot Select jumper (link 3-4) and power on platform.

System configuration

Wireless network can be easily configured using this instructions. It is also required to setup DNS in /etc/resolv.conf ie.:

Bug hunting

There was time when I asked myself what I can do ? Where to start ? Good way to analyze system compatibility (and find bugs) from firmware perspective is FirmwareTestSuit. It can be cloned using:

To compile:

To run:

At point of writing this post only 13 tests passed. Most of testes (243) were aborted since no support for given feature was detected. This results show that there is plenty to do before getting well-supported firmware on HiKey.

Summary

As presented above HiKey developement process is not so simple. Using precompiled binaries is very useful for presentation purposes, but adding features to EDK2 will requires recompilation some of mentioned components. Documentation is not easy to search as well as forum, key probablem is that it needs more order, because various information (sometimes unrelated) are spread actoss directories and repositories.

Nevertheless hacking ARMv8 firmware may be fun and there huge undiscovered area to explore. Key question is what valid use cases may lead to extensive firmware development in this area ? First I would look into features that have to be exposed to operating system ie. verify boot for Linux OS use of TEE module in Linux.

As always please share if you feel this is valuable and comment if you have any questions or something is unclear.