a20
Differences
This shows you the differences between two versions of the page.
Both sides previous revisionPrevious revisionNext revision | Previous revision | ||
a20 [2015/04/01 16:26] – damien | a20 [2018/05/22 10:33] (current) – external edit 127.0.0.1 | ||
---|---|---|---|
Line 1: | Line 1: | ||
+ | ====== Getting started with Olimex A20-SOM ====== | ||
+ | Interesting links: | ||
+ | * https:// | ||
+ | * http:// | ||
+ | * http:// | ||
+ | * https:// | ||
+ | |||
+ | ===== Buildroot system ===== | ||
+ | |||
+ | Based on https:// | ||
+ | |||
+ | < | ||
+ | make a20_olinuxino_defconfig | ||
+ | make | ||
+ | </ | ||
+ | |||
+ | ===== Bootable microSD ===== | ||
+ | |||
+ | Make two partitions: | ||
+ | |||
+ | * boot partition: FAT16, starting at offset 1MB, for u-boot.img, script.bin, uEnv.txt and uImage | ||
+ | * linux partion: ext3 for rootfs | ||
+ | |||
+ | > :!: Before running below commands be sure of which device is your to-be-formatted microSD card. In this example we take ''/ | ||
+ | |||
+ | < | ||
+ | sudo sfdisk /dev/sdc << EOF | ||
+ | 2048, | ||
+ | ,,,- | ||
+ | EOF | ||
+ | </ | ||
+ | |||
+ | Format the first partition in FAT16 for boot | ||
+ | < | ||
+ | sudo mkfs.vfat -F 16 /dev/sdc1 -n boot | ||
+ | </ | ||
+ | |||
+ | Format the second in EXT3 for the root filesystem | ||
+ | < | ||
+ | sudo mkfs.ext3 /dev/sdc2 -L rootfs | ||
+ | </ | ||
+ | |||
+ | Burn '' | ||
+ | < | ||
+ | sudo dd if=u-boot.bin of=/dev/sdc bs=1024 seek=32 | ||
+ | </ | ||
+ | or, equivalently, | ||
+ | < | ||
+ | sudo dd if=u-boot-sunxi-with-spl.bin of=/dev/sdc bs=1024 seek=8 | ||
+ | </ | ||
+ | |||
+ | Copy the content of the boot partition: | ||
+ | < | ||
+ | tar -xvf rootfs.tar -C </ | ||
+ | </ | ||
+ | |||
+ | Copy the content of the root filesystem: | ||
+ | < | ||
+ | sudo tar xvf rootfs.tar -C </ | ||
+ | </ | ||
+ | |||
+ | |||
+ | ===== Display ===== | ||
+ | |||
+ | [[http:// | ||
+ | ==== SPI support ==== | ||
+ | - Add the spi-sun7i driver support to the linux kernel: [[http:// | ||
+ | - Load the spi driver: '' | ||
+ | |||
+ | ==== FBTFT support ==== | ||
+ | [[https:// | ||
+ | |||
+ | (requires spi driver to be loaded) | ||
+ | - Add the fbtft driver support to Buildroot: [[http:// | ||
+ | - Load the fbtft_device driver: '' | ||
+ | * '' | ||
+ | * '' | ||
+ | * '' | ||
+ | * '' | ||
+ | - Load the driver corresponding to the screen: '' | ||
+ | |||
+ | === Backlight === | ||
+ | |||
+ | https:// | ||
+ | |||
+ | ===== Network configuration ===== | ||
+ | |||
+ | ==== Ethernet ==== | ||
+ | To enable eth0 interface, load sunxi-emac driver on the OLinuXino-Lime | ||
+ | < | ||
+ | modprobe sunxi-emac | ||
+ | </ | ||
+ | |||
+ | ==== WLAN ==== | ||
+ | === with a rt2870 chipset === | ||
+ | Add the support for the rt2870 chipset to your system: | ||
+ | * make sure linux-firmware is ticked in your buildroot configuration | ||
+ | * make sure Busybox mdev is configured to support firmware hotload | ||
+ | |||
+ | On target, | ||
+ | * configure mdev as kernel hotplug | ||
+ | < | ||
+ | sysctl -w kernel.hotplug=/ | ||
+ | mdev -s | ||
+ | </ | ||
+ | * load the rt2800usb driver | ||
+ | < | ||
+ | modprobe rt2800usb | ||
+ | </ | ||
+ | * bring up the wlan0 interface | ||
+ | < | ||
+ | ifconfig wlan0 up | ||
+ | </ | ||
+ | |||
+ | === with a mt7601 chipset === | ||
+ | |||
+ | == Build the driver == | ||
+ | |||
+ | Download the driver sources from [[https:// | ||
+ | |||
+ | Apply the following patch: | ||
+ | < | ||
+ | diff --git a/ | ||
+ | index dfe1283..b2615ab 100755 | ||
+ | --- a/ | ||
+ | +++ b/ | ||
+ | @@ -197,11 +197,13 @@ endif | ||
+ | |||
+ | ifeq ($(PLATFORM), | ||
+ | # Linux 2.6 | ||
+ | -LINUX_SRC = / | ||
+ | +LINUX_SRC = < | ||
+ | # Linux 2.4 Change to your local setting | ||
+ | # | ||
+ | -LINUX_SRC_MODULE = / | ||
+ | -CROSS_COMPILE = | ||
+ | +LINUX_SRC_MODULE = $LINUX_SRC/ | ||
+ | +CROSS_COMPILE = < | ||
+ | +ARCH=arm | ||
+ | +export ARCH | ||
+ | endif | ||
+ | |||
+ | ifeq ($(PLATFORM), | ||
+ | diff --git a/ | ||
+ | index 3726b9e..821e401 100755 | ||
+ | --- a/ | ||
+ | +++ b/ | ||
+ | @@ -279,7 +279,7 @@ typedef struct file* RTMP_OS_FD; | ||
+ | |||
+ | | ||
+ | { | ||
+ | -#if LINUX_VERSION_CODE >= KERNEL_VERSION(3, | ||
+ | +#if LINUX_VERSION_CODE >= KERNEL_VERSION(3, | ||
+ | | ||
+ | | ||
+ | #else | ||
+ | diff --git a/ | ||
+ | index 2afcb77..b69af63 100755 | ||
+ | --- a/ | ||
+ | +++ b/ | ||
+ | @@ -75,7 +75,7 @@ | ||
+ | # | ||
+ | # | ||
+ | # | ||
+ | -#define LOCAL_TXBUF_SIZE | ||
+ | +#define LOCAL_TXBUF_SIZE | ||
+ | # | ||
+ | |||
+ | # | ||
+ | diff --git a/ | ||
+ | index 531b00e..e67c864 100755 | ||
+ | --- a/ | ||
+ | +++ b/ | ||
+ | @@ -1054,7 +1054,7 @@ CFLAGS := -D__KERNEL__ -I$(LINUX_SRC)/ | ||
+ | | ||
+ | endif | ||
+ | |||
+ | -GCCVERSION = $(shell gcc -dumpversion) | ||
+ | +GCCVERSION = $(shell $(CROSS_COMPILE)gcc -dumpversion) | ||
+ | |||
+ | ifeq ($(PLATFORM), | ||
+ | ifneq (, | ||
+ | </ | ||
+ | |||
+ | where | ||
+ | - ''< | ||
+ | - ''< | ||
+ | Note that changing the '' | ||
+ | |||
+ | Launch the compilation: | ||
+ | < | ||
+ | $ cd src | ||
+ | $ make | ||
+ | </ | ||
+ | |||
+ | and copy the generated '' | ||
+ | Note that the generated file is quite big (15MB)... | ||
+ | |||
+ | == Load the driver == | ||
+ | On your target: | ||
+ | * load the driver: | ||
+ | < | ||
+ | $ insmod mt7601Usta.ko | ||
+ | </ | ||
+ | |||
+ | * enable the '' | ||
+ | < | ||
+ | $ ifconfig ra0 up | ||
+ | </ | ||
+ | |||
+ | ===== PWM ===== | ||
+ | |||
+ | [[https:// | ||
+ | |||
+ | ===== OpenGL ===== | ||
+ | |||
+ | via the mali driver ([[http:// | ||
+ | |||
+ | To redirect the output the a non standard // | ||
+ | THe same variable has to be used to launch a Qt5 application, |
a20.txt · Last modified: 2018/05/22 10:33 by 127.0.0.1