Differences between revisions 5 and 6
Revision 5 as of 2016-11-01 04:09:31
Size: 1561
Editor: wookey
Comment: Add info on board setup.
Revision 6 as of 2016-11-30 19:09:01
Size: 4907
Editor: wookey
Comment:
Deletions are marked like this. Additions are marked like this.
Line 30: Line 30:
If your board comes with that then life is simple. If not you need to follow the instructions below for installing it. If your board comes with that then life is simple: put debian installer on an SD card, put the SD card in the device, have a console connected and run the installer.

If the board does not have UEFI on it (early boards didn't) you need to follow the instructions below for 'Installing UEFI'


== Installing UEFI bootloader ==
Line 34: Line 39:

The short(er) version is:

=== Preparation ===

You need:
 * Micro USB cable
 * Hikey with 8-18V PSU (board is not powered by USB)
 * android-tools-fastboot installed
 * hisi.py bootloader-update script
 * Files to flash
{{{
$ wget http://builds.96boards.org/releases/reference-platform/debian/hikey/16.06/bootloader/hisi-idt.py
}}}
{{{
$ wget http://builds.96boards.org/releases/reference-platform/debian/hikey/16.06/bootloader/l-loader.bin
$ wget http://builds.96boards.org/releases/reference-platform/debian/hikey/16.06/bootloader/fip.bin
( $ wget http://builds.96boards.org/releases/reference-platform/debian/hikey/16.06/bootloader/ptable-linux-4g.img )
$ wget http://builds.96boards.org/releases/reference-platform/debian/hikey/16.06/bootloader/ptable-linux-8g.img
$ wget http://builds.96boards.org/releases/reference-platform/debian/hikey/16.06/bootloader/nvme.img
$ wget http://builds.96boards.org/releases/reference-platform/debian/hikey/16.06/hikey-boot-linux-*.uefi.img.gz
}}}

ptable-linux-4g.img is for boards with 4G eMMC flash, ptable-linux-8g.img is for boards with 8g flash. So far as I know they all have 8G in practice.

=== Doing the install ===

Use the [[https://www.96boards.org/wp-content/uploads/2015/02/HiKey_User_Guide_Rev0.2.pdf|Hardware Guide]] for details on setting up links and power etc.

 * power off
 * Close links 1 ('auto-power-on') and 2 ('install bootloader from USB') on J15
 * Connect micro USB cable from the Hikey micro USB ('USB OTG') socket to your computer
 * power on (dmesg should show something like:
{{{
usb 4-2: New USB device found, idVendor=12d1, idProduct=3609
usb 4-2: New USB device strings: Mfr=1, Product=4, SerialNumber=0
usb 4-2: Product: \xffffffe3\xffffff84\xffffffb0㌲㔴㜶㤸
usb 4-2: Manufacturer: 䕇䕎䥎
option 4-2:1.0: GSM modem (1-port) converter detected
usb 4-2: GSM modem (1-port) converter now attached to ttyUSB0
}}}
 * Note: You get 90 seconds to do the initial l-loader.bin upload - power-cycle if you took too long
{{{
$ sudo python hisi-idt.py -d /dev/ttyUSB0 --img1=l-loader.bin
}}} (remember ttyUSB* can change)
 If you see 'Done' then it's worked. Wait 10 seconds for the board to restart into fastboot.
 * Install the partition table first, then the other files/images
{{{
$ sudo fastboot flash ptable ptable-linux-8g.img
}}} (choose 4/8 by board flash size - 4 should always work, but might waste half your flash)
{{{
$ sudo fastboot flash fastboot fip.bin
$ sudo fastboot flash nvme nvme.img
$ sudo fastboot flash boot boot-fat.uefi.img
}}}
 * The board should now have UEFI installed.
 * Power off
 * Move link 2 on J15 to open (storing it closed on posititon 3 is smart)
 * Power on
 * Now dmesg should show something like:
{{{
usb 8-2: new high-speed USB device number 15 using ehci-pci
usb 8-2: New USB device found, idVendor=18d1, idProduct=d00d
usb 8-2: New USB device strings: Mfr=1, Product=2, SerialNumber=3
usb 8-2: Product: Android 2.0
usb 8-2: Manufacturer: Androi
usb 8-2: SerialNumber: 0123456789ABCDEF
}}}
and you should now be able to boot debian-installer

HiKey

The HiKey is based on a HiSilicon Kirin processor. There are two variants of the HiKey: the original from CircuitCo and a new version in 1GB and 2GB variants from LeMaker.

Technical specification

CPU

HiSilicon Kirin 620 1.2 GHz

GPU

Mali 450-MP4

RAM

1GB (CircuitCo or LeMaker) or 2GB (LeMaker)

Storage

4GB (CircuitCo) or 8GB (LeMaker) eMMC flash

WIFI

yes

Audio

yes

Bluetooth

yes

Connectors

micro SD, USB (2 standard, 1 micro), HDMI

Other

96Boards 40-pin low speed and 60-pin high speed expansion connector

Debian support

The HiKey uses UEFI, so Debian should work out of the box once there's a kernel.

Kilian Krause requested ARCH_HISI to be enabled in the kernel recently. However, it seems that HiSilicon Kirin support in the kernel is still very basic (e.g. no USB support).

Current bug list associated with the HiKey support:

  • Bug 816350 missing firmware for wlan support

Installation

to install Debian, you need UEFI installed on the board.

If your board comes with that then life is simple: put debian installer on an SD card, put the SD card in the device, have a console connected and run the installer.

If the board does not have UEFI on it (early boards didn't) you need to follow the instructions below for 'Installing UEFI'

Installing UEFI bootloader

This page gives good detail on how to get the board set up from scratch. https://github.com/96boards/documentation/blob/master/ConsumerEdition/HiKey/Installation/BoardRecovery.md

The short(er) version is:

Preparation

You need:

  • Micro USB cable
  • Hikey with 8-18V PSU (board is not powered by USB)
  • android-tools-fastboot installed
  • hisi.py bootloader-update script
  • Files to flash

$ wget http://builds.96boards.org/releases/reference-platform/debian/hikey/16.06/bootloader/hisi-idt.py

$ wget http://builds.96boards.org/releases/reference-platform/debian/hikey/16.06/bootloader/l-loader.bin
$ wget http://builds.96boards.org/releases/reference-platform/debian/hikey/16.06/bootloader/fip.bin
( $ wget http://builds.96boards.org/releases/reference-platform/debian/hikey/16.06/bootloader/ptable-linux-4g.img )
$ wget http://builds.96boards.org/releases/reference-platform/debian/hikey/16.06/bootloader/ptable-linux-8g.img
$ wget http://builds.96boards.org/releases/reference-platform/debian/hikey/16.06/bootloader/nvme.img
$ wget http://builds.96boards.org/releases/reference-platform/debian/hikey/16.06/hikey-boot-linux-*.uefi.img.gz

ptable-linux-4g.img is for boards with 4G eMMC flash, ptable-linux-8g.img is for boards with 8g flash. So far as I know they all have 8G in practice.

Doing the install

Use the Hardware Guide for details on setting up links and power etc.

  • power off
  • Close links 1 ('auto-power-on') and 2 ('install bootloader from USB') on J15
  • Connect micro USB cable from the Hikey micro USB ('USB OTG') socket to your computer
  • power on (dmesg should show something like:

usb 4-2: New USB device found, idVendor=12d1, idProduct=3609
usb 4-2: New USB device strings: Mfr=1, Product=4, SerialNumber=0
usb 4-2: Product: \xffffffe3\xffffff84\xffffffb0㌲㔴㜶㤸
usb 4-2: Manufacturer: 䕇䕎䥎
option 4-2:1.0: GSM modem (1-port) converter detected
usb 4-2: GSM modem (1-port) converter now attached to ttyUSB0
  • Note: You get 90 seconds to do the initial l-loader.bin upload - power-cycle if you took too long

$ sudo python hisi-idt.py -d /dev/ttyUSB0 --img1=l-loader.bin

(remember ttyUSB* can change)

  • If you see 'Done' then it's worked. Wait 10 seconds for the board to restart into fastboot.
  • Install the partition table first, then the other files/images

$ sudo fastboot flash ptable ptable-linux-8g.img

(choose 4/8 by board flash size - 4 should always work, but might waste half your flash)

$ sudo fastboot flash fastboot fip.bin
$ sudo fastboot flash nvme nvme.img
$ sudo fastboot flash boot boot-fat.uefi.img 
  • The board should now have UEFI installed.
  • Power off
  • Move link 2 on J15 to open (storing it closed on posititon 3 is smart)
  • Power on
  • Now dmesg should show something like:

usb 8-2: new high-speed USB device number 15 using ehci-pci
usb 8-2: New USB device found, idVendor=18d1, idProduct=d00d
usb 8-2: New USB device strings: Mfr=1, Product=2, SerialNumber=3
usb 8-2: Product: Android 2.0
usb 8-2: Manufacturer: Androi
usb 8-2: SerialNumber: 0123456789ABCDEF

and you should now be able to boot debian-installer