Ubuntu 16.04 LTS Linux LibreTech 4.13.3 Desktop Preview Image

edited November 2017 in AML-S905X-CC

Overview:

This is a preview image based on Ubuntu 16.04 LTS with the mainline Linux 4.13.3 with some out-of-tree patches.
The u-boot is an Amlogic modified branch from 2015.
The image is designed for >4GB SD cards at the moment and has not been tested (and definitely will not work) on eMMC.

Image Download Link

aml-s905x-cc-ubuntu-xenial-linux-libretech-4.13.3-g019e61d-dirty-mali-2017-11-08.img.zip

Getting Started

  1. Extract the image first by running unzip aml-s905x-cc-ubuntu-xenial-linux-libretech-4.13.3-g019e61d-dirty-mali-2017-11-08.img.zip.

  2. Write image to a MicroSD card (all data on the MicroSD card will be wiped):

Plug the MicroSD card into your computer via a USB card reader or built-in card reader.

  • USB card readers will usually expose the MicroSD card as a block device /dev/sdX where X is a letter. Partitions will be exposed as /dev/sdXN where N is the partition number.

  • Built-in card reader found on laptops will usually expose the MicroSD card as a block device /dev/mmcblkX where X is a number. Partitions will be exposed as /dev/mmcblkXpN where N is the partition number.

Write the image to the MicroSD card via sudo dd if=aml-s905x-cc-ubuntu-xenial-linux-libretech-4.13.3-g019e61d-dirty-mali-2017-11-08.img of=/dev/sdX bs=1M or sudo dd if=aml-s905x-cc-ubuntu-xenial-linux-libretech-4.13.3-g019e61d-dirty-mali-2017-11-08.img of=/dev/mmcblkX bs=1M. Place replace X with the correct letter or number.

Possible gotchas: Do not flash it to a partition (eg /dev/sda1 or /dev/mmcblk0p1) as that will not work. If you pick the wrong block device, you may lose data on that block device so be extra careful!

After dd is finished, you can remove it and plug it into the board and power it up.

Running

The default login credentials are as follows:
Username: libre
Password: computer

Disk Layout:

1MB Reserved for boot logic
255MB FAT32 Partition containing device tree blob and u-boot Linux image
512MB BTRFS Partition with @ subvolume for root

The BTRFS root partition is only 512MB so you will have to expand it manually. When we release the final images will do this automatically on bootup so this step will not be necessary.

sudo fdisk /dev/mmcblk1
d
2
n
p
2
524288
press enter to default to maximum size
w
q
sudo partprobe /dev/mmcblk1
sudo btrfs filesystem resize max /

Advanced

Custom kernel:

Building your own kernel

u-boot logic:

"if fatls mmc 0:1; then " "if test -e mmc 0:1 linux-amlogic; then " "fatload mmc 0:1 ${loadaddr} uImage.amlogic;" "fatload mmc 0:1 ${fdt_high} gxl_p212_2g.dtb;" "setenv bootargs boot_delay=3 root=/dev/mmcblk0p2 rootfstype=btrfs rootflags=subvol=@ rootwait console=ttyS0,115200 no_console_suspend earlyprintk=aml-uart,0xc81004c0 ramoops.pstore_en=1 ramoops.record_size=0x8000 ramoops.console_size=0x4000 init=/sbin/init;" "else " "fatload mmc 0:1 ${dtb_mem_addr} gxl_p212_2g.dtb;" "hdmi_init;" "fatload mmc 0:1 ${loadaddr} uImage;" "saradc_12bit open 1;" "if saradc_12bit get_in_range 0x370 0x380;" "then fatload mmc 0:1 ${fdt_high} meson-gxl-s905x-libretech-cc.nouhs.dtb;" "else fatload mmc 0:1 ${fdt_high} meson-gxl-s905x-libretech-cc.dtb;" "fi;" "setenv bootargs root=/dev/mmcblk1p2 rootfstype=btrfs rootflags=subvol=@ rootwait console=ttyAML0,115200 no_console_suspend;" "fi;" "bootm ${loadaddr} - ${fdt_high};"

Other:

Additional Resources

Comments

Sign In or Register to comment.