https://linux-sunxi.org/api.php?action=feedcontributions&user=Rocker&feedformat=atomlinux-sunxi.org - User contributions [en]2024-03-29T10:43:57ZUser contributionsMediaWiki 1.35.8https://linux-sunxi.org/index.php?title=CedarX/XBMC&diff=16029CedarX/XBMC2016-01-18T14:54:45Z<p>Rocker: </p>
<hr />
<div>{{redbox|<big><br />
{{warn|'''Kodi/XBMC for linux on Allwinner devices is NOT READY FOR USE!'''|}}<br />
<br />
This is still only a hack intended for developers and curious users at the moment. Don't expect it to work as you want it! Hardware is capable to make it run quite good in the future, but software and drivers are not ready yet. Sadly, nobody is working towards making a smooth Kodi/XBMC experience possible at the moment.<br />
<br />
If you want to help developing the needed components to have a stable Kodi/XBMC in the future, join the [[:Category:Community|irc and mailing list]]. Developers wanted!</big>}}<br />
<br/><br />
<br />
'''Kodi''' (formerly '''XBMC''') is a popular free and open source media player software application designed as a 10-foot frontend graphical home theater (a.k.a. media center) interface for large-screen televisions. Made to be controlled with a remote control it enables ARM-based media players and set-top boxes like those with Allwinner SoCs with [[CedarX]] VPU (Video Processor Unit) to hardware decode and play high-definition videos, music, and other digital media files from local and network storage media, as well as stream podcasts, videocasts, and such of the internet, and displayed in a appealing way on your living-room TV.<br />
<br />
This article contain instructions on compiling and developing Kodi/XBMC on and for Allwinner SoCs that features the [[CedarX]] VPU, like [[A10]], [[A10s]], [[A13]], [[A20]], and [[A23]]. Note that these instructions are specifically only meant for developers and advanced or expert Linux users that can actively assist with the porting process.<br />
<br />
=Overview=<br />
Kodi/XBMC has already have an initial but ultimatly obsolete port for the A10 / A20 SoC with [[CedarX]] hardware accelerated video decoding, this experimental third-party port and the code patches have however not made it upstream into mainline Kodi/XBMC.<ref>http://www.j1nx.nl/buildroot-xbmc-on-mele-a1000-allwinner-a10/ Buildroot XBMC on the Mele A1000 (Allwinner A10)</ref><ref>http://www.cnx-software.com/2012/11/12/xbmc-for-linux-on-allwinner-a10-devices-it-works-sort-of/ XBMC for Linux on AllWinner A10 Devices? It Works! (Sort of)</ref><br />
<br />
Pre-built application binaries of this initial port are not available so therefore you will need to compile Kodi/XBMC yourself, at least until if and when code for these CedarX based Allwinner SoCs makes it into the mainline XBMC upstream at http://kodi.tv<br />
<br />
Team-Kodi (who before used to be known as Team-XBMC), the official development team of Kodi/XBMC, does currently not recommend that any end-user buy Allwinner A1x or A2x based hardware for the specific purpose of only running Kodi/XBMC since they do not have the resources to support this platform as of yet.<br />
<br />
More information about Kodi/XBMC can be found on wikipedia http://en.wikipedia.org/wiki/XBMC and the Kodi wiki http://wiki.kodi.tv or http://forum.kodi.tv<br />
<br />
= Building Kodi/XBMC for A10 and A20 SoC series=<br />
This is a little how-to of steps to compile XBMC for devices using Allwinner A10 and A20 SoC series (e.g. for hardware like Mele A1000, Cubieboard, and Banana Pi) based on Empat0's GitHub sources [http://github.com/empatzero/xbmca10 http://github.com/empatzero/xbmca10].<br />
The development work on the coding side was all done by Empat0 (a.k.a. empat zero). The used repository in the example below is however from [http://github.com/rellla/xbmca10 http://github.com/rellla/xbmca10] which is currently the newest and contains a few adaptions. It is a fork of empat0's work. If you want an only A20 version you can use this repository: [https://github.com/fflayol/xbmc https://github.com/fflayol/xbmc] .<br />
<br />
The result should be a Debian armhf system with XBMC using [[CedarX]] for hardware accelerated video decoding.<br />
<br />
This version of XBMC runs directly on the framebuffer, and thus XServer is therefor not needed!<br />
<br />
== Prerequisites ==<br />
There are more ways to prepare a working rootfs for XBMC. You can either prepare the sdcard directly as described or you can chroot into the rootfs on your host system and sync it with your sdcard later when you have finished.<br />
So the following steps can also be done in a chroot on your host if you are cross-compiling.<br />
<br />
=== Prepare your SD-Card ===<br />
Create a bootable SD-Card follwing [[Manual_build_howto| our manual build howto]] and Debian. Be sure to use a kernel with mali-drivers-version r3p0 (sunxi-3.0 should be good).<br />
<br />
=== Boot into your target system ===<br />
Boot the new debian from the sd-card directly on the target and bring the system up to date:<br />
root@mele:~/# apt-get update<br />
root@mele:~/# apt-get upgrade<br />
<br />
=== Install the dependencies for XBMC (needs update!) ===<br />
root@mele:~/# apt-get build-dep xbmc<br />
<br />
:this should install the following packages:<code><br />
:autoconf automake autopoint autotools-dev binutils bsdmainutils build-essential bzip2 cmake cmake-data comerr-dev cpp cpp-4.4 cpp-4.6 curl debhelper dpkg-dev emacsen-common fontconfig-config g++ g++-4.4 g++-4.6 gawk gcc gcc-4.4 gcc-4.4-base gcc-4.6 gcc-4.6-base gettext gettext-base git git-man gperf groff-base html2text intltool-debian krb5-multidev libao-common libao-dev libao4 libarchive12 libasound2 libasound2-dev libasprintf0c2 libass-dev libass4 libasyncns0 libavahi-client-dev libavahi-client3 libavahi-common-data libavahi-common-dev libavahi-common3 libavcodec-dev libavcodec53 libavfilter-dev libavfilter2 libavformat-dev libavformat53 libavutil-dev libavutil51 libbluetooth-dev libbluetooth3 libbluray-dev libbluray1 libboost-date-time1.49-dev libboost-date-time1.49.0 libboost-dev libboost-serialization1.49-dev libboost-serialization1.49.0 libboost-thread-dev libboost-thread1.49-dev libboost-thread1.49.0 libboost1.49-dev libbz2-dev libc-dev-bin libc6-dev libcaca-dev libcaca0 libcdio-dev libcdio13 libcec-dev libcec1 libcroco3 libcurl3 libcurl3-gnutls libcurl4-gnutls-dev libcwiid-dev libcwiid1 libdbus-1-3 libdbus-1-dev libdirac-encoder0 libdirectfb-1.2-9 libdirectfb-dev libdirectfb-extra libdpkg-perl libdrm2 libelf1 libenca-dev libenca0 liberror-perl libexpat1 libexpat1-dev libflac-dev libflac8 libfontconfig1 libfontconfig1-dev libfreetype6 libfreetype6-dev libfribidi-dev libfribidi0 libgcrypt11-dev libgettextpo0 libgl1-mesa-dev libgl1-mesa-glx libglapi-mesa libglew-dev libglew1.7 libglib2.0-bin libglib2.0-dev libglu1-mesa libglu1-mesa-dev libgmp10 libgnutls-dev libgnutls-openssl27 libgnutlsxx27 libgomp1 libgpg-error-dev libgsm1 libgssrpc4 libhal-dev libhal-storage-dev libhal-storage1 libhal1 libice-dev libice6 libicu48 libidn11-dev libiso9660-8 libiso9660-dev libjasper-dev libjasper1 libjbig-dev libjbig0 libjpeg8 libjpeg8-dev libjson0 libkadm5clnt-mit8 libkadm5srv-mit8 libkdb5-6 libkrb5-dev liblcms1 libldap-2.4-2 libldap2-dev libltdl-dev libltdl7 liblzo2-2 liblzo2-dev libmad0 libmad0-dev libmicrohttpd-dev libmicrohttpd10 libmikmod2 libmikmod2-dev libmodplug-dev libmodplug1 libmp3lame-dev libmp3lame0 libmpc2 libmpeg2-4 libmpeg2-4-dev libmpfr4 libmysqlclient-dev libmysqlclient18 libnettle4 libnfs-dev libnfs1 libogg-dev libogg0 libopencv-core2.3 libopencv-imgproc2.3 libopenjpeg2 liborc-0.4-0 libp11-kit-dev libpcre3-dev libpcrecpp0 libpipeline1 libplist-dev libplist1 libpng12-0 libpng12-dev libpopt0 libpostproc-dev libpostproc52 libpthread-stubs0 libpthread-stubs0-dev libpulse-dev libpulse-mainloop-glib0 libpulse0 libpython2.7 librtmp-dev librtmp0 libsamplerate0 libsamplerate0-dev libsasl2-2 libschroedinger-1.0-0 libsdl-image1.2 libsdl-image1.2-dev libsdl-mixer1.2 libsdl-mixer1.2-dev libsdl1.2-dev libsdl1.2debian libshairport-dev libshairport1 libsigsegv2 libslang2-dev libsm-dev libsm6 libsmbclient libsmbclient-dev libsndfile1 libspeex1 libsqlite3-0 libsqlite3-dev libssh2-1 libssh2-1-dev libssl-dev libstdc++6-4.4-dev libstdc++6-4.6-dev libswscale-dev libswscale2 libtalloc2 libtasn1-3-dev libtdb1 libtheora0 libtiff4 libtiff4-dev libtiffxx0c2 libtimedate-perl libtinyxml-dev libtinyxml2.6.2 libtool libts-0.0-0 libts-dev libudev-dev libunistring0 libva-dev libva-egl1 libva-glx1 libva-tpi1 libva-x11-1 libva1 libvdpau-dev libvdpau1 libvorbis-dev libvorbis0a libvorbisenc2 libvorbisfile3 libvpx1 libwbclient0 libwebp-dev libwebp2 libx11-dev libx11-xcb1 libx264-123 libxau-dev libxcb-glx0 libxcb1-dev libxdamage1 libxdmcp-dev libxext-dev libxfixes3 libxi6 libxml2-dev libxmlrpc-core-c3 libxmu-dev libxmu-headers libxmu6 libxrandr-dev libxrandr2 libxrender-dev libxrender1 libxt-dev libxt6 libxtst6 libxvidcore4 libxxf86vm1 libyajl-dev libyajl2 linux-libc-dev m4 make man-db mesa-common-dev mysql-common patch pkg-config po-debconf python python-dev python-imaging python-minimal python-support python2.7 python2.7-dev python2.7-minimal tsconf ttf-dejavu-core ucf x11-common x11proto-core-dev x11proto-input-dev x11proto-kb-dev x11proto-randr-dev x11proto-render-dev x11proto-xext-dev xorg-sgml-doctools xtrans-dev yasm zip zlib1g-dev</code><br />
<br />
need to install 3 more dependencies:<br />
root@mele:~/# apt-get install swig default-jre libgtk2.0-bin libssh-4 libssh-dev<br />
<br />
ensure you use hardware acceleration<br />
root@mele:~/# echo -e "\nA10HWR=1" >> /etc/environment (to set it permanently)<br />
<br />
Now go on with [[XBMC#Native_Compile_of_XBMC | Native Compile]] or [[XBMC#Cross_Compile_of_XBMC | Cross Compile]].<br />
<br />
== Native Compile of XBMC ==<br />
<br />
=== Prerequisites for native compile ===<br />
<br />
Create a swap-file, because otherwise the compiler runs out of memory during compiling and aborts<br />
root@mele:~/# dd if=/dev/zero of=/swap bs=1M count=384<br />
root@mele:~/# mkswap -c /swap<br />
root@mele:~/# swapon /swap<br />
<br />
Create your workspace directory:<br />
root@mele:~/# mkdir melehacking<br />
root@mele:~/# cd melehacking<br />
<br />
=== Checkout the source code ===<br />
root@mele:~/melehacking# apt-get install git<br />
root@mele:~/melehacking# git clone git://github.com/rellla/xbmca10.git<br />
root@mele:~/melehacking# cd xbmca10<br />
root@mele:~/melehacking/xbmca10# git checkout stage/Frodo<br />
<br />
=== Build ===<br />
The following external libs/ repos are used/ downloaded:<br />
* taglib: https://github.com/downloads/taglib/taglib/taglib-1.8.tar.gz<br />
* cedarx: https://github.com/linux-sunxi/cedarx-libs/tree/master/libcedarv/linux-armhf<br />
* libmad: ftp://ftp.mars.org/pub/mpeg/libmad-0.15.1b.tar.gz<br />
* mali: https://github.com/linux-sunxi/sunxi-mali-proprietary/tree/master/r3p0/armhf<br />
* mali-dev: https://github.com/linux-sunxi/sunxi-mali/tree/master/include<br />
<br />
Build dependencies<br />
root@mele:~/melehacking/xbmca10# cd tools/a10/depends<br />
root@mele:~/melehacking/xbmca10/tools/a10/depends# make<br />
Build xbmc itself<br />
root@mele:~/melehacking/xbmca10/tools/a10/depends# make -C xbmc<br />
root@mele:~/melehacking/xbmca10/tools/a10/depends# cd ../../../<br />
root@mele:~/melehacking/xbmca10# make install<br />
<br />
Move on to [[XBMC#Start_XBMC]] and start XBMC.<br />
<br />
== Cross Compile of XBMC ==<br />
This was tested with github.com/rellla/xbmca10 and built in Debian Sid as host. You will need several packages on the build system and a copy <br />
of the root file system of the target to build against. This howto assumes you are running off an SD card with the root file system in /dev/sdb2.<br />
=== Setup Cross Compiler ===<br />
* At first set up your [[Toolchain|toolchain]].<br />
<br />
=== Prerequisites for Cross Compiling ===<br />
* Sync and move SD card to build system<br />
* Mount the rootfs of the prepared SD Card<br />
root@debian:~/# mount /dev/sdb2 /mnt/rootfs-a10<br />
* Create symlinks to the mounted libraries<br />
root@debian:~/# ln -s /mnt/rootfs-a10/lib/arm-linux-gnueabihf /lib/arm-linux-gnueabihf<br />
root@debian:~/# ln -s /mnt/rootfs-a10/usr/lib/arm-linux-gnueabihf /usr/lib/arm-linux-gnueabihf<br />
root@debian:~/# ln -s /mnt/rootfs-a10/usr/include/arm-linux-gnueabihf /usr/include/arm-linux-gnueabihf<br />
* Install the dependencies for building XBMC on the host system<br />
root@debian:~/# apt-get build-dep xbmc<br />
root@debian:~/# apt-get install shtool swig default-jre<br />
Note: If compiling on a 64 bit system there is a known bug with the libcurl headers not working with 32 bit programs. To work around the problem build on a 32 bit system, or copy the file /usr/include/curl/curlbuild.h from a 32 bit system to your 64 bit build host.<br />
* Create your workspace directory:<br />
root@debian:~/# mkdir melehacking<br />
root@debian:~/# cd melehacking<br />
<br />
=== Checkout the source code ===<br />
root@debian:~/melehacking# git clone git://github.com/rellla/xbmca10.git<br />
root@debian:~/melehacking# cd xbmca10<br />
root@debian:~/melehacking/xbmca10# git checkout stage/Frodo<br />
<br />
=== Update XBMC build config ===<br />
Update this section at line 48 of tools/a10/depends/depends.mk with your values, e.g.<br />
#where is your arm rootfs<br />
SDKSTAGE=/mnt/rootfs-a10<br />
#where is your xbmc install root <br />
XBMCPREFIX=/allwinner/xbmc-pvr-bin$(HF)<br />
#where is your toolchain<br />
TOOLCHAIN=/usr/arm-linux-gnueabi$(HF)<br />
<br />
=== Build ===<br />
At this point the settings are basically the same for the native build:<br />
Build dependencies<br />
root@debian:~/melehacking/xbmca10# cd tools/a10/depends<br />
root@debian:~/melehacking/xbmca10/tools/a10/depends# make<br />
Build xbmc itself<br />
root@debian:~/melehacking/xbmca10/tools/a10/depends# make -C xbmc<br />
root@debian:~/melehacking/xbmca10/tools/a10/depends# cd ../../../<br />
root@debian:~/melehacking/xbmca10# make install<br />
<br />
=== Move XBMC to target system ===<br />
You should copy from your install location on your build system to an identical location on the target system (may not vital that they have the same path) like so ...<br />
root@debian:~/melehacking/xbmca10/cp -r /allwinner/xbmc-pvr-binhf /mnt/rootfs-a10/allwinner/xbmc-pvr-binhf<br />
<br />
To redistribute it, you can also create a tarball:<br />
root@debian:~/melehacking/xbmca10/tools/a10/depends# make -C package tarball<br />
This results in a xbmca10.tar.gz which includes all needed (and stripped) files in /allwinner/xbmc-pvr-binhf. This can easily be copied and extracted on the target rootfs.<br />
<br />
Umount your SD Card<br />
root@debian:~/melehacking/xbmca10# umount /dev/sdb2<br />
and boot it on your A10 Device.<br />
<br />
== Start XBMC ==<br />
After a reboot you modprobe the needed modules (depending on the used kernel version):<br />
root@mele:~/# modprobe disp<br />
root@mele:~/# modprobe lcd<br />
root@mele:~/# modprobe hdmi<br />
root@mele:~/# modprobe mali<br />
root@mele:~/# export A10HWR=1 (ensure to have this set if not rebooting!)<br />
root@mele:~/# cd /allwinner/xbmc-pvr-bin/lib/xbmc<br />
root@mele:/allwinner/xbmc-pvr-bin/lib/xbmc# ./xbmc.bin<br />
<br />
== Using the Android libraries via libhybris ==<br />
Due to some bugs in the native linux binaries of cedarx, ''ssvb'' succeeded to use libhybris and the Android binaries instead. This is the recommended way.<br />
See [[CedarX/libve]].<br />
<br />
== Troubleshooting ==<br />
* (native) If you get a compiler error when processing h264.o or building xbmc.bin, then check, if swap is enabled. The compiler ran out of memory!<br />
* (native) If deb-building fails, check, if your tmp-directory has enough free space and is no tmpfs, because of the lack of memory an mele.<br />
* To use the bash-script bin/xbmc to start xbmc, you have to comment out the exec of FEH.py, because of a failing test of glxinfo -> no display found.<br />
* Depending on your setup you may have to change some things to build<br />
* If mysql_config is not found, even though it is clearly there you can set disable-mysql in Makefile under xbmca10/tools/a10/depends/xbmc<br />
* Header files might not be where they are expected, this can be fixed with symlinks and copying headers, for example...<br />
ln -s usr/include/dbus1.0/dbus usr/include/dbus <br />
* Once you get in trouble with some mesa conflicts, ensure to not have installed the following packages on your target system: <br />
libegl1-mesa libegl1-mesa-dev libegl1-mesa-drivers libgles2-mesa libgles2-mesa-dev<br />
* Check the discussion section for more notes.<br />
* Ensure that you have installed ALL of the dependencies, header files etc. in your target rootfs and ensure that they are available during build. The build script does not search for them on your host-rootfs!<br />
<br />
= Configuring XBMC dependencies for Linux on A10 based devices =<br />
== Getting IR (infrared) remotes working on A10 based media players ==<br />
For getting IR (infrared) remote controls working on the A10 based media players, please see the [[LIRC]] article in this wiki. Place a suitable [[Lircmap.xml]] in userdata-directory.<br />
<br />
= Enabling dirty regions (a.k.a. dirty textures) for XBMC =<br />
This dirty region (a.k.a. dirty texture) feature in XBMC is designed to improve XBMC's GUI renderer performance on the GPU by only drawing when something like a texture changes on the screen, that region is then marked as dirty by XBMC's GUI library and only that region is redraw region on the screen.<br />
<br />
This feature is however still a little buggy and therefor not enabled by default in XBMC, but all users of XBMC on A10 based devices can try enabling the hidden "dirty regions" (a.k.a. "dirty textures") rendering feature advanced setting themselves manually. <br />
<br />
* http://wiki.xbmc.org/index.php?title=HOW-TO:Enable_dirty_regions<br />
* http://xbmc.org/theuni/2011/06/19/working-with-dirty-regions/<br />
* http://wiki.xbmc.org/index.php?title=Advancedsettings.xml#.3Calgorithmdirtyregions.3E<br />
<br />
Dirty regions are any parts of the screen that have changed since the last frame. By not re-rendering what hasn't changed, big speed gains can be seen. Because all GPUs work differently, only Mode 3, combined with nofliptimeout=0, is guaranteed to be safe for everyone, but current timing issues with nofliptimeout keep this from being the default. Note that with "dirty regions" your system CPU usage might go up a little (because it is doing the dirty regions calculations) but your GPU usage will be much lower, and since it is the GPU and not CPU that is the bottleneck in XBMC for embedded systems your GUI performance will be better even though the CPU usage is higher.<br />
<br />
{| class="wikitable"<br />
! value !! result !! description<br />
|-<br />
! 0<br />
| Off<br />
| The entire viewport is always rendered, which is the same as having the dirty regions feature disabled. This is the default mode.<br />
|-<br />
! 1<br />
|Union<br />
|All dirty regions are grouped into the smallest possible rectangle. This is typically the fastest mode for slower GPUs due to only making one pass.<br />
|-<br />
! 2<br />
|Cost reduction<br />
| Each dirty region is presented separately, in as many passes as there are regions.<br />
|-<br />
! 3<br />
|Whole Screen<br />
| The entire screen is rendered if there are any dirty regions. This, combined with nofliptimeout is a safe default for drivers that clear buffer contents (manifests as blinking or vibrating images)<br />
|}<br />
<br />
To enable dirty regions manually you need to create a "advancedsettings.xml" text file youself and put the XML <algorithmdirtyregions> enabling tags in there and copying to your "/userdata/" folder (/home/username/.xbmc/userdata/).<br />
<br />
Example:<br />
<code><br />
<gui> <br />
<algorithmdirtyregions>1</algorithmdirtyregions><br />
</gui><br />
</code><br />
<br />
You could also try to enable the <nofliptimeout> feature but that is even more experimental so know that it can cause even more GUI rendering issues in XBMC<br />
<br />
Example: <br />
<code><br />
<gui> <br />
<nofliptimeout>1000</nofliptimeout><br />
</gui><br />
</code><br />
<br />
To have both of these enabled your "advancedsettings.xml" then the finished file should look something like this:<br />
<br />
<code><br />
<advancedsettings><br />
<gui> <br />
<algorithmdirtyregions>1</algorithmdirtyregions><br />
<nofliptimeout>1000</nofliptimeout><br />
</gui><br />
</advancedsettings><br />
</code><br />
<br />
=Sources implementing CedarX support in XBMC=<br />
* [https://github.com/empatzero/xbmca10 https://github.com/empatzero/xbmca10]<br />
** [https://github.com/rellla/xbmca10 https://github.com/rellla/xbmca10] Recommended fork of empatzero ([http://pastebin.com/M4Di5tha Diff to upstream])<br />
** [https://github.com/vidonme/xbmc/ https://github.com/vidonme/xbmc/] Sources of [http://www.vidon.me/download.html VidOn.Me Player]? Seems to be a fork from empatzero. ([http://pastebin.com/LuQ4AB9J Diff to upstream] and [https://github.com/vidonme/xbmc/compare/xbmc:7b9ab8a85fd2b6030e6cf2659ff16380afef3996...master Github Compare]) This repo is reported from VidOn.me to be the "official" source code for their Allwinner XBMC version, yet the only code commit from VidOn.me themselves is [https://github.com/vidonme/xbmc/commit/b2b1696e8eb6617da07e0a043ca6ef2219ca080d#diff-2c44bd39cfe6b4185fe6a51b78c46cd0R122 this one]. <br />
* [https://github.com/huceke/xbmc/tree/allwinner https://github.com/huceke/xbmc/tree/allwinner] Gimli's implementation ([http://pastebin.com/Nu3DrfNK Diff to upstream])<br />
<br />
= See also =<br />
* [[CedarX]] - Library for Allwinner CedarX VPU (Video Processor Unit) used for audio and video decoding and encoding hardware off-loading on A1x and A2x SoC series.<br />
** [[CedarXVideoRenderingChart]] - Overview chart of working/ non working video files<br />
* [[LIRC|LIRC (Linux Infrared Remote Control) for IR receivers and and remotes]]<br />
* [[Tvheadend TV Tuner Server and PVR backend]]<br />
<br />
=xternal Links=<br />
* http://kodi.tv - Kodi.tv the official Kodi/XBMC website with wiki and forums.<br />
** http://github.com/xbmc/xbmc/ - The upstream Kodi mainstream source code repository on GitHub.<br />
* [http://forum.xbmc.org/showthread.php?tid=126995 XBMC Official Community Forum discussion about porting to Allwinner A10]<br />
* [http://jas-hacks.blogspot.co.uk/2012/11/hackberry-a10-xbmc.html Jas Hacks Hackberry A10 - XBMC on Ubuntu 12.10 image]<br />
* [http://www.j1nx.nl/buildroot-xbmc-on-mele-a1000-allwinner-a10/ Buildroot XBMC on the Mele A1000 (Allwinner A10)]<br />
* [http://www.cnx-software.com/2012/11/12/xbmc-for-linux-on-allwinner-a10-devices-it-works-sort-of/ XBMC for Linux on AllWinner A10 Devices? It Works! (Sort of)]<br />
<br />
=References=<br />
<references /><br />
<br />
[[Category:Software]]<br />
[[Category:Tutorial]]<br />
[[Category:CedarX]]</div>Rockerhttps://linux-sunxi.org/index.php?title=CedarX/XBMC&diff=16028CedarX/XBMC2016-01-18T14:54:05Z<p>Rocker: </p>
<hr />
<div>{{redbox|<big><br />
{{warn|'''Kodi/XBMC for linux on Allwinner devices is NOT READY FOR USE!'''|}}<br />
<br />
This is still only a hack intended for developers and curious users at the moment. Don't expect it to work as you want it! Hardware is capable to make it run quite good in the future, but software and drivers are not ready yet. Sadly, nobody is working towards making a smooth Kodi/XBMC experience possible at the moment.<br />
<br />
If you want to help developing the needed components to have a stable Kodi/XBMC in the future, join the [[:Category:Community|irc and mailing list]]. Developers wanted!</big>}}<br />
<br/><br />
<br />
'''Kodi''' (formerly '''XBMC''') is a popular free and open source media player software application designed as a home theater (a.k.a. media center) 10-foot frontend graphical interface with interface for large-screen televisions. Made to be controlled with a remote control it enables ARM-based media players and set-top boxes like those with Allwinner SoCs with [[CedarX]] VPU (Video Processor Unit) to hardware decode and play high-definition videos, music, and other digital media files from local and network storage media, as well as stream podcasts, videocasts, and such of the internet, and displayed in a appealing way on your living-room TV.<br />
<br />
This article contain instructions on compiling and developing Kodi/XBMC on and for Allwinner SoCs that features the [[CedarX]] VPU, like [[A10]], [[A10s]], [[A13]], [[A20]], and [[A23]]. Note that these instructions are specifically only meant for developers and advanced or expert Linux users that can actively assist with the porting process.<br />
<br />
=Overview=<br />
Kodi/XBMC has already have an initial but ultimatly obsolete port for the A10 / A20 SoC with [[CedarX]] hardware accelerated video decoding, this experimental third-party port and the code patches have however not made it upstream into mainline Kodi/XBMC.<ref>http://www.j1nx.nl/buildroot-xbmc-on-mele-a1000-allwinner-a10/ Buildroot XBMC on the Mele A1000 (Allwinner A10)</ref><ref>http://www.cnx-software.com/2012/11/12/xbmc-for-linux-on-allwinner-a10-devices-it-works-sort-of/ XBMC for Linux on AllWinner A10 Devices? It Works! (Sort of)</ref><br />
<br />
Pre-built application binaries of this initial port are not available so therefore you will need to compile Kodi/XBMC yourself, at least until if and when code for these CedarX based Allwinner SoCs makes it into the mainline XBMC upstream at http://kodi.tv<br />
<br />
Team-Kodi (who before used to be known as Team-XBMC), the official development team of Kodi/XBMC, does currently not recommend that any end-user buy Allwinner A1x or A2x based hardware for the specific purpose of only running Kodi/XBMC since they do not have the resources to support this platform as of yet.<br />
<br />
More information about Kodi/XBMC can be found on wikipedia http://en.wikipedia.org/wiki/XBMC and the Kodi wiki http://wiki.kodi.tv or http://forum.kodi.tv<br />
<br />
= Building Kodi/XBMC for A10 and A20 SoC series=<br />
This is a little how-to of steps to compile XBMC for devices using Allwinner A10 and A20 SoC series (e.g. for hardware like Mele A1000, Cubieboard, and Banana Pi) based on Empat0's GitHub sources [http://github.com/empatzero/xbmca10 http://github.com/empatzero/xbmca10].<br />
The development work on the coding side was all done by Empat0 (a.k.a. empat zero). The used repository in the example below is however from [http://github.com/rellla/xbmca10 http://github.com/rellla/xbmca10] which is currently the newest and contains a few adaptions. It is a fork of empat0's work. If you want an only A20 version you can use this repository: [https://github.com/fflayol/xbmc https://github.com/fflayol/xbmc] .<br />
<br />
The result should be a Debian armhf system with XBMC using [[CedarX]] for hardware accelerated video decoding.<br />
<br />
This version of XBMC runs directly on the framebuffer, and thus XServer is therefor not needed!<br />
<br />
== Prerequisites ==<br />
There are more ways to prepare a working rootfs for XBMC. You can either prepare the sdcard directly as described or you can chroot into the rootfs on your host system and sync it with your sdcard later when you have finished.<br />
So the following steps can also be done in a chroot on your host if you are cross-compiling.<br />
<br />
=== Prepare your SD-Card ===<br />
Create a bootable SD-Card follwing [[Manual_build_howto| our manual build howto]] and Debian. Be sure to use a kernel with mali-drivers-version r3p0 (sunxi-3.0 should be good).<br />
<br />
=== Boot into your target system ===<br />
Boot the new debian from the sd-card directly on the target and bring the system up to date:<br />
root@mele:~/# apt-get update<br />
root@mele:~/# apt-get upgrade<br />
<br />
=== Install the dependencies for XBMC (needs update!) ===<br />
root@mele:~/# apt-get build-dep xbmc<br />
<br />
:this should install the following packages:<code><br />
:autoconf automake autopoint autotools-dev binutils bsdmainutils build-essential bzip2 cmake cmake-data comerr-dev cpp cpp-4.4 cpp-4.6 curl debhelper dpkg-dev emacsen-common fontconfig-config g++ g++-4.4 g++-4.6 gawk gcc gcc-4.4 gcc-4.4-base gcc-4.6 gcc-4.6-base gettext gettext-base git git-man gperf groff-base html2text intltool-debian krb5-multidev libao-common libao-dev libao4 libarchive12 libasound2 libasound2-dev libasprintf0c2 libass-dev libass4 libasyncns0 libavahi-client-dev libavahi-client3 libavahi-common-data libavahi-common-dev libavahi-common3 libavcodec-dev libavcodec53 libavfilter-dev libavfilter2 libavformat-dev libavformat53 libavutil-dev libavutil51 libbluetooth-dev libbluetooth3 libbluray-dev libbluray1 libboost-date-time1.49-dev libboost-date-time1.49.0 libboost-dev libboost-serialization1.49-dev libboost-serialization1.49.0 libboost-thread-dev libboost-thread1.49-dev libboost-thread1.49.0 libboost1.49-dev libbz2-dev libc-dev-bin libc6-dev libcaca-dev libcaca0 libcdio-dev libcdio13 libcec-dev libcec1 libcroco3 libcurl3 libcurl3-gnutls libcurl4-gnutls-dev libcwiid-dev libcwiid1 libdbus-1-3 libdbus-1-dev libdirac-encoder0 libdirectfb-1.2-9 libdirectfb-dev libdirectfb-extra libdpkg-perl libdrm2 libelf1 libenca-dev libenca0 liberror-perl libexpat1 libexpat1-dev libflac-dev libflac8 libfontconfig1 libfontconfig1-dev libfreetype6 libfreetype6-dev libfribidi-dev libfribidi0 libgcrypt11-dev libgettextpo0 libgl1-mesa-dev libgl1-mesa-glx libglapi-mesa libglew-dev libglew1.7 libglib2.0-bin libglib2.0-dev libglu1-mesa libglu1-mesa-dev libgmp10 libgnutls-dev libgnutls-openssl27 libgnutlsxx27 libgomp1 libgpg-error-dev libgsm1 libgssrpc4 libhal-dev libhal-storage-dev libhal-storage1 libhal1 libice-dev libice6 libicu48 libidn11-dev libiso9660-8 libiso9660-dev libjasper-dev libjasper1 libjbig-dev libjbig0 libjpeg8 libjpeg8-dev libjson0 libkadm5clnt-mit8 libkadm5srv-mit8 libkdb5-6 libkrb5-dev liblcms1 libldap-2.4-2 libldap2-dev libltdl-dev libltdl7 liblzo2-2 liblzo2-dev libmad0 libmad0-dev libmicrohttpd-dev libmicrohttpd10 libmikmod2 libmikmod2-dev libmodplug-dev libmodplug1 libmp3lame-dev libmp3lame0 libmpc2 libmpeg2-4 libmpeg2-4-dev libmpfr4 libmysqlclient-dev libmysqlclient18 libnettle4 libnfs-dev libnfs1 libogg-dev libogg0 libopencv-core2.3 libopencv-imgproc2.3 libopenjpeg2 liborc-0.4-0 libp11-kit-dev libpcre3-dev libpcrecpp0 libpipeline1 libplist-dev libplist1 libpng12-0 libpng12-dev libpopt0 libpostproc-dev libpostproc52 libpthread-stubs0 libpthread-stubs0-dev libpulse-dev libpulse-mainloop-glib0 libpulse0 libpython2.7 librtmp-dev librtmp0 libsamplerate0 libsamplerate0-dev libsasl2-2 libschroedinger-1.0-0 libsdl-image1.2 libsdl-image1.2-dev libsdl-mixer1.2 libsdl-mixer1.2-dev libsdl1.2-dev libsdl1.2debian libshairport-dev libshairport1 libsigsegv2 libslang2-dev libsm-dev libsm6 libsmbclient libsmbclient-dev libsndfile1 libspeex1 libsqlite3-0 libsqlite3-dev libssh2-1 libssh2-1-dev libssl-dev libstdc++6-4.4-dev libstdc++6-4.6-dev libswscale-dev libswscale2 libtalloc2 libtasn1-3-dev libtdb1 libtheora0 libtiff4 libtiff4-dev libtiffxx0c2 libtimedate-perl libtinyxml-dev libtinyxml2.6.2 libtool libts-0.0-0 libts-dev libudev-dev libunistring0 libva-dev libva-egl1 libva-glx1 libva-tpi1 libva-x11-1 libva1 libvdpau-dev libvdpau1 libvorbis-dev libvorbis0a libvorbisenc2 libvorbisfile3 libvpx1 libwbclient0 libwebp-dev libwebp2 libx11-dev libx11-xcb1 libx264-123 libxau-dev libxcb-glx0 libxcb1-dev libxdamage1 libxdmcp-dev libxext-dev libxfixes3 libxi6 libxml2-dev libxmlrpc-core-c3 libxmu-dev libxmu-headers libxmu6 libxrandr-dev libxrandr2 libxrender-dev libxrender1 libxt-dev libxt6 libxtst6 libxvidcore4 libxxf86vm1 libyajl-dev libyajl2 linux-libc-dev m4 make man-db mesa-common-dev mysql-common patch pkg-config po-debconf python python-dev python-imaging python-minimal python-support python2.7 python2.7-dev python2.7-minimal tsconf ttf-dejavu-core ucf x11-common x11proto-core-dev x11proto-input-dev x11proto-kb-dev x11proto-randr-dev x11proto-render-dev x11proto-xext-dev xorg-sgml-doctools xtrans-dev yasm zip zlib1g-dev</code><br />
<br />
need to install 3 more dependencies:<br />
root@mele:~/# apt-get install swig default-jre libgtk2.0-bin libssh-4 libssh-dev<br />
<br />
ensure you use hardware acceleration<br />
root@mele:~/# echo -e "\nA10HWR=1" >> /etc/environment (to set it permanently)<br />
<br />
Now go on with [[XBMC#Native_Compile_of_XBMC | Native Compile]] or [[XBMC#Cross_Compile_of_XBMC | Cross Compile]].<br />
<br />
== Native Compile of XBMC ==<br />
<br />
=== Prerequisites for native compile ===<br />
<br />
Create a swap-file, because otherwise the compiler runs out of memory during compiling and aborts<br />
root@mele:~/# dd if=/dev/zero of=/swap bs=1M count=384<br />
root@mele:~/# mkswap -c /swap<br />
root@mele:~/# swapon /swap<br />
<br />
Create your workspace directory:<br />
root@mele:~/# mkdir melehacking<br />
root@mele:~/# cd melehacking<br />
<br />
=== Checkout the source code ===<br />
root@mele:~/melehacking# apt-get install git<br />
root@mele:~/melehacking# git clone git://github.com/rellla/xbmca10.git<br />
root@mele:~/melehacking# cd xbmca10<br />
root@mele:~/melehacking/xbmca10# git checkout stage/Frodo<br />
<br />
=== Build ===<br />
The following external libs/ repos are used/ downloaded:<br />
* taglib: https://github.com/downloads/taglib/taglib/taglib-1.8.tar.gz<br />
* cedarx: https://github.com/linux-sunxi/cedarx-libs/tree/master/libcedarv/linux-armhf<br />
* libmad: ftp://ftp.mars.org/pub/mpeg/libmad-0.15.1b.tar.gz<br />
* mali: https://github.com/linux-sunxi/sunxi-mali-proprietary/tree/master/r3p0/armhf<br />
* mali-dev: https://github.com/linux-sunxi/sunxi-mali/tree/master/include<br />
<br />
Build dependencies<br />
root@mele:~/melehacking/xbmca10# cd tools/a10/depends<br />
root@mele:~/melehacking/xbmca10/tools/a10/depends# make<br />
Build xbmc itself<br />
root@mele:~/melehacking/xbmca10/tools/a10/depends# make -C xbmc<br />
root@mele:~/melehacking/xbmca10/tools/a10/depends# cd ../../../<br />
root@mele:~/melehacking/xbmca10# make install<br />
<br />
Move on to [[XBMC#Start_XBMC]] and start XBMC.<br />
<br />
== Cross Compile of XBMC ==<br />
This was tested with github.com/rellla/xbmca10 and built in Debian Sid as host. You will need several packages on the build system and a copy <br />
of the root file system of the target to build against. This howto assumes you are running off an SD card with the root file system in /dev/sdb2.<br />
=== Setup Cross Compiler ===<br />
* At first set up your [[Toolchain|toolchain]].<br />
<br />
=== Prerequisites for Cross Compiling ===<br />
* Sync and move SD card to build system<br />
* Mount the rootfs of the prepared SD Card<br />
root@debian:~/# mount /dev/sdb2 /mnt/rootfs-a10<br />
* Create symlinks to the mounted libraries<br />
root@debian:~/# ln -s /mnt/rootfs-a10/lib/arm-linux-gnueabihf /lib/arm-linux-gnueabihf<br />
root@debian:~/# ln -s /mnt/rootfs-a10/usr/lib/arm-linux-gnueabihf /usr/lib/arm-linux-gnueabihf<br />
root@debian:~/# ln -s /mnt/rootfs-a10/usr/include/arm-linux-gnueabihf /usr/include/arm-linux-gnueabihf<br />
* Install the dependencies for building XBMC on the host system<br />
root@debian:~/# apt-get build-dep xbmc<br />
root@debian:~/# apt-get install shtool swig default-jre<br />
Note: If compiling on a 64 bit system there is a known bug with the libcurl headers not working with 32 bit programs. To work around the problem build on a 32 bit system, or copy the file /usr/include/curl/curlbuild.h from a 32 bit system to your 64 bit build host.<br />
* Create your workspace directory:<br />
root@debian:~/# mkdir melehacking<br />
root@debian:~/# cd melehacking<br />
<br />
=== Checkout the source code ===<br />
root@debian:~/melehacking# git clone git://github.com/rellla/xbmca10.git<br />
root@debian:~/melehacking# cd xbmca10<br />
root@debian:~/melehacking/xbmca10# git checkout stage/Frodo<br />
<br />
=== Update XBMC build config ===<br />
Update this section at line 48 of tools/a10/depends/depends.mk with your values, e.g.<br />
#where is your arm rootfs<br />
SDKSTAGE=/mnt/rootfs-a10<br />
#where is your xbmc install root <br />
XBMCPREFIX=/allwinner/xbmc-pvr-bin$(HF)<br />
#where is your toolchain<br />
TOOLCHAIN=/usr/arm-linux-gnueabi$(HF)<br />
<br />
=== Build ===<br />
At this point the settings are basically the same for the native build:<br />
Build dependencies<br />
root@debian:~/melehacking/xbmca10# cd tools/a10/depends<br />
root@debian:~/melehacking/xbmca10/tools/a10/depends# make<br />
Build xbmc itself<br />
root@debian:~/melehacking/xbmca10/tools/a10/depends# make -C xbmc<br />
root@debian:~/melehacking/xbmca10/tools/a10/depends# cd ../../../<br />
root@debian:~/melehacking/xbmca10# make install<br />
<br />
=== Move XBMC to target system ===<br />
You should copy from your install location on your build system to an identical location on the target system (may not vital that they have the same path) like so ...<br />
root@debian:~/melehacking/xbmca10/cp -r /allwinner/xbmc-pvr-binhf /mnt/rootfs-a10/allwinner/xbmc-pvr-binhf<br />
<br />
To redistribute it, you can also create a tarball:<br />
root@debian:~/melehacking/xbmca10/tools/a10/depends# make -C package tarball<br />
This results in a xbmca10.tar.gz which includes all needed (and stripped) files in /allwinner/xbmc-pvr-binhf. This can easily be copied and extracted on the target rootfs.<br />
<br />
Umount your SD Card<br />
root@debian:~/melehacking/xbmca10# umount /dev/sdb2<br />
and boot it on your A10 Device.<br />
<br />
== Start XBMC ==<br />
After a reboot you modprobe the needed modules (depending on the used kernel version):<br />
root@mele:~/# modprobe disp<br />
root@mele:~/# modprobe lcd<br />
root@mele:~/# modprobe hdmi<br />
root@mele:~/# modprobe mali<br />
root@mele:~/# export A10HWR=1 (ensure to have this set if not rebooting!)<br />
root@mele:~/# cd /allwinner/xbmc-pvr-bin/lib/xbmc<br />
root@mele:/allwinner/xbmc-pvr-bin/lib/xbmc# ./xbmc.bin<br />
<br />
== Using the Android libraries via libhybris ==<br />
Due to some bugs in the native linux binaries of cedarx, ''ssvb'' succeeded to use libhybris and the Android binaries instead. This is the recommended way.<br />
See [[CedarX/libve]].<br />
<br />
== Troubleshooting ==<br />
* (native) If you get a compiler error when processing h264.o or building xbmc.bin, then check, if swap is enabled. The compiler ran out of memory!<br />
* (native) If deb-building fails, check, if your tmp-directory has enough free space and is no tmpfs, because of the lack of memory an mele.<br />
* To use the bash-script bin/xbmc to start xbmc, you have to comment out the exec of FEH.py, because of a failing test of glxinfo -> no display found.<br />
* Depending on your setup you may have to change some things to build<br />
* If mysql_config is not found, even though it is clearly there you can set disable-mysql in Makefile under xbmca10/tools/a10/depends/xbmc<br />
* Header files might not be where they are expected, this can be fixed with symlinks and copying headers, for example...<br />
ln -s usr/include/dbus1.0/dbus usr/include/dbus <br />
* Once you get in trouble with some mesa conflicts, ensure to not have installed the following packages on your target system: <br />
libegl1-mesa libegl1-mesa-dev libegl1-mesa-drivers libgles2-mesa libgles2-mesa-dev<br />
* Check the discussion section for more notes.<br />
* Ensure that you have installed ALL of the dependencies, header files etc. in your target rootfs and ensure that they are available during build. The build script does not search for them on your host-rootfs!<br />
<br />
= Configuring XBMC dependencies for Linux on A10 based devices =<br />
== Getting IR (infrared) remotes working on A10 based media players ==<br />
For getting IR (infrared) remote controls working on the A10 based media players, please see the [[LIRC]] article in this wiki. Place a suitable [[Lircmap.xml]] in userdata-directory.<br />
<br />
= Enabling dirty regions (a.k.a. dirty textures) for XBMC =<br />
This dirty region (a.k.a. dirty texture) feature in XBMC is designed to improve XBMC's GUI renderer performance on the GPU by only drawing when something like a texture changes on the screen, that region is then marked as dirty by XBMC's GUI library and only that region is redraw region on the screen.<br />
<br />
This feature is however still a little buggy and therefor not enabled by default in XBMC, but all users of XBMC on A10 based devices can try enabling the hidden "dirty regions" (a.k.a. "dirty textures") rendering feature advanced setting themselves manually. <br />
<br />
* http://wiki.xbmc.org/index.php?title=HOW-TO:Enable_dirty_regions<br />
* http://xbmc.org/theuni/2011/06/19/working-with-dirty-regions/<br />
* http://wiki.xbmc.org/index.php?title=Advancedsettings.xml#.3Calgorithmdirtyregions.3E<br />
<br />
Dirty regions are any parts of the screen that have changed since the last frame. By not re-rendering what hasn't changed, big speed gains can be seen. Because all GPUs work differently, only Mode 3, combined with nofliptimeout=0, is guaranteed to be safe for everyone, but current timing issues with nofliptimeout keep this from being the default. Note that with "dirty regions" your system CPU usage might go up a little (because it is doing the dirty regions calculations) but your GPU usage will be much lower, and since it is the GPU and not CPU that is the bottleneck in XBMC for embedded systems your GUI performance will be better even though the CPU usage is higher.<br />
<br />
{| class="wikitable"<br />
! value !! result !! description<br />
|-<br />
! 0<br />
| Off<br />
| The entire viewport is always rendered, which is the same as having the dirty regions feature disabled. This is the default mode.<br />
|-<br />
! 1<br />
|Union<br />
|All dirty regions are grouped into the smallest possible rectangle. This is typically the fastest mode for slower GPUs due to only making one pass.<br />
|-<br />
! 2<br />
|Cost reduction<br />
| Each dirty region is presented separately, in as many passes as there are regions.<br />
|-<br />
! 3<br />
|Whole Screen<br />
| The entire screen is rendered if there are any dirty regions. This, combined with nofliptimeout is a safe default for drivers that clear buffer contents (manifests as blinking or vibrating images)<br />
|}<br />
<br />
To enable dirty regions manually you need to create a "advancedsettings.xml" text file youself and put the XML <algorithmdirtyregions> enabling tags in there and copying to your "/userdata/" folder (/home/username/.xbmc/userdata/).<br />
<br />
Example:<br />
<code><br />
<gui> <br />
<algorithmdirtyregions>1</algorithmdirtyregions><br />
</gui><br />
</code><br />
<br />
You could also try to enable the <nofliptimeout> feature but that is even more experimental so know that it can cause even more GUI rendering issues in XBMC<br />
<br />
Example: <br />
<code><br />
<gui> <br />
<nofliptimeout>1000</nofliptimeout><br />
</gui><br />
</code><br />
<br />
To have both of these enabled your "advancedsettings.xml" then the finished file should look something like this:<br />
<br />
<code><br />
<advancedsettings><br />
<gui> <br />
<algorithmdirtyregions>1</algorithmdirtyregions><br />
<nofliptimeout>1000</nofliptimeout><br />
</gui><br />
</advancedsettings><br />
</code><br />
<br />
=Sources implementing CedarX support in XBMC=<br />
* [https://github.com/empatzero/xbmca10 https://github.com/empatzero/xbmca10]<br />
** [https://github.com/rellla/xbmca10 https://github.com/rellla/xbmca10] Recommended fork of empatzero ([http://pastebin.com/M4Di5tha Diff to upstream])<br />
** [https://github.com/vidonme/xbmc/ https://github.com/vidonme/xbmc/] Sources of [http://www.vidon.me/download.html VidOn.Me Player]? Seems to be a fork from empatzero. ([http://pastebin.com/LuQ4AB9J Diff to upstream] and [https://github.com/vidonme/xbmc/compare/xbmc:7b9ab8a85fd2b6030e6cf2659ff16380afef3996...master Github Compare]) This repo is reported from VidOn.me to be the "official" source code for their Allwinner XBMC version, yet the only code commit from VidOn.me themselves is [https://github.com/vidonme/xbmc/commit/b2b1696e8eb6617da07e0a043ca6ef2219ca080d#diff-2c44bd39cfe6b4185fe6a51b78c46cd0R122 this one]. <br />
* [https://github.com/huceke/xbmc/tree/allwinner https://github.com/huceke/xbmc/tree/allwinner] Gimli's implementation ([http://pastebin.com/Nu3DrfNK Diff to upstream])<br />
<br />
= See also =<br />
* [[CedarX]] - Library for Allwinner CedarX VPU (Video Processor Unit) used for audio and video decoding and encoding hardware off-loading on A1x and A2x SoC series.<br />
** [[CedarXVideoRenderingChart]] - Overview chart of working/ non working video files<br />
* [[LIRC|LIRC (Linux Infrared Remote Control) for IR receivers and and remotes]]<br />
* [[Tvheadend TV Tuner Server and PVR backend]]<br />
<br />
=xternal Links=<br />
* http://kodi.tv - Kodi.tv the official Kodi/XBMC website with wiki and forums.<br />
** http://github.com/xbmc/xbmc/ - The upstream Kodi mainstream source code repository on GitHub.<br />
* [http://forum.xbmc.org/showthread.php?tid=126995 XBMC Official Community Forum discussion about porting to Allwinner A10]<br />
* [http://jas-hacks.blogspot.co.uk/2012/11/hackberry-a10-xbmc.html Jas Hacks Hackberry A10 - XBMC on Ubuntu 12.10 image]<br />
* [http://www.j1nx.nl/buildroot-xbmc-on-mele-a1000-allwinner-a10/ Buildroot XBMC on the Mele A1000 (Allwinner A10)]<br />
* [http://www.cnx-software.com/2012/11/12/xbmc-for-linux-on-allwinner-a10-devices-it-works-sort-of/ XBMC for Linux on AllWinner A10 Devices? It Works! (Sort of)]<br />
<br />
=References=<br />
<references /><br />
<br />
[[Category:Software]]<br />
[[Category:Tutorial]]<br />
[[Category:CedarX]]</div>Rockerhttps://linux-sunxi.org/index.php?title=CedarX/XBMC&diff=16027CedarX/XBMC2016-01-18T14:52:24Z<p>Rocker: </p>
<hr />
<div>{{redbox|<big><br />
{{warn|'''Kodi/XBMC for linux on Allwinner devices is NOT READY FOR USE!'''|}}<br />
<br />
This is still only a hack intended for developers and curious users at the moment. Don't expect it to work as you want it! Hardware is capable to make it run quite good in the future, but software and drivers are not ready yet. Sadly, nobody is working towards making a smooth Kodi/XBMC experience possible at the moment.<br />
<br />
If you want to help developing the needed components to have a stable Kodi/XBMC in the future, join the [[:Category:Community|irc and mailing list]]. Developers wanted!</big>}}<br />
<br/><br />
<br />
'''Kodi''' (formerly '''XBMC''') is a popular free and open source media player softwar designed as a home theater (a.k.a. media center) 10-foot frontend graphical interface with interface for large-screen televisions. Made to be controlled with a remote control it enables ARM-based media players and set-top boxes like those with Allwinner SoCs with [[CedarX]] VPU (Video Processor Unit) to hardware decode and play high-definition videos, music, and other digital media files from local and network storage media, as well as stream podcasts, videocasts, and such of the internet, and displayed in a appealing way on your living-room TV.<br />
<br />
This article contain instructions on compiling and developing Kodi/XBMC on and for Allwinner SoCs that features the [[CedarX]] VPU, like [[A10]], [[A10s]], [[A13]], [[A20]], and [[A23]]. Note that these instructions are specifically only meant for developers and advanced or expert Linux users that can actively assist with the porting process.<br />
<br />
=Overview=<br />
Kodi/XBMC has already have an initial but ultimatly obsolete port for the A10 / A20 SoC with [[CedarX]] hardware accelerated video decoding, this experimental third-party port and the code patches have however not made it upstream into mainline Kodi/XBMC.<ref>http://www.j1nx.nl/buildroot-xbmc-on-mele-a1000-allwinner-a10/ Buildroot XBMC on the Mele A1000 (Allwinner A10)</ref><ref>http://www.cnx-software.com/2012/11/12/xbmc-for-linux-on-allwinner-a10-devices-it-works-sort-of/ XBMC for Linux on AllWinner A10 Devices? It Works! (Sort of)</ref><br />
<br />
Pre-built application binaries of this initial port are not available so therefore you will need to compile Kodi/XBMC yourself, at least until if and when code for these CedarX based Allwinner SoCs makes it into the mainline XBMC upstream at http://kodi.tv<br />
<br />
Team-Kodi (who before used to be known as Team-XBMC), the official development team of Kodi/XBMC, does currently not recommend that any end-user buy Allwinner A1x or A2x based hardware for the specific purpose of only running Kodi/XBMC since they do not have the resources to support this platform as of yet.<br />
<br />
More information about Kodi/XBMC can be found on wikipedia http://en.wikipedia.org/wiki/XBMC and the Kodi wiki http://wiki.kodi.tv or http://forum.kodi.tv<br />
<br />
= Building Kodi/XBMC for A10 and A20 SoC series=<br />
This is a little how-to of steps to compile XBMC for devices using Allwinner A10 and A20 SoC series (e.g. for hardware like Mele A1000, Cubieboard, and Banana Pi) based on Empat0's GitHub sources [http://github.com/empatzero/xbmca10 http://github.com/empatzero/xbmca10].<br />
The development work on the coding side was all done by Empat0 (a.k.a. empat zero). The used repository in the example below is however from [http://github.com/rellla/xbmca10 http://github.com/rellla/xbmca10] which is currently the newest and contains a few adaptions. It is a fork of empat0's work. If you want an only A20 version you can use this repository: [https://github.com/fflayol/xbmc https://github.com/fflayol/xbmc] .<br />
<br />
The result should be a Debian armhf system with XBMC using [[CedarX]] for hardware accelerated video decoding.<br />
<br />
This version of XBMC runs directly on the framebuffer, and thus XServer is therefor not needed!<br />
<br />
== Prerequisites ==<br />
There are more ways to prepare a working rootfs for XBMC. You can either prepare the sdcard directly as described or you can chroot into the rootfs on your host system and sync it with your sdcard later when you have finished.<br />
So the following steps can also be done in a chroot on your host if you are cross-compiling.<br />
<br />
=== Prepare your SD-Card ===<br />
Create a bootable SD-Card follwing [[Manual_build_howto| our manual build howto]] and Debian. Be sure to use a kernel with mali-drivers-version r3p0 (sunxi-3.0 should be good).<br />
<br />
=== Boot into your target system ===<br />
Boot the new debian from the sd-card directly on the target and bring the system up to date:<br />
root@mele:~/# apt-get update<br />
root@mele:~/# apt-get upgrade<br />
<br />
=== Install the dependencies for XBMC (needs update!) ===<br />
root@mele:~/# apt-get build-dep xbmc<br />
<br />
:this should install the following packages:<code><br />
:autoconf automake autopoint autotools-dev binutils bsdmainutils build-essential bzip2 cmake cmake-data comerr-dev cpp cpp-4.4 cpp-4.6 curl debhelper dpkg-dev emacsen-common fontconfig-config g++ g++-4.4 g++-4.6 gawk gcc gcc-4.4 gcc-4.4-base gcc-4.6 gcc-4.6-base gettext gettext-base git git-man gperf groff-base html2text intltool-debian krb5-multidev libao-common libao-dev libao4 libarchive12 libasound2 libasound2-dev libasprintf0c2 libass-dev libass4 libasyncns0 libavahi-client-dev libavahi-client3 libavahi-common-data libavahi-common-dev libavahi-common3 libavcodec-dev libavcodec53 libavfilter-dev libavfilter2 libavformat-dev libavformat53 libavutil-dev libavutil51 libbluetooth-dev libbluetooth3 libbluray-dev libbluray1 libboost-date-time1.49-dev libboost-date-time1.49.0 libboost-dev libboost-serialization1.49-dev libboost-serialization1.49.0 libboost-thread-dev libboost-thread1.49-dev libboost-thread1.49.0 libboost1.49-dev libbz2-dev libc-dev-bin libc6-dev libcaca-dev libcaca0 libcdio-dev libcdio13 libcec-dev libcec1 libcroco3 libcurl3 libcurl3-gnutls libcurl4-gnutls-dev libcwiid-dev libcwiid1 libdbus-1-3 libdbus-1-dev libdirac-encoder0 libdirectfb-1.2-9 libdirectfb-dev libdirectfb-extra libdpkg-perl libdrm2 libelf1 libenca-dev libenca0 liberror-perl libexpat1 libexpat1-dev libflac-dev libflac8 libfontconfig1 libfontconfig1-dev libfreetype6 libfreetype6-dev libfribidi-dev libfribidi0 libgcrypt11-dev libgettextpo0 libgl1-mesa-dev libgl1-mesa-glx libglapi-mesa libglew-dev libglew1.7 libglib2.0-bin libglib2.0-dev libglu1-mesa libglu1-mesa-dev libgmp10 libgnutls-dev libgnutls-openssl27 libgnutlsxx27 libgomp1 libgpg-error-dev libgsm1 libgssrpc4 libhal-dev libhal-storage-dev libhal-storage1 libhal1 libice-dev libice6 libicu48 libidn11-dev libiso9660-8 libiso9660-dev libjasper-dev libjasper1 libjbig-dev libjbig0 libjpeg8 libjpeg8-dev libjson0 libkadm5clnt-mit8 libkadm5srv-mit8 libkdb5-6 libkrb5-dev liblcms1 libldap-2.4-2 libldap2-dev libltdl-dev libltdl7 liblzo2-2 liblzo2-dev libmad0 libmad0-dev libmicrohttpd-dev libmicrohttpd10 libmikmod2 libmikmod2-dev libmodplug-dev libmodplug1 libmp3lame-dev libmp3lame0 libmpc2 libmpeg2-4 libmpeg2-4-dev libmpfr4 libmysqlclient-dev libmysqlclient18 libnettle4 libnfs-dev libnfs1 libogg-dev libogg0 libopencv-core2.3 libopencv-imgproc2.3 libopenjpeg2 liborc-0.4-0 libp11-kit-dev libpcre3-dev libpcrecpp0 libpipeline1 libplist-dev libplist1 libpng12-0 libpng12-dev libpopt0 libpostproc-dev libpostproc52 libpthread-stubs0 libpthread-stubs0-dev libpulse-dev libpulse-mainloop-glib0 libpulse0 libpython2.7 librtmp-dev librtmp0 libsamplerate0 libsamplerate0-dev libsasl2-2 libschroedinger-1.0-0 libsdl-image1.2 libsdl-image1.2-dev libsdl-mixer1.2 libsdl-mixer1.2-dev libsdl1.2-dev libsdl1.2debian libshairport-dev libshairport1 libsigsegv2 libslang2-dev libsm-dev libsm6 libsmbclient libsmbclient-dev libsndfile1 libspeex1 libsqlite3-0 libsqlite3-dev libssh2-1 libssh2-1-dev libssl-dev libstdc++6-4.4-dev libstdc++6-4.6-dev libswscale-dev libswscale2 libtalloc2 libtasn1-3-dev libtdb1 libtheora0 libtiff4 libtiff4-dev libtiffxx0c2 libtimedate-perl libtinyxml-dev libtinyxml2.6.2 libtool libts-0.0-0 libts-dev libudev-dev libunistring0 libva-dev libva-egl1 libva-glx1 libva-tpi1 libva-x11-1 libva1 libvdpau-dev libvdpau1 libvorbis-dev libvorbis0a libvorbisenc2 libvorbisfile3 libvpx1 libwbclient0 libwebp-dev libwebp2 libx11-dev libx11-xcb1 libx264-123 libxau-dev libxcb-glx0 libxcb1-dev libxdamage1 libxdmcp-dev libxext-dev libxfixes3 libxi6 libxml2-dev libxmlrpc-core-c3 libxmu-dev libxmu-headers libxmu6 libxrandr-dev libxrandr2 libxrender-dev libxrender1 libxt-dev libxt6 libxtst6 libxvidcore4 libxxf86vm1 libyajl-dev libyajl2 linux-libc-dev m4 make man-db mesa-common-dev mysql-common patch pkg-config po-debconf python python-dev python-imaging python-minimal python-support python2.7 python2.7-dev python2.7-minimal tsconf ttf-dejavu-core ucf x11-common x11proto-core-dev x11proto-input-dev x11proto-kb-dev x11proto-randr-dev x11proto-render-dev x11proto-xext-dev xorg-sgml-doctools xtrans-dev yasm zip zlib1g-dev</code><br />
<br />
need to install 3 more dependencies:<br />
root@mele:~/# apt-get install swig default-jre libgtk2.0-bin libssh-4 libssh-dev<br />
<br />
ensure you use hardware acceleration<br />
root@mele:~/# echo -e "\nA10HWR=1" >> /etc/environment (to set it permanently)<br />
<br />
Now go on with [[XBMC#Native_Compile_of_XBMC | Native Compile]] or [[XBMC#Cross_Compile_of_XBMC | Cross Compile]].<br />
<br />
== Native Compile of XBMC ==<br />
<br />
=== Prerequisites for native compile ===<br />
<br />
Create a swap-file, because otherwise the compiler runs out of memory during compiling and aborts<br />
root@mele:~/# dd if=/dev/zero of=/swap bs=1M count=384<br />
root@mele:~/# mkswap -c /swap<br />
root@mele:~/# swapon /swap<br />
<br />
Create your workspace directory:<br />
root@mele:~/# mkdir melehacking<br />
root@mele:~/# cd melehacking<br />
<br />
=== Checkout the source code ===<br />
root@mele:~/melehacking# apt-get install git<br />
root@mele:~/melehacking# git clone git://github.com/rellla/xbmca10.git<br />
root@mele:~/melehacking# cd xbmca10<br />
root@mele:~/melehacking/xbmca10# git checkout stage/Frodo<br />
<br />
=== Build ===<br />
The following external libs/ repos are used/ downloaded:<br />
* taglib: https://github.com/downloads/taglib/taglib/taglib-1.8.tar.gz<br />
* cedarx: https://github.com/linux-sunxi/cedarx-libs/tree/master/libcedarv/linux-armhf<br />
* libmad: ftp://ftp.mars.org/pub/mpeg/libmad-0.15.1b.tar.gz<br />
* mali: https://github.com/linux-sunxi/sunxi-mali-proprietary/tree/master/r3p0/armhf<br />
* mali-dev: https://github.com/linux-sunxi/sunxi-mali/tree/master/include<br />
<br />
Build dependencies<br />
root@mele:~/melehacking/xbmca10# cd tools/a10/depends<br />
root@mele:~/melehacking/xbmca10/tools/a10/depends# make<br />
Build xbmc itself<br />
root@mele:~/melehacking/xbmca10/tools/a10/depends# make -C xbmc<br />
root@mele:~/melehacking/xbmca10/tools/a10/depends# cd ../../../<br />
root@mele:~/melehacking/xbmca10# make install<br />
<br />
Move on to [[XBMC#Start_XBMC]] and start XBMC.<br />
<br />
== Cross Compile of XBMC ==<br />
This was tested with github.com/rellla/xbmca10 and built in Debian Sid as host. You will need several packages on the build system and a copy <br />
of the root file system of the target to build against. This howto assumes you are running off an SD card with the root file system in /dev/sdb2.<br />
=== Setup Cross Compiler ===<br />
* At first set up your [[Toolchain|toolchain]].<br />
<br />
=== Prerequisites for Cross Compiling ===<br />
* Sync and move SD card to build system<br />
* Mount the rootfs of the prepared SD Card<br />
root@debian:~/# mount /dev/sdb2 /mnt/rootfs-a10<br />
* Create symlinks to the mounted libraries<br />
root@debian:~/# ln -s /mnt/rootfs-a10/lib/arm-linux-gnueabihf /lib/arm-linux-gnueabihf<br />
root@debian:~/# ln -s /mnt/rootfs-a10/usr/lib/arm-linux-gnueabihf /usr/lib/arm-linux-gnueabihf<br />
root@debian:~/# ln -s /mnt/rootfs-a10/usr/include/arm-linux-gnueabihf /usr/include/arm-linux-gnueabihf<br />
* Install the dependencies for building XBMC on the host system<br />
root@debian:~/# apt-get build-dep xbmc<br />
root@debian:~/# apt-get install shtool swig default-jre<br />
Note: If compiling on a 64 bit system there is a known bug with the libcurl headers not working with 32 bit programs. To work around the problem build on a 32 bit system, or copy the file /usr/include/curl/curlbuild.h from a 32 bit system to your 64 bit build host.<br />
* Create your workspace directory:<br />
root@debian:~/# mkdir melehacking<br />
root@debian:~/# cd melehacking<br />
<br />
=== Checkout the source code ===<br />
root@debian:~/melehacking# git clone git://github.com/rellla/xbmca10.git<br />
root@debian:~/melehacking# cd xbmca10<br />
root@debian:~/melehacking/xbmca10# git checkout stage/Frodo<br />
<br />
=== Update XBMC build config ===<br />
Update this section at line 48 of tools/a10/depends/depends.mk with your values, e.g.<br />
#where is your arm rootfs<br />
SDKSTAGE=/mnt/rootfs-a10<br />
#where is your xbmc install root <br />
XBMCPREFIX=/allwinner/xbmc-pvr-bin$(HF)<br />
#where is your toolchain<br />
TOOLCHAIN=/usr/arm-linux-gnueabi$(HF)<br />
<br />
=== Build ===<br />
At this point the settings are basically the same for the native build:<br />
Build dependencies<br />
root@debian:~/melehacking/xbmca10# cd tools/a10/depends<br />
root@debian:~/melehacking/xbmca10/tools/a10/depends# make<br />
Build xbmc itself<br />
root@debian:~/melehacking/xbmca10/tools/a10/depends# make -C xbmc<br />
root@debian:~/melehacking/xbmca10/tools/a10/depends# cd ../../../<br />
root@debian:~/melehacking/xbmca10# make install<br />
<br />
=== Move XBMC to target system ===<br />
You should copy from your install location on your build system to an identical location on the target system (may not vital that they have the same path) like so ...<br />
root@debian:~/melehacking/xbmca10/cp -r /allwinner/xbmc-pvr-binhf /mnt/rootfs-a10/allwinner/xbmc-pvr-binhf<br />
<br />
To redistribute it, you can also create a tarball:<br />
root@debian:~/melehacking/xbmca10/tools/a10/depends# make -C package tarball<br />
This results in a xbmca10.tar.gz which includes all needed (and stripped) files in /allwinner/xbmc-pvr-binhf. This can easily be copied and extracted on the target rootfs.<br />
<br />
Umount your SD Card<br />
root@debian:~/melehacking/xbmca10# umount /dev/sdb2<br />
and boot it on your A10 Device.<br />
<br />
== Start XBMC ==<br />
After a reboot you modprobe the needed modules (depending on the used kernel version):<br />
root@mele:~/# modprobe disp<br />
root@mele:~/# modprobe lcd<br />
root@mele:~/# modprobe hdmi<br />
root@mele:~/# modprobe mali<br />
root@mele:~/# export A10HWR=1 (ensure to have this set if not rebooting!)<br />
root@mele:~/# cd /allwinner/xbmc-pvr-bin/lib/xbmc<br />
root@mele:/allwinner/xbmc-pvr-bin/lib/xbmc# ./xbmc.bin<br />
<br />
== Using the Android libraries via libhybris ==<br />
Due to some bugs in the native linux binaries of cedarx, ''ssvb'' succeeded to use libhybris and the Android binaries instead. This is the recommended way.<br />
See [[CedarX/libve]].<br />
<br />
== Troubleshooting ==<br />
* (native) If you get a compiler error when processing h264.o or building xbmc.bin, then check, if swap is enabled. The compiler ran out of memory!<br />
* (native) If deb-building fails, check, if your tmp-directory has enough free space and is no tmpfs, because of the lack of memory an mele.<br />
* To use the bash-script bin/xbmc to start xbmc, you have to comment out the exec of FEH.py, because of a failing test of glxinfo -> no display found.<br />
* Depending on your setup you may have to change some things to build<br />
* If mysql_config is not found, even though it is clearly there you can set disable-mysql in Makefile under xbmca10/tools/a10/depends/xbmc<br />
* Header files might not be where they are expected, this can be fixed with symlinks and copying headers, for example...<br />
ln -s usr/include/dbus1.0/dbus usr/include/dbus <br />
* Once you get in trouble with some mesa conflicts, ensure to not have installed the following packages on your target system: <br />
libegl1-mesa libegl1-mesa-dev libegl1-mesa-drivers libgles2-mesa libgles2-mesa-dev<br />
* Check the discussion section for more notes.<br />
* Ensure that you have installed ALL of the dependencies, header files etc. in your target rootfs and ensure that they are available during build. The build script does not search for them on your host-rootfs!<br />
<br />
= Configuring XBMC dependencies for Linux on A10 based devices =<br />
== Getting IR (infrared) remotes working on A10 based media players ==<br />
For getting IR (infrared) remote controls working on the A10 based media players, please see the [[LIRC]] article in this wiki. Place a suitable [[Lircmap.xml]] in userdata-directory.<br />
<br />
= Enabling dirty regions (a.k.a. dirty textures) for XBMC =<br />
This dirty region (a.k.a. dirty texture) feature in XBMC is designed to improve XBMC's GUI renderer performance on the GPU by only drawing when something like a texture changes on the screen, that region is then marked as dirty by XBMC's GUI library and only that region is redraw region on the screen.<br />
<br />
This feature is however still a little buggy and therefor not enabled by default in XBMC, but all users of XBMC on A10 based devices can try enabling the hidden "dirty regions" (a.k.a. "dirty textures") rendering feature advanced setting themselves manually. <br />
<br />
* http://wiki.xbmc.org/index.php?title=HOW-TO:Enable_dirty_regions<br />
* http://xbmc.org/theuni/2011/06/19/working-with-dirty-regions/<br />
* http://wiki.xbmc.org/index.php?title=Advancedsettings.xml#.3Calgorithmdirtyregions.3E<br />
<br />
Dirty regions are any parts of the screen that have changed since the last frame. By not re-rendering what hasn't changed, big speed gains can be seen. Because all GPUs work differently, only Mode 3, combined with nofliptimeout=0, is guaranteed to be safe for everyone, but current timing issues with nofliptimeout keep this from being the default. Note that with "dirty regions" your system CPU usage might go up a little (because it is doing the dirty regions calculations) but your GPU usage will be much lower, and since it is the GPU and not CPU that is the bottleneck in XBMC for embedded systems your GUI performance will be better even though the CPU usage is higher.<br />
<br />
{| class="wikitable"<br />
! value !! result !! description<br />
|-<br />
! 0<br />
| Off<br />
| The entire viewport is always rendered, which is the same as having the dirty regions feature disabled. This is the default mode.<br />
|-<br />
! 1<br />
|Union<br />
|All dirty regions are grouped into the smallest possible rectangle. This is typically the fastest mode for slower GPUs due to only making one pass.<br />
|-<br />
! 2<br />
|Cost reduction<br />
| Each dirty region is presented separately, in as many passes as there are regions.<br />
|-<br />
! 3<br />
|Whole Screen<br />
| The entire screen is rendered if there are any dirty regions. This, combined with nofliptimeout is a safe default for drivers that clear buffer contents (manifests as blinking or vibrating images)<br />
|}<br />
<br />
To enable dirty regions manually you need to create a "advancedsettings.xml" text file youself and put the XML <algorithmdirtyregions> enabling tags in there and copying to your "/userdata/" folder (/home/username/.xbmc/userdata/).<br />
<br />
Example:<br />
<code><br />
<gui> <br />
<algorithmdirtyregions>1</algorithmdirtyregions><br />
</gui><br />
</code><br />
<br />
You could also try to enable the <nofliptimeout> feature but that is even more experimental so know that it can cause even more GUI rendering issues in XBMC<br />
<br />
Example: <br />
<code><br />
<gui> <br />
<nofliptimeout>1000</nofliptimeout><br />
</gui><br />
</code><br />
<br />
To have both of these enabled your "advancedsettings.xml" then the finished file should look something like this:<br />
<br />
<code><br />
<advancedsettings><br />
<gui> <br />
<algorithmdirtyregions>1</algorithmdirtyregions><br />
<nofliptimeout>1000</nofliptimeout><br />
</gui><br />
</advancedsettings><br />
</code><br />
<br />
=Sources implementing CedarX support in XBMC=<br />
* [https://github.com/empatzero/xbmca10 https://github.com/empatzero/xbmca10]<br />
** [https://github.com/rellla/xbmca10 https://github.com/rellla/xbmca10] Recommended fork of empatzero ([http://pastebin.com/M4Di5tha Diff to upstream])<br />
** [https://github.com/vidonme/xbmc/ https://github.com/vidonme/xbmc/] Sources of [http://www.vidon.me/download.html VidOn.Me Player]? Seems to be a fork from empatzero. ([http://pastebin.com/LuQ4AB9J Diff to upstream] and [https://github.com/vidonme/xbmc/compare/xbmc:7b9ab8a85fd2b6030e6cf2659ff16380afef3996...master Github Compare]) This repo is reported from VidOn.me to be the "official" source code for their Allwinner XBMC version, yet the only code commit from VidOn.me themselves is [https://github.com/vidonme/xbmc/commit/b2b1696e8eb6617da07e0a043ca6ef2219ca080d#diff-2c44bd39cfe6b4185fe6a51b78c46cd0R122 this one]. <br />
* [https://github.com/huceke/xbmc/tree/allwinner https://github.com/huceke/xbmc/tree/allwinner] Gimli's implementation ([http://pastebin.com/Nu3DrfNK Diff to upstream])<br />
<br />
= See also =<br />
* [[CedarX]] - Library for Allwinner CedarX VPU (Video Processor Unit) used for audio and video decoding and encoding hardware off-loading on A1x and A2x SoC series.<br />
** [[CedarXVideoRenderingChart]] - Overview chart of working/ non working video files<br />
* [[LIRC|LIRC (Linux Infrared Remote Control) for IR receivers and and remotes]]<br />
* [[Tvheadend TV Tuner Server and PVR backend]]<br />
<br />
=xternal Links=<br />
* http://kodi.tv - Kodi.tv the official Kodi/XBMC website with wiki and forums.<br />
** http://github.com/xbmc/xbmc/ - The upstream Kodi mainstream source code repository on GitHub.<br />
* [http://forum.xbmc.org/showthread.php?tid=126995 XBMC Official Community Forum discussion about porting to Allwinner A10]<br />
* [http://jas-hacks.blogspot.co.uk/2012/11/hackberry-a10-xbmc.html Jas Hacks Hackberry A10 - XBMC on Ubuntu 12.10 image]<br />
* [http://www.j1nx.nl/buildroot-xbmc-on-mele-a1000-allwinner-a10/ Buildroot XBMC on the Mele A1000 (Allwinner A10)]<br />
* [http://www.cnx-software.com/2012/11/12/xbmc-for-linux-on-allwinner-a10-devices-it-works-sort-of/ XBMC for Linux on AllWinner A10 Devices? It Works! (Sort of)]<br />
<br />
=References=<br />
<references /><br />
<br />
[[Category:Software]]<br />
[[Category:Tutorial]]<br />
[[Category:CedarX]]</div>Rockerhttps://linux-sunxi.org/index.php?title=Allwinner_SoC_Family&diff=12940Allwinner SoC Family2015-01-28T13:21:46Z<p>Rocker: /* 2013 naming scheme change */</p>
<hr />
<div>= "A"-Series =<br />
Based on ARMv7 Cortex-A cores (Cortex-A7,A8, and A15) targeted for hi-end devices like digital media player, tablets, and netbooks:<br />
* [[A10|Allwinner A10]] <small>(sun4i)</small> (1 x Cortex-A8 CPU-core)<br />
* [[A13|Allwinner A13]] <small>(sun5i)</small> (1 x Cortex-A8 CPU-core)<br />
* [[A10s|Allwinner A10s]]<small>(sun5i)</small>(1 x Cortex-A8 CPU-core)<br />
* [[A20|Allwinner A20]] <small>(sun7i)</small> (2 x Cortex-A7 CPU-cores)<br />
* [[A23|Allwinner A23]] <small>(sun8i)</small> (2 x Cortex-A7 CPU-cores)<br />
* [[A31|Allwinner A31]] <small>(sun6i)</small> (4 x Cortex-A7 CPU-cores)<br />
* [[A31s|Allwinner A31s]] <small>(sun6i)</small> (4 x Cortex-A7 CPU-cores)<br />
* [[A33|Allwinner A33]] <small>(sun8i)</small> (4 x Cortex-A7 CPU-cores)<br />
* [[A80|Allwinner A80]] <small>(sun9i)</small> (4 x Cortex-A7 CPU-cores + 4 x Cortex-A15 CPU-cores using ARM big.LITTLE heterogeneous CPU architecture)<br />
* [[A83T|Allwinner A83T]] <small>(sun9i)</small> (8 x Cortex-A7 CPU-cores)<br />
<br />
= 2013 naming scheme change =<br />
<br />
Initially, Allwinner named their SoCs chronologically:<br />
* sun4i = A10<br />
* sun5i = A13/A10s<br />
* sun6i = A31<br />
* sun7i = A20<br />
<br />
But, somewhere in 2013, Allwinner decided to update their naming scheme to be based on the ARM core used instead: (taken from the A80 SDK kernel code)<br />
<pre>sunxi<br />
|-- sun4i ----------------------------- : cortex-a8<br />
| |-- sun4iw1 --------------- wafer1<br />
| | `-- sun4iw1p1 ----- a10<br />
| `-- sun4iw2 --------------- wafer2<br />
| |-- sun4iw2p1 ----- a13<br />
| |-- sun4iw2p2 ----- a12<br />
| `-- sun4iw2p3 ----- a10s<br />
|-- sun8i ----------------------------- : cortex-a7 smp<br />
| |-- sun8iw1 --------------- wafer1<br />
| | |-- sun8iw1p1 ----- a31<br />
| | `-- sun8iw1p2 ----- a31s<br />
| |-- sun8iw2 --------------- wafer2<br />
| | |-- sun8iw2p1 ----- a20<br />
| | `-- sun8iw2p2<br />
| |-- sun8iw3 --------------- wafer3<br />
| | |-- sun8iw3p1 ----- a23<br />
| | `-- sun8iw3p2<br />
| |-- sun8iw5<br />
| | `-- sun8iw5p1 ----- a33<br />
| `-- sun8iw6<br />
| `-- sun8iw6p1<br />
`-- sun9i<br />
`-- sun9iw1<br />
|-- sun9iw1p1 ----- a80<br />
`-- sun9iw1p2 ----- a80t</pre><br />
<br />
This new naming scheme is of absolutely no value with respect to the rest of the SoC. The actual ARM core(s) used are usually the least important piece of information for SoC support. This table completely ignores the fact that A20 is an updated A10 and is pin compatible. It also ignores the fact that A31 introduced a lot of changes which were carried on to the A23/A33 and possibly A80 parts. It therefore is quite likely that this naming scheme was purely a marketing decision, and that Allwinner marketing will change its mind again.<br />
<br />
= features =<br />
* CPU: ARMv7-A [http://en.wikipedia.org/wiki/ARM_Cortex-A7 Cortex-A7], [http://en.wikipedia.org/wiki/ARM_Cortex-A15 Cortex-A15] or [http://en.wikipedia.org/wiki/ARM_Cortex-A8 Cortex-A8] Central Processor Unit which have [[NEON]], [[Vector Floating Point Unit|VFP]], [[TrustZone]], and [[Thumb-2]] co-processor extensions: <br />
** Advanced SIMD: [[NEON]] (ARM's extended general-purpose advanced SIMD vector processing extension engine)<br />
** Vector FPU: [[Vector Floating Point Unit]] - ARM VFPv3 lite (Cortex-A8) / VFPv4 (Cortex-A7) VFPU (Vector Floating Point Unit)<br />
** Security Extensions: <br />
*** TrustZone secure world<br />
*** [[Security_System|Security accelerator]] supporting AES, DES, 3DES, SHA-1, MD5 and pseudo-random number generation<br />
** [[Thumb2]] intruction set extension for optimized code to reduce memory footprint and improve performance<br />
* GPU: [[Mali400]], Mali400P2 or SGX544, PowerVR G6230 Graphics Procesor Unit, supporting OpenGL ES2.<br />
* VPU: [[CedarX]] (Video Processor Unit for audio and video hardware decoding or encoding)<br />
* HDMI-transmitter with [[HDMI CEC (Consumer Electronics Control)]], (with exception of A13 which lacks HDMI-transmitter and SATA-controller<ref>[http://olimex.wordpress.com/2012/04/24/cortex-a8-in-tqfp-sure-allwinner-a13/ "Cortex A8 in TQFP? sure Allwinner A13"] ''Retrieved 23 September 2012''</ref>)<br />
* Hardware virtualization capabilities (Cortex-A7 only).<br />
* Up to 4GB memory (Cortex-A8), Up to 1TB memory with LPAE (Cortex-A7 only).<br />
<br />
== Comparison table ==<br />
{| class="wikitable"<br />
|-<br />
! scope="row" | !! [[A10]] !! [[A10s]] !! [[A13]] !! [[A20]] !! [[A23]] !! [[A31]] !! [[A31s]] !! [[A33]] !! [[A80]]<br />
|-<br />
! scope="row" | Generation <br />
| sun4i || sun5i || sun5i || sun7i || sun8i || sun6i || sun?i (A31S)|| sun?i (A33) || sun9i <br />
|-<br />
! scope="row" | CPU<br />
| Cortex-A8 || Cortex-A8 || Cortex-A8 || Cortex-A7 || Cortex-A7 ||Cortex-A7 || Cortex-A7 || Cortex-A7 || Cortex-A7 / A15 <br />
|-<br />
! scope="row" | CPU Maximum frequency<br />
| 1GHz|| 1GHz || 1GHz|| 912MHz|| 1.5Ghz || ?GHz || ?Ghz || ?.?Ghz || 2(??) Ghz<br />
|-<br />
! scope="row" | Cores<br />
| 1 || 1 || 1 || 2 || 2 || 4 || 4 || 4 || 2x4<br />
|-<br />
! scope="row" | Extensions<br />
| NEON, VFPv3, Thumb-2 || NEON, VFPv3, Thumb-2 || NEON, VFPv3, Thumb-2 || NEON, VFPv3 / VFPv4, Thumb-2 ||NEON, VFPv3 / VFPv4, Thumb-2 || NEON, VFPv3 / VFPv4, Thumb-2 || NEON, VFPv3 / VFPv4, Thumb-2 || NEON, VFPv3 / VFPv4, Thumb-2 || ? (A80)<br />
|-<br />
! scope="row" | Memory<br />
| DDR2, DDR3 (max 2GB @ DDR800) || DDR2, DDR3 (max 2GB @ DDR800) || DDR2, DDR3 (max 512MB @ DDR800) || LPDDR3/DDR3/LPDDR2 || DDR3 (max 1GB) || 2-channel DDR3/LPDDR2, 2-channel DDR3L/DDR3U || DDR3/DDR3L/LPDDR2 || ? (A33) || 2-channel DDR3/DDR3L/LPDDR3/LPDDR2, up to 8GB<br />
|-<br />
! scope="row" | GPU<br />
| [[Mali400]] @ 320Mhz || [[Mali400]] @ 320Mhz || [[Mali400]] @ 320Mhz || [[Mali400]] MP2 @ 350Mhz ||Mali400 MP2 || SGX544 @ 200Mhz || SGX544 @ 200Mhz || Mali400 MP2 || 64-core PowerVR G6230<br />
|-<br />
! scope="row" | GPU API<br />
| OpenGL ES 2.0, OpenVG 1.1 || OpenGL ES 2.0, OpenVG 1.1 || OpenGL ES 2.0, OpenVG 1.1 || OpenGL ES 2.0, OpenVG 1.1 || OpenGL ES 2.0, OpenVG 1.1 || OpenGL ES 2.0, OpenVG 1.1, OpenCL 1.1, and DirectX 9.3 || OpenGL ES 2.0, OpenVG 1.1, OpenCL 1.1, and DirectX 9.3 || OpenGL ES 2.0, OpenVG 1.1 || OpenGL 3.x, OpenGL ES Next,3.0,2.0, Open CL 1.x, DirectX 11 level 9_3/10_0<ref>http://www.imgtec.com/news/detail.asp?ID=845</ref><br />
|-<br />
! scope="row" | [[CedarX|Video decoder]]<br />
| 2160P || 1080P || 1080P || 2160p, 4K×2K, 1080p 3D || 1080p@60fps || 2160p, 4K×2K, 1080p 3D || 2160p, 1080p 3D || 1080p@60fps || ? (A80)<br />
|-<br />
! scope="row" | [[CedarX|Video encoder]]<br />
| H.264 1080P@30fps,JPEG || H.264 1080P@30fps,JPEG || H.264 1080P@30fps,JPEG || H.264 1080P@30fps,JPEG || 1080p@60fps || H.264 1080P@60fps,JPEG || H264 1080p@30fps, 720p@60fps || ? (A33) || H.264 HP/VP8 4Kx2K@30fp<br />
|-<br />
! scope="row" | [[CedarX|Audio decoder]]<br />
| AC3,DTS || ?|| ? || AC3,DTS|| - || ? (A31) || ? (A31S) || ? (A33) || ? (A80)<br />
|-<br />
! scope="row" | Video interfaces<br />
| HDMI 1.3, YPbPr, VGA, CPU/RGB/LVDS LCD || HDMI 1.3, RGB/LVDS LCD || RGB LCD, VGA|| HDMI 1.4, CVBS, YPbPr, VGA, CPU/RGB/LVDS LCD || CPU/RGB/LVDS LCD, MIPI DSI || HDMI 1.4, MIPI DSI, 2-channel LVDS, 2-channel RGB LCD || HDMI 1.4, LVDS, RGB LCD || ? (A33) || HDMI 4K , RGB LCD 2048x1536@60fps, dual-channel LVDS 1920x1080@60fps, 4-lane MIPI DSI 1920x1200@60fps, 4-lane eDP 2560x1600@60fps<br />
|-<br />
! scope="row" | Audio interfaces<br />
| I2S, SPDIF, AC97 || I2S, AC97 || I2S, AC97 || I2S, PCM, AC97 || I2S, PCM || 2 I2S, 2 PCM || I2S, 2 PCM || ? (A33) || ? (A80)<br />
|-<br />
! scope="row" | USB OTG<br />
| 1 || 1 || 1 || 1 || 1 || 1 || 1 || ? (A33) || 1<br />
|-<br />
! scope="row" | USB Host<br />
| 2 || 1 || 1 || 2 || 1 || 2 || 2 || ? (A33) || 2x USB Host, USB 3.0/2.0 Dual-Role (host/device)<br />
|-<br />
! scope="row" | Ethernet<br />
| EMAC || EMAC || - || EMAC/GMAC || - || GMAC || ? (A31S) || ? (A33) || GMAC<br />
|-<br />
! scope="row" | Storage<br />
| NAND (max 64GB), SATA II, SD Card 3.0 || NAND (max 64GB), SD Card 3.0 || NAND (max 64GB), SD Card 3.0 || NAND, MMC, [http://olimex.wordpress.com/2013/04/05/allwinners-a10-and-a20-are-they-really-pin-to-pin-compatible-and-drop-in-replacement/#comment-5452 SATA] || raw NAND, eMMC, SD card || 4x SD Card, eMMC NAND, 2-channel raw NAND || 4x SD Card, eMMC NAND, raw NAND || ? (A33) || 4x SD/MMC<br />
|-<br />
! scope="row" | Package<br />
| BGA441 19mm × 19mm, 0.80mm Pitch || BGA336 14mm × 14mm, 0.65mm Pitch || eLQFP176 20mm × 20mm ||BGA441 19mm × 19mm, 0.80mm Pitch || FBGA280 14x14x1.4, 0.80mm pitch || BGA609 18mm × 18mm, 0.65mm Pitch || ? (A31S) || ? (Allwinner: pin compatible with A23) || ? (A80)<br />
|-<br />
! scope="row" | Litography<br />
| 55nm || 55nm|| 55nm || 40nm || 40nm || 40nm || 40nm || 40nm || 28nm<br />
|}<br />
<ref>http://blog.thinkteletronics.com/all-mobile-socsolutions/ All Mobile Soc/Solutions.</ref><br />
<br />
= "F"-Series =<br />
'''NOTE: F series not supported by linux-sunxi community due lack of developers and hardware, sun3i have only offical linux port, sunii have no linux support only aw's melis RTOS'''<br />
<br />
<br />
Based on ARMv6 ARM926-EJS core and currenty targeted for low market devices such as cheap ebook readers, etc.<br />
<br />
* [[C100|Boxchip C100]] <small>(sun3i)</small><br />
* [[E200|Boxchip E200]] <small>(sun3i)</small><br />
* [[F20|Boxchip F20]] <small>(sun3i)</small><br />
* [[F10|Boxchip F10]] aka SoChip SC9800 aka Teclast T8100<small>(sunii)</small><br />
* [[F13|Boxchip F13]] <small>(sunii)</small><br />
* [[F13|Boxchip F15]] aka SoChip SC8600 aka Teclast T7200<small>(sunii)</small><br />
* [[F18|Boxchip F18]] <small>(sunii)</small><br />
<br />
==References==<br />
<references /></div>Rockerhttps://linux-sunxi.org/index.php?title=Allwinner_SoC_Family&diff=12939Allwinner SoC Family2015-01-28T13:21:31Z<p>Rocker: /* "A"-Series */</p>
<hr />
<div>= "A"-Series =<br />
Based on ARMv7 Cortex-A cores (Cortex-A7,A8, and A15) targeted for hi-end devices like digital media player, tablets, and netbooks:<br />
* [[A10|Allwinner A10]] <small>(sun4i)</small> (1 x Cortex-A8 CPU-core)<br />
* [[A13|Allwinner A13]] <small>(sun5i)</small> (1 x Cortex-A8 CPU-core)<br />
* [[A10s|Allwinner A10s]]<small>(sun5i)</small>(1 x Cortex-A8 CPU-core)<br />
* [[A20|Allwinner A20]] <small>(sun7i)</small> (2 x Cortex-A7 CPU-cores)<br />
* [[A23|Allwinner A23]] <small>(sun8i)</small> (2 x Cortex-A7 CPU-cores)<br />
* [[A31|Allwinner A31]] <small>(sun6i)</small> (4 x Cortex-A7 CPU-cores)<br />
* [[A31s|Allwinner A31s]] <small>(sun6i)</small> (4 x Cortex-A7 CPU-cores)<br />
* [[A33|Allwinner A33]] <small>(sun8i)</small> (4 x Cortex-A7 CPU-cores)<br />
* [[A80|Allwinner A80]] <small>(sun9i)</small> (4 x Cortex-A7 CPU-cores + 4 x Cortex-A15 CPU-cores using ARM big.LITTLE heterogeneous CPU architecture)<br />
* [[A83T|Allwinner A83T]] <small>(sun9i)</small> (8 x Cortex-A7 CPU-cores)<br />
<br />
= 2013 naming scheme change =<br />
<br />
Initially, Allwinner named their SoCs chronologically:<br />
* sun4i = A10<br />
* sun5i = A13/A10s<br />
* sun6i = A31<br />
* sun7i = A20<br />
<br />
But, somewhere in 2013, Allwinner decided to update their naming scheme to be based on the ARM core used instead: (taken from the A80 SDK kernel code)<br />
<pre>sunxi<br />
|-- sun4i ----------------------------- : cortex-a8<br />
| |-- sun4iw1 --------------- wafer1<br />
| | `-- sun4iw1p1 ----- a10<br />
| `-- sun4iw2 --------------- wafer2<br />
| |-- sun4iw2p1 ----- a13<br />
| |-- sun4iw2p2 ----- a12<br />
| `-- sun4iw2p3 ----- a10s<br />
|-- sun8i ----------------------------- : cortex-a7 smp<br />
| |-- sun8iw1 --------------- wafer1<br />
| | |-- sun8iw1p1 ----- a31<br />
| | `-- sun8iw1p2 ----- a31s<br />
| |-- sun8iw2 --------------- wafer2<br />
| | |-- sun8iw2p1 ----- a20<br />
| | `-- sun8iw2p2<br />
| |-- sun8iw3 --------------- wafer3<br />
| | |-- sun8iw3p1 ----- a23<br />
| | `-- sun8iw3p2<br />
| |-- sun8iw5<br />
| | `-- sun8iw5p1 ----- a33<br />
| `-- sun8iw6<br />
| `-- sun8iw6p1<br />
`-- sun9i<br />
`-- sun9iw1<br />
|-- sun9iw1p1 ----- a80<br />
`-- sun9iw1p2</pre><br />
<br />
This new naming scheme is of absolutely no value with respect to the rest of the SoC. The actual ARM core(s) used are usually the least important piece of information for SoC support. This table completely ignores the fact that A20 is an updated A10 and is pin compatible. It also ignores the fact that A31 introduced a lot of changes which were carried on to the A23/A33 and possibly A80 parts. It therefore is quite likely that this naming scheme was purely a marketing decision, and that Allwinner marketing will change its mind again.<br />
<br />
= features =<br />
* CPU: ARMv7-A [http://en.wikipedia.org/wiki/ARM_Cortex-A7 Cortex-A7], [http://en.wikipedia.org/wiki/ARM_Cortex-A15 Cortex-A15] or [http://en.wikipedia.org/wiki/ARM_Cortex-A8 Cortex-A8] Central Processor Unit which have [[NEON]], [[Vector Floating Point Unit|VFP]], [[TrustZone]], and [[Thumb-2]] co-processor extensions: <br />
** Advanced SIMD: [[NEON]] (ARM's extended general-purpose advanced SIMD vector processing extension engine)<br />
** Vector FPU: [[Vector Floating Point Unit]] - ARM VFPv3 lite (Cortex-A8) / VFPv4 (Cortex-A7) VFPU (Vector Floating Point Unit)<br />
** Security Extensions: <br />
*** TrustZone secure world<br />
*** [[Security_System|Security accelerator]] supporting AES, DES, 3DES, SHA-1, MD5 and pseudo-random number generation<br />
** [[Thumb2]] intruction set extension for optimized code to reduce memory footprint and improve performance<br />
* GPU: [[Mali400]], Mali400P2 or SGX544, PowerVR G6230 Graphics Procesor Unit, supporting OpenGL ES2.<br />
* VPU: [[CedarX]] (Video Processor Unit for audio and video hardware decoding or encoding)<br />
* HDMI-transmitter with [[HDMI CEC (Consumer Electronics Control)]], (with exception of A13 which lacks HDMI-transmitter and SATA-controller<ref>[http://olimex.wordpress.com/2012/04/24/cortex-a8-in-tqfp-sure-allwinner-a13/ "Cortex A8 in TQFP? sure Allwinner A13"] ''Retrieved 23 September 2012''</ref>)<br />
* Hardware virtualization capabilities (Cortex-A7 only).<br />
* Up to 4GB memory (Cortex-A8), Up to 1TB memory with LPAE (Cortex-A7 only).<br />
<br />
== Comparison table ==<br />
{| class="wikitable"<br />
|-<br />
! scope="row" | !! [[A10]] !! [[A10s]] !! [[A13]] !! [[A20]] !! [[A23]] !! [[A31]] !! [[A31s]] !! [[A33]] !! [[A80]]<br />
|-<br />
! scope="row" | Generation <br />
| sun4i || sun5i || sun5i || sun7i || sun8i || sun6i || sun?i (A31S)|| sun?i (A33) || sun9i <br />
|-<br />
! scope="row" | CPU<br />
| Cortex-A8 || Cortex-A8 || Cortex-A8 || Cortex-A7 || Cortex-A7 ||Cortex-A7 || Cortex-A7 || Cortex-A7 || Cortex-A7 / A15 <br />
|-<br />
! scope="row" | CPU Maximum frequency<br />
| 1GHz|| 1GHz || 1GHz|| 912MHz|| 1.5Ghz || ?GHz || ?Ghz || ?.?Ghz || 2(??) Ghz<br />
|-<br />
! scope="row" | Cores<br />
| 1 || 1 || 1 || 2 || 2 || 4 || 4 || 4 || 2x4<br />
|-<br />
! scope="row" | Extensions<br />
| NEON, VFPv3, Thumb-2 || NEON, VFPv3, Thumb-2 || NEON, VFPv3, Thumb-2 || NEON, VFPv3 / VFPv4, Thumb-2 ||NEON, VFPv3 / VFPv4, Thumb-2 || NEON, VFPv3 / VFPv4, Thumb-2 || NEON, VFPv3 / VFPv4, Thumb-2 || NEON, VFPv3 / VFPv4, Thumb-2 || ? (A80)<br />
|-<br />
! scope="row" | Memory<br />
| DDR2, DDR3 (max 2GB @ DDR800) || DDR2, DDR3 (max 2GB @ DDR800) || DDR2, DDR3 (max 512MB @ DDR800) || LPDDR3/DDR3/LPDDR2 || DDR3 (max 1GB) || 2-channel DDR3/LPDDR2, 2-channel DDR3L/DDR3U || DDR3/DDR3L/LPDDR2 || ? (A33) || 2-channel DDR3/DDR3L/LPDDR3/LPDDR2, up to 8GB<br />
|-<br />
! scope="row" | GPU<br />
| [[Mali400]] @ 320Mhz || [[Mali400]] @ 320Mhz || [[Mali400]] @ 320Mhz || [[Mali400]] MP2 @ 350Mhz ||Mali400 MP2 || SGX544 @ 200Mhz || SGX544 @ 200Mhz || Mali400 MP2 || 64-core PowerVR G6230<br />
|-<br />
! scope="row" | GPU API<br />
| OpenGL ES 2.0, OpenVG 1.1 || OpenGL ES 2.0, OpenVG 1.1 || OpenGL ES 2.0, OpenVG 1.1 || OpenGL ES 2.0, OpenVG 1.1 || OpenGL ES 2.0, OpenVG 1.1 || OpenGL ES 2.0, OpenVG 1.1, OpenCL 1.1, and DirectX 9.3 || OpenGL ES 2.0, OpenVG 1.1, OpenCL 1.1, and DirectX 9.3 || OpenGL ES 2.0, OpenVG 1.1 || OpenGL 3.x, OpenGL ES Next,3.0,2.0, Open CL 1.x, DirectX 11 level 9_3/10_0<ref>http://www.imgtec.com/news/detail.asp?ID=845</ref><br />
|-<br />
! scope="row" | [[CedarX|Video decoder]]<br />
| 2160P || 1080P || 1080P || 2160p, 4K×2K, 1080p 3D || 1080p@60fps || 2160p, 4K×2K, 1080p 3D || 2160p, 1080p 3D || 1080p@60fps || ? (A80)<br />
|-<br />
! scope="row" | [[CedarX|Video encoder]]<br />
| H.264 1080P@30fps,JPEG || H.264 1080P@30fps,JPEG || H.264 1080P@30fps,JPEG || H.264 1080P@30fps,JPEG || 1080p@60fps || H.264 1080P@60fps,JPEG || H264 1080p@30fps, 720p@60fps || ? (A33) || H.264 HP/VP8 4Kx2K@30fp<br />
|-<br />
! scope="row" | [[CedarX|Audio decoder]]<br />
| AC3,DTS || ?|| ? || AC3,DTS|| - || ? (A31) || ? (A31S) || ? (A33) || ? (A80)<br />
|-<br />
! scope="row" | Video interfaces<br />
| HDMI 1.3, YPbPr, VGA, CPU/RGB/LVDS LCD || HDMI 1.3, RGB/LVDS LCD || RGB LCD, VGA|| HDMI 1.4, CVBS, YPbPr, VGA, CPU/RGB/LVDS LCD || CPU/RGB/LVDS LCD, MIPI DSI || HDMI 1.4, MIPI DSI, 2-channel LVDS, 2-channel RGB LCD || HDMI 1.4, LVDS, RGB LCD || ? (A33) || HDMI 4K , RGB LCD 2048x1536@60fps, dual-channel LVDS 1920x1080@60fps, 4-lane MIPI DSI 1920x1200@60fps, 4-lane eDP 2560x1600@60fps<br />
|-<br />
! scope="row" | Audio interfaces<br />
| I2S, SPDIF, AC97 || I2S, AC97 || I2S, AC97 || I2S, PCM, AC97 || I2S, PCM || 2 I2S, 2 PCM || I2S, 2 PCM || ? (A33) || ? (A80)<br />
|-<br />
! scope="row" | USB OTG<br />
| 1 || 1 || 1 || 1 || 1 || 1 || 1 || ? (A33) || 1<br />
|-<br />
! scope="row" | USB Host<br />
| 2 || 1 || 1 || 2 || 1 || 2 || 2 || ? (A33) || 2x USB Host, USB 3.0/2.0 Dual-Role (host/device)<br />
|-<br />
! scope="row" | Ethernet<br />
| EMAC || EMAC || - || EMAC/GMAC || - || GMAC || ? (A31S) || ? (A33) || GMAC<br />
|-<br />
! scope="row" | Storage<br />
| NAND (max 64GB), SATA II, SD Card 3.0 || NAND (max 64GB), SD Card 3.0 || NAND (max 64GB), SD Card 3.0 || NAND, MMC, [http://olimex.wordpress.com/2013/04/05/allwinners-a10-and-a20-are-they-really-pin-to-pin-compatible-and-drop-in-replacement/#comment-5452 SATA] || raw NAND, eMMC, SD card || 4x SD Card, eMMC NAND, 2-channel raw NAND || 4x SD Card, eMMC NAND, raw NAND || ? (A33) || 4x SD/MMC<br />
|-<br />
! scope="row" | Package<br />
| BGA441 19mm × 19mm, 0.80mm Pitch || BGA336 14mm × 14mm, 0.65mm Pitch || eLQFP176 20mm × 20mm ||BGA441 19mm × 19mm, 0.80mm Pitch || FBGA280 14x14x1.4, 0.80mm pitch || BGA609 18mm × 18mm, 0.65mm Pitch || ? (A31S) || ? (Allwinner: pin compatible with A23) || ? (A80)<br />
|-<br />
! scope="row" | Litography<br />
| 55nm || 55nm|| 55nm || 40nm || 40nm || 40nm || 40nm || 40nm || 28nm<br />
|}<br />
<ref>http://blog.thinkteletronics.com/all-mobile-socsolutions/ All Mobile Soc/Solutions.</ref><br />
<br />
= "F"-Series =<br />
'''NOTE: F series not supported by linux-sunxi community due lack of developers and hardware, sun3i have only offical linux port, sunii have no linux support only aw's melis RTOS'''<br />
<br />
<br />
Based on ARMv6 ARM926-EJS core and currenty targeted for low market devices such as cheap ebook readers, etc.<br />
<br />
* [[C100|Boxchip C100]] <small>(sun3i)</small><br />
* [[E200|Boxchip E200]] <small>(sun3i)</small><br />
* [[F20|Boxchip F20]] <small>(sun3i)</small><br />
* [[F10|Boxchip F10]] aka SoChip SC9800 aka Teclast T8100<small>(sunii)</small><br />
* [[F13|Boxchip F13]] <small>(sunii)</small><br />
* [[F13|Boxchip F15]] aka SoChip SC8600 aka Teclast T7200<small>(sunii)</small><br />
* [[F18|Boxchip F18]] <small>(sunii)</small><br />
<br />
==References==<br />
<references /></div>Rockerhttps://linux-sunxi.org/index.php?title=Allwinner_SoC_Family&diff=12938Allwinner SoC Family2015-01-28T13:21:18Z<p>Rocker: /* "A"-Series */</p>
<hr />
<div>= "A"-Series =<br />
Based on ARMv7 Cortex-A cores (Cortex-A7,A8, and A15) targeted for hi-end devices like digital media player, tablets, and netbooks:<br />
* [[A10|Allwinner A10]] <small>(sun4i)</small> (1 x Cortex-A8 CPU-core)<br />
* [[A13|Allwinner A13]] <small>(sun5i)</small> (1 x Cortex-A8 CPU-core)<br />
* [[A10s|Allwinner A10s]]<small>(sun5i)</small>(1 x Cortex-A8 CPU-core)<br />
* [[A20|Allwinner A20]] <small>(sun7i)</small> (2 x Cortex-A7 CPU-cores)<br />
* [[A23|Allwinner A23]] <small>(sun8i)</small> (2 x Cortex-A7 CPU-cores)<br />
* [[A31|Allwinner A31]] <small>(sun6i)</small> (4 x Cortex-A7 CPU-cores)<br />
* [[A31s|Allwinner A31s]] <small>(sun6i)</small> (4 x Cortex-A7 CPU-cores)<br />
* [[A33|Allwinner A33]] <small>(sun8i)</small> (4 x Cortex-A7 CPU-cores)<br />
* [[A80|Allwinner A80]] <small>(sun9i)</small> (4 x Cortex-A7 CPU-cores + 4 x Cortex-A15 CPU-cores using ARM big.LITTLE heterogeneous CPU architecture)<br />
* [[A83T|Allwinner A83T]] <small>(sun?i)</small> (8 x Cortex-A7 CPU-cores)<br />
<br />
= 2013 naming scheme change =<br />
<br />
Initially, Allwinner named their SoCs chronologically:<br />
* sun4i = A10<br />
* sun5i = A13/A10s<br />
* sun6i = A31<br />
* sun7i = A20<br />
<br />
But, somewhere in 2013, Allwinner decided to update their naming scheme to be based on the ARM core used instead: (taken from the A80 SDK kernel code)<br />
<pre>sunxi<br />
|-- sun4i ----------------------------- : cortex-a8<br />
| |-- sun4iw1 --------------- wafer1<br />
| | `-- sun4iw1p1 ----- a10<br />
| `-- sun4iw2 --------------- wafer2<br />
| |-- sun4iw2p1 ----- a13<br />
| |-- sun4iw2p2 ----- a12<br />
| `-- sun4iw2p3 ----- a10s<br />
|-- sun8i ----------------------------- : cortex-a7 smp<br />
| |-- sun8iw1 --------------- wafer1<br />
| | |-- sun8iw1p1 ----- a31<br />
| | `-- sun8iw1p2 ----- a31s<br />
| |-- sun8iw2 --------------- wafer2<br />
| | |-- sun8iw2p1 ----- a20<br />
| | `-- sun8iw2p2<br />
| |-- sun8iw3 --------------- wafer3<br />
| | |-- sun8iw3p1 ----- a23<br />
| | `-- sun8iw3p2<br />
| |-- sun8iw5<br />
| | `-- sun8iw5p1 ----- a33<br />
| `-- sun8iw6<br />
| `-- sun8iw6p1<br />
`-- sun9i<br />
`-- sun9iw1<br />
|-- sun9iw1p1 ----- a80<br />
`-- sun9iw1p2</pre><br />
<br />
This new naming scheme is of absolutely no value with respect to the rest of the SoC. The actual ARM core(s) used are usually the least important piece of information for SoC support. This table completely ignores the fact that A20 is an updated A10 and is pin compatible. It also ignores the fact that A31 introduced a lot of changes which were carried on to the A23/A33 and possibly A80 parts. It therefore is quite likely that this naming scheme was purely a marketing decision, and that Allwinner marketing will change its mind again.<br />
<br />
= features =<br />
* CPU: ARMv7-A [http://en.wikipedia.org/wiki/ARM_Cortex-A7 Cortex-A7], [http://en.wikipedia.org/wiki/ARM_Cortex-A15 Cortex-A15] or [http://en.wikipedia.org/wiki/ARM_Cortex-A8 Cortex-A8] Central Processor Unit which have [[NEON]], [[Vector Floating Point Unit|VFP]], [[TrustZone]], and [[Thumb-2]] co-processor extensions: <br />
** Advanced SIMD: [[NEON]] (ARM's extended general-purpose advanced SIMD vector processing extension engine)<br />
** Vector FPU: [[Vector Floating Point Unit]] - ARM VFPv3 lite (Cortex-A8) / VFPv4 (Cortex-A7) VFPU (Vector Floating Point Unit)<br />
** Security Extensions: <br />
*** TrustZone secure world<br />
*** [[Security_System|Security accelerator]] supporting AES, DES, 3DES, SHA-1, MD5 and pseudo-random number generation<br />
** [[Thumb2]] intruction set extension for optimized code to reduce memory footprint and improve performance<br />
* GPU: [[Mali400]], Mali400P2 or SGX544, PowerVR G6230 Graphics Procesor Unit, supporting OpenGL ES2.<br />
* VPU: [[CedarX]] (Video Processor Unit for audio and video hardware decoding or encoding)<br />
* HDMI-transmitter with [[HDMI CEC (Consumer Electronics Control)]], (with exception of A13 which lacks HDMI-transmitter and SATA-controller<ref>[http://olimex.wordpress.com/2012/04/24/cortex-a8-in-tqfp-sure-allwinner-a13/ "Cortex A8 in TQFP? sure Allwinner A13"] ''Retrieved 23 September 2012''</ref>)<br />
* Hardware virtualization capabilities (Cortex-A7 only).<br />
* Up to 4GB memory (Cortex-A8), Up to 1TB memory with LPAE (Cortex-A7 only).<br />
<br />
== Comparison table ==<br />
{| class="wikitable"<br />
|-<br />
! scope="row" | !! [[A10]] !! [[A10s]] !! [[A13]] !! [[A20]] !! [[A23]] !! [[A31]] !! [[A31s]] !! [[A33]] !! [[A80]]<br />
|-<br />
! scope="row" | Generation <br />
| sun4i || sun5i || sun5i || sun7i || sun8i || sun6i || sun?i (A31S)|| sun?i (A33) || sun9i <br />
|-<br />
! scope="row" | CPU<br />
| Cortex-A8 || Cortex-A8 || Cortex-A8 || Cortex-A7 || Cortex-A7 ||Cortex-A7 || Cortex-A7 || Cortex-A7 || Cortex-A7 / A15 <br />
|-<br />
! scope="row" | CPU Maximum frequency<br />
| 1GHz|| 1GHz || 1GHz|| 912MHz|| 1.5Ghz || ?GHz || ?Ghz || ?.?Ghz || 2(??) Ghz<br />
|-<br />
! scope="row" | Cores<br />
| 1 || 1 || 1 || 2 || 2 || 4 || 4 || 4 || 2x4<br />
|-<br />
! scope="row" | Extensions<br />
| NEON, VFPv3, Thumb-2 || NEON, VFPv3, Thumb-2 || NEON, VFPv3, Thumb-2 || NEON, VFPv3 / VFPv4, Thumb-2 ||NEON, VFPv3 / VFPv4, Thumb-2 || NEON, VFPv3 / VFPv4, Thumb-2 || NEON, VFPv3 / VFPv4, Thumb-2 || NEON, VFPv3 / VFPv4, Thumb-2 || ? (A80)<br />
|-<br />
! scope="row" | Memory<br />
| DDR2, DDR3 (max 2GB @ DDR800) || DDR2, DDR3 (max 2GB @ DDR800) || DDR2, DDR3 (max 512MB @ DDR800) || LPDDR3/DDR3/LPDDR2 || DDR3 (max 1GB) || 2-channel DDR3/LPDDR2, 2-channel DDR3L/DDR3U || DDR3/DDR3L/LPDDR2 || ? (A33) || 2-channel DDR3/DDR3L/LPDDR3/LPDDR2, up to 8GB<br />
|-<br />
! scope="row" | GPU<br />
| [[Mali400]] @ 320Mhz || [[Mali400]] @ 320Mhz || [[Mali400]] @ 320Mhz || [[Mali400]] MP2 @ 350Mhz ||Mali400 MP2 || SGX544 @ 200Mhz || SGX544 @ 200Mhz || Mali400 MP2 || 64-core PowerVR G6230<br />
|-<br />
! scope="row" | GPU API<br />
| OpenGL ES 2.0, OpenVG 1.1 || OpenGL ES 2.0, OpenVG 1.1 || OpenGL ES 2.0, OpenVG 1.1 || OpenGL ES 2.0, OpenVG 1.1 || OpenGL ES 2.0, OpenVG 1.1 || OpenGL ES 2.0, OpenVG 1.1, OpenCL 1.1, and DirectX 9.3 || OpenGL ES 2.0, OpenVG 1.1, OpenCL 1.1, and DirectX 9.3 || OpenGL ES 2.0, OpenVG 1.1 || OpenGL 3.x, OpenGL ES Next,3.0,2.0, Open CL 1.x, DirectX 11 level 9_3/10_0<ref>http://www.imgtec.com/news/detail.asp?ID=845</ref><br />
|-<br />
! scope="row" | [[CedarX|Video decoder]]<br />
| 2160P || 1080P || 1080P || 2160p, 4K×2K, 1080p 3D || 1080p@60fps || 2160p, 4K×2K, 1080p 3D || 2160p, 1080p 3D || 1080p@60fps || ? (A80)<br />
|-<br />
! scope="row" | [[CedarX|Video encoder]]<br />
| H.264 1080P@30fps,JPEG || H.264 1080P@30fps,JPEG || H.264 1080P@30fps,JPEG || H.264 1080P@30fps,JPEG || 1080p@60fps || H.264 1080P@60fps,JPEG || H264 1080p@30fps, 720p@60fps || ? (A33) || H.264 HP/VP8 4Kx2K@30fp<br />
|-<br />
! scope="row" | [[CedarX|Audio decoder]]<br />
| AC3,DTS || ?|| ? || AC3,DTS|| - || ? (A31) || ? (A31S) || ? (A33) || ? (A80)<br />
|-<br />
! scope="row" | Video interfaces<br />
| HDMI 1.3, YPbPr, VGA, CPU/RGB/LVDS LCD || HDMI 1.3, RGB/LVDS LCD || RGB LCD, VGA|| HDMI 1.4, CVBS, YPbPr, VGA, CPU/RGB/LVDS LCD || CPU/RGB/LVDS LCD, MIPI DSI || HDMI 1.4, MIPI DSI, 2-channel LVDS, 2-channel RGB LCD || HDMI 1.4, LVDS, RGB LCD || ? (A33) || HDMI 4K , RGB LCD 2048x1536@60fps, dual-channel LVDS 1920x1080@60fps, 4-lane MIPI DSI 1920x1200@60fps, 4-lane eDP 2560x1600@60fps<br />
|-<br />
! scope="row" | Audio interfaces<br />
| I2S, SPDIF, AC97 || I2S, AC97 || I2S, AC97 || I2S, PCM, AC97 || I2S, PCM || 2 I2S, 2 PCM || I2S, 2 PCM || ? (A33) || ? (A80)<br />
|-<br />
! scope="row" | USB OTG<br />
| 1 || 1 || 1 || 1 || 1 || 1 || 1 || ? (A33) || 1<br />
|-<br />
! scope="row" | USB Host<br />
| 2 || 1 || 1 || 2 || 1 || 2 || 2 || ? (A33) || 2x USB Host, USB 3.0/2.0 Dual-Role (host/device)<br />
|-<br />
! scope="row" | Ethernet<br />
| EMAC || EMAC || - || EMAC/GMAC || - || GMAC || ? (A31S) || ? (A33) || GMAC<br />
|-<br />
! scope="row" | Storage<br />
| NAND (max 64GB), SATA II, SD Card 3.0 || NAND (max 64GB), SD Card 3.0 || NAND (max 64GB), SD Card 3.0 || NAND, MMC, [http://olimex.wordpress.com/2013/04/05/allwinners-a10-and-a20-are-they-really-pin-to-pin-compatible-and-drop-in-replacement/#comment-5452 SATA] || raw NAND, eMMC, SD card || 4x SD Card, eMMC NAND, 2-channel raw NAND || 4x SD Card, eMMC NAND, raw NAND || ? (A33) || 4x SD/MMC<br />
|-<br />
! scope="row" | Package<br />
| BGA441 19mm × 19mm, 0.80mm Pitch || BGA336 14mm × 14mm, 0.65mm Pitch || eLQFP176 20mm × 20mm ||BGA441 19mm × 19mm, 0.80mm Pitch || FBGA280 14x14x1.4, 0.80mm pitch || BGA609 18mm × 18mm, 0.65mm Pitch || ? (A31S) || ? (Allwinner: pin compatible with A23) || ? (A80)<br />
|-<br />
! scope="row" | Litography<br />
| 55nm || 55nm|| 55nm || 40nm || 40nm || 40nm || 40nm || 40nm || 28nm<br />
|}<br />
<ref>http://blog.thinkteletronics.com/all-mobile-socsolutions/ All Mobile Soc/Solutions.</ref><br />
<br />
= "F"-Series =<br />
'''NOTE: F series not supported by linux-sunxi community due lack of developers and hardware, sun3i have only offical linux port, sunii have no linux support only aw's melis RTOS'''<br />
<br />
<br />
Based on ARMv6 ARM926-EJS core and currenty targeted for low market devices such as cheap ebook readers, etc.<br />
<br />
* [[C100|Boxchip C100]] <small>(sun3i)</small><br />
* [[E200|Boxchip E200]] <small>(sun3i)</small><br />
* [[F20|Boxchip F20]] <small>(sun3i)</small><br />
* [[F10|Boxchip F10]] aka SoChip SC9800 aka Teclast T8100<small>(sunii)</small><br />
* [[F13|Boxchip F13]] <small>(sunii)</small><br />
* [[F13|Boxchip F15]] aka SoChip SC8600 aka Teclast T7200<small>(sunii)</small><br />
* [[F18|Boxchip F18]] <small>(sunii)</small><br />
<br />
==References==<br />
<references /></div>Rockerhttps://linux-sunxi.org/index.php?title=GPL_Violations&diff=12937GPL Violations2015-01-28T13:15:49Z<p>Rocker: </p>
<hr />
<div>[[Allwinner]] has repeatedly violated the GPL, (and by proxy so are most hardware manufacturers and resellers using or selling products based on [[Allwinner]] chipsets). Either by not providing (Linux/Android) kernel or u-boot source at all, or by delivering trees with pre-built binaries and no matching source code. They even blatantly use LGPLed license code in their userspace libraries for media decoding.<br />
<br />
Over time, Allwinner has only increased the binary blobs present in their kernel trees, showing clearly that, even though Allwinner in the meantime joined Linaro, it is not progressing. Quite the opposite actually, and one has to worry about what value Linaro membership really has if a member is allowed to behave like this.<br />
<br />
= In the linux kernel =<br />
<br />
Inclusion of binaries in the kernel source tree are a clear and obvious violation of the license of the linux kernel (GPL).<br />
<br />
== NAND support ==<br />
<br />
libnand is Allwinners own implementation of a block device on top of a raw NAND flash controller.<br />
<br />
We have a very old source tree for this, but all newer versions have only been included as binaries in both kernel and u-boot SDK trees.<br />
<br />
GPL violations in:<br />
* [[A20#GPL_Violations |A20 SDK]]<br />
* [[A31#GPL_Violations |A31/A31s SDK]]<br />
* [[A23#GPL_violations |A23 SDK]]<br />
* [[A80#GPL_violations |A80 SDK]]<br />
<br />
== USB3.0 ==<br />
<br />
libusb300 provides USB3.0 support for the Allwinner A80. This crucial kernel code is of course another GPL violation.<br />
<br />
GPL violations in:<br />
* [[A80#GPL_violations |A80 SDK]]<br />
<br />
== Display support ==<br />
<br />
Both DSI and eDP support for A80 are binary blobs, and hdcp support for HDMI is a binary as well.<br />
<br />
GPL violations in:<br />
* [[A80#GPL_violations |A80 SDK]]<br />
<br />
== DRAM frequency scaling code ==<br />
<br />
Two binary blobs are provided here as well.<br />
<br />
GPL violations in:<br />
* [[A23#GPL_violations |A23 SDK]]<br />
* [[A80#GPL_violations |A80 SDK]]<br />
<br />
== Camera support ==<br />
<br />
=== libisp ===<br />
libisp is a driver for the Image signal processor (HawkView ISP), used for camera picture preprocessing and image enhancement.<br />
<br />
GPL violations in:<br />
* [[A31#GPL_Violations |A31/A31s SDK]]<br />
* [[A23#GPL_violations |A23 SDK]]<br />
* [[A80#GPL_violations |A80 SDK]]<br />
<br />
=== Other camera code ===<br />
<br />
For A80, [[A80#GPL_violations|allwinner introduced 3 further blobs]], 2 for MIPICSI, and one for a "Face detector."<br />
<br />
GPL violations in:<br />
* [[A80#GPL_violations |A80 SDK]]<br />
<br />
== Touchscreen support ==<br />
<br />
Some binary blobs for touchscreen drivers are present in several SDKs.<br />
<br />
GPL violations in:<br />
* [[A31#GPL_Violations |A31/A31a SDK]]<br />
* [[A23#GPL_violations |A23 SDK]]<br />
* [[A80#GPL_violations |A80 SDK]]<br />
<br />
= U-boot =<br />
<br />
Inclusion of binaries in the u-boot source tree are a clear and obvious violation of the license of u-boot (GPL).<br />
<br />
Allwinner published the [https://github.com/allwinner-zh/bootloader u-boot source dump] on Github on 2015.01.15.<br />
== DRAM support ==<br />
<br />
Allwinner's [https://github.com/allwinner-zh/bootloader u-boot repository] contains libdram implementation only in binary form:<br />
* [https://github.com/allwinner-zh/bootloader/blob/master/u-boot-2011.09/arch/arm/cpu/armv7/sun8iw8/dram/libdram arch/arm/cpu/armv7/sun8iw8/dram/libdram]<br />
* [https://github.com/allwinner-zh/bootloader/blob/master/u-boot-2011.09/arch/arm/cpu/armv7/sun8iw7/dram/libdram arch/arm/cpu/armv7/sun8iw7/dram/libdram]<br />
* [https://github.com/allwinner-zh/bootloader/blob/master/u-boot-2011.09/arch/arm/cpu/armv7/sun8iw6/dram/libdram arch/arm/cpu/armv7/sun8iw6/dram/libdram-pad]<br />
* [https://github.com/allwinner-zh/bootloader/blob/master/u-boot-2011.09/arch/arm/cpu/armv7/sun8iw6/dram/libdram arch/arm/cpu/armv7/sun8iw6/dram/libdram-homlet]<br />
* [https://github.com/allwinner-zh/bootloader/blob/master/u-boot-2011.09/arch/arm/cpu/armv7/sun8iw5/dram/libdram arch/arm/cpu/armv7/sun8iw5/dram/libdram]<br />
* [https://github.com/allwinner-zh/bootloader/blob/master/u-boot-2011.09/arch/arm/cpu/armv7/sun9iw1/dram/libdram arch/arm/cpu/armv7/sun9iw1/dram/libdram]<br />
<br />
== NAND support ==<br />
<br />
libnand is Allwinners own implementation of a block device on top of a raw NAND flash controller.<br />
<br />
We have a very old source tree for this, but all newer versions have only been included as binaries in both kernel and u-boot SDK trees.<br />
<br />
GPL violations in:<br />
* [[A20#GPL_Violations |A20 SDK]]<br />
* [[A31#GPL_Violations |A31/A31a SDK]]<br />
* [[A23#GPL_violations |A23 SDK]]<br />
* [[A80#GPL_violations |A80 SDK]]<br />
<br />
== Other u-boot issues ==<br />
<br />
* drivers/video_sunxi/sunxi_v2/de_bsp/hdmi/aw/libhdcp<br />
* board/sunxi/sun8iw7/box_standby/cpus_pm/cpus_pm_binary.code<br />
* board/sunxi/sun8iw6/box_standby/cpus_pm/cpus_pm_binary.code<br />
* tools/gen_check_sum<br />
<br />
= CedarX =<br />
<br />
This is the userspace library that implements media decoding (JPEG, MPEG2/4, h264, VC1, VP6/8, ...). This driver is [[CedarX_binary_analysis |a mix and match of many bits]], including some reference decoders, surrounded by allwinner and hw specific code. But, crucially, several parts of it have been taken straight from libavcodec from the FFMPEG project. This code is LGPL, but since this code has been adapted and included, CedarX is not a dependency and the LGPL applies to the whole library, forcing Allwinner to release the lot.<br />
<br />
Also, [[CedarXPlayerTest]] has staticly linked in ffmpeg demuxer.</div>Rockerhttps://linux-sunxi.org/index.php?title=GPL_Violations&diff=12936GPL Violations2015-01-28T13:13:30Z<p>Rocker: </p>
<hr />
<div>[[Allwinner]] has repeatedly violated the GPL, (and by proxy so are most hardware manufacturers and resellers using or selling products based on [[Allwinner]] chipsets). Either by not providing (Linux/Android) kernel or u-boot source at all, or by delivering trees with pre-built binaries and no matching source code. They even blatantly use LGPLed license code in their userspace libraries for media decoding.<br />
<br />
Over time, Allwinner has only increased the binary blobs present in their kernel trees, showing clearly that, even though Allwinner in the meantime joined Linaro, it is not progressing. Quite the opposite actually, and one has to worry about what value Linaro membership really has if a member is allowed to behave like this.<br />
<br />
= In the linux kernel =<br />
<br />
Inclusion of binaries in the kernel source tree are a clear and obvious violation of the license of the linux kernel (GPL).<br />
<br />
== NAND support ==<br />
<br />
libnand is Allwinners own implementation of a block device on top of a raw NAND flash controller.<br />
<br />
We have a very old source tree for this, but all newer versions have only been included as binaries in both kernel and u-boot SDK trees.<br />
<br />
GPL violations in:<br />
* [[A20#GPL_Violations |A20 SDK]]<br />
* [[A31#GPL_Violations |A31/A31s SDK]]<br />
* [[A23#GPL_violations |A23 SDK]]<br />
* [[A80#GPL_violations |A80 SDK]]<br />
<br />
== USB3.0 ==<br />
<br />
libusb300 provides USB3.0 support for the Allwinner A80. This crucial kernel code is of course another GPL violation.<br />
<br />
GPL violations in:<br />
* [[A80#GPL_violations |A80 SDK]]<br />
<br />
== Display support ==<br />
<br />
Both DSI and eDP support for A80 are binary blobs, and hdcp support for HDMI is a binary as well.<br />
<br />
GPL violations in:<br />
* [[A80#GPL_violations |A80 SDK]]<br />
<br />
== DRAM frequency scaling code ==<br />
<br />
Two binary blobs are provided here as well.<br />
<br />
GPL violations in:<br />
* [[A23#GPL_violations |A23 SDK]]<br />
* [[A80#GPL_violations |A80 SDK]]<br />
<br />
== Camera support ==<br />
<br />
=== libisp ===<br />
libisp is a driver for the Image signal processor (HawkView ISP), used for camera picture preprocessing and image enhancement.<br />
<br />
GPL violations in:<br />
* [[A31#GPL_Violations |A31 SDK]]<br />
* [[A23#GPL_violations |A23 SDK]]<br />
* [[A80#GPL_violations |A80 SDK]]<br />
<br />
=== Other camera code ===<br />
<br />
For A80, [[A80#GPL_violations|allwinner introduced 3 further blobs]], 2 for MIPICSI, and one for a "Face detector."<br />
<br />
GPL violations in:<br />
* [[A80#GPL_violations |A80 SDK]]<br />
<br />
== Touchscreen support ==<br />
<br />
Some binary blobs for touchscreen drivers are present in several SDKs.<br />
<br />
GPL violations in:<br />
* [[A31#GPL_Violations |A31 SDK]]<br />
* [[A23#GPL_violations |A23 SDK]]<br />
* [[A80#GPL_violations |A80 SDK]]<br />
<br />
= U-boot =<br />
<br />
Inclusion of binaries in the u-boot source tree are a clear and obvious violation of the license of u-boot (GPL).<br />
<br />
Allwinner published the [https://github.com/allwinner-zh/bootloader u-boot source dump] on Github on 2015.01.15.<br />
== DRAM support ==<br />
<br />
Allwinner's [https://github.com/allwinner-zh/bootloader u-boot repository] contains libdram implementation only in binary form:<br />
* [https://github.com/allwinner-zh/bootloader/blob/master/u-boot-2011.09/arch/arm/cpu/armv7/sun8iw8/dram/libdram arch/arm/cpu/armv7/sun8iw8/dram/libdram]<br />
* [https://github.com/allwinner-zh/bootloader/blob/master/u-boot-2011.09/arch/arm/cpu/armv7/sun8iw7/dram/libdram arch/arm/cpu/armv7/sun8iw7/dram/libdram]<br />
* [https://github.com/allwinner-zh/bootloader/blob/master/u-boot-2011.09/arch/arm/cpu/armv7/sun8iw6/dram/libdram arch/arm/cpu/armv7/sun8iw6/dram/libdram-pad]<br />
* [https://github.com/allwinner-zh/bootloader/blob/master/u-boot-2011.09/arch/arm/cpu/armv7/sun8iw6/dram/libdram arch/arm/cpu/armv7/sun8iw6/dram/libdram-homlet]<br />
* [https://github.com/allwinner-zh/bootloader/blob/master/u-boot-2011.09/arch/arm/cpu/armv7/sun8iw5/dram/libdram arch/arm/cpu/armv7/sun8iw5/dram/libdram]<br />
* [https://github.com/allwinner-zh/bootloader/blob/master/u-boot-2011.09/arch/arm/cpu/armv7/sun9iw1/dram/libdram arch/arm/cpu/armv7/sun9iw1/dram/libdram]<br />
<br />
== NAND support ==<br />
<br />
libnand is Allwinners own implementation of a block device on top of a raw NAND flash controller.<br />
<br />
We have a very old source tree for this, but all newer versions have only been included as binaries in both kernel and u-boot SDK trees.<br />
<br />
GPL violations in:<br />
* [[A20#GPL_Violations |A20 SDK]]<br />
* [[A31#GPL_Violations |A31 SDK]]<br />
* [[A23#GPL_violations |A23 SDK]]<br />
* [[A80#GPL_violations |A80 SDK]]<br />
<br />
== Other u-boot issues ==<br />
<br />
* drivers/video_sunxi/sunxi_v2/de_bsp/hdmi/aw/libhdcp<br />
* board/sunxi/sun8iw7/box_standby/cpus_pm/cpus_pm_binary.code<br />
* board/sunxi/sun8iw6/box_standby/cpus_pm/cpus_pm_binary.code<br />
* tools/gen_check_sum<br />
<br />
= CedarX =<br />
<br />
This is the userspace library that implements media decoding (JPEG, MPEG2/4, h264, VC1, VP6/8, ...). This driver is [[CedarX_binary_analysis |a mix and match of many bits]], including some reference decoders, surrounded by allwinner and hw specific code. But, crucially, several parts of it have been taken straight from libavcodec from the FFMPEG project. This code is LGPL, but since this code has been adapted and included, CedarX is not a dependency and the LGPL applies to the whole library, forcing Allwinner to release the lot.<br />
<br />
Also, [[CedarXPlayerTest]] has staticly linked in ffmpeg demuxer.</div>Rockerhttps://linux-sunxi.org/index.php?title=GPL_Violations&diff=12935GPL Violations2015-01-28T12:50:15Z<p>Rocker: </p>
<hr />
<div>[[Allwinner]] has repeatedly violated the GPL, (and by proxy so are most hardware manufacturers and resellers using or selling products based on [[Allwinner]] chipsets). Either by not providing (Linux/Android) kernel or u-boot source at all, or by delivering trees with pre-built binaries and no matching source code. They even blatantly use LGPLed license code in their userspace libraries for media decoding.<br />
<br />
Over time, Allwinner has only increased the binary blobs present in their kernel trees, showing clearly that, even though Allwinner in the meantime joined Linaro, it is not progressing. Quite the opposite actually, and one has to worry about what value Linaro membership really has if a member is allowed to behave like this.<br />
<br />
= In the linux kernel =<br />
<br />
Inclusion of binaries in the kernel source tree are a clear and obvious violation of the license of the linux kernel (GPL).<br />
<br />
== NAND support ==<br />
<br />
libnand is Allwinners own implementation of a block device on top of a raw NAND flash controller.<br />
<br />
We have a very old source tree for this, but all newer versions have only been included as binaries in both kernel and u-boot SDK trees.<br />
<br />
GPL violations in:<br />
* [[A20#GPL_Violations |A20 SDK]]<br />
* [[A31#GPL_Violations |A31 SDK]]<br />
* [[A23#GPL_violations |A23 SDK]]<br />
* [[A80#GPL_violations |A80 SDK]]<br />
<br />
== USB3.0 ==<br />
<br />
libusb300 provides USB3.0 support for the Allwinner A80. This crucial kernel code is of course another GPL violation.<br />
<br />
GPL violations in:<br />
* [[A80#GPL_violations |A80 SDK]]<br />
<br />
== Display support ==<br />
<br />
Both DSI and eDP support for A80 are binary blobs, and hdcp support for HDMI is a binary as well.<br />
<br />
GPL violations in:<br />
* [[A80#GPL_violations |A80 SDK]]<br />
<br />
== DRAM frequency scaling code ==<br />
<br />
Two binary blobs are provided here as well.<br />
<br />
GPL violations in:<br />
* [[A23#GPL_violations |A23 SDK]]<br />
* [[A80#GPL_violations |A80 SDK]]<br />
<br />
== Camera support ==<br />
<br />
=== libisp ===<br />
libisp is a driver for the Image signal processor (HawkView ISP), used for camera picture preprocessing and image enhancement.<br />
<br />
GPL violations in:<br />
* [[A31#GPL_Violations |A31 SDK]]<br />
* [[A23#GPL_violations |A23 SDK]]<br />
* [[A80#GPL_violations |A80 SDK]]<br />
<br />
=== Other camera code ===<br />
<br />
For A80, [[A80#GPL_violations|allwinner introduced 3 further blobs]], 2 for MIPICSI, and one for a "Face detector."<br />
<br />
GPL violations in:<br />
* [[A80#GPL_violations |A80 SDK]]<br />
<br />
== Touchscreen support ==<br />
<br />
Some binary blobs for touchscreen drivers are present in several SDKs.<br />
<br />
GPL violations in:<br />
* [[A31#GPL_Violations |A31 SDK]]<br />
* [[A23#GPL_violations |A23 SDK]]<br />
* [[A80#GPL_violations |A80 SDK]]<br />
<br />
= U-boot =<br />
<br />
Inclusion of binaries in the u-boot source tree are a clear and obvious violation of the license of u-boot (GPL).<br />
<br />
Allwinner published the [https://github.com/allwinner-zh/bootloader u-boot source dump] on Github on 2015.01.15.<br />
== DRAM support ==<br />
<br />
Allwinner's [https://github.com/allwinner-zh/bootloader u-boot repository] contains libdram implementation only in binary form:<br />
* [https://github.com/allwinner-zh/bootloader/blob/master/u-boot-2011.09/arch/arm/cpu/armv7/sun8iw8/dram/libdram arch/arm/cpu/armv7/sun8iw8/dram/libdram]<br />
* [https://github.com/allwinner-zh/bootloader/blob/master/u-boot-2011.09/arch/arm/cpu/armv7/sun8iw7/dram/libdram arch/arm/cpu/armv7/sun8iw7/dram/libdram]<br />
* [https://github.com/allwinner-zh/bootloader/blob/master/u-boot-2011.09/arch/arm/cpu/armv7/sun8iw6/dram/libdram arch/arm/cpu/armv7/sun8iw6/dram/libdram-pad]<br />
* [https://github.com/allwinner-zh/bootloader/blob/master/u-boot-2011.09/arch/arm/cpu/armv7/sun8iw6/dram/libdram arch/arm/cpu/armv7/sun8iw6/dram/libdram-homlet]<br />
* [https://github.com/allwinner-zh/bootloader/blob/master/u-boot-2011.09/arch/arm/cpu/armv7/sun8iw5/dram/libdram arch/arm/cpu/armv7/sun8iw5/dram/libdram]<br />
* [https://github.com/allwinner-zh/bootloader/blob/master/u-boot-2011.09/arch/arm/cpu/armv7/sun9iw1/dram/libdram arch/arm/cpu/armv7/sun9iw1/dram/libdram]<br />
<br />
== NAND support ==<br />
<br />
libnand is Allwinners own implementation of a block device on top of a raw NAND flash controller.<br />
<br />
We have a very old source tree for this, but all newer versions have only been included as binaries in both kernel and u-boot SDK trees.<br />
<br />
GPL violations in:<br />
* [[A20#GPL_Violations |A20 SDK]]<br />
* [[A31#GPL_Violations |A31 SDK]]<br />
* [[A23#GPL_violations |A23 SDK]]<br />
* [[A80#GPL_violations |A80 SDK]]<br />
<br />
== Other u-boot issues ==<br />
<br />
* drivers/video_sunxi/sunxi_v2/de_bsp/hdmi/aw/libhdcp<br />
* board/sunxi/sun8iw7/box_standby/cpus_pm/cpus_pm_binary.code<br />
* board/sunxi/sun8iw6/box_standby/cpus_pm/cpus_pm_binary.code<br />
* tools/gen_check_sum<br />
<br />
= CedarX =<br />
<br />
This is the userspace library that implements media decoding (JPEG, MPEG2/4, h264, VC1, VP6/8, ...). This driver is [[CedarX_binary_analysis |a mix and match of many bits]], including some reference decoders, surrounded by allwinner and hw specific code. But, crucially, several parts of it have been taken straight from libavcodec from the FFMPEG project. This code is LGPL, but since this code has been adapted and included, CedarX is not a dependency and the LGPL applies to the whole library, forcing Allwinner to release the lot.<br />
<br />
Also, [[CedarXPlayerTest]] has staticly linked in ffmpeg demuxer.</div>Rockerhttps://linux-sunxi.org/index.php?title=CedarX/XBMC&diff=10092CedarX/XBMC2014-07-30T15:27:39Z<p>Rocker: /* Building XBMC for A10 and A20 */</p>
<hr />
<div><div style="color:#6F0000; border: 3px dashed #BF4F4F; padding: 2em;"><big><br />
'''XBMC for linux on Allwinner devices is NOT READY FOR USE!'''<br />
<br />
This is only a hack intended for developers and curious users at the moment. Don't expect it to work as you want it! Hardware is capable to make it run quite good in the future, but software and drivers are not ready yet. The [[:Category:Community|sunxi-community]] is working towards making a smooth XBMC experience possible.<br />
<br />
If you want to help developing the needed components to have a stable XBMC in the future, join the [[:Category:Community|irc and mailing list]]. Developers wanted!</big></div><br />
<br/><br />
<br />
XBMC is a popular media center software with 10-foot interface designed for large-screen televisions, and it enables ARM-based media players and set-top boxes like those with Allwinner SoCs with [[CedarX]] VPU (Video Processor Unit) to hardware decode and play high-definition videos, music, and other digital media files from local and network storage media, as well as stream podcasts, videocasts, and such of the internet.<br />
<br />
This article contain instructions on compiling and developing XBMC on and for Allwinner SoCs that features the [[CedarX]] VPU, like [[A10]], [[A10s]], [[A13]], [[A20]], and [[A23]]. Note that these instructions are specifically only meant for developers and advanced or expert Linux users that can actively assist with the porting process.<br />
<br />
=Overview=<br />
XBMC has already have an initial port for the A10 / A20 SoC with [[CedarX]] hardware accelerated video decoding, this experimental third-party port and the code patches have however not yet made it upstream into mainline XBMC.<ref>http://www.j1nx.nl/buildroot-xbmc-on-mele-a1000-allwinner-a10/ Buildroot XBMC on the Mele A1000 (Allwinner A10)</ref><ref>http://www.cnx-software.com/2012/11/12/xbmc-for-linux-on-allwinner-a10-devices-it-works-sort-of/ XBMC for Linux on AllWinner A10 Devices? It Works! (Sort of)</ref><br />
<br />
Pre-built application binaries of this port are not available so therefore you will need to compile XBMC yourself, at least until if and when the code makes it into the mainline XBMC upstream at http://xbmc.org<br />
<br />
Team-XBMC, the official development team of XBMC, does currently not recommend that any end-user buy Allwinner A10 or A20 based hardware for the specific purpose of only running XBMC since they do not have the resources to support this platform as of yet.<br />
<br />
More information about XBMC can be found on wikipedia http://en.wikipedia.org/wiki/XBMC and the XBMC wiki http://wiki.xbmc.org or http://forum.xbmc.org<br />
<br />
= Building XBMC for A10 and A20 SoC series=<br />
This is a little how-to of steps to compile XBMC for devices using Allwinner A10 and A20 SoC series (e.g. for hardware like Mele A1000, Cubieboard, and Banana Pi) based on Empat0's GitHub sources [http://github.com/empatzero/xbmca10 http://github.com/empatzero/xbmca10].<br />
The development work on the coding side was all done by Empat0 (a.k.a. empat zero). The used repository in the example below is however from [http://github.com/rellla/xbmca10 http://github.com/rellla/xbmca10] which is currently the newest and contains a few adaptions. It is a fork of empat0's work. <br />
<br />
The result should be a Debian armhf system with XBMC using [[CedarX]] for hardware accelerated video decoding.<br />
<br />
This version of XBMC runs directly on the framebuffer, and thus XServer is therefor not needed!<br />
<br />
== Prerequisites ==<br />
There are more ways to prepare a working rootfs for XBMC. You can either prepare the sdcard directly as described or you can chroot into the rootfs on your host system and sync it with your sdcard later when you have finished.<br />
So the following steps can also be done in a chroot on your host if you are cross-compiling.<br />
<br />
=== Prepare your SD-Card ===<br />
Create a bootable SD-Card follwing [[Manual_build_howto| our manual build howto]] and Debian. Be sure to use a kernel with mali-drivers-version r3p0 (sunxi-3.0 should be good).<br />
<br />
=== Boot into your target system ===<br />
Boot the new debian from the sd-card directly on the target and bring the system up to date:<br />
root@mele:~/# apt-get update<br />
root@mele:~/# apt-get upgrade<br />
<br />
=== Install the dependencies for XBMC (needs update!) ===<br />
root@mele:~/# apt-get build-dep xbmc<br />
<br />
this should install the following packages:<br />
autoconf automake autopoint autotools-dev binutils bsdmainutils build-essential bzip2 cmake cmake-data comerr-dev cpp cpp-4.4 cpp-4.6 curl<br />
debhelper dpkg-dev emacsen-common fontconfig-config g++ g++-4.4 g++-4.6 gawk gcc gcc-4.4 gcc-4.4-base gcc-4.6 gcc-4.6-base gettext<br />
gettext-base git git-man gperf groff-base html2text intltool-debian krb5-multidev libao-common libao-dev libao4 libarchive12 libasound2<br />
libasound2-dev libasprintf0c2 libass-dev libass4 libasyncns0 libavahi-client-dev libavahi-client3 libavahi-common-data libavahi-common-dev<br />
libavahi-common3 libavcodec-dev libavcodec53 libavfilter-dev libavfilter2 libavformat-dev libavformat53 libavutil-dev libavutil51<br />
libbluetooth-dev libbluetooth3 libbluray-dev libbluray1 libboost-date-time1.49-dev libboost-date-time1.49.0 libboost-dev<br />
libboost-serialization1.49-dev libboost-serialization1.49.0 libboost-thread-dev libboost-thread1.49-dev libboost-thread1.49.0<br />
libboost1.49-dev libbz2-dev libc-dev-bin libc6-dev libcaca-dev libcaca0 libcdio-dev libcdio13 libcec-dev libcec1 libcroco3 libcurl3<br />
libcurl3-gnutls libcurl4-gnutls-dev libcwiid-dev libcwiid1 libdbus-1-3 libdbus-1-dev libdirac-encoder0 libdirectfb-1.2-9 libdirectfb-dev<br />
libdirectfb-extra libdpkg-perl libdrm2 libelf1 libenca-dev libenca0 liberror-perl libexpat1 libexpat1-dev libflac-dev libflac8 libfontconfig1<br />
libfontconfig1-dev libfreetype6 libfreetype6-dev libfribidi-dev libfribidi0 libgcrypt11-dev libgettextpo0 libgl1-mesa-dev libgl1-mesa-glx<br />
libglapi-mesa libglew-dev libglew1.7 libglib2.0-bin libglib2.0-dev libglu1-mesa libglu1-mesa-dev libgmp10 libgnutls-dev libgnutls-openssl27<br />
libgnutlsxx27 libgomp1 libgpg-error-dev libgsm1 libgssrpc4 libhal-dev libhal-storage-dev libhal-storage1 libhal1 libice-dev libice6 libicu48<br />
libidn11-dev libiso9660-8 libiso9660-dev libjasper-dev libjasper1 libjbig-dev libjbig0 libjpeg8 libjpeg8-dev libjson0 libkadm5clnt-mit8<br />
libkadm5srv-mit8 libkdb5-6 libkrb5-dev liblcms1 libldap-2.4-2 libldap2-dev libltdl-dev libltdl7 liblzo2-2 liblzo2-dev libmad0 libmad0-dev<br />
libmicrohttpd-dev libmicrohttpd10 libmikmod2 libmikmod2-dev libmodplug-dev libmodplug1 libmp3lame-dev libmp3lame0 libmpc2 libmpeg2-4<br />
libmpeg2-4-dev libmpfr4 libmysqlclient-dev libmysqlclient18 libnettle4 libnfs-dev libnfs1 libogg-dev libogg0 libopencv-core2.3<br />
libopencv-imgproc2.3 libopenjpeg2 liborc-0.4-0 libp11-kit-dev libpcre3-dev libpcrecpp0 libpipeline1 libplist-dev libplist1 libpng12-0<br />
libpng12-dev libpopt0 libpostproc-dev libpostproc52 libpthread-stubs0 libpthread-stubs0-dev libpulse-dev libpulse-mainloop-glib0 libpulse0<br />
libpython2.7 librtmp-dev librtmp0 libsamplerate0 libsamplerate0-dev libsasl2-2 libschroedinger-1.0-0 libsdl-image1.2 libsdl-image1.2-dev<br />
libsdl-mixer1.2 libsdl-mixer1.2-dev libsdl1.2-dev libsdl1.2debian libshairport-dev libshairport1 libsigsegv2 libslang2-dev libsm-dev libsm6<br />
libsmbclient libsmbclient-dev libsndfile1 libspeex1 libsqlite3-0 libsqlite3-dev libssh2-1 libssh2-1-dev libssl-dev libstdc++6-4.4-dev<br />
libstdc++6-4.6-dev libswscale-dev libswscale2 libtalloc2 libtasn1-3-dev libtdb1 libtheora0 libtiff4 libtiff4-dev libtiffxx0c2<br />
libtimedate-perl libtinyxml-dev libtinyxml2.6.2 libtool libts-0.0-0 libts-dev libudev-dev libunistring0 libva-dev libva-egl1 libva-glx1<br />
libva-tpi1 libva-x11-1 libva1 libvdpau-dev libvdpau1 libvorbis-dev libvorbis0a libvorbisenc2 libvorbisfile3 libvpx1 libwbclient0 libwebp-dev<br />
libwebp2 libx11-dev libx11-xcb1 libx264-123 libxau-dev libxcb-glx0 libxcb1-dev libxdamage1 libxdmcp-dev libxext-dev libxfixes3 libxi6<br />
libxml2-dev libxmlrpc-core-c3 libxmu-dev libxmu-headers libxmu6 libxrandr-dev libxrandr2 libxrender-dev libxrender1 libxt-dev libxt6 libxtst6<br />
libxvidcore4 libxxf86vm1 libyajl-dev libyajl2 linux-libc-dev m4 make man-db mesa-common-dev mysql-common patch pkg-config po-debconf python<br />
python-dev python-imaging python-minimal python-support python2.7 python2.7-dev python2.7-minimal tsconf ttf-dejavu-core ucf x11-common<br />
x11proto-core-dev x11proto-input-dev x11proto-kb-dev x11proto-randr-dev x11proto-render-dev x11proto-xext-dev xorg-sgml-doctools xtrans-dev<br />
yasm zip zlib1g-dev<br />
<br />
need to install 3 more dependencies:<br />
root@mele:~/# apt-get install swig default-jre libgtk2.0-bin libssh-4 libssh-dev<br />
<br />
ensure you use hardware acceleration<br />
root@mele:~/# echo -e "\nA10HWR=1" >> /etc/environment (to set it permanently)<br />
<br />
Now go on with [[XBMC#Native_Compile_of_XBMC | Native Compile]] or [[XBMC#Cross_Compile_of_XBMC | Cross Compile]].<br />
<br />
== Native Compile of XBMC ==<br />
<br />
=== Prerequisites for native compile ===<br />
<br />
Create a swap-file, because otherwise the compiler runs out of memory during compiling and aborts<br />
root@mele:~/# dd if=/dev/zero of=/swap bs=1M count=384<br />
root@mele:~/# mkswap -c /swap<br />
root@mele:~/# swapon /swap<br />
<br />
Create your workspace directory:<br />
root@mele:~/# mkdir melehacking<br />
root@mele:~/# cd melehacking<br />
<br />
=== Checkout the source code ===<br />
root@mele:~/melehacking# apt-get install git<br />
root@mele:~/melehacking# git clone git://github.com/rellla/xbmca10.git<br />
root@mele:~/melehacking# cd xbmca10<br />
root@mele:~/melehacking/xbmca10# git checkout stage/Frodo<br />
<br />
=== Build ===<br />
The following external libs/ repos are used/ downloaded:<br />
* taglib: https://github.com/downloads/taglib/taglib/taglib-1.8.tar.gz<br />
* cedarx: https://github.com/linux-sunxi/cedarx-libs/tree/master/libcedarv/linux-armhf<br />
* libmad: ftp://ftp.mars.org/pub/mpeg/libmad-0.15.1b.tar.gz<br />
* mali: https://github.com/linux-sunxi/sunxi-mali-proprietary/tree/master/r3p0/armhf<br />
* mali-dev: https://github.com/linux-sunxi/sunxi-mali/tree/master/include<br />
<br />
Build dependencies<br />
root@mele:~/melehacking/xbmca10# cd tools/a10/depends<br />
root@mele:~/melehacking/xbmca10/tools/a10/depends# make<br />
Build xbmc itself<br />
root@mele:~/melehacking/xbmca10/tools/a10/depends# make -C xbmc<br />
root@mele:~/melehacking/xbmca10/tools/a10/depends# cd ../../../<br />
root@mele:~/melehacking/xbmca10# make install<br />
<br />
Move on to [[XBMC#Start_XBMC]] and start XBMC.<br />
<br />
== Cross Compile of XBMC ==<br />
This was tested with github.com/rellla/xbmca10 and built in Debian Sid as host. You will need several packages on the build system and a copy <br />
of the root file system of the target to build against. This howto assumes you are running off an SD card with the root file system in /dev/sdb2.<br />
=== Setup Cross Compiler ===<br />
* At first set up your [[Toolchain|toolchain]].<br />
<br />
=== Prerequisites for Cross Compiling ===<br />
* Sync and move SD card to build system<br />
* Mount the rootfs of the prepared SD Card<br />
root@debian:~/# mount /dev/sdb2 /mnt/rootfs-a10<br />
* Create symlinks to the mounted libraries<br />
root@debian:~/# ln -s /mnt/rootfs-a10/lib/arm-linux-gnueabihf /lib/arm-linux-gnueabihf<br />
root@debian:~/# ln -s /mnt/rootfs-a10/usr/lib/arm-linux-gnueabihf /usr/lib/arm-linux-gnueabihf<br />
root@debian:~/# ln -s /mnt/rootfs-a10/usr/include/arm-linux-gnueabihf /usr/include/arm-linux-gnueabihf<br />
* Install the dependencies for building XBMC on the host system<br />
root@debian:~/# apt-get build-dep xbmc<br />
root@debian:~/# apt-get install shtool swig default-jre<br />
Note: If compiling on a 64 bit system there is a known bug with the libcurl headers not working with 32 bit programs. To work around the problem build on a 32 bit system, or copy the file /usr/include/curl/curlbuild.h from a 32 bit system to your 64 bit build host.<br />
* Create your workspace directory:<br />
root@debian:~/# mkdir melehacking<br />
root@debian:~/# cd melehacking<br />
<br />
=== Checkout the source code ===<br />
root@debian:~/melehacking# git clone git://github.com/rellla/xbmca10.git<br />
root@debian:~/melehacking# cd xbmca10<br />
root@debian:~/melehacking/xbmca10# git checkout stage/Frodo<br />
<br />
=== Update XBMC build config ===<br />
Update this section at line 48 of tools/a10/depends/depends.mk with your values, e.g.<br />
#where is your arm rootfs<br />
SDKSTAGE=/mnt/rootfs-a10<br />
#where is your xbmc install root <br />
XBMCPREFIX=/allwinner/xbmc-pvr-bin$(HF)<br />
#where is your toolchain<br />
TOOLCHAIN=/usr/arm-linux-gnueabi$(HF)<br />
<br />
=== Build ===<br />
At this point the settings are basically the same for the native build:<br />
Build dependencies<br />
root@debian:~/melehacking/xbmca10# cd tools/a10/depends<br />
root@debian:~/melehacking/xbmca10/tools/a10/depends# make<br />
Build xbmc itself<br />
root@debian:~/melehacking/xbmca10/tools/a10/depends# make -C xbmc<br />
root@debian:~/melehacking/xbmca10/tools/a10/depends# cd ../../../<br />
root@debian:~/melehacking/xbmca10# make install<br />
<br />
=== Move XBMC to target system ===<br />
You should copy from your install location on your build system to an identical location on the target system (may not vital that they have the same path) like so ...<br />
root@debian:~/melehacking/xbmca10/cp -r /allwinner/xbmc-pvr-binhf /mnt/rootfs-a10/allwinner/xbmc-pvr-binhf<br />
<br />
To redistribute it, you can also create a tarball:<br />
root@debian:~/melehacking/xbmca10/tools/a10/depends# make -C package tarball<br />
This results in a xbmca10.tar.gz which includes all needed (and stripped) files in /allwinner/xbmc-pvr-binhf. This can easily be copied and extracted on the target rootfs.<br />
<br />
Umount your SD Card<br />
root@debian:~/melehacking/xbmca10# umount /dev/sdb2<br />
and boot it on your A10 Device.<br />
<br />
== Start XBMC ==<br />
After a reboot you modprobe the needed modules (depending on the used kernel version):<br />
root@mele:~/# modprobe disp<br />
root@mele:~/# modprobe lcd<br />
root@mele:~/# modprobe hdmi<br />
root@mele:~/# modprobe mali<br />
root@mele:~/# export A10HWR=1 (ensure to have this set if not rebooting!)<br />
root@mele:~/# cd /allwinner/xbmc-pvr-bin/lib/xbmc<br />
root@mele:/allwinner/xbmc-pvr-bin/lib/xbmc# ./xbmc.bin<br />
<br />
== Using the Android libraries via libhybris ==<br />
Due to some bugs in the native linux binaries of cedarx, ssvb succeeded to use libhybris and the Android binaries instead. This is the recommended way.<br />
See [[CedarX/libve]].<br />
<br />
== Troubleshooting ==<br />
* (native) If you get a compiler error when processing h264.o or building xbmc.bin, then check, if swap is enabled. The compiler ran out of memory!<br />
* (native) If deb-building fails, check, if your tmp-directory has enough free space and is no tmpfs, because of the lack of memory an mele.<br />
* To use the bash-script bin/xbmc to start xbmc, you have to comment out the exec of FEH.py, because of a failing test of glxinfo -> no display found.<br />
* Depending on your setup you may have to change some things to build<br />
* If mysql_config is not found, even though it is clearly there you can set disable-mysql in Makefile under xbmca10/tools/a10/depends/xbmc<br />
* Header files might not be where they are expected, this can be fixed with symlinks and copying headers, for example...<br />
ln -s usr/include/dbus1.0/dbus usr/include/dbus <br />
* Once you get in trouble with some mesa conflicts, ensure to not have installed the following packages on your target system: <br />
libegl1-mesa libegl1-mesa-dev libegl1-mesa-drivers libgles2-mesa libgles2-mesa-dev<br />
* Check the discussion section for more notes.<br />
* Ensure that you have installed ALL of the dependencies, header files etc. in your target rootfs and ensure that they are available during build. The build script does not search for them on your host-rootfs!<br />
<br />
= Configuring XBMC dependencies for Linux on A10 based devices =<br />
== Getting IR (infrared) remotes working on A10 based media players ==<br />
For getting IR (infrared) remote controls working on the A10 based media players, please see the [[LIRC (Linux Infrared Remote Control) for the IR receivers and and remotes]] article in this wiki. Place a suitable [[Lircmap.xml]] in userdata-directory.<br />
<br />
= Enabling dirty regions (a.k.a. dirty textures) for XBMC =<br />
This dirty region (a.k.a. dirty texture) feature in XBMC is designed to improve XBMC's GUI renderer performance on the GPU by only drawing when something like a texture changes on the screen, that region is then marked as dirty by XBMC's GUI library and only that region is redraw region on the screen.<br />
<br />
This feature is however still a little buggy and therefor not enabled by default in XBMC, but all users of XBMC on A10 based devices can try enabling the hidden "dirty regions" (a.k.a. "dirty textures") rendering feature advanced setting themselves manually. <br />
<br />
* http://wiki.xbmc.org/index.php?title=HOW-TO:Enable_dirty_regions<br />
* http://xbmc.org/theuni/2011/06/19/working-with-dirty-regions/<br />
* http://wiki.xbmc.org/index.php?title=Advancedsettings.xml#.3Calgorithmdirtyregions.3E<br />
<br />
Dirty regions are any parts of the screen that have changed since the last frame. By not re-rendering what hasn't changed, big speed gains can be seen. Because all GPUs work differently, only Mode 3, combined with nofliptimeout=0, is guaranteed to be safe for everyone, but current timing issues with nofliptimeout keep this from being the default. Note that with "dirty regions" your system CPU usage might go up a little (because it is doing the dirty regions calculations) but your GPU usage will be much lower, and since it is the GPU and not CPU that is the bottleneck in XBMC for embedded systems your GUI performance will be better even though the CPU usage is higher.<br />
<br />
{| class="wikitable"<br />
! value !! result !! description<br />
|-<br />
! 0<br />
| Off<br />
| The entire viewport is always rendered, which is the same as having the dirty regions feature disabled. This is the default mode.<br />
|-<br />
! 1<br />
|Union<br />
|All dirty regions are grouped into the smallest possible rectangle. This is typically the fastest mode for slower GPUs due to only making one pass.<br />
|-<br />
! 2<br />
|Cost reduction<br />
| Each dirty region is presented separately, in as many passes as there are regions.<br />
|-<br />
! 3<br />
|Whole Screen<br />
| The entire screen is rendered if there are any dirty regions. This, combined with nofliptimeout is a safe default for drivers that clear buffer contents (manifests as blinking or vibrating images)<br />
|}<br />
<br />
To enable dirty regions manually you need to create a "advancedsettings.xml" text file youself and put the XML <algorithmdirtyregions> enabling tags in there and copying to your "/userdata/" folder (/home/username/.xbmc/userdata/).<br />
<br />
Example:<br />
<code><br />
<gui> <br />
<algorithmdirtyregions>1</algorithmdirtyregions><br />
</gui><br />
</code><br />
<br />
You could also try to enable the <nofliptimeout> feature but that is even more experimental so know that it can cause even more GUI rendering issues in XBMC<br />
<br />
Example: <br />
<code><br />
<gui> <br />
<nofliptimeout>1000</nofliptimeout><br />
</gui><br />
</code><br />
<br />
To have both of these enabled your "advancedsettings.xml" then the finished file should look something like this:<br />
<br />
<code><br />
<advancedsettings><br />
<gui> <br />
<algorithmdirtyregions>1</algorithmdirtyregions><br />
<nofliptimeout>1000</nofliptimeout><br />
</gui><br />
</advancedsettings><br />
</code><br />
<br />
=Sources implementing CedarX support in XBMC=<br />
* [https://github.com/empatzero/xbmca10 https://github.com/empatzero/xbmca10]<br />
** [https://github.com/rellla/xbmca10 https://github.com/rellla/xbmca10] Recommended fork of empatzero ([http://pastebin.com/M4Di5tha Diff to upstream])<br />
** [https://github.com/vidonme/xbmc/ https://github.com/vidonme/xbmc/] Sources of [http://www.vidon.me/download.html VidOn.Me Player]? Seems to be a fork from empatzero. ([http://pastebin.com/LuQ4AB9J Diff to upstream] and [https://github.com/vidonme/xbmc/compare/xbmc:7b9ab8a85fd2b6030e6cf2659ff16380afef3996...master Github Compare]) This repo is reported from VidOn.me to be the "official" source code for their Allwinner XBMC version, yet the only code commit from VidOn.me themselves is [https://github.com/vidonme/xbmc/commit/b2b1696e8eb6617da07e0a043ca6ef2219ca080d#diff-2c44bd39cfe6b4185fe6a51b78c46cd0R122 this one]. <br />
* [https://github.com/huceke/xbmc/tree/allwinner https://github.com/huceke/xbmc/tree/allwinner] Gimli's implementation ([http://pastebin.com/Nu3DrfNK Diff to upstream])<br />
<br />
=References=<br />
<references /><br />
<br />
= See also =<br />
* [[CedarX]] - Library for Allwinner CedarX VPU (Video Processor Unit) used for audio and video decoding and encoding hardware off-loading on A1x and A2x SoC series.<br />
** [[CedarXVideoRenderingChart]] - Overview chart of working/ non working video files<br />
* [[LIRC (Linux Infrared Remote Control) for the IR receivers and and remotes]]<br />
* [[Tvheadend TV Tuner Server and PVR backend]]<br />
<br />
=External Links=<br />
* [http://forum.xbmc.org/showthread.php?tid=126995 XBMC Official Community Forum discussion about porting to Allwinner A10]<br />
* [http://jas-hacks.blogspot.co.uk/2012/11/hackberry-a10-xbmc.html Jas Hacks Hackberry A10 - XBMC on Ubuntu 12.10 image]<br />
* [http://www.j1nx.nl/buildroot-xbmc-on-mele-a1000-allwinner-a10/ Buildroot XBMC on the Mele A1000 (Allwinner A10)]<br />
* [http://www.cnx-software.com/2012/11/12/xbmc-for-linux-on-allwinner-a10-devices-it-works-sort-of/ XBMC for Linux on AllWinner A10 Devices? It Works! (Sort of)]<br />
<br />
[[Category:Software]]<br />
[[Category:Tutorial]]<br />
[[Category:CedarX]]</div>Rockerhttps://linux-sunxi.org/index.php?title=CedarX/XBMC&diff=10091CedarX/XBMC2014-07-30T15:24:30Z<p>Rocker: /* Sources implementing A10 on XBMC */</p>
<hr />
<div><div style="color:#6F0000; border: 3px dashed #BF4F4F; padding: 2em;"><big><br />
'''XBMC for linux on Allwinner devices is NOT READY FOR USE!'''<br />
<br />
This is only a hack intended for developers and curious users at the moment. Don't expect it to work as you want it! Hardware is capable to make it run quite good in the future, but software and drivers are not ready yet. The [[:Category:Community|sunxi-community]] is working towards making a smooth XBMC experience possible.<br />
<br />
If you want to help developing the needed components to have a stable XBMC in the future, join the [[:Category:Community|irc and mailing list]]. Developers wanted!</big></div><br />
<br/><br />
<br />
XBMC is a popular media center software with 10-foot interface designed for large-screen televisions, and it enables ARM-based media players and set-top boxes like those with Allwinner SoCs with [[CedarX]] VPU (Video Processor Unit) to hardware decode and play high-definition videos, music, and other digital media files from local and network storage media, as well as stream podcasts, videocasts, and such of the internet.<br />
<br />
This article contain instructions on compiling and developing XBMC on and for Allwinner SoCs that features the [[CedarX]] VPU, like [[A10]], [[A10s]], [[A13]], [[A20]], and [[A23]]. Note that these instructions are specifically only meant for developers and advanced or expert Linux users that can actively assist with the porting process.<br />
<br />
=Overview=<br />
XBMC has already have an initial port for the A10 / A20 SoC with [[CedarX]] hardware accelerated video decoding, this experimental third-party port and the code patches have however not yet made it upstream into mainline XBMC.<ref>http://www.j1nx.nl/buildroot-xbmc-on-mele-a1000-allwinner-a10/ Buildroot XBMC on the Mele A1000 (Allwinner A10)</ref><ref>http://www.cnx-software.com/2012/11/12/xbmc-for-linux-on-allwinner-a10-devices-it-works-sort-of/ XBMC for Linux on AllWinner A10 Devices? It Works! (Sort of)</ref><br />
<br />
Pre-built application binaries of this port are not available so therefore you will need to compile XBMC yourself, at least until if and when the code makes it into the mainline XBMC upstream at http://xbmc.org<br />
<br />
Team-XBMC, the official development team of XBMC, does currently not recommend that any end-user buy Allwinner A10 or A20 based hardware for the specific purpose of only running XBMC since they do not have the resources to support this platform as of yet.<br />
<br />
More information about XBMC can be found on wikipedia http://en.wikipedia.org/wiki/XBMC and the XBMC wiki http://wiki.xbmc.org or http://forum.xbmc.org<br />
<br />
= Building XBMC for A10 and A20 =<br />
This is a little how-to of steps to compile XBMC for devices using Allwinner A10 and A20 SoCs (e.g. Mele A1000, Cubieboard, Banana Pi) based on Empat0's GitHub sources [http://github.com/empatzero/xbmca10 http://github.com/empatzero/xbmca10].<br />
The development work on the coding side was all done by Empat0 (a.k.a. empat zero). The used repository in the example below is however from [http://github.com/rellla/xbmca10 http://github.com/rellla/xbmca10] which is currently the newest and contains a few adaptions. It is a fork of empat0's work. <br />
<br />
The result should be a Debian armhf system with XBMC using [[CedarX]] for hardware accelerated video decoding.<br />
<br />
This version of XBMC runs directly on the framebuffer, and thus XServer is therefor not needed!<br />
<br />
== Prerequisites ==<br />
There are more ways to prepare a working rootfs for XBMC. You can either prepare the sdcard directly as described or you can chroot into the rootfs on your host system and sync it with your sdcard later when you have finished.<br />
So the following steps can also be done in a chroot on your host if you are cross-compiling.<br />
<br />
=== Prepare your SD-Card ===<br />
Create a bootable SD-Card follwing [[Manual_build_howto| our manual build howto]] and Debian. Be sure to use a kernel with mali-drivers-version r3p0 (sunxi-3.0 should be good).<br />
<br />
=== Boot into your target system ===<br />
Boot the new debian from the sd-card directly on the target and bring the system up to date:<br />
root@mele:~/# apt-get update<br />
root@mele:~/# apt-get upgrade<br />
<br />
=== Install the dependencies for XBMC (needs update!) ===<br />
root@mele:~/# apt-get build-dep xbmc<br />
<br />
this should install the following packages:<br />
autoconf automake autopoint autotools-dev binutils bsdmainutils build-essential bzip2 cmake cmake-data comerr-dev cpp cpp-4.4 cpp-4.6 curl<br />
debhelper dpkg-dev emacsen-common fontconfig-config g++ g++-4.4 g++-4.6 gawk gcc gcc-4.4 gcc-4.4-base gcc-4.6 gcc-4.6-base gettext<br />
gettext-base git git-man gperf groff-base html2text intltool-debian krb5-multidev libao-common libao-dev libao4 libarchive12 libasound2<br />
libasound2-dev libasprintf0c2 libass-dev libass4 libasyncns0 libavahi-client-dev libavahi-client3 libavahi-common-data libavahi-common-dev<br />
libavahi-common3 libavcodec-dev libavcodec53 libavfilter-dev libavfilter2 libavformat-dev libavformat53 libavutil-dev libavutil51<br />
libbluetooth-dev libbluetooth3 libbluray-dev libbluray1 libboost-date-time1.49-dev libboost-date-time1.49.0 libboost-dev<br />
libboost-serialization1.49-dev libboost-serialization1.49.0 libboost-thread-dev libboost-thread1.49-dev libboost-thread1.49.0<br />
libboost1.49-dev libbz2-dev libc-dev-bin libc6-dev libcaca-dev libcaca0 libcdio-dev libcdio13 libcec-dev libcec1 libcroco3 libcurl3<br />
libcurl3-gnutls libcurl4-gnutls-dev libcwiid-dev libcwiid1 libdbus-1-3 libdbus-1-dev libdirac-encoder0 libdirectfb-1.2-9 libdirectfb-dev<br />
libdirectfb-extra libdpkg-perl libdrm2 libelf1 libenca-dev libenca0 liberror-perl libexpat1 libexpat1-dev libflac-dev libflac8 libfontconfig1<br />
libfontconfig1-dev libfreetype6 libfreetype6-dev libfribidi-dev libfribidi0 libgcrypt11-dev libgettextpo0 libgl1-mesa-dev libgl1-mesa-glx<br />
libglapi-mesa libglew-dev libglew1.7 libglib2.0-bin libglib2.0-dev libglu1-mesa libglu1-mesa-dev libgmp10 libgnutls-dev libgnutls-openssl27<br />
libgnutlsxx27 libgomp1 libgpg-error-dev libgsm1 libgssrpc4 libhal-dev libhal-storage-dev libhal-storage1 libhal1 libice-dev libice6 libicu48<br />
libidn11-dev libiso9660-8 libiso9660-dev libjasper-dev libjasper1 libjbig-dev libjbig0 libjpeg8 libjpeg8-dev libjson0 libkadm5clnt-mit8<br />
libkadm5srv-mit8 libkdb5-6 libkrb5-dev liblcms1 libldap-2.4-2 libldap2-dev libltdl-dev libltdl7 liblzo2-2 liblzo2-dev libmad0 libmad0-dev<br />
libmicrohttpd-dev libmicrohttpd10 libmikmod2 libmikmod2-dev libmodplug-dev libmodplug1 libmp3lame-dev libmp3lame0 libmpc2 libmpeg2-4<br />
libmpeg2-4-dev libmpfr4 libmysqlclient-dev libmysqlclient18 libnettle4 libnfs-dev libnfs1 libogg-dev libogg0 libopencv-core2.3<br />
libopencv-imgproc2.3 libopenjpeg2 liborc-0.4-0 libp11-kit-dev libpcre3-dev libpcrecpp0 libpipeline1 libplist-dev libplist1 libpng12-0<br />
libpng12-dev libpopt0 libpostproc-dev libpostproc52 libpthread-stubs0 libpthread-stubs0-dev libpulse-dev libpulse-mainloop-glib0 libpulse0<br />
libpython2.7 librtmp-dev librtmp0 libsamplerate0 libsamplerate0-dev libsasl2-2 libschroedinger-1.0-0 libsdl-image1.2 libsdl-image1.2-dev<br />
libsdl-mixer1.2 libsdl-mixer1.2-dev libsdl1.2-dev libsdl1.2debian libshairport-dev libshairport1 libsigsegv2 libslang2-dev libsm-dev libsm6<br />
libsmbclient libsmbclient-dev libsndfile1 libspeex1 libsqlite3-0 libsqlite3-dev libssh2-1 libssh2-1-dev libssl-dev libstdc++6-4.4-dev<br />
libstdc++6-4.6-dev libswscale-dev libswscale2 libtalloc2 libtasn1-3-dev libtdb1 libtheora0 libtiff4 libtiff4-dev libtiffxx0c2<br />
libtimedate-perl libtinyxml-dev libtinyxml2.6.2 libtool libts-0.0-0 libts-dev libudev-dev libunistring0 libva-dev libva-egl1 libva-glx1<br />
libva-tpi1 libva-x11-1 libva1 libvdpau-dev libvdpau1 libvorbis-dev libvorbis0a libvorbisenc2 libvorbisfile3 libvpx1 libwbclient0 libwebp-dev<br />
libwebp2 libx11-dev libx11-xcb1 libx264-123 libxau-dev libxcb-glx0 libxcb1-dev libxdamage1 libxdmcp-dev libxext-dev libxfixes3 libxi6<br />
libxml2-dev libxmlrpc-core-c3 libxmu-dev libxmu-headers libxmu6 libxrandr-dev libxrandr2 libxrender-dev libxrender1 libxt-dev libxt6 libxtst6<br />
libxvidcore4 libxxf86vm1 libyajl-dev libyajl2 linux-libc-dev m4 make man-db mesa-common-dev mysql-common patch pkg-config po-debconf python<br />
python-dev python-imaging python-minimal python-support python2.7 python2.7-dev python2.7-minimal tsconf ttf-dejavu-core ucf x11-common<br />
x11proto-core-dev x11proto-input-dev x11proto-kb-dev x11proto-randr-dev x11proto-render-dev x11proto-xext-dev xorg-sgml-doctools xtrans-dev<br />
yasm zip zlib1g-dev<br />
<br />
need to install 3 more dependencies:<br />
root@mele:~/# apt-get install swig default-jre libgtk2.0-bin libssh-4 libssh-dev<br />
<br />
ensure you use hardware acceleration<br />
root@mele:~/# echo -e "\nA10HWR=1" >> /etc/environment (to set it permanently)<br />
<br />
Now go on with [[XBMC#Native_Compile_of_XBMC | Native Compile]] or [[XBMC#Cross_Compile_of_XBMC | Cross Compile]].<br />
<br />
== Native Compile of XBMC ==<br />
<br />
=== Prerequisites for native compile ===<br />
<br />
Create a swap-file, because otherwise the compiler runs out of memory during compiling and aborts<br />
root@mele:~/# dd if=/dev/zero of=/swap bs=1M count=384<br />
root@mele:~/# mkswap -c /swap<br />
root@mele:~/# swapon /swap<br />
<br />
Create your workspace directory:<br />
root@mele:~/# mkdir melehacking<br />
root@mele:~/# cd melehacking<br />
<br />
=== Checkout the source code ===<br />
root@mele:~/melehacking# apt-get install git<br />
root@mele:~/melehacking# git clone git://github.com/rellla/xbmca10.git<br />
root@mele:~/melehacking# cd xbmca10<br />
root@mele:~/melehacking/xbmca10# git checkout stage/Frodo<br />
<br />
=== Build ===<br />
The following external libs/ repos are used/ downloaded:<br />
* taglib: https://github.com/downloads/taglib/taglib/taglib-1.8.tar.gz<br />
* cedarx: https://github.com/linux-sunxi/cedarx-libs/tree/master/libcedarv/linux-armhf<br />
* libmad: ftp://ftp.mars.org/pub/mpeg/libmad-0.15.1b.tar.gz<br />
* mali: https://github.com/linux-sunxi/sunxi-mali-proprietary/tree/master/r3p0/armhf<br />
* mali-dev: https://github.com/linux-sunxi/sunxi-mali/tree/master/include<br />
<br />
Build dependencies<br />
root@mele:~/melehacking/xbmca10# cd tools/a10/depends<br />
root@mele:~/melehacking/xbmca10/tools/a10/depends# make<br />
Build xbmc itself<br />
root@mele:~/melehacking/xbmca10/tools/a10/depends# make -C xbmc<br />
root@mele:~/melehacking/xbmca10/tools/a10/depends# cd ../../../<br />
root@mele:~/melehacking/xbmca10# make install<br />
<br />
Move on to [[XBMC#Start_XBMC]] and start XBMC.<br />
<br />
== Cross Compile of XBMC ==<br />
This was tested with github.com/rellla/xbmca10 and built in Debian Sid as host. You will need several packages on the build system and a copy <br />
of the root file system of the target to build against. This howto assumes you are running off an SD card with the root file system in /dev/sdb2.<br />
=== Setup Cross Compiler ===<br />
* At first set up your [[Toolchain|toolchain]].<br />
<br />
=== Prerequisites for Cross Compiling ===<br />
* Sync and move SD card to build system<br />
* Mount the rootfs of the prepared SD Card<br />
root@debian:~/# mount /dev/sdb2 /mnt/rootfs-a10<br />
* Create symlinks to the mounted libraries<br />
root@debian:~/# ln -s /mnt/rootfs-a10/lib/arm-linux-gnueabihf /lib/arm-linux-gnueabihf<br />
root@debian:~/# ln -s /mnt/rootfs-a10/usr/lib/arm-linux-gnueabihf /usr/lib/arm-linux-gnueabihf<br />
root@debian:~/# ln -s /mnt/rootfs-a10/usr/include/arm-linux-gnueabihf /usr/include/arm-linux-gnueabihf<br />
* Install the dependencies for building XBMC on the host system<br />
root@debian:~/# apt-get build-dep xbmc<br />
root@debian:~/# apt-get install shtool swig default-jre<br />
Note: If compiling on a 64 bit system there is a known bug with the libcurl headers not working with 32 bit programs. To work around the problem build on a 32 bit system, or copy the file /usr/include/curl/curlbuild.h from a 32 bit system to your 64 bit build host.<br />
* Create your workspace directory:<br />
root@debian:~/# mkdir melehacking<br />
root@debian:~/# cd melehacking<br />
<br />
=== Checkout the source code ===<br />
root@debian:~/melehacking# git clone git://github.com/rellla/xbmca10.git<br />
root@debian:~/melehacking# cd xbmca10<br />
root@debian:~/melehacking/xbmca10# git checkout stage/Frodo<br />
<br />
=== Update XBMC build config ===<br />
Update this section at line 48 of tools/a10/depends/depends.mk with your values, e.g.<br />
#where is your arm rootfs<br />
SDKSTAGE=/mnt/rootfs-a10<br />
#where is your xbmc install root <br />
XBMCPREFIX=/allwinner/xbmc-pvr-bin$(HF)<br />
#where is your toolchain<br />
TOOLCHAIN=/usr/arm-linux-gnueabi$(HF)<br />
<br />
=== Build ===<br />
At this point the settings are basically the same for the native build:<br />
Build dependencies<br />
root@debian:~/melehacking/xbmca10# cd tools/a10/depends<br />
root@debian:~/melehacking/xbmca10/tools/a10/depends# make<br />
Build xbmc itself<br />
root@debian:~/melehacking/xbmca10/tools/a10/depends# make -C xbmc<br />
root@debian:~/melehacking/xbmca10/tools/a10/depends# cd ../../../<br />
root@debian:~/melehacking/xbmca10# make install<br />
<br />
=== Move XBMC to target system ===<br />
You should copy from your install location on your build system to an identical location on the target system (may not vital that they have the same path) like so ...<br />
root@debian:~/melehacking/xbmca10/cp -r /allwinner/xbmc-pvr-binhf /mnt/rootfs-a10/allwinner/xbmc-pvr-binhf<br />
<br />
To redistribute it, you can also create a tarball:<br />
root@debian:~/melehacking/xbmca10/tools/a10/depends# make -C package tarball<br />
This results in a xbmca10.tar.gz which includes all needed (and stripped) files in /allwinner/xbmc-pvr-binhf. This can easily be copied and extracted on the target rootfs.<br />
<br />
Umount your SD Card<br />
root@debian:~/melehacking/xbmca10# umount /dev/sdb2<br />
and boot it on your A10 Device.<br />
<br />
== Start XBMC ==<br />
After a reboot you modprobe the needed modules (depending on the used kernel version):<br />
root@mele:~/# modprobe disp<br />
root@mele:~/# modprobe lcd<br />
root@mele:~/# modprobe hdmi<br />
root@mele:~/# modprobe mali<br />
root@mele:~/# export A10HWR=1 (ensure to have this set if not rebooting!)<br />
root@mele:~/# cd /allwinner/xbmc-pvr-bin/lib/xbmc<br />
root@mele:/allwinner/xbmc-pvr-bin/lib/xbmc# ./xbmc.bin<br />
<br />
== Using the Android libraries via libhybris ==<br />
Due to some bugs in the native linux binaries of cedarx, ssvb succeeded to use libhybris and the Android binaries instead. This is the recommended way.<br />
See [[CedarX/libve]].<br />
<br />
== Troubleshooting ==<br />
* (native) If you get a compiler error when processing h264.o or building xbmc.bin, then check, if swap is enabled. The compiler ran out of memory!<br />
* (native) If deb-building fails, check, if your tmp-directory has enough free space and is no tmpfs, because of the lack of memory an mele.<br />
* To use the bash-script bin/xbmc to start xbmc, you have to comment out the exec of FEH.py, because of a failing test of glxinfo -> no display found.<br />
* Depending on your setup you may have to change some things to build<br />
* If mysql_config is not found, even though it is clearly there you can set disable-mysql in Makefile under xbmca10/tools/a10/depends/xbmc<br />
* Header files might not be where they are expected, this can be fixed with symlinks and copying headers, for example...<br />
ln -s usr/include/dbus1.0/dbus usr/include/dbus <br />
* Once you get in trouble with some mesa conflicts, ensure to not have installed the following packages on your target system: <br />
libegl1-mesa libegl1-mesa-dev libegl1-mesa-drivers libgles2-mesa libgles2-mesa-dev<br />
* Check the discussion section for more notes.<br />
* Ensure that you have installed ALL of the dependencies, header files etc. in your target rootfs and ensure that they are available during build. The build script does not search for them on your host-rootfs!<br />
<br />
= Configuring XBMC dependencies for Linux on A10 based devices =<br />
== Getting IR (infrared) remotes working on A10 based media players ==<br />
For getting IR (infrared) remote controls working on the A10 based media players, please see the [[LIRC (Linux Infrared Remote Control) for the IR receivers and and remotes]] article in this wiki. Place a suitable [[Lircmap.xml]] in userdata-directory.<br />
<br />
= Enabling dirty regions (a.k.a. dirty textures) for XBMC =<br />
This dirty region (a.k.a. dirty texture) feature in XBMC is designed to improve XBMC's GUI renderer performance on the GPU by only drawing when something like a texture changes on the screen, that region is then marked as dirty by XBMC's GUI library and only that region is redraw region on the screen.<br />
<br />
This feature is however still a little buggy and therefor not enabled by default in XBMC, but all users of XBMC on A10 based devices can try enabling the hidden "dirty regions" (a.k.a. "dirty textures") rendering feature advanced setting themselves manually. <br />
<br />
* http://wiki.xbmc.org/index.php?title=HOW-TO:Enable_dirty_regions<br />
* http://xbmc.org/theuni/2011/06/19/working-with-dirty-regions/<br />
* http://wiki.xbmc.org/index.php?title=Advancedsettings.xml#.3Calgorithmdirtyregions.3E<br />
<br />
Dirty regions are any parts of the screen that have changed since the last frame. By not re-rendering what hasn't changed, big speed gains can be seen. Because all GPUs work differently, only Mode 3, combined with nofliptimeout=0, is guaranteed to be safe for everyone, but current timing issues with nofliptimeout keep this from being the default. Note that with "dirty regions" your system CPU usage might go up a little (because it is doing the dirty regions calculations) but your GPU usage will be much lower, and since it is the GPU and not CPU that is the bottleneck in XBMC for embedded systems your GUI performance will be better even though the CPU usage is higher.<br />
<br />
{| class="wikitable"<br />
! value !! result !! description<br />
|-<br />
! 0<br />
| Off<br />
| The entire viewport is always rendered, which is the same as having the dirty regions feature disabled. This is the default mode.<br />
|-<br />
! 1<br />
|Union<br />
|All dirty regions are grouped into the smallest possible rectangle. This is typically the fastest mode for slower GPUs due to only making one pass.<br />
|-<br />
! 2<br />
|Cost reduction<br />
| Each dirty region is presented separately, in as many passes as there are regions.<br />
|-<br />
! 3<br />
|Whole Screen<br />
| The entire screen is rendered if there are any dirty regions. This, combined with nofliptimeout is a safe default for drivers that clear buffer contents (manifests as blinking or vibrating images)<br />
|}<br />
<br />
To enable dirty regions manually you need to create a "advancedsettings.xml" text file youself and put the XML <algorithmdirtyregions> enabling tags in there and copying to your "/userdata/" folder (/home/username/.xbmc/userdata/).<br />
<br />
Example:<br />
<code><br />
<gui> <br />
<algorithmdirtyregions>1</algorithmdirtyregions><br />
</gui><br />
</code><br />
<br />
You could also try to enable the <nofliptimeout> feature but that is even more experimental so know that it can cause even more GUI rendering issues in XBMC<br />
<br />
Example: <br />
<code><br />
<gui> <br />
<nofliptimeout>1000</nofliptimeout><br />
</gui><br />
</code><br />
<br />
To have both of these enabled your "advancedsettings.xml" then the finished file should look something like this:<br />
<br />
<code><br />
<advancedsettings><br />
<gui> <br />
<algorithmdirtyregions>1</algorithmdirtyregions><br />
<nofliptimeout>1000</nofliptimeout><br />
</gui><br />
</advancedsettings><br />
</code><br />
<br />
=Sources implementing CedarX support in XBMC=<br />
* [https://github.com/empatzero/xbmca10 https://github.com/empatzero/xbmca10]<br />
** [https://github.com/rellla/xbmca10 https://github.com/rellla/xbmca10] Recommended fork of empatzero ([http://pastebin.com/M4Di5tha Diff to upstream])<br />
** [https://github.com/vidonme/xbmc/ https://github.com/vidonme/xbmc/] Sources of [http://www.vidon.me/download.html VidOn.Me Player]? Seems to be a fork from empatzero. ([http://pastebin.com/LuQ4AB9J Diff to upstream] and [https://github.com/vidonme/xbmc/compare/xbmc:7b9ab8a85fd2b6030e6cf2659ff16380afef3996...master Github Compare]) This repo is reported from VidOn.me to be the "official" source code for their Allwinner XBMC version, yet the only code commit from VidOn.me themselves is [https://github.com/vidonme/xbmc/commit/b2b1696e8eb6617da07e0a043ca6ef2219ca080d#diff-2c44bd39cfe6b4185fe6a51b78c46cd0R122 this one]. <br />
* [https://github.com/huceke/xbmc/tree/allwinner https://github.com/huceke/xbmc/tree/allwinner] Gimli's implementation ([http://pastebin.com/Nu3DrfNK Diff to upstream])<br />
<br />
=References=<br />
<references /><br />
<br />
= See also =<br />
* [[CedarX]] - Library for Allwinner CedarX VPU (Video Processor Unit) used for audio and video decoding and encoding hardware off-loading on A1x and A2x SoC series.<br />
** [[CedarXVideoRenderingChart]] - Overview chart of working/ non working video files<br />
* [[LIRC (Linux Infrared Remote Control) for the IR receivers and and remotes]]<br />
* [[Tvheadend TV Tuner Server and PVR backend]]<br />
<br />
=External Links=<br />
* [http://forum.xbmc.org/showthread.php?tid=126995 XBMC Official Community Forum discussion about porting to Allwinner A10]<br />
* [http://jas-hacks.blogspot.co.uk/2012/11/hackberry-a10-xbmc.html Jas Hacks Hackberry A10 - XBMC on Ubuntu 12.10 image]<br />
* [http://www.j1nx.nl/buildroot-xbmc-on-mele-a1000-allwinner-a10/ Buildroot XBMC on the Mele A1000 (Allwinner A10)]<br />
* [http://www.cnx-software.com/2012/11/12/xbmc-for-linux-on-allwinner-a10-devices-it-works-sort-of/ XBMC for Linux on AllWinner A10 Devices? It Works! (Sort of)]<br />
<br />
[[Category:Software]]<br />
[[Category:Tutorial]]<br />
[[Category:CedarX]]</div>Rockerhttps://linux-sunxi.org/index.php?title=CedarX/XBMC&diff=10090CedarX/XBMC2014-07-30T15:21:20Z<p>Rocker: /* See also */</p>
<hr />
<div><div style="color:#6F0000; border: 3px dashed #BF4F4F; padding: 2em;"><big><br />
'''XBMC for linux on Allwinner devices is NOT READY FOR USE!'''<br />
<br />
This is only a hack intended for developers and curious users at the moment. Don't expect it to work as you want it! Hardware is capable to make it run quite good in the future, but software and drivers are not ready yet. The [[:Category:Community|sunxi-community]] is working towards making a smooth XBMC experience possible.<br />
<br />
If you want to help developing the needed components to have a stable XBMC in the future, join the [[:Category:Community|irc and mailing list]]. Developers wanted!</big></div><br />
<br/><br />
<br />
XBMC is a popular media center software with 10-foot interface designed for large-screen televisions, and it enables ARM-based media players and set-top boxes like those with Allwinner SoCs with [[CedarX]] VPU (Video Processor Unit) to hardware decode and play high-definition videos, music, and other digital media files from local and network storage media, as well as stream podcasts, videocasts, and such of the internet.<br />
<br />
This article contain instructions on compiling and developing XBMC on and for Allwinner SoCs that features the [[CedarX]] VPU, like [[A10]], [[A10s]], [[A13]], [[A20]], and [[A23]]. Note that these instructions are specifically only meant for developers and advanced or expert Linux users that can actively assist with the porting process.<br />
<br />
=Overview=<br />
XBMC has already have an initial port for the A10 / A20 SoC with [[CedarX]] hardware accelerated video decoding, this experimental third-party port and the code patches have however not yet made it upstream into mainline XBMC.<ref>http://www.j1nx.nl/buildroot-xbmc-on-mele-a1000-allwinner-a10/ Buildroot XBMC on the Mele A1000 (Allwinner A10)</ref><ref>http://www.cnx-software.com/2012/11/12/xbmc-for-linux-on-allwinner-a10-devices-it-works-sort-of/ XBMC for Linux on AllWinner A10 Devices? It Works! (Sort of)</ref><br />
<br />
Pre-built application binaries of this port are not available so therefore you will need to compile XBMC yourself, at least until if and when the code makes it into the mainline XBMC upstream at http://xbmc.org<br />
<br />
Team-XBMC, the official development team of XBMC, does currently not recommend that any end-user buy Allwinner A10 or A20 based hardware for the specific purpose of only running XBMC since they do not have the resources to support this platform as of yet.<br />
<br />
More information about XBMC can be found on wikipedia http://en.wikipedia.org/wiki/XBMC and the XBMC wiki http://wiki.xbmc.org or http://forum.xbmc.org<br />
<br />
= Building XBMC for A10 and A20 =<br />
This is a little how-to of steps to compile XBMC for devices using Allwinner A10 and A20 SoCs (e.g. Mele A1000, Cubieboard, Banana Pi) based on Empat0's GitHub sources [http://github.com/empatzero/xbmca10 http://github.com/empatzero/xbmca10].<br />
The development work on the coding side was all done by Empat0 (a.k.a. empat zero). The used repository in the example below is however from [http://github.com/rellla/xbmca10 http://github.com/rellla/xbmca10] which is currently the newest and contains a few adaptions. It is a fork of empat0's work. <br />
<br />
The result should be a Debian armhf system with XBMC using [[CedarX]] for hardware accelerated video decoding.<br />
<br />
This version of XBMC runs directly on the framebuffer, and thus XServer is therefor not needed!<br />
<br />
== Prerequisites ==<br />
There are more ways to prepare a working rootfs for XBMC. You can either prepare the sdcard directly as described or you can chroot into the rootfs on your host system and sync it with your sdcard later when you have finished.<br />
So the following steps can also be done in a chroot on your host if you are cross-compiling.<br />
<br />
=== Prepare your SD-Card ===<br />
Create a bootable SD-Card follwing [[Manual_build_howto| our manual build howto]] and Debian. Be sure to use a kernel with mali-drivers-version r3p0 (sunxi-3.0 should be good).<br />
<br />
=== Boot into your target system ===<br />
Boot the new debian from the sd-card directly on the target and bring the system up to date:<br />
root@mele:~/# apt-get update<br />
root@mele:~/# apt-get upgrade<br />
<br />
=== Install the dependencies for XBMC (needs update!) ===<br />
root@mele:~/# apt-get build-dep xbmc<br />
<br />
this should install the following packages:<br />
autoconf automake autopoint autotools-dev binutils bsdmainutils build-essential bzip2 cmake cmake-data comerr-dev cpp cpp-4.4 cpp-4.6 curl<br />
debhelper dpkg-dev emacsen-common fontconfig-config g++ g++-4.4 g++-4.6 gawk gcc gcc-4.4 gcc-4.4-base gcc-4.6 gcc-4.6-base gettext<br />
gettext-base git git-man gperf groff-base html2text intltool-debian krb5-multidev libao-common libao-dev libao4 libarchive12 libasound2<br />
libasound2-dev libasprintf0c2 libass-dev libass4 libasyncns0 libavahi-client-dev libavahi-client3 libavahi-common-data libavahi-common-dev<br />
libavahi-common3 libavcodec-dev libavcodec53 libavfilter-dev libavfilter2 libavformat-dev libavformat53 libavutil-dev libavutil51<br />
libbluetooth-dev libbluetooth3 libbluray-dev libbluray1 libboost-date-time1.49-dev libboost-date-time1.49.0 libboost-dev<br />
libboost-serialization1.49-dev libboost-serialization1.49.0 libboost-thread-dev libboost-thread1.49-dev libboost-thread1.49.0<br />
libboost1.49-dev libbz2-dev libc-dev-bin libc6-dev libcaca-dev libcaca0 libcdio-dev libcdio13 libcec-dev libcec1 libcroco3 libcurl3<br />
libcurl3-gnutls libcurl4-gnutls-dev libcwiid-dev libcwiid1 libdbus-1-3 libdbus-1-dev libdirac-encoder0 libdirectfb-1.2-9 libdirectfb-dev<br />
libdirectfb-extra libdpkg-perl libdrm2 libelf1 libenca-dev libenca0 liberror-perl libexpat1 libexpat1-dev libflac-dev libflac8 libfontconfig1<br />
libfontconfig1-dev libfreetype6 libfreetype6-dev libfribidi-dev libfribidi0 libgcrypt11-dev libgettextpo0 libgl1-mesa-dev libgl1-mesa-glx<br />
libglapi-mesa libglew-dev libglew1.7 libglib2.0-bin libglib2.0-dev libglu1-mesa libglu1-mesa-dev libgmp10 libgnutls-dev libgnutls-openssl27<br />
libgnutlsxx27 libgomp1 libgpg-error-dev libgsm1 libgssrpc4 libhal-dev libhal-storage-dev libhal-storage1 libhal1 libice-dev libice6 libicu48<br />
libidn11-dev libiso9660-8 libiso9660-dev libjasper-dev libjasper1 libjbig-dev libjbig0 libjpeg8 libjpeg8-dev libjson0 libkadm5clnt-mit8<br />
libkadm5srv-mit8 libkdb5-6 libkrb5-dev liblcms1 libldap-2.4-2 libldap2-dev libltdl-dev libltdl7 liblzo2-2 liblzo2-dev libmad0 libmad0-dev<br />
libmicrohttpd-dev libmicrohttpd10 libmikmod2 libmikmod2-dev libmodplug-dev libmodplug1 libmp3lame-dev libmp3lame0 libmpc2 libmpeg2-4<br />
libmpeg2-4-dev libmpfr4 libmysqlclient-dev libmysqlclient18 libnettle4 libnfs-dev libnfs1 libogg-dev libogg0 libopencv-core2.3<br />
libopencv-imgproc2.3 libopenjpeg2 liborc-0.4-0 libp11-kit-dev libpcre3-dev libpcrecpp0 libpipeline1 libplist-dev libplist1 libpng12-0<br />
libpng12-dev libpopt0 libpostproc-dev libpostproc52 libpthread-stubs0 libpthread-stubs0-dev libpulse-dev libpulse-mainloop-glib0 libpulse0<br />
libpython2.7 librtmp-dev librtmp0 libsamplerate0 libsamplerate0-dev libsasl2-2 libschroedinger-1.0-0 libsdl-image1.2 libsdl-image1.2-dev<br />
libsdl-mixer1.2 libsdl-mixer1.2-dev libsdl1.2-dev libsdl1.2debian libshairport-dev libshairport1 libsigsegv2 libslang2-dev libsm-dev libsm6<br />
libsmbclient libsmbclient-dev libsndfile1 libspeex1 libsqlite3-0 libsqlite3-dev libssh2-1 libssh2-1-dev libssl-dev libstdc++6-4.4-dev<br />
libstdc++6-4.6-dev libswscale-dev libswscale2 libtalloc2 libtasn1-3-dev libtdb1 libtheora0 libtiff4 libtiff4-dev libtiffxx0c2<br />
libtimedate-perl libtinyxml-dev libtinyxml2.6.2 libtool libts-0.0-0 libts-dev libudev-dev libunistring0 libva-dev libva-egl1 libva-glx1<br />
libva-tpi1 libva-x11-1 libva1 libvdpau-dev libvdpau1 libvorbis-dev libvorbis0a libvorbisenc2 libvorbisfile3 libvpx1 libwbclient0 libwebp-dev<br />
libwebp2 libx11-dev libx11-xcb1 libx264-123 libxau-dev libxcb-glx0 libxcb1-dev libxdamage1 libxdmcp-dev libxext-dev libxfixes3 libxi6<br />
libxml2-dev libxmlrpc-core-c3 libxmu-dev libxmu-headers libxmu6 libxrandr-dev libxrandr2 libxrender-dev libxrender1 libxt-dev libxt6 libxtst6<br />
libxvidcore4 libxxf86vm1 libyajl-dev libyajl2 linux-libc-dev m4 make man-db mesa-common-dev mysql-common patch pkg-config po-debconf python<br />
python-dev python-imaging python-minimal python-support python2.7 python2.7-dev python2.7-minimal tsconf ttf-dejavu-core ucf x11-common<br />
x11proto-core-dev x11proto-input-dev x11proto-kb-dev x11proto-randr-dev x11proto-render-dev x11proto-xext-dev xorg-sgml-doctools xtrans-dev<br />
yasm zip zlib1g-dev<br />
<br />
need to install 3 more dependencies:<br />
root@mele:~/# apt-get install swig default-jre libgtk2.0-bin libssh-4 libssh-dev<br />
<br />
ensure you use hardware acceleration<br />
root@mele:~/# echo -e "\nA10HWR=1" >> /etc/environment (to set it permanently)<br />
<br />
Now go on with [[XBMC#Native_Compile_of_XBMC | Native Compile]] or [[XBMC#Cross_Compile_of_XBMC | Cross Compile]].<br />
<br />
== Native Compile of XBMC ==<br />
<br />
=== Prerequisites for native compile ===<br />
<br />
Create a swap-file, because otherwise the compiler runs out of memory during compiling and aborts<br />
root@mele:~/# dd if=/dev/zero of=/swap bs=1M count=384<br />
root@mele:~/# mkswap -c /swap<br />
root@mele:~/# swapon /swap<br />
<br />
Create your workspace directory:<br />
root@mele:~/# mkdir melehacking<br />
root@mele:~/# cd melehacking<br />
<br />
=== Checkout the source code ===<br />
root@mele:~/melehacking# apt-get install git<br />
root@mele:~/melehacking# git clone git://github.com/rellla/xbmca10.git<br />
root@mele:~/melehacking# cd xbmca10<br />
root@mele:~/melehacking/xbmca10# git checkout stage/Frodo<br />
<br />
=== Build ===<br />
The following external libs/ repos are used/ downloaded:<br />
* taglib: https://github.com/downloads/taglib/taglib/taglib-1.8.tar.gz<br />
* cedarx: https://github.com/linux-sunxi/cedarx-libs/tree/master/libcedarv/linux-armhf<br />
* libmad: ftp://ftp.mars.org/pub/mpeg/libmad-0.15.1b.tar.gz<br />
* mali: https://github.com/linux-sunxi/sunxi-mali-proprietary/tree/master/r3p0/armhf<br />
* mali-dev: https://github.com/linux-sunxi/sunxi-mali/tree/master/include<br />
<br />
Build dependencies<br />
root@mele:~/melehacking/xbmca10# cd tools/a10/depends<br />
root@mele:~/melehacking/xbmca10/tools/a10/depends# make<br />
Build xbmc itself<br />
root@mele:~/melehacking/xbmca10/tools/a10/depends# make -C xbmc<br />
root@mele:~/melehacking/xbmca10/tools/a10/depends# cd ../../../<br />
root@mele:~/melehacking/xbmca10# make install<br />
<br />
Move on to [[XBMC#Start_XBMC]] and start XBMC.<br />
<br />
== Cross Compile of XBMC ==<br />
This was tested with github.com/rellla/xbmca10 and built in Debian Sid as host. You will need several packages on the build system and a copy <br />
of the root file system of the target to build against. This howto assumes you are running off an SD card with the root file system in /dev/sdb2.<br />
=== Setup Cross Compiler ===<br />
* At first set up your [[Toolchain|toolchain]].<br />
<br />
=== Prerequisites for Cross Compiling ===<br />
* Sync and move SD card to build system<br />
* Mount the rootfs of the prepared SD Card<br />
root@debian:~/# mount /dev/sdb2 /mnt/rootfs-a10<br />
* Create symlinks to the mounted libraries<br />
root@debian:~/# ln -s /mnt/rootfs-a10/lib/arm-linux-gnueabihf /lib/arm-linux-gnueabihf<br />
root@debian:~/# ln -s /mnt/rootfs-a10/usr/lib/arm-linux-gnueabihf /usr/lib/arm-linux-gnueabihf<br />
root@debian:~/# ln -s /mnt/rootfs-a10/usr/include/arm-linux-gnueabihf /usr/include/arm-linux-gnueabihf<br />
* Install the dependencies for building XBMC on the host system<br />
root@debian:~/# apt-get build-dep xbmc<br />
root@debian:~/# apt-get install shtool swig default-jre<br />
Note: If compiling on a 64 bit system there is a known bug with the libcurl headers not working with 32 bit programs. To work around the problem build on a 32 bit system, or copy the file /usr/include/curl/curlbuild.h from a 32 bit system to your 64 bit build host.<br />
* Create your workspace directory:<br />
root@debian:~/# mkdir melehacking<br />
root@debian:~/# cd melehacking<br />
<br />
=== Checkout the source code ===<br />
root@debian:~/melehacking# git clone git://github.com/rellla/xbmca10.git<br />
root@debian:~/melehacking# cd xbmca10<br />
root@debian:~/melehacking/xbmca10# git checkout stage/Frodo<br />
<br />
=== Update XBMC build config ===<br />
Update this section at line 48 of tools/a10/depends/depends.mk with your values, e.g.<br />
#where is your arm rootfs<br />
SDKSTAGE=/mnt/rootfs-a10<br />
#where is your xbmc install root <br />
XBMCPREFIX=/allwinner/xbmc-pvr-bin$(HF)<br />
#where is your toolchain<br />
TOOLCHAIN=/usr/arm-linux-gnueabi$(HF)<br />
<br />
=== Build ===<br />
At this point the settings are basically the same for the native build:<br />
Build dependencies<br />
root@debian:~/melehacking/xbmca10# cd tools/a10/depends<br />
root@debian:~/melehacking/xbmca10/tools/a10/depends# make<br />
Build xbmc itself<br />
root@debian:~/melehacking/xbmca10/tools/a10/depends# make -C xbmc<br />
root@debian:~/melehacking/xbmca10/tools/a10/depends# cd ../../../<br />
root@debian:~/melehacking/xbmca10# make install<br />
<br />
=== Move XBMC to target system ===<br />
You should copy from your install location on your build system to an identical location on the target system (may not vital that they have the same path) like so ...<br />
root@debian:~/melehacking/xbmca10/cp -r /allwinner/xbmc-pvr-binhf /mnt/rootfs-a10/allwinner/xbmc-pvr-binhf<br />
<br />
To redistribute it, you can also create a tarball:<br />
root@debian:~/melehacking/xbmca10/tools/a10/depends# make -C package tarball<br />
This results in a xbmca10.tar.gz which includes all needed (and stripped) files in /allwinner/xbmc-pvr-binhf. This can easily be copied and extracted on the target rootfs.<br />
<br />
Umount your SD Card<br />
root@debian:~/melehacking/xbmca10# umount /dev/sdb2<br />
and boot it on your A10 Device.<br />
<br />
== Start XBMC ==<br />
After a reboot you modprobe the needed modules (depending on the used kernel version):<br />
root@mele:~/# modprobe disp<br />
root@mele:~/# modprobe lcd<br />
root@mele:~/# modprobe hdmi<br />
root@mele:~/# modprobe mali<br />
root@mele:~/# export A10HWR=1 (ensure to have this set if not rebooting!)<br />
root@mele:~/# cd /allwinner/xbmc-pvr-bin/lib/xbmc<br />
root@mele:/allwinner/xbmc-pvr-bin/lib/xbmc# ./xbmc.bin<br />
<br />
== Using the Android libraries via libhybris ==<br />
Due to some bugs in the native linux binaries of cedarx, ssvb succeeded to use libhybris and the Android binaries instead. This is the recommended way.<br />
See [[CedarX/libve]].<br />
<br />
== Troubleshooting ==<br />
* (native) If you get a compiler error when processing h264.o or building xbmc.bin, then check, if swap is enabled. The compiler ran out of memory!<br />
* (native) If deb-building fails, check, if your tmp-directory has enough free space and is no tmpfs, because of the lack of memory an mele.<br />
* To use the bash-script bin/xbmc to start xbmc, you have to comment out the exec of FEH.py, because of a failing test of glxinfo -> no display found.<br />
* Depending on your setup you may have to change some things to build<br />
* If mysql_config is not found, even though it is clearly there you can set disable-mysql in Makefile under xbmca10/tools/a10/depends/xbmc<br />
* Header files might not be where they are expected, this can be fixed with symlinks and copying headers, for example...<br />
ln -s usr/include/dbus1.0/dbus usr/include/dbus <br />
* Once you get in trouble with some mesa conflicts, ensure to not have installed the following packages on your target system: <br />
libegl1-mesa libegl1-mesa-dev libegl1-mesa-drivers libgles2-mesa libgles2-mesa-dev<br />
* Check the discussion section for more notes.<br />
* Ensure that you have installed ALL of the dependencies, header files etc. in your target rootfs and ensure that they are available during build. The build script does not search for them on your host-rootfs!<br />
<br />
= Configuring XBMC dependencies for Linux on A10 based devices =<br />
== Getting IR (infrared) remotes working on A10 based media players ==<br />
For getting IR (infrared) remote controls working on the A10 based media players, please see the [[LIRC (Linux Infrared Remote Control) for the IR receivers and and remotes]] article in this wiki. Place a suitable [[Lircmap.xml]] in userdata-directory.<br />
<br />
= Enabling dirty regions (a.k.a. dirty textures) for XBMC =<br />
This dirty region (a.k.a. dirty texture) feature in XBMC is designed to improve XBMC's GUI renderer performance on the GPU by only drawing when something like a texture changes on the screen, that region is then marked as dirty by XBMC's GUI library and only that region is redraw region on the screen.<br />
<br />
This feature is however still a little buggy and therefor not enabled by default in XBMC, but all users of XBMC on A10 based devices can try enabling the hidden "dirty regions" (a.k.a. "dirty textures") rendering feature advanced setting themselves manually. <br />
<br />
* http://wiki.xbmc.org/index.php?title=HOW-TO:Enable_dirty_regions<br />
* http://xbmc.org/theuni/2011/06/19/working-with-dirty-regions/<br />
* http://wiki.xbmc.org/index.php?title=Advancedsettings.xml#.3Calgorithmdirtyregions.3E<br />
<br />
Dirty regions are any parts of the screen that have changed since the last frame. By not re-rendering what hasn't changed, big speed gains can be seen. Because all GPUs work differently, only Mode 3, combined with nofliptimeout=0, is guaranteed to be safe for everyone, but current timing issues with nofliptimeout keep this from being the default. Note that with "dirty regions" your system CPU usage might go up a little (because it is doing the dirty regions calculations) but your GPU usage will be much lower, and since it is the GPU and not CPU that is the bottleneck in XBMC for embedded systems your GUI performance will be better even though the CPU usage is higher.<br />
<br />
{| class="wikitable"<br />
! value !! result !! description<br />
|-<br />
! 0<br />
| Off<br />
| The entire viewport is always rendered, which is the same as having the dirty regions feature disabled. This is the default mode.<br />
|-<br />
! 1<br />
|Union<br />
|All dirty regions are grouped into the smallest possible rectangle. This is typically the fastest mode for slower GPUs due to only making one pass.<br />
|-<br />
! 2<br />
|Cost reduction<br />
| Each dirty region is presented separately, in as many passes as there are regions.<br />
|-<br />
! 3<br />
|Whole Screen<br />
| The entire screen is rendered if there are any dirty regions. This, combined with nofliptimeout is a safe default for drivers that clear buffer contents (manifests as blinking or vibrating images)<br />
|}<br />
<br />
To enable dirty regions manually you need to create a "advancedsettings.xml" text file youself and put the XML <algorithmdirtyregions> enabling tags in there and copying to your "/userdata/" folder (/home/username/.xbmc/userdata/).<br />
<br />
Example:<br />
<code><br />
<gui> <br />
<algorithmdirtyregions>1</algorithmdirtyregions><br />
</gui><br />
</code><br />
<br />
You could also try to enable the <nofliptimeout> feature but that is even more experimental so know that it can cause even more GUI rendering issues in XBMC<br />
<br />
Example: <br />
<code><br />
<gui> <br />
<nofliptimeout>1000</nofliptimeout><br />
</gui><br />
</code><br />
<br />
To have both of these enabled your "advancedsettings.xml" then the finished file should look something like this:<br />
<br />
<code><br />
<advancedsettings><br />
<gui> <br />
<algorithmdirtyregions>1</algorithmdirtyregions><br />
<nofliptimeout>1000</nofliptimeout><br />
</gui><br />
</advancedsettings><br />
</code><br />
<br />
=Sources implementing A10 on XBMC=<br />
* [https://github.com/empatzero/xbmca10 https://github.com/empatzero/xbmca10]<br />
** [https://github.com/rellla/xbmca10 https://github.com/rellla/xbmca10] Recommended fork of empatzero ([http://pastebin.com/M4Di5tha Diff to upstream])<br />
** [https://github.com/vidonme/xbmc/ https://github.com/vidonme/xbmc/] Sources of [http://www.vidon.me/download.html VidOn.Me Player]? Seems to be a fork from empatzero. ([http://pastebin.com/LuQ4AB9J Diff to upstream] and [https://github.com/vidonme/xbmc/compare/xbmc:7b9ab8a85fd2b6030e6cf2659ff16380afef3996...master Github Compare]) This repo is reported from VidOn.me to be the "official" source code for their Allwinner XBMC version. The only commit from VidOn.me is [https://github.com/vidonme/xbmc/commit/b2b1696e8eb6617da07e0a043ca6ef2219ca080d#diff-2c44bd39cfe6b4185fe6a51b78c46cd0R122 this one]. <br />
* [https://github.com/huceke/xbmc/tree/allwinner https://github.com/huceke/xbmc/tree/allwinner] Gimli's implementation ([http://pastebin.com/Nu3DrfNK Diff to upstream])<br />
<br />
=References=<br />
<references /><br />
<br />
= See also =<br />
* [[CedarX]] - Library for Allwinner CedarX VPU (Video Processor Unit) used for audio and video decoding and encoding hardware off-loading on A1x and A2x SoC series.<br />
** [[CedarXVideoRenderingChart]] - Overview chart of working/ non working video files<br />
* [[LIRC (Linux Infrared Remote Control) for the IR receivers and and remotes]]<br />
* [[Tvheadend TV Tuner Server and PVR backend]]<br />
<br />
=External Links=<br />
* [http://forum.xbmc.org/showthread.php?tid=126995 XBMC Official Community Forum discussion about porting to Allwinner A10]<br />
* [http://jas-hacks.blogspot.co.uk/2012/11/hackberry-a10-xbmc.html Jas Hacks Hackberry A10 - XBMC on Ubuntu 12.10 image]<br />
* [http://www.j1nx.nl/buildroot-xbmc-on-mele-a1000-allwinner-a10/ Buildroot XBMC on the Mele A1000 (Allwinner A10)]<br />
* [http://www.cnx-software.com/2012/11/12/xbmc-for-linux-on-allwinner-a10-devices-it-works-sort-of/ XBMC for Linux on AllWinner A10 Devices? It Works! (Sort of)]<br />
<br />
[[Category:Software]]<br />
[[Category:Tutorial]]<br />
[[Category:CedarX]]</div>Rockerhttps://linux-sunxi.org/index.php?title=Main_Page&diff=10089Main Page2014-07-30T15:19:11Z<p>Rocker: /* What is sunxi */</p>
<hr />
<div>Welcome to the wiki of the [[:Category:Community | linux-sunxi community]], an open source software community dedicated to Allwinner SoC based [[:Category:Devices|devices]].<br />
<br />
<div style="float:right; margin-left:1em;">__TOC__</div><br />
<br />
= What is sunxi =<br />
<br />
'''sunxi''' represents the family of ARM SoCs from [[Allwinner|Allwinner Technology]], a fabless chinese semiconductor company. Their best known products are the '''sunxi''' SoC series, such as the A10 (sun4i), A13 (sun5i) and A20 (sun7i) chips, which were very successful in the low budget tablet market. See [[Allwinner SoC Family]] for more information on the different Allwinner chips.<br />
<br />
= Community =<br />
The [[:Category:Community|sunxi community]] is a very active and advanced one. For more information, check our [[:Category:Community|linux-sunxi community page]]. It explains how to get help and how to contact us, and how you can contribute as well.<br />
<br />
[[Allwinner]] does not actively participate in or support this community. In fact, it is [[GPL_Violations|violating the GPLv2 license]] in several ways and has so far not shown willingness to resolve this.<br />
<br />
= Allwinner based devices =<br />
Due to the popularity of the cheap Allwinner SoCs, there are literally thousands of different devices out there.<br />
<br />
If you are looking for support for your device from the [[:Category:Community|sunxi community]] here, please take a look at our [[Identification_guide | guide to identifying your device]]. If you cannot find your device, then you might need to work through our [[New_Device_howto| new device howto]].<br />
<br />
If you are interested in buying an Allwinner SoC based device, then read through our [[Buying_guide | buying guide]].<br />
<br />
= Documentation =<br />
== Quick reference guide ==<br />
<br />
{| class="wikitable"<br />
|- style="vertical-align: top; text-align:center;"<br />
!| Software<br />
!| Hardware<br />
|- style="vertical-align: top;"<br />
|<br />
* [[Bootable OS images]]: Complete ready-to-use SD card images<br />
* [[BSP|Board Support Package (BSP)]]: A scripted way to create images and SD-Cards.<br />
* [[Manual_build_howto|Manual build howto]]: Getting a specific U-Boot, Linux kernel, and a rootfs on an SD card.<br />
* [[sunxi-tools]]: Tools to help hacking sunxi devices<br />
* [[Packages]]: The linux-sunxi package repository<br />
* [[Linux Kernel]]: Kernel repositories and versions<br />
<categorytree mode=pages hideroot=off depth=0>Linux Distributions</categorytree><br />
<categorytree mode=pages hideroot=off depth=0>Android</categorytree><br />
<categorytree mode=pages hideroot=off depth=0>BSD</categorytree><br />
<categorytree mode=pages hideroot=off depth=0>Software</categorytree><br />
<categorytree mode=pages hideroot=off depth=0>Proprietary Software</categorytree><br />
<categorytree mode=pages hideroot=off depth=0>Development</categorytree><br />
|<br />
<categorytree mode=pages hideroot=off depth=0>Register guide</categorytree><br />
<categorytree mode=pages hideroot=off depth=0>CedarX</categorytree><br />
* [[Used IP cores]] - used IP cores in current generation SoCs<br />
* [[JTAG]] on A10 devices through µSD port<br />
* [[GPIO]] - General Purpose Input/Output<br />
* [[PIO]] - Programmed input/output<br />
* [[MicroSD Breakout]]<br />
* [[Audio Codec]]<br />
* [[CSI]] - Camera Sensor Interface<br />
* [[Cpufreq]]<br />
* [[Wifi]]<br />
* [[I2Cdev]] - I2c communication in the userspace.<br />
* [[SPIdev]] - SPI communication in the userspace.<br />
* [[1-Wire]] - 1-Wire communication in the userspace.<br />
|}<br />
<br />
== Tutorials ==<br />
This wiki includes some fine tutorials. Please consider improving them.<br />
<categorytree mode=pages hideroot=off depth=0>Tutorial</categorytree></div>Rockerhttps://linux-sunxi.org/index.php?title=CedarX&diff=10088CedarX2014-07-30T15:16:44Z<p>Rocker: </p>
<hr />
<div>[[CedarX]] is Allwinner's multimedia co-processing VPU (Video Processor Unit) technology for hardware accelerated video and image decoding, as used inside their [[A10]], [[A10s]], [[A13]], [[A20]], and [[A23]] SoC series.<ref>http://www.j1nx.nl/buildroot-xbmc-on-mele-a1000-allwinner-a10/ Buildroot XBMC on the Mele A1000 (Allwinner A10)</ref><ref>http://www.cnx-software.com/2012/11/12/xbmc-for-linux-on-allwinner-a10-devices-it-works-sort-of/ XBMC for Linux on AllWinner A10 Devices? It Works! (Sort of)</ref><br />
<br />
=Overview=<br />
'''CedarX''' is composed of several parts, including:<br />
* A hardware video unit (video engine or "VE" for short)<br />
** Varous Features<br />
*** Adaptive Motion Filter<br />
*** 3D Anaglyph decoding<br />
** MPEG Decoder SubEngine <br />
*** MPEG1 <br />
*** MPEG2<br />
*** MPEG4<br />
*** MS-MPEG<br />
*** VP6<br />
*** MJPEG (JPEG)<br />
*** XDIV/DIVX (mpeg 3.11)<br />
*** Soreson<br />
** H264 Decoder SubEngine <br />
*** H264 <br />
*** VP8<br />
*** AVS Jizun<br />
** VC1 Decoder SubEngine<br />
*** WMV9<br />
** RMVB SubEngine<br />
*** Real Media<br />
** ISP Engine (Image signal processor) <br />
*** Alpha blending{need check}<br />
*** Non-integer resize<br />
** AVC Encoder SubEngine<br />
*** H264 Encode<br />
*** JPEG Encode<br />
*** MPEG Encode {need check}<br />
* A hardware audio codec engine (ACE) (only A10, modern A20,A13 have no this module)<br />
** Audio engines<br />
*** DTS Audio hardware decoder<br />
*** AC3 Audio hardware decoder<br />
** Codec engines<br />
*** PNG (zlib's deflate offload)<br />
*** TSCC Codec(zlib's deflate offload)<br />
<br />
==== Benefits to Allwinner's CedarX technology and libraries:====<br />
* Efficient use of system resources when decoding multimedia, offloading audio and video decoding to CedarX co-processor so that the CPU can be used for other things, (when CedarX is working as it as it should).<br />
* Allows small and low-powered ARM systems to playback high resolution/bitrate multimedia content, which would not be possible using software-only decoding using only the CPU.<br />
<br />
==== Disadvantages Allwinner's CedarX technology and libraries:====<br />
* Allwinner's own CedarX proprietary libraries have no clear usage license, so even if the source code for some versions is available the terms-of-use is unknown in open source software.<br />
* The Android glue code is implemented as a "media player" (parallel to the official Android's MediaCodec API and underlying Stagefright multimedia framework) instead of as standard OpenMAX (OMX) components and API's.<br />
* This "media player" has limitations when it comes to playing back content pointed to by Android URIs and some web-based content.<br />
* There is no glue code for any other multimedia frameworks on GNU/Linux systems. The use of OpenMAX (OMX) instead would have rendered this a non-issue, with existing projects like GstOpenMAX (GStreamer OpenMAX).<br />
<br />
= Reverse engineering =<br />
The video engine is current being reverse engineered with successful results. To the point of making possible an experimental vdpau implementation capable of be used to play videos.<br />
* [[CedarX/Reverse Engineering|Reverse engineering status]]<br />
* Video Engine (VE) [[VE Register guide]]<br />
* Audio Codec Engine (ACE) [[ACE Register guide]]<br />
* A basic tutorial to help get users started in using [[Cedrus|Cedrus/libvdpau-sunxi]].<br />
<br />
= Integration =<br />
* [[XBMC]]<br />
* [[VLC]]<br />
<br />
=CedarX official source code libraries and third-party forks=<br />
* https://github.com/allwinner-dev-team/android_external_cedarx Allwinner Dev Team Android external CedarX fork<br />
* https://github.com/linux-sunxi/cedarx-libs linux-sunxi team fork of the official Allwinner CedarX libcedar source code libraries<br />
* https://github.com/huceke/libcedar libcedar decoder library for libvecore by Edgar Hucek (a.k.a. Gimli) fork for [[XBMC]]<br />
* https://github.com/willswang/libcedarx Wills Wang libcedarx library for libvecore fork for [[VLC]]<br />
* https://github.com/mortaromarcello/android_external_cedarx Android external CedarX fork by mortaromarcello<br />
<br />
= Possibly irrelevant observations =<br />
* There seems to be a distinction in the Android code between audio decoding ("CedarA") and video decoding ("CedarV").<br />
<br />
=References=<br />
<references /><br />
<br />
= See also =<br />
* [[CedarX/Misc Docs]] - some useful facts from IRC chat conversations<br />
* [[CedarXVideoRenderingChart]] - Overview chart of working/ non working video files<br />
* [[CedarX/libve]] - Using the Android blob on linux via libhybris<br />
* [[XBMC]] - XBMC Media Center<br />
* [[VLC]] - VideoLAN Client<br />
* [[CedarXPlayerTest]] - Testing player from Ubuntu image<br />
[[Category:CedarX]]</div>Rockerhttps://linux-sunxi.org/index.php?title=CedarX/XBMC&diff=10087CedarX/XBMC2014-07-30T15:16:17Z<p>Rocker: </p>
<hr />
<div><div style="color:#6F0000; border: 3px dashed #BF4F4F; padding: 2em;"><big><br />
'''XBMC for linux on Allwinner devices is NOT READY FOR USE!'''<br />
<br />
This is only a hack intended for developers and curious users at the moment. Don't expect it to work as you want it! Hardware is capable to make it run quite good in the future, but software and drivers are not ready yet. The [[:Category:Community|sunxi-community]] is working towards making a smooth XBMC experience possible.<br />
<br />
If you want to help developing the needed components to have a stable XBMC in the future, join the [[:Category:Community|irc and mailing list]]. Developers wanted!</big></div><br />
<br/><br />
<br />
XBMC is a popular media center software with 10-foot interface designed for large-screen televisions, and it enables ARM-based media players and set-top boxes like those with Allwinner SoCs with [[CedarX]] VPU (Video Processor Unit) to hardware decode and play high-definition videos, music, and other digital media files from local and network storage media, as well as stream podcasts, videocasts, and such of the internet.<br />
<br />
This article contain instructions on compiling and developing XBMC on and for Allwinner SoCs that features the [[CedarX]] VPU, like [[A10]], [[A10s]], [[A13]], [[A20]], and [[A23]]. Note that these instructions are specifically only meant for developers and advanced or expert Linux users that can actively assist with the porting process.<br />
<br />
=Overview=<br />
XBMC has already have an initial port for the A10 / A20 SoC with [[CedarX]] hardware accelerated video decoding, this experimental third-party port and the code patches have however not yet made it upstream into mainline XBMC.<ref>http://www.j1nx.nl/buildroot-xbmc-on-mele-a1000-allwinner-a10/ Buildroot XBMC on the Mele A1000 (Allwinner A10)</ref><ref>http://www.cnx-software.com/2012/11/12/xbmc-for-linux-on-allwinner-a10-devices-it-works-sort-of/ XBMC for Linux on AllWinner A10 Devices? It Works! (Sort of)</ref><br />
<br />
Pre-built application binaries of this port are not available so therefore you will need to compile XBMC yourself, at least until if and when the code makes it into the mainline XBMC upstream at http://xbmc.org<br />
<br />
Team-XBMC, the official development team of XBMC, does currently not recommend that any end-user buy Allwinner A10 or A20 based hardware for the specific purpose of only running XBMC since they do not have the resources to support this platform as of yet.<br />
<br />
More information about XBMC can be found on wikipedia http://en.wikipedia.org/wiki/XBMC and the XBMC wiki http://wiki.xbmc.org or http://forum.xbmc.org<br />
<br />
= Building XBMC for A10 and A20 =<br />
This is a little how-to of steps to compile XBMC for devices using Allwinner A10 and A20 SoCs (e.g. Mele A1000, Cubieboard, Banana Pi) based on Empat0's GitHub sources [http://github.com/empatzero/xbmca10 http://github.com/empatzero/xbmca10].<br />
The development work on the coding side was all done by Empat0 (a.k.a. empat zero). The used repository in the example below is however from [http://github.com/rellla/xbmca10 http://github.com/rellla/xbmca10] which is currently the newest and contains a few adaptions. It is a fork of empat0's work. <br />
<br />
The result should be a Debian armhf system with XBMC using [[CedarX]] for hardware accelerated video decoding.<br />
<br />
This version of XBMC runs directly on the framebuffer, and thus XServer is therefor not needed!<br />
<br />
== Prerequisites ==<br />
There are more ways to prepare a working rootfs for XBMC. You can either prepare the sdcard directly as described or you can chroot into the rootfs on your host system and sync it with your sdcard later when you have finished.<br />
So the following steps can also be done in a chroot on your host if you are cross-compiling.<br />
<br />
=== Prepare your SD-Card ===<br />
Create a bootable SD-Card follwing [[Manual_build_howto| our manual build howto]] and Debian. Be sure to use a kernel with mali-drivers-version r3p0 (sunxi-3.0 should be good).<br />
<br />
=== Boot into your target system ===<br />
Boot the new debian from the sd-card directly on the target and bring the system up to date:<br />
root@mele:~/# apt-get update<br />
root@mele:~/# apt-get upgrade<br />
<br />
=== Install the dependencies for XBMC (needs update!) ===<br />
root@mele:~/# apt-get build-dep xbmc<br />
<br />
this should install the following packages:<br />
autoconf automake autopoint autotools-dev binutils bsdmainutils build-essential bzip2 cmake cmake-data comerr-dev cpp cpp-4.4 cpp-4.6 curl<br />
debhelper dpkg-dev emacsen-common fontconfig-config g++ g++-4.4 g++-4.6 gawk gcc gcc-4.4 gcc-4.4-base gcc-4.6 gcc-4.6-base gettext<br />
gettext-base git git-man gperf groff-base html2text intltool-debian krb5-multidev libao-common libao-dev libao4 libarchive12 libasound2<br />
libasound2-dev libasprintf0c2 libass-dev libass4 libasyncns0 libavahi-client-dev libavahi-client3 libavahi-common-data libavahi-common-dev<br />
libavahi-common3 libavcodec-dev libavcodec53 libavfilter-dev libavfilter2 libavformat-dev libavformat53 libavutil-dev libavutil51<br />
libbluetooth-dev libbluetooth3 libbluray-dev libbluray1 libboost-date-time1.49-dev libboost-date-time1.49.0 libboost-dev<br />
libboost-serialization1.49-dev libboost-serialization1.49.0 libboost-thread-dev libboost-thread1.49-dev libboost-thread1.49.0<br />
libboost1.49-dev libbz2-dev libc-dev-bin libc6-dev libcaca-dev libcaca0 libcdio-dev libcdio13 libcec-dev libcec1 libcroco3 libcurl3<br />
libcurl3-gnutls libcurl4-gnutls-dev libcwiid-dev libcwiid1 libdbus-1-3 libdbus-1-dev libdirac-encoder0 libdirectfb-1.2-9 libdirectfb-dev<br />
libdirectfb-extra libdpkg-perl libdrm2 libelf1 libenca-dev libenca0 liberror-perl libexpat1 libexpat1-dev libflac-dev libflac8 libfontconfig1<br />
libfontconfig1-dev libfreetype6 libfreetype6-dev libfribidi-dev libfribidi0 libgcrypt11-dev libgettextpo0 libgl1-mesa-dev libgl1-mesa-glx<br />
libglapi-mesa libglew-dev libglew1.7 libglib2.0-bin libglib2.0-dev libglu1-mesa libglu1-mesa-dev libgmp10 libgnutls-dev libgnutls-openssl27<br />
libgnutlsxx27 libgomp1 libgpg-error-dev libgsm1 libgssrpc4 libhal-dev libhal-storage-dev libhal-storage1 libhal1 libice-dev libice6 libicu48<br />
libidn11-dev libiso9660-8 libiso9660-dev libjasper-dev libjasper1 libjbig-dev libjbig0 libjpeg8 libjpeg8-dev libjson0 libkadm5clnt-mit8<br />
libkadm5srv-mit8 libkdb5-6 libkrb5-dev liblcms1 libldap-2.4-2 libldap2-dev libltdl-dev libltdl7 liblzo2-2 liblzo2-dev libmad0 libmad0-dev<br />
libmicrohttpd-dev libmicrohttpd10 libmikmod2 libmikmod2-dev libmodplug-dev libmodplug1 libmp3lame-dev libmp3lame0 libmpc2 libmpeg2-4<br />
libmpeg2-4-dev libmpfr4 libmysqlclient-dev libmysqlclient18 libnettle4 libnfs-dev libnfs1 libogg-dev libogg0 libopencv-core2.3<br />
libopencv-imgproc2.3 libopenjpeg2 liborc-0.4-0 libp11-kit-dev libpcre3-dev libpcrecpp0 libpipeline1 libplist-dev libplist1 libpng12-0<br />
libpng12-dev libpopt0 libpostproc-dev libpostproc52 libpthread-stubs0 libpthread-stubs0-dev libpulse-dev libpulse-mainloop-glib0 libpulse0<br />
libpython2.7 librtmp-dev librtmp0 libsamplerate0 libsamplerate0-dev libsasl2-2 libschroedinger-1.0-0 libsdl-image1.2 libsdl-image1.2-dev<br />
libsdl-mixer1.2 libsdl-mixer1.2-dev libsdl1.2-dev libsdl1.2debian libshairport-dev libshairport1 libsigsegv2 libslang2-dev libsm-dev libsm6<br />
libsmbclient libsmbclient-dev libsndfile1 libspeex1 libsqlite3-0 libsqlite3-dev libssh2-1 libssh2-1-dev libssl-dev libstdc++6-4.4-dev<br />
libstdc++6-4.6-dev libswscale-dev libswscale2 libtalloc2 libtasn1-3-dev libtdb1 libtheora0 libtiff4 libtiff4-dev libtiffxx0c2<br />
libtimedate-perl libtinyxml-dev libtinyxml2.6.2 libtool libts-0.0-0 libts-dev libudev-dev libunistring0 libva-dev libva-egl1 libva-glx1<br />
libva-tpi1 libva-x11-1 libva1 libvdpau-dev libvdpau1 libvorbis-dev libvorbis0a libvorbisenc2 libvorbisfile3 libvpx1 libwbclient0 libwebp-dev<br />
libwebp2 libx11-dev libx11-xcb1 libx264-123 libxau-dev libxcb-glx0 libxcb1-dev libxdamage1 libxdmcp-dev libxext-dev libxfixes3 libxi6<br />
libxml2-dev libxmlrpc-core-c3 libxmu-dev libxmu-headers libxmu6 libxrandr-dev libxrandr2 libxrender-dev libxrender1 libxt-dev libxt6 libxtst6<br />
libxvidcore4 libxxf86vm1 libyajl-dev libyajl2 linux-libc-dev m4 make man-db mesa-common-dev mysql-common patch pkg-config po-debconf python<br />
python-dev python-imaging python-minimal python-support python2.7 python2.7-dev python2.7-minimal tsconf ttf-dejavu-core ucf x11-common<br />
x11proto-core-dev x11proto-input-dev x11proto-kb-dev x11proto-randr-dev x11proto-render-dev x11proto-xext-dev xorg-sgml-doctools xtrans-dev<br />
yasm zip zlib1g-dev<br />
<br />
need to install 3 more dependencies:<br />
root@mele:~/# apt-get install swig default-jre libgtk2.0-bin libssh-4 libssh-dev<br />
<br />
ensure you use hardware acceleration<br />
root@mele:~/# echo -e "\nA10HWR=1" >> /etc/environment (to set it permanently)<br />
<br />
Now go on with [[XBMC#Native_Compile_of_XBMC | Native Compile]] or [[XBMC#Cross_Compile_of_XBMC | Cross Compile]].<br />
<br />
== Native Compile of XBMC ==<br />
<br />
=== Prerequisites for native compile ===<br />
<br />
Create a swap-file, because otherwise the compiler runs out of memory during compiling and aborts<br />
root@mele:~/# dd if=/dev/zero of=/swap bs=1M count=384<br />
root@mele:~/# mkswap -c /swap<br />
root@mele:~/# swapon /swap<br />
<br />
Create your workspace directory:<br />
root@mele:~/# mkdir melehacking<br />
root@mele:~/# cd melehacking<br />
<br />
=== Checkout the source code ===<br />
root@mele:~/melehacking# apt-get install git<br />
root@mele:~/melehacking# git clone git://github.com/rellla/xbmca10.git<br />
root@mele:~/melehacking# cd xbmca10<br />
root@mele:~/melehacking/xbmca10# git checkout stage/Frodo<br />
<br />
=== Build ===<br />
The following external libs/ repos are used/ downloaded:<br />
* taglib: https://github.com/downloads/taglib/taglib/taglib-1.8.tar.gz<br />
* cedarx: https://github.com/linux-sunxi/cedarx-libs/tree/master/libcedarv/linux-armhf<br />
* libmad: ftp://ftp.mars.org/pub/mpeg/libmad-0.15.1b.tar.gz<br />
* mali: https://github.com/linux-sunxi/sunxi-mali-proprietary/tree/master/r3p0/armhf<br />
* mali-dev: https://github.com/linux-sunxi/sunxi-mali/tree/master/include<br />
<br />
Build dependencies<br />
root@mele:~/melehacking/xbmca10# cd tools/a10/depends<br />
root@mele:~/melehacking/xbmca10/tools/a10/depends# make<br />
Build xbmc itself<br />
root@mele:~/melehacking/xbmca10/tools/a10/depends# make -C xbmc<br />
root@mele:~/melehacking/xbmca10/tools/a10/depends# cd ../../../<br />
root@mele:~/melehacking/xbmca10# make install<br />
<br />
Move on to [[XBMC#Start_XBMC]] and start XBMC.<br />
<br />
== Cross Compile of XBMC ==<br />
This was tested with github.com/rellla/xbmca10 and built in Debian Sid as host. You will need several packages on the build system and a copy <br />
of the root file system of the target to build against. This howto assumes you are running off an SD card with the root file system in /dev/sdb2.<br />
=== Setup Cross Compiler ===<br />
* At first set up your [[Toolchain|toolchain]].<br />
<br />
=== Prerequisites for Cross Compiling ===<br />
* Sync and move SD card to build system<br />
* Mount the rootfs of the prepared SD Card<br />
root@debian:~/# mount /dev/sdb2 /mnt/rootfs-a10<br />
* Create symlinks to the mounted libraries<br />
root@debian:~/# ln -s /mnt/rootfs-a10/lib/arm-linux-gnueabihf /lib/arm-linux-gnueabihf<br />
root@debian:~/# ln -s /mnt/rootfs-a10/usr/lib/arm-linux-gnueabihf /usr/lib/arm-linux-gnueabihf<br />
root@debian:~/# ln -s /mnt/rootfs-a10/usr/include/arm-linux-gnueabihf /usr/include/arm-linux-gnueabihf<br />
* Install the dependencies for building XBMC on the host system<br />
root@debian:~/# apt-get build-dep xbmc<br />
root@debian:~/# apt-get install shtool swig default-jre<br />
Note: If compiling on a 64 bit system there is a known bug with the libcurl headers not working with 32 bit programs. To work around the problem build on a 32 bit system, or copy the file /usr/include/curl/curlbuild.h from a 32 bit system to your 64 bit build host.<br />
* Create your workspace directory:<br />
root@debian:~/# mkdir melehacking<br />
root@debian:~/# cd melehacking<br />
<br />
=== Checkout the source code ===<br />
root@debian:~/melehacking# git clone git://github.com/rellla/xbmca10.git<br />
root@debian:~/melehacking# cd xbmca10<br />
root@debian:~/melehacking/xbmca10# git checkout stage/Frodo<br />
<br />
=== Update XBMC build config ===<br />
Update this section at line 48 of tools/a10/depends/depends.mk with your values, e.g.<br />
#where is your arm rootfs<br />
SDKSTAGE=/mnt/rootfs-a10<br />
#where is your xbmc install root <br />
XBMCPREFIX=/allwinner/xbmc-pvr-bin$(HF)<br />
#where is your toolchain<br />
TOOLCHAIN=/usr/arm-linux-gnueabi$(HF)<br />
<br />
=== Build ===<br />
At this point the settings are basically the same for the native build:<br />
Build dependencies<br />
root@debian:~/melehacking/xbmca10# cd tools/a10/depends<br />
root@debian:~/melehacking/xbmca10/tools/a10/depends# make<br />
Build xbmc itself<br />
root@debian:~/melehacking/xbmca10/tools/a10/depends# make -C xbmc<br />
root@debian:~/melehacking/xbmca10/tools/a10/depends# cd ../../../<br />
root@debian:~/melehacking/xbmca10# make install<br />
<br />
=== Move XBMC to target system ===<br />
You should copy from your install location on your build system to an identical location on the target system (may not vital that they have the same path) like so ...<br />
root@debian:~/melehacking/xbmca10/cp -r /allwinner/xbmc-pvr-binhf /mnt/rootfs-a10/allwinner/xbmc-pvr-binhf<br />
<br />
To redistribute it, you can also create a tarball:<br />
root@debian:~/melehacking/xbmca10/tools/a10/depends# make -C package tarball<br />
This results in a xbmca10.tar.gz which includes all needed (and stripped) files in /allwinner/xbmc-pvr-binhf. This can easily be copied and extracted on the target rootfs.<br />
<br />
Umount your SD Card<br />
root@debian:~/melehacking/xbmca10# umount /dev/sdb2<br />
and boot it on your A10 Device.<br />
<br />
== Start XBMC ==<br />
After a reboot you modprobe the needed modules (depending on the used kernel version):<br />
root@mele:~/# modprobe disp<br />
root@mele:~/# modprobe lcd<br />
root@mele:~/# modprobe hdmi<br />
root@mele:~/# modprobe mali<br />
root@mele:~/# export A10HWR=1 (ensure to have this set if not rebooting!)<br />
root@mele:~/# cd /allwinner/xbmc-pvr-bin/lib/xbmc<br />
root@mele:/allwinner/xbmc-pvr-bin/lib/xbmc# ./xbmc.bin<br />
<br />
== Using the Android libraries via libhybris ==<br />
Due to some bugs in the native linux binaries of cedarx, ssvb succeeded to use libhybris and the Android binaries instead. This is the recommended way.<br />
See [[CedarX/libve]].<br />
<br />
== Troubleshooting ==<br />
* (native) If you get a compiler error when processing h264.o or building xbmc.bin, then check, if swap is enabled. The compiler ran out of memory!<br />
* (native) If deb-building fails, check, if your tmp-directory has enough free space and is no tmpfs, because of the lack of memory an mele.<br />
* To use the bash-script bin/xbmc to start xbmc, you have to comment out the exec of FEH.py, because of a failing test of glxinfo -> no display found.<br />
* Depending on your setup you may have to change some things to build<br />
* If mysql_config is not found, even though it is clearly there you can set disable-mysql in Makefile under xbmca10/tools/a10/depends/xbmc<br />
* Header files might not be where they are expected, this can be fixed with symlinks and copying headers, for example...<br />
ln -s usr/include/dbus1.0/dbus usr/include/dbus <br />
* Once you get in trouble with some mesa conflicts, ensure to not have installed the following packages on your target system: <br />
libegl1-mesa libegl1-mesa-dev libegl1-mesa-drivers libgles2-mesa libgles2-mesa-dev<br />
* Check the discussion section for more notes.<br />
* Ensure that you have installed ALL of the dependencies, header files etc. in your target rootfs and ensure that they are available during build. The build script does not search for them on your host-rootfs!<br />
<br />
= Configuring XBMC dependencies for Linux on A10 based devices =<br />
== Getting IR (infrared) remotes working on A10 based media players ==<br />
For getting IR (infrared) remote controls working on the A10 based media players, please see the [[LIRC (Linux Infrared Remote Control) for the IR receivers and and remotes]] article in this wiki. Place a suitable [[Lircmap.xml]] in userdata-directory.<br />
<br />
= Enabling dirty regions (a.k.a. dirty textures) for XBMC =<br />
This dirty region (a.k.a. dirty texture) feature in XBMC is designed to improve XBMC's GUI renderer performance on the GPU by only drawing when something like a texture changes on the screen, that region is then marked as dirty by XBMC's GUI library and only that region is redraw region on the screen.<br />
<br />
This feature is however still a little buggy and therefor not enabled by default in XBMC, but all users of XBMC on A10 based devices can try enabling the hidden "dirty regions" (a.k.a. "dirty textures") rendering feature advanced setting themselves manually. <br />
<br />
* http://wiki.xbmc.org/index.php?title=HOW-TO:Enable_dirty_regions<br />
* http://xbmc.org/theuni/2011/06/19/working-with-dirty-regions/<br />
* http://wiki.xbmc.org/index.php?title=Advancedsettings.xml#.3Calgorithmdirtyregions.3E<br />
<br />
Dirty regions are any parts of the screen that have changed since the last frame. By not re-rendering what hasn't changed, big speed gains can be seen. Because all GPUs work differently, only Mode 3, combined with nofliptimeout=0, is guaranteed to be safe for everyone, but current timing issues with nofliptimeout keep this from being the default. Note that with "dirty regions" your system CPU usage might go up a little (because it is doing the dirty regions calculations) but your GPU usage will be much lower, and since it is the GPU and not CPU that is the bottleneck in XBMC for embedded systems your GUI performance will be better even though the CPU usage is higher.<br />
<br />
{| class="wikitable"<br />
! value !! result !! description<br />
|-<br />
! 0<br />
| Off<br />
| The entire viewport is always rendered, which is the same as having the dirty regions feature disabled. This is the default mode.<br />
|-<br />
! 1<br />
|Union<br />
|All dirty regions are grouped into the smallest possible rectangle. This is typically the fastest mode for slower GPUs due to only making one pass.<br />
|-<br />
! 2<br />
|Cost reduction<br />
| Each dirty region is presented separately, in as many passes as there are regions.<br />
|-<br />
! 3<br />
|Whole Screen<br />
| The entire screen is rendered if there are any dirty regions. This, combined with nofliptimeout is a safe default for drivers that clear buffer contents (manifests as blinking or vibrating images)<br />
|}<br />
<br />
To enable dirty regions manually you need to create a "advancedsettings.xml" text file youself and put the XML <algorithmdirtyregions> enabling tags in there and copying to your "/userdata/" folder (/home/username/.xbmc/userdata/).<br />
<br />
Example:<br />
<code><br />
<gui> <br />
<algorithmdirtyregions>1</algorithmdirtyregions><br />
</gui><br />
</code><br />
<br />
You could also try to enable the <nofliptimeout> feature but that is even more experimental so know that it can cause even more GUI rendering issues in XBMC<br />
<br />
Example: <br />
<code><br />
<gui> <br />
<nofliptimeout>1000</nofliptimeout><br />
</gui><br />
</code><br />
<br />
To have both of these enabled your "advancedsettings.xml" then the finished file should look something like this:<br />
<br />
<code><br />
<advancedsettings><br />
<gui> <br />
<algorithmdirtyregions>1</algorithmdirtyregions><br />
<nofliptimeout>1000</nofliptimeout><br />
</gui><br />
</advancedsettings><br />
</code><br />
<br />
=Sources implementing A10 on XBMC=<br />
* [https://github.com/empatzero/xbmca10 https://github.com/empatzero/xbmca10]<br />
** [https://github.com/rellla/xbmca10 https://github.com/rellla/xbmca10] Recommended fork of empatzero ([http://pastebin.com/M4Di5tha Diff to upstream])<br />
** [https://github.com/vidonme/xbmc/ https://github.com/vidonme/xbmc/] Sources of [http://www.vidon.me/download.html VidOn.Me Player]? Seems to be a fork from empatzero. ([http://pastebin.com/LuQ4AB9J Diff to upstream] and [https://github.com/vidonme/xbmc/compare/xbmc:7b9ab8a85fd2b6030e6cf2659ff16380afef3996...master Github Compare]) This repo is reported from VidOn.me to be the "official" source code for their Allwinner XBMC version. The only commit from VidOn.me is [https://github.com/vidonme/xbmc/commit/b2b1696e8eb6617da07e0a043ca6ef2219ca080d#diff-2c44bd39cfe6b4185fe6a51b78c46cd0R122 this one]. <br />
* [https://github.com/huceke/xbmc/tree/allwinner https://github.com/huceke/xbmc/tree/allwinner] Gimli's implementation ([http://pastebin.com/Nu3DrfNK Diff to upstream])<br />
<br />
=References=<br />
<references /><br />
<br />
= See also =<br />
* [[CedarX]] - Library for Allwinner A10 VPU (Video Processor Unit) used for audio and video decoding and encoding hardware off-loading.<br />
** [[CedarXVideoRenderingChart]] - Overview chart of working/ non working video files<br />
* [[LIRC (Linux Infrared Remote Control) for the IR receivers and and remotes]]<br />
* [[Tvheadend TV Tuner Server and PVR backend]]<br />
<br />
=External Links=<br />
* [http://forum.xbmc.org/showthread.php?tid=126995 XBMC Official Community Forum discussion about porting to Allwinner A10]<br />
* [http://jas-hacks.blogspot.co.uk/2012/11/hackberry-a10-xbmc.html Jas Hacks Hackberry A10 - XBMC on Ubuntu 12.10 image]<br />
* [http://www.j1nx.nl/buildroot-xbmc-on-mele-a1000-allwinner-a10/ Buildroot XBMC on the Mele A1000 (Allwinner A10)]<br />
* [http://www.cnx-software.com/2012/11/12/xbmc-for-linux-on-allwinner-a10-devices-it-works-sort-of/ XBMC for Linux on AllWinner A10 Devices? It Works! (Sort of)]<br />
<br />
[[Category:Software]]<br />
[[Category:Tutorial]]<br />
[[Category:CedarX]]</div>Rockerhttps://linux-sunxi.org/index.php?title=CedarX/XBMC&diff=10086CedarX/XBMC2014-07-30T15:14:17Z<p>Rocker: </p>
<hr />
<div><div style="color:#6F0000; border: 3px dashed #BF4F4F; padding: 2em;"><big><br />
'''XBMC for linux on Allwinner devices is NOT READY FOR USE!'''<br />
<br />
This is only a hack intended for developers and curious users at the moment. Don't expect it to work as you want it! Hardware is capable to make it run quite good in the future, but software and drivers are not ready yet. The [[:Category:Community|sunxi-community]] is working towards making a smooth XBMC experience possible.<br />
<br />
If you want to help developing the needed components to have a stable XBMC in the future, join the [[:Category:Community|irc and mailing list]]. Developers wanted!</big></div><br />
<br/><br />
<br />
XBMC is a popular media center software with 10-foot interface designed for large-screen televisions, and it enables ARM-based media players and set-top boxes like those with Allwinner SoCs with [[CedarX]] VPU (Video Processor Unit) to hardware decode and play high-definition videos, music, and other digital media files from local and network storage media, as well as stream podcasts, videocasts, and such of the internet.<br />
<br />
This article contain instructions on compiling and developing XBMC on and for Allwinner SoCs that features the [[CedarX]] VPU, like A10, A10s, A13, A20, and A23. Note that these instructions are specifically only meant for developers and advanced or expert Linux users that can actively assist with the porting process.<br />
<br />
=Overview=<br />
XBMC has already have an initial port for the A10 / A20 SoC with [[CedarX]] hardware accelerated video decoding, this experimental third-party port and the code patches have however not yet made it upstream into mainline XBMC.<ref>http://www.j1nx.nl/buildroot-xbmc-on-mele-a1000-allwinner-a10/ Buildroot XBMC on the Mele A1000 (Allwinner A10)</ref><ref>http://www.cnx-software.com/2012/11/12/xbmc-for-linux-on-allwinner-a10-devices-it-works-sort-of/ XBMC for Linux on AllWinner A10 Devices? It Works! (Sort of)</ref><br />
<br />
Pre-built application binaries of this port are not available so therefore you will need to compile XBMC yourself, at least until if and when the code makes it into the mainline XBMC upstream at http://xbmc.org<br />
<br />
Team-XBMC, the official development team of XBMC, does currently not recommend that any end-user buy Allwinner A10 or A20 based hardware for the specific purpose of only running XBMC since they do not have the resources to support this platform as of yet.<br />
<br />
More information about XBMC can be found on wikipedia http://en.wikipedia.org/wiki/XBMC and the XBMC wiki http://wiki.xbmc.org or http://forum.xbmc.org<br />
<br />
= Building XBMC for A10 and A20 =<br />
This is a little how-to of steps to compile XBMC for devices using Allwinner A10 and A20 SoCs (e.g. Mele A1000, Cubieboard, Banana Pi) based on Empat0's GitHub sources [http://github.com/empatzero/xbmca10 http://github.com/empatzero/xbmca10].<br />
The development work on the coding side was all done by Empat0 (a.k.a. empat zero). The used repository in the example below is however from [http://github.com/rellla/xbmca10 http://github.com/rellla/xbmca10] which is currently the newest and contains a few adaptions. It is a fork of empat0's work. <br />
<br />
The result should be a Debian armhf system with XBMC using [[CedarX]] for hardware accelerated video decoding.<br />
<br />
This version of XBMC runs directly on the framebuffer, and thus XServer is therefor not needed!<br />
<br />
== Prerequisites ==<br />
There are more ways to prepare a working rootfs for XBMC. You can either prepare the sdcard directly as described or you can chroot into the rootfs on your host system and sync it with your sdcard later when you have finished.<br />
So the following steps can also be done in a chroot on your host if you are cross-compiling.<br />
<br />
=== Prepare your SD-Card ===<br />
Create a bootable SD-Card follwing [[Manual_build_howto| our manual build howto]] and Debian. Be sure to use a kernel with mali-drivers-version r3p0 (sunxi-3.0 should be good).<br />
<br />
=== Boot into your target system ===<br />
Boot the new debian from the sd-card directly on the target and bring the system up to date:<br />
root@mele:~/# apt-get update<br />
root@mele:~/# apt-get upgrade<br />
<br />
=== Install the dependencies for XBMC (needs update!) ===<br />
root@mele:~/# apt-get build-dep xbmc<br />
<br />
this should install the following packages:<br />
autoconf automake autopoint autotools-dev binutils bsdmainutils build-essential bzip2 cmake cmake-data comerr-dev cpp cpp-4.4 cpp-4.6 curl<br />
debhelper dpkg-dev emacsen-common fontconfig-config g++ g++-4.4 g++-4.6 gawk gcc gcc-4.4 gcc-4.4-base gcc-4.6 gcc-4.6-base gettext<br />
gettext-base git git-man gperf groff-base html2text intltool-debian krb5-multidev libao-common libao-dev libao4 libarchive12 libasound2<br />
libasound2-dev libasprintf0c2 libass-dev libass4 libasyncns0 libavahi-client-dev libavahi-client3 libavahi-common-data libavahi-common-dev<br />
libavahi-common3 libavcodec-dev libavcodec53 libavfilter-dev libavfilter2 libavformat-dev libavformat53 libavutil-dev libavutil51<br />
libbluetooth-dev libbluetooth3 libbluray-dev libbluray1 libboost-date-time1.49-dev libboost-date-time1.49.0 libboost-dev<br />
libboost-serialization1.49-dev libboost-serialization1.49.0 libboost-thread-dev libboost-thread1.49-dev libboost-thread1.49.0<br />
libboost1.49-dev libbz2-dev libc-dev-bin libc6-dev libcaca-dev libcaca0 libcdio-dev libcdio13 libcec-dev libcec1 libcroco3 libcurl3<br />
libcurl3-gnutls libcurl4-gnutls-dev libcwiid-dev libcwiid1 libdbus-1-3 libdbus-1-dev libdirac-encoder0 libdirectfb-1.2-9 libdirectfb-dev<br />
libdirectfb-extra libdpkg-perl libdrm2 libelf1 libenca-dev libenca0 liberror-perl libexpat1 libexpat1-dev libflac-dev libflac8 libfontconfig1<br />
libfontconfig1-dev libfreetype6 libfreetype6-dev libfribidi-dev libfribidi0 libgcrypt11-dev libgettextpo0 libgl1-mesa-dev libgl1-mesa-glx<br />
libglapi-mesa libglew-dev libglew1.7 libglib2.0-bin libglib2.0-dev libglu1-mesa libglu1-mesa-dev libgmp10 libgnutls-dev libgnutls-openssl27<br />
libgnutlsxx27 libgomp1 libgpg-error-dev libgsm1 libgssrpc4 libhal-dev libhal-storage-dev libhal-storage1 libhal1 libice-dev libice6 libicu48<br />
libidn11-dev libiso9660-8 libiso9660-dev libjasper-dev libjasper1 libjbig-dev libjbig0 libjpeg8 libjpeg8-dev libjson0 libkadm5clnt-mit8<br />
libkadm5srv-mit8 libkdb5-6 libkrb5-dev liblcms1 libldap-2.4-2 libldap2-dev libltdl-dev libltdl7 liblzo2-2 liblzo2-dev libmad0 libmad0-dev<br />
libmicrohttpd-dev libmicrohttpd10 libmikmod2 libmikmod2-dev libmodplug-dev libmodplug1 libmp3lame-dev libmp3lame0 libmpc2 libmpeg2-4<br />
libmpeg2-4-dev libmpfr4 libmysqlclient-dev libmysqlclient18 libnettle4 libnfs-dev libnfs1 libogg-dev libogg0 libopencv-core2.3<br />
libopencv-imgproc2.3 libopenjpeg2 liborc-0.4-0 libp11-kit-dev libpcre3-dev libpcrecpp0 libpipeline1 libplist-dev libplist1 libpng12-0<br />
libpng12-dev libpopt0 libpostproc-dev libpostproc52 libpthread-stubs0 libpthread-stubs0-dev libpulse-dev libpulse-mainloop-glib0 libpulse0<br />
libpython2.7 librtmp-dev librtmp0 libsamplerate0 libsamplerate0-dev libsasl2-2 libschroedinger-1.0-0 libsdl-image1.2 libsdl-image1.2-dev<br />
libsdl-mixer1.2 libsdl-mixer1.2-dev libsdl1.2-dev libsdl1.2debian libshairport-dev libshairport1 libsigsegv2 libslang2-dev libsm-dev libsm6<br />
libsmbclient libsmbclient-dev libsndfile1 libspeex1 libsqlite3-0 libsqlite3-dev libssh2-1 libssh2-1-dev libssl-dev libstdc++6-4.4-dev<br />
libstdc++6-4.6-dev libswscale-dev libswscale2 libtalloc2 libtasn1-3-dev libtdb1 libtheora0 libtiff4 libtiff4-dev libtiffxx0c2<br />
libtimedate-perl libtinyxml-dev libtinyxml2.6.2 libtool libts-0.0-0 libts-dev libudev-dev libunistring0 libva-dev libva-egl1 libva-glx1<br />
libva-tpi1 libva-x11-1 libva1 libvdpau-dev libvdpau1 libvorbis-dev libvorbis0a libvorbisenc2 libvorbisfile3 libvpx1 libwbclient0 libwebp-dev<br />
libwebp2 libx11-dev libx11-xcb1 libx264-123 libxau-dev libxcb-glx0 libxcb1-dev libxdamage1 libxdmcp-dev libxext-dev libxfixes3 libxi6<br />
libxml2-dev libxmlrpc-core-c3 libxmu-dev libxmu-headers libxmu6 libxrandr-dev libxrandr2 libxrender-dev libxrender1 libxt-dev libxt6 libxtst6<br />
libxvidcore4 libxxf86vm1 libyajl-dev libyajl2 linux-libc-dev m4 make man-db mesa-common-dev mysql-common patch pkg-config po-debconf python<br />
python-dev python-imaging python-minimal python-support python2.7 python2.7-dev python2.7-minimal tsconf ttf-dejavu-core ucf x11-common<br />
x11proto-core-dev x11proto-input-dev x11proto-kb-dev x11proto-randr-dev x11proto-render-dev x11proto-xext-dev xorg-sgml-doctools xtrans-dev<br />
yasm zip zlib1g-dev<br />
<br />
need to install 3 more dependencies:<br />
root@mele:~/# apt-get install swig default-jre libgtk2.0-bin libssh-4 libssh-dev<br />
<br />
ensure you use hardware acceleration<br />
root@mele:~/# echo -e "\nA10HWR=1" >> /etc/environment (to set it permanently)<br />
<br />
Now go on with [[XBMC#Native_Compile_of_XBMC | Native Compile]] or [[XBMC#Cross_Compile_of_XBMC | Cross Compile]].<br />
<br />
== Native Compile of XBMC ==<br />
<br />
=== Prerequisites for native compile ===<br />
<br />
Create a swap-file, because otherwise the compiler runs out of memory during compiling and aborts<br />
root@mele:~/# dd if=/dev/zero of=/swap bs=1M count=384<br />
root@mele:~/# mkswap -c /swap<br />
root@mele:~/# swapon /swap<br />
<br />
Create your workspace directory:<br />
root@mele:~/# mkdir melehacking<br />
root@mele:~/# cd melehacking<br />
<br />
=== Checkout the source code ===<br />
root@mele:~/melehacking# apt-get install git<br />
root@mele:~/melehacking# git clone git://github.com/rellla/xbmca10.git<br />
root@mele:~/melehacking# cd xbmca10<br />
root@mele:~/melehacking/xbmca10# git checkout stage/Frodo<br />
<br />
=== Build ===<br />
The following external libs/ repos are used/ downloaded:<br />
* taglib: https://github.com/downloads/taglib/taglib/taglib-1.8.tar.gz<br />
* cedarx: https://github.com/linux-sunxi/cedarx-libs/tree/master/libcedarv/linux-armhf<br />
* libmad: ftp://ftp.mars.org/pub/mpeg/libmad-0.15.1b.tar.gz<br />
* mali: https://github.com/linux-sunxi/sunxi-mali-proprietary/tree/master/r3p0/armhf<br />
* mali-dev: https://github.com/linux-sunxi/sunxi-mali/tree/master/include<br />
<br />
Build dependencies<br />
root@mele:~/melehacking/xbmca10# cd tools/a10/depends<br />
root@mele:~/melehacking/xbmca10/tools/a10/depends# make<br />
Build xbmc itself<br />
root@mele:~/melehacking/xbmca10/tools/a10/depends# make -C xbmc<br />
root@mele:~/melehacking/xbmca10/tools/a10/depends# cd ../../../<br />
root@mele:~/melehacking/xbmca10# make install<br />
<br />
Move on to [[XBMC#Start_XBMC]] and start XBMC.<br />
<br />
== Cross Compile of XBMC ==<br />
This was tested with github.com/rellla/xbmca10 and built in Debian Sid as host. You will need several packages on the build system and a copy <br />
of the root file system of the target to build against. This howto assumes you are running off an SD card with the root file system in /dev/sdb2.<br />
=== Setup Cross Compiler ===<br />
* At first set up your [[Toolchain|toolchain]].<br />
<br />
=== Prerequisites for Cross Compiling ===<br />
* Sync and move SD card to build system<br />
* Mount the rootfs of the prepared SD Card<br />
root@debian:~/# mount /dev/sdb2 /mnt/rootfs-a10<br />
* Create symlinks to the mounted libraries<br />
root@debian:~/# ln -s /mnt/rootfs-a10/lib/arm-linux-gnueabihf /lib/arm-linux-gnueabihf<br />
root@debian:~/# ln -s /mnt/rootfs-a10/usr/lib/arm-linux-gnueabihf /usr/lib/arm-linux-gnueabihf<br />
root@debian:~/# ln -s /mnt/rootfs-a10/usr/include/arm-linux-gnueabihf /usr/include/arm-linux-gnueabihf<br />
* Install the dependencies for building XBMC on the host system<br />
root@debian:~/# apt-get build-dep xbmc<br />
root@debian:~/# apt-get install shtool swig default-jre<br />
Note: If compiling on a 64 bit system there is a known bug with the libcurl headers not working with 32 bit programs. To work around the problem build on a 32 bit system, or copy the file /usr/include/curl/curlbuild.h from a 32 bit system to your 64 bit build host.<br />
* Create your workspace directory:<br />
root@debian:~/# mkdir melehacking<br />
root@debian:~/# cd melehacking<br />
<br />
=== Checkout the source code ===<br />
root@debian:~/melehacking# git clone git://github.com/rellla/xbmca10.git<br />
root@debian:~/melehacking# cd xbmca10<br />
root@debian:~/melehacking/xbmca10# git checkout stage/Frodo<br />
<br />
=== Update XBMC build config ===<br />
Update this section at line 48 of tools/a10/depends/depends.mk with your values, e.g.<br />
#where is your arm rootfs<br />
SDKSTAGE=/mnt/rootfs-a10<br />
#where is your xbmc install root <br />
XBMCPREFIX=/allwinner/xbmc-pvr-bin$(HF)<br />
#where is your toolchain<br />
TOOLCHAIN=/usr/arm-linux-gnueabi$(HF)<br />
<br />
=== Build ===<br />
At this point the settings are basically the same for the native build:<br />
Build dependencies<br />
root@debian:~/melehacking/xbmca10# cd tools/a10/depends<br />
root@debian:~/melehacking/xbmca10/tools/a10/depends# make<br />
Build xbmc itself<br />
root@debian:~/melehacking/xbmca10/tools/a10/depends# make -C xbmc<br />
root@debian:~/melehacking/xbmca10/tools/a10/depends# cd ../../../<br />
root@debian:~/melehacking/xbmca10# make install<br />
<br />
=== Move XBMC to target system ===<br />
You should copy from your install location on your build system to an identical location on the target system (may not vital that they have the same path) like so ...<br />
root@debian:~/melehacking/xbmca10/cp -r /allwinner/xbmc-pvr-binhf /mnt/rootfs-a10/allwinner/xbmc-pvr-binhf<br />
<br />
To redistribute it, you can also create a tarball:<br />
root@debian:~/melehacking/xbmca10/tools/a10/depends# make -C package tarball<br />
This results in a xbmca10.tar.gz which includes all needed (and stripped) files in /allwinner/xbmc-pvr-binhf. This can easily be copied and extracted on the target rootfs.<br />
<br />
Umount your SD Card<br />
root@debian:~/melehacking/xbmca10# umount /dev/sdb2<br />
and boot it on your A10 Device.<br />
<br />
== Start XBMC ==<br />
After a reboot you modprobe the needed modules (depending on the used kernel version):<br />
root@mele:~/# modprobe disp<br />
root@mele:~/# modprobe lcd<br />
root@mele:~/# modprobe hdmi<br />
root@mele:~/# modprobe mali<br />
root@mele:~/# export A10HWR=1 (ensure to have this set if not rebooting!)<br />
root@mele:~/# cd /allwinner/xbmc-pvr-bin/lib/xbmc<br />
root@mele:/allwinner/xbmc-pvr-bin/lib/xbmc# ./xbmc.bin<br />
<br />
== Using the Android libraries via libhybris ==<br />
Due to some bugs in the native linux binaries of cedarx, ssvb succeeded to use libhybris and the Android binaries instead. This is the recommended way.<br />
See [[CedarX/libve]].<br />
<br />
== Troubleshooting ==<br />
* (native) If you get a compiler error when processing h264.o or building xbmc.bin, then check, if swap is enabled. The compiler ran out of memory!<br />
* (native) If deb-building fails, check, if your tmp-directory has enough free space and is no tmpfs, because of the lack of memory an mele.<br />
* To use the bash-script bin/xbmc to start xbmc, you have to comment out the exec of FEH.py, because of a failing test of glxinfo -> no display found.<br />
* Depending on your setup you may have to change some things to build<br />
* If mysql_config is not found, even though it is clearly there you can set disable-mysql in Makefile under xbmca10/tools/a10/depends/xbmc<br />
* Header files might not be where they are expected, this can be fixed with symlinks and copying headers, for example...<br />
ln -s usr/include/dbus1.0/dbus usr/include/dbus <br />
* Once you get in trouble with some mesa conflicts, ensure to not have installed the following packages on your target system: <br />
libegl1-mesa libegl1-mesa-dev libegl1-mesa-drivers libgles2-mesa libgles2-mesa-dev<br />
* Check the discussion section for more notes.<br />
* Ensure that you have installed ALL of the dependencies, header files etc. in your target rootfs and ensure that they are available during build. The build script does not search for them on your host-rootfs!<br />
<br />
= Configuring XBMC dependencies for Linux on A10 based devices =<br />
== Getting IR (infrared) remotes working on A10 based media players ==<br />
For getting IR (infrared) remote controls working on the A10 based media players, please see the [[LIRC (Linux Infrared Remote Control) for the IR receivers and and remotes]] article in this wiki. Place a suitable [[Lircmap.xml]] in userdata-directory.<br />
<br />
= Enabling dirty regions (a.k.a. dirty textures) for XBMC =<br />
This dirty region (a.k.a. dirty texture) feature in XBMC is designed to improve XBMC's GUI renderer performance on the GPU by only drawing when something like a texture changes on the screen, that region is then marked as dirty by XBMC's GUI library and only that region is redraw region on the screen.<br />
<br />
This feature is however still a little buggy and therefor not enabled by default in XBMC, but all users of XBMC on A10 based devices can try enabling the hidden "dirty regions" (a.k.a. "dirty textures") rendering feature advanced setting themselves manually. <br />
<br />
* http://wiki.xbmc.org/index.php?title=HOW-TO:Enable_dirty_regions<br />
* http://xbmc.org/theuni/2011/06/19/working-with-dirty-regions/<br />
* http://wiki.xbmc.org/index.php?title=Advancedsettings.xml#.3Calgorithmdirtyregions.3E<br />
<br />
Dirty regions are any parts of the screen that have changed since the last frame. By not re-rendering what hasn't changed, big speed gains can be seen. Because all GPUs work differently, only Mode 3, combined with nofliptimeout=0, is guaranteed to be safe for everyone, but current timing issues with nofliptimeout keep this from being the default. Note that with "dirty regions" your system CPU usage might go up a little (because it is doing the dirty regions calculations) but your GPU usage will be much lower, and since it is the GPU and not CPU that is the bottleneck in XBMC for embedded systems your GUI performance will be better even though the CPU usage is higher.<br />
<br />
{| class="wikitable"<br />
! value !! result !! description<br />
|-<br />
! 0<br />
| Off<br />
| The entire viewport is always rendered, which is the same as having the dirty regions feature disabled. This is the default mode.<br />
|-<br />
! 1<br />
|Union<br />
|All dirty regions are grouped into the smallest possible rectangle. This is typically the fastest mode for slower GPUs due to only making one pass.<br />
|-<br />
! 2<br />
|Cost reduction<br />
| Each dirty region is presented separately, in as many passes as there are regions.<br />
|-<br />
! 3<br />
|Whole Screen<br />
| The entire screen is rendered if there are any dirty regions. This, combined with nofliptimeout is a safe default for drivers that clear buffer contents (manifests as blinking or vibrating images)<br />
|}<br />
<br />
To enable dirty regions manually you need to create a "advancedsettings.xml" text file youself and put the XML <algorithmdirtyregions> enabling tags in there and copying to your "/userdata/" folder (/home/username/.xbmc/userdata/).<br />
<br />
Example:<br />
<code><br />
<gui> <br />
<algorithmdirtyregions>1</algorithmdirtyregions><br />
</gui><br />
</code><br />
<br />
You could also try to enable the <nofliptimeout> feature but that is even more experimental so know that it can cause even more GUI rendering issues in XBMC<br />
<br />
Example: <br />
<code><br />
<gui> <br />
<nofliptimeout>1000</nofliptimeout><br />
</gui><br />
</code><br />
<br />
To have both of these enabled your "advancedsettings.xml" then the finished file should look something like this:<br />
<br />
<code><br />
<advancedsettings><br />
<gui> <br />
<algorithmdirtyregions>1</algorithmdirtyregions><br />
<nofliptimeout>1000</nofliptimeout><br />
</gui><br />
</advancedsettings><br />
</code><br />
<br />
=Sources implementing A10 on XBMC=<br />
* [https://github.com/empatzero/xbmca10 https://github.com/empatzero/xbmca10]<br />
** [https://github.com/rellla/xbmca10 https://github.com/rellla/xbmca10] Recommended fork of empatzero ([http://pastebin.com/M4Di5tha Diff to upstream])<br />
** [https://github.com/vidonme/xbmc/ https://github.com/vidonme/xbmc/] Sources of [http://www.vidon.me/download.html VidOn.Me Player]? Seems to be a fork from empatzero. ([http://pastebin.com/LuQ4AB9J Diff to upstream] and [https://github.com/vidonme/xbmc/compare/xbmc:7b9ab8a85fd2b6030e6cf2659ff16380afef3996...master Github Compare]) This repo is reported from VidOn.me to be the "official" source code for their Allwinner XBMC version. The only commit from VidOn.me is [https://github.com/vidonme/xbmc/commit/b2b1696e8eb6617da07e0a043ca6ef2219ca080d#diff-2c44bd39cfe6b4185fe6a51b78c46cd0R122 this one]. <br />
* [https://github.com/huceke/xbmc/tree/allwinner https://github.com/huceke/xbmc/tree/allwinner] Gimli's implementation ([http://pastebin.com/Nu3DrfNK Diff to upstream])<br />
<br />
=References=<br />
<references /><br />
<br />
= See also =<br />
* [[CedarX]] - Library for Allwinner A10 VPU (Video Processor Unit) used for audio and video decoding and encoding hardware off-loading.<br />
** [[CedarXVideoRenderingChart]] - Overview chart of working/ non working video files<br />
* [[LIRC (Linux Infrared Remote Control) for the IR receivers and and remotes]]<br />
* [[Tvheadend TV Tuner Server and PVR backend]]<br />
<br />
=External Links=<br />
* [http://forum.xbmc.org/showthread.php?tid=126995 XBMC Official Community Forum discussion about porting to Allwinner A10]<br />
* [http://jas-hacks.blogspot.co.uk/2012/11/hackberry-a10-xbmc.html Jas Hacks Hackberry A10 - XBMC on Ubuntu 12.10 image]<br />
* [http://www.j1nx.nl/buildroot-xbmc-on-mele-a1000-allwinner-a10/ Buildroot XBMC on the Mele A1000 (Allwinner A10)]<br />
* [http://www.cnx-software.com/2012/11/12/xbmc-for-linux-on-allwinner-a10-devices-it-works-sort-of/ XBMC for Linux on AllWinner A10 Devices? It Works! (Sort of)]<br />
<br />
[[Category:Software]]<br />
[[Category:Tutorial]]<br />
[[Category:CedarX]]</div>Rockerhttps://linux-sunxi.org/index.php?title=Allwinner_SoC_Family&diff=9278Allwinner SoC Family2014-06-11T13:47:40Z<p>Rocker: /* Comparison table for "A"-Series Allwinner SoC's */</p>
<hr />
<div>=== "A"-Series ===<br />
Based on ARMv7 Cortex-A cores (Cortex-A7,A8, and A15) targeted for hi-end devices like digital media player, tablets, and netbooks:<br />
* [[A10|Allwinner A10]] <small>(sun4i)</small> (1 x Cortex-A8 CPU-core)<br />
* [[A13|Allwinner A13]] <small>(sun5i)</small> (1 x Cortex-A8 CPU-core)<br />
* [[A10s|Allwinner A10s]]<small>(sun5i)</small>(1 x Cortex-A8 CPU-core)<br />
* [[A20|Allwinner A20]] <small>(sun7i)</small> (2 x Cortex-A7 CPU-cores)<br />
* [[A23|Allwinner A23]] <small>(sun8i)</small> (2 x Cortex-A7 CPU-cores)<br />
* [[A31|Allwinner A31]] <small>(sun6i)</small> (4 x Cortex-A7 CPU-cores)<br />
* [[A31s|Allwinner A31s]] <small>(sun6i)</small> (4 x Cortex-A7 CPU-cores)<br />
* [[A33|Allwinner A33]] <small>(sun?i)</small> (4 x Cortex-A7 CPU-cores)<br />
* [[A80|Allwinner A80]] <small>(sun?i)</small> (4 x Cortex-A7 CPU-cores + 4 x Cortex-A15 CPU-cores using ARM big.LITTLE heterogeneous CPU architecture)<br />
<br />
=== "A"- Series features: ===<br />
* CPU: ARMv7-A [http://en.wikipedia.org/wiki/ARM_Cortex-A7 Cortex-A7] or [http://en.wikipedia.org/wiki/ARM_Cortex-A8 Cortex-A8] Central Processor Unit which have [[NEON]], [[Vector Floating Point Unit|VFP]], [[TrustZone]], and [[Thumb-2]] co-processor extensions: <br />
** Advanced SIMD: [[NEON]] (ARM's extended general-purpose advanced SIMD vector processing extension engine)<br />
** Vector FPU: [[Vector Floating Point Unit]] - ARM VFPv3 lite (Cortex-A8) / VFPv4 (Cortex-A7) VFPU (Vector Floating Point Unit)<br />
** Security Extensions: <br />
*** TrustZone secure world<br />
*** [[Security_System|Security accelerator]] supporting AES, DES, 3DES, SHA-1, MD5 and pseudo-random number generation<br />
** [[Thumb2]] intruction set extension for optimized code to reduce memory footprint and improve performance<br />
* GPU: [[Mali400]] or SGX544 Graphics Procesor Unit, supporting OpenGL ES and [[Framebuffer]] <br />
* VPU: [[CedarX]] (Video Processor Unit for audio and video hardware decoding or encoding)<br />
* HDMI-transmitter with [[HDMI CEC (Consumer Electronics Control)]], (with exception of A13 which lacks HDMI-transmitter and SATA-controller<ref>[http://olimex.wordpress.com/2012/04/24/cortex-a8-in-tqfp-sure-allwinner-a13/ "Cortex A8 in TQFP? sure Allwinner A13"] ''Retrieved 23 September 2012''</ref>)<br />
* Hardware virtualization capabilities (Cortex-A7 only).<br />
* Up to 4GB memory (Cortex-A8), Up to 1TB memory with LPAE (Cortex-A7 only).<br />
<br />
=== Comparison table for "A"-Series Allwinner SoC's ===<br />
{| class="wikitable"<br />
|-<br />
! scope="row" | !! [[A10]] !! [[A10s]] !! [[A13]] !! [[A20]] !! [[A31]]!! [[A31s]] !! [[A23]] !! [[A80]]<br />
|-<br />
! scope="row" | Generation <br />
| sun4i || sun5i || sun5i || sun7i || sun6i || || sun8i || sun??i<br />
|-<br />
! scope="row" | CPU<br />
| Cortex-A8 || Cortex-A8 || Cortex-A8 || Cortex-A7 || Cortex-A7 || Cortex-A7 || Cortex-A7 || 4xCortex-A7, 4xCortex-A15 <br />
|-<br />
! scope="row" | CPU Maximum frequency<br />
| 1GHz|| 1GHz || 1GHz|| 912MHz|| ?GHz || ?Ghz || ?Ghz || 2(??) Ghz<br />
|-<br />
! scope="row" | Cores<br />
| 1 || 1 || 1 || 2 || 4 || 4 || 2 || 2x4<br />
|-<br />
! scope="row" | Extensions<br />
| NEON, VFPv3, Thumb-2 || NEON, VFPv3, Thumb-2 || NEON, VFPv3, Thumb-2 || NEON, VFPv3 / VFPv4, Thumb-2 || NEON, VFPv3 / VFPv4, Thumb-2 || NEON, VFPv3 / VFPv4, Thumb-2 || NEON, VFPv3 / VFPv4, Thumb-2 || ?<br />
|-<br />
! scope="row" | Memory<br />
| DDR2, DDR3 (max 2GB @ DDR800) || DDR2, DDR3 (max 2GB @ DDR800) || DDR2, DDR3 (max 512MB @ DDR800) || LPDDR3/DDR3/LPDDR2 || 2-channel DDR3/LPDDR2, 2-channel DDR3L || || || 2-channel DDR3/DDR3L/LPDDR3/LPDDR2, up to 8GB<br />
|-<br />
! scope="row" | GPU<br />
| [[Mali400]] @ 320Mhz || [[Mali400]] @ 320Mhz || [[Mali400]] @ 320Mhz || [[Mali400]] MP2 @ 350Mhz per shader engine || SGX544 @ 200Mhz per shader engine || SGX544 @ 200Mhz per shader engine || Mali400 MP2 || 64-core PowerVR G6230<br />
|-<br />
! scope="row" | GPU API<br />
| OpenGL ES 2.0, OpenVG 1.1 || OpenGL ES 2.0, OpenVG 1.1 || OpenGL ES 2.0, OpenVG 1.1 || OpenGL ES 2.0, OpenVG 1.1 || OpenGL ES 2.0, OpenVG 1.1, OpenCL 1.1, and DirectX 9.3 || OpenGL ES 2.0, OpenVG 1.1, OpenCL 1.1, and DirectX 9.3 || OpenGL ES 2.0, OpenVG 1.1 || Open GL ES3.x, Open CL1.x, DirectX 11 level 9_3/10_0<br />
|-<br />
! scope="row" | [[CedarX|Video decoder]]<br />
| 2160P || 1080P || 1080P || 2160p, 4K×2K, 1080p 3D || 2160p, 4K×2K, 1080p 3D || || || ?<br />
|-<br />
! scope="row" | [[CedarX|Video encoder]]<br />
| H.264 1080P@30fps,JPEG || H.264 1080P@30fps,JPEG || H.264 1080P@30fps,JPEG || H.264 1080P@30fps,JPEG || H.264 1080P@30fps,JPEG || || || H.264 HP/VP8 4Kx2K@30fp<br />
|-<br />
! scope="row" | [[CedarX|Audio decoder]]<br />
| AC3,DTS || ?|| ? || AC3,DTS|| ? || || || ?<br />
|-<br />
! scope="row" | Video interfaces<br />
| HDMI 1.3, YPbPr, VGA, CPU/RGB/LVDS LCD || HDMI 1.3, RGB/LVDS LCD || RGB LCD, VGA|| HDMI 1.4, CVBS, YPbPr, VGA, CPU/RGB/LVDS LCD || HDMI 1.4, MIPI DSI, 2-channel LVDS, 2-channel RGB LCD || || || HDMI 4K , RGB LCD 2048x1536@60fps, dual-channel LVDS 1920x1080@60fps, 4-lane MIPI DSI 1920x1200@60fps, 4-lane eDP 2560x1600@60fps<br />
|-<br />
! scope="row" | Audio interfaces<br />
| I2S, SPDIF, AC97 || I2S, AC97 || I2S, AC97 || I2S, PCM, AC97 || I2S, PCM || || || ?<br />
|-<br />
! scope="row" | USB OTG<br />
| 1 || 1 || 1 || 1 || 1 || || || 1<br />
|-<br />
! scope="row" | USB Host<br />
| 2 || 1 || 1 || 2 || 2 || || ||2x USB Host, USB 3.0/2.0 Dual-Role (host/device)<br />
|-<br />
! scope="row" | Ethernet<br />
| EMAC || EMAC || - || EMAC/GMAC || EMAC/GMAC || || ||EMAC/GMAC (?)<br />
|-<br />
! scope="row" | Storage<br />
| NAND (max 64GB), SATA II, SD Card 3.0 || NAND (max 64GB), SD Card 3.0 || NAND (max 64GB), SD Card 3.0 || NAND, MMC, [http://olimex.wordpress.com/2013/04/05/allwinners-a10-and-a20-are-they-really-pin-to-pin-compatible-and-drop-in-replacement/#comment-5452 SATA] || 4x SD Card, eMMC NAND, 2-channel raw NAND || || || 4x SD/MMC<br />
|-<br />
! scope="row" | Package<br />
| BGA441 19mm × 19mm, 0.80mm Pitch || BGA336 14mm × 14mm, 0.65mm Pitch || eLQFP176 20mm × 20mm ||BGA441 19mm × 19mm, 0.80mm Pitch || BGA609 18mm × 18mm, 0.65mm Pitch || || ||<br />
|-<br />
! scope="row" | Litography<br />
| 55nm || 55nm|| 55nm || 40nm || 40nm|| 40nm ||40nm || 28nm HPM<br />
|}<br />
<ref>http://blog.thinkteletronics.com/all-mobile-socsolutions/ All Mobile Soc/Solutions.</ref><br />
<br />
=== "F"-Series ===<br />
'''NOTE: F series not supported by linux-sunxi community due lack of developers and hardware, sun3i have only offical linux port, sunii have no linux support only aw's melis RTOS'''<br />
<br />
<br />
Based on ARMv6 ARM926-EJS core and currenty targeted for low market devices such as cheap ebook readers, etc.<br />
<br />
* [[C100|Boxchip C100]] <small>(sun3i)</small><br />
* [[E200|Boxchip E200]] <small>(sun3i)</small><br />
* [[F20|Boxchip F20]] <small>(sun3i)</small><br />
* [[F10|Boxchip F10]] aka SoChip SC9800 aka Teclast T8100<small>(sunii)</small><br />
* [[F13|Boxchip F13]] <small>(sunii)</small><br />
* [[F13|Boxchip F15]] aka SoChip SC8600 aka Teclast T7200<small>(sunii)</small><br />
* [[F18|Boxchip F18]] <small>(sunii)</small><br />
<br />
==References==<br />
<references /><br />
<br />
[[Category:System_on_Chip]]</div>Rockerhttps://linux-sunxi.org/index.php?title=Allwinner_SoC_Family&diff=9277Allwinner SoC Family2014-06-11T13:46:29Z<p>Rocker: </p>
<hr />
<div>=== "A"-Series ===<br />
Based on ARMv7 Cortex-A cores (Cortex-A7,A8, and A15) targeted for hi-end devices like digital media player, tablets, and netbooks:<br />
* [[A10|Allwinner A10]] <small>(sun4i)</small> (1 x Cortex-A8 CPU-core)<br />
* [[A13|Allwinner A13]] <small>(sun5i)</small> (1 x Cortex-A8 CPU-core)<br />
* [[A10s|Allwinner A10s]]<small>(sun5i)</small>(1 x Cortex-A8 CPU-core)<br />
* [[A20|Allwinner A20]] <small>(sun7i)</small> (2 x Cortex-A7 CPU-cores)<br />
* [[A23|Allwinner A23]] <small>(sun8i)</small> (2 x Cortex-A7 CPU-cores)<br />
* [[A31|Allwinner A31]] <small>(sun6i)</small> (4 x Cortex-A7 CPU-cores)<br />
* [[A31s|Allwinner A31s]] <small>(sun6i)</small> (4 x Cortex-A7 CPU-cores)<br />
* [[A33|Allwinner A33]] <small>(sun?i)</small> (4 x Cortex-A7 CPU-cores)<br />
* [[A80|Allwinner A80]] <small>(sun?i)</small> (4 x Cortex-A7 CPU-cores + 4 x Cortex-A15 CPU-cores using ARM big.LITTLE heterogeneous CPU architecture)<br />
<br />
=== "A"- Series features: ===<br />
* CPU: ARMv7-A [http://en.wikipedia.org/wiki/ARM_Cortex-A7 Cortex-A7] or [http://en.wikipedia.org/wiki/ARM_Cortex-A8 Cortex-A8] Central Processor Unit which have [[NEON]], [[Vector Floating Point Unit|VFP]], [[TrustZone]], and [[Thumb-2]] co-processor extensions: <br />
** Advanced SIMD: [[NEON]] (ARM's extended general-purpose advanced SIMD vector processing extension engine)<br />
** Vector FPU: [[Vector Floating Point Unit]] - ARM VFPv3 lite (Cortex-A8) / VFPv4 (Cortex-A7) VFPU (Vector Floating Point Unit)<br />
** Security Extensions: <br />
*** TrustZone secure world<br />
*** [[Security_System|Security accelerator]] supporting AES, DES, 3DES, SHA-1, MD5 and pseudo-random number generation<br />
** [[Thumb2]] intruction set extension for optimized code to reduce memory footprint and improve performance<br />
* GPU: [[Mali400]] or SGX544 Graphics Procesor Unit, supporting OpenGL ES and [[Framebuffer]] <br />
* VPU: [[CedarX]] (Video Processor Unit for audio and video hardware decoding or encoding)<br />
* HDMI-transmitter with [[HDMI CEC (Consumer Electronics Control)]], (with exception of A13 which lacks HDMI-transmitter and SATA-controller<ref>[http://olimex.wordpress.com/2012/04/24/cortex-a8-in-tqfp-sure-allwinner-a13/ "Cortex A8 in TQFP? sure Allwinner A13"] ''Retrieved 23 September 2012''</ref>)<br />
* Hardware virtualization capabilities (Cortex-A7 only).<br />
* Up to 4GB memory (Cortex-A8), Up to 1TB memory with LPAE (Cortex-A7 only).<br />
<br />
=== Comparison table for "A"-Series Allwinner SoC's ===<br />
{| class="wikitable"<br />
|-<br />
! scope="row" | !! [[A10]] !! [[A10s]] !! [[A13]] !! [[A20]] !! [[A31]]!! [[A31s]] !! [[A23]] !! [[A80] preliminary ]<br />
|-<br />
! scope="row" | Generation <br />
| sun4i || sun5i || sun5i || sun7i || sun6i || || sun8i || sun??i<br />
|-<br />
! scope="row" | CPU<br />
| Cortex-A8 || Cortex-A8 || Cortex-A8 || Cortex-A7 || Cortex-A7 || Cortex-A7 || Cortex-A7 || 4xCortex-A7, 4xCortex-A15 <br />
|-<br />
! scope="row" | CPU Maximum frequency<br />
| 1GHz|| 1GHz || 1GHz|| 912MHz|| ?GHz || ?Ghz || ?Ghz || 2(??) Ghz<br />
|-<br />
! scope="row" | Cores<br />
| 1 || 1 || 1 || 2 || 4 || 4 || 2 || 2x4<br />
|-<br />
! scope="row" | Extensions<br />
| NEON, VFPv3, Thumb-2 || NEON, VFPv3, Thumb-2 || NEON, VFPv3, Thumb-2 || NEON, VFPv3 / VFPv4, Thumb-2 || NEON, VFPv3 / VFPv4, Thumb-2 || NEON, VFPv3 / VFPv4, Thumb-2 || NEON, VFPv3 / VFPv4, Thumb-2 || ?<br />
|-<br />
! scope="row" | Memory<br />
| DDR2, DDR3 (max 2GB @ DDR800) || DDR2, DDR3 (max 2GB @ DDR800) || DDR2, DDR3 (max 512MB @ DDR800) || LPDDR3/DDR3/LPDDR2 || 2-channel DDR3/LPDDR2, 2-channel DDR3L || || || 2-channel DDR3/DDR3L/LPDDR3/LPDDR2, up to 8GB<br />
|-<br />
! scope="row" | GPU<br />
| [[Mali400]] @ 320Mhz || [[Mali400]] @ 320Mhz || [[Mali400]] @ 320Mhz || [[Mali400]] MP2 @ 350Mhz per shader engine || SGX544 @ 200Mhz per shader engine || SGX544 @ 200Mhz per shader engine || Mali400 MP2 || 64-core PowerVR G6230<br />
|-<br />
! scope="row" | GPU API<br />
| OpenGL ES 2.0, OpenVG 1.1 || OpenGL ES 2.0, OpenVG 1.1 || OpenGL ES 2.0, OpenVG 1.1 || OpenGL ES 2.0, OpenVG 1.1 || OpenGL ES 2.0, OpenVG 1.1, OpenCL 1.1, and DirectX 9.3 || OpenGL ES 2.0, OpenVG 1.1, OpenCL 1.1, and DirectX 9.3 || OpenGL ES 2.0, OpenVG 1.1 || Open GL ES3.x, Open CL1.x, DirectX 11 level 9_3/10_0<br />
|-<br />
! scope="row" | [[CedarX|Video decoder]]<br />
| 2160P || 1080P || 1080P || 2160p, 4K×2K, 1080p 3D || 2160p, 4K×2K, 1080p 3D || || || ?<br />
|-<br />
! scope="row" | [[CedarX|Video encoder]]<br />
| H.264 1080P@30fps,JPEG || H.264 1080P@30fps,JPEG || H.264 1080P@30fps,JPEG || H.264 1080P@30fps,JPEG || H.264 1080P@30fps,JPEG || || || H.264 HP/VP8 4Kx2K@30fp<br />
|-<br />
! scope="row" | [[CedarX|Audio decoder]]<br />
| AC3,DTS || ?|| ? || AC3,DTS|| ? || || || ?<br />
|-<br />
! scope="row" | Video interfaces<br />
| HDMI 1.3, YPbPr, VGA, CPU/RGB/LVDS LCD || HDMI 1.3, RGB/LVDS LCD || RGB LCD, VGA|| HDMI 1.4, CVBS, YPbPr, VGA, CPU/RGB/LVDS LCD || HDMI 1.4, MIPI DSI, 2-channel LVDS, 2-channel RGB LCD || || || HDMI 4K , RGB LCD 2048x1536@60fps, dual-channel LVDS 1920x1080@60fps, 4-lane MIPI DSI 1920x1200@60fps, 4-lane eDP 2560x1600@60fps<br />
|-<br />
! scope="row" | Audio interfaces<br />
| I2S, SPDIF, AC97 || I2S, AC97 || I2S, AC97 || I2S, PCM, AC97 || I2S, PCM || || || ?<br />
|-<br />
! scope="row" | USB OTG<br />
| 1 || 1 || 1 || 1 || 1 || || || 1<br />
|-<br />
! scope="row" | USB Host<br />
| 2 || 1 || 1 || 2 || 2 || || ||2x USB Host, USB 3.0/2.0 Dual-Role (host/device)<br />
|-<br />
! scope="row" | Ethernet<br />
| EMAC || EMAC || - || EMAC/GMAC || EMAC/GMAC || || ||EMAC/GMAC (?)<br />
|-<br />
! scope="row" | Storage<br />
| NAND (max 64GB), SATA II, SD Card 3.0 || NAND (max 64GB), SD Card 3.0 || NAND (max 64GB), SD Card 3.0 || NAND, MMC, [http://olimex.wordpress.com/2013/04/05/allwinners-a10-and-a20-are-they-really-pin-to-pin-compatible-and-drop-in-replacement/#comment-5452 SATA] || 4x SD Card, eMMC NAND, 2-channel raw NAND || || || 4x SD/MMC<br />
|-<br />
! scope="row" | Package<br />
| BGA441 19mm × 19mm, 0.80mm Pitch || BGA336 14mm × 14mm, 0.65mm Pitch || eLQFP176 20mm × 20mm ||BGA441 19mm × 19mm, 0.80mm Pitch || BGA609 18mm × 18mm, 0.65mm Pitch || || ||<br />
|-<br />
! scope="row" | Litography<br />
| 55nm || 55nm|| 55nm || 40nm || 40nm|| 40nm ||40nm || 28nm HPM<br />
|}<br />
<ref>http://blog.thinkteletronics.com/all-mobile-socsolutions/ All Mobile Soc/Solutions.</ref><br />
<br />
=== "F"-Series ===<br />
'''NOTE: F series not supported by linux-sunxi community due lack of developers and hardware, sun3i have only offical linux port, sunii have no linux support only aw's melis RTOS'''<br />
<br />
<br />
Based on ARMv6 ARM926-EJS core and currenty targeted for low market devices such as cheap ebook readers, etc.<br />
<br />
* [[C100|Boxchip C100]] <small>(sun3i)</small><br />
* [[E200|Boxchip E200]] <small>(sun3i)</small><br />
* [[F20|Boxchip F20]] <small>(sun3i)</small><br />
* [[F10|Boxchip F10]] aka SoChip SC9800 aka Teclast T8100<small>(sunii)</small><br />
* [[F13|Boxchip F13]] <small>(sunii)</small><br />
* [[F13|Boxchip F15]] aka SoChip SC8600 aka Teclast T7200<small>(sunii)</small><br />
* [[F18|Boxchip F18]] <small>(sunii)</small><br />
<br />
==References==<br />
<references /><br />
<br />
[[Category:System_on_Chip]]</div>Rockerhttps://linux-sunxi.org/index.php?title=Main_Page&diff=9276Main Page2014-06-11T13:41:29Z<p>Rocker: </p>
<hr />
<div>Welcome to the wiki of the [[:Category:Community | linux-sunxi community]], an open source software community dedicated to Allwinner based [[:Category:Devices|devices]].<br />
<br />
<div style="float:right; margin-left:1em;">__TOC__</div><br />
<br />
= What is sunxi =<br />
<br />
'''sunxi''' represents the family of ARM [[System on Chip|SoC (System on Chip)]] designed for embedded systems, and design by [[Allwinner Tech.|Allwinner Technology]] fabless semiconductor company based in [http://en.wikipedia.org/wiki/Zhuhai Zhuhai (Guangdong, China)]. The most popular of Allwinner's '''sunxi''' SoC models are currently the [http://en.wikipedia.org/wiki/Pin_compatibility pin-compatible] A1''x'' and A2''x'' series which are the [[A10|Allwinner A10]], [[A13]], [[A20]], [[A23]], and [[A33]]. Their predecessor was an ARM9 named [[F20|Boxchip F20]] (<small>''sun3i''</small>), and their successors are Allwinner [[A31]] and [[A80]]. See [[Allwinner SoC Family]] for more information.<br />
<br />
Since March of 2014 [[Allwinner Tech.]] company is also an official member of the [[Linaro]] group, a not-for-profit engineering consortium aimed at developing open source software for the ARM architecture.[http://www.linaro.org/news/linaro-announces-allwinner-technology-as-a-founding-member-of-the-new-linaro-digital-home-group/]<br />
<br />
= Community =<br />
The [[:Category:Community|sunxi community]] is a very active and advanced one. For more information, check our [[:Category:Community|linux-sunxi community page]]. It explains how to get help and how to contact us, and how you can contribute as well.<br />
<br />
= Allwinner based devices =<br />
Due to the popularity of the Allwinner SoCs, there are literally thousands of different devices out there.<br />
<br />
If you are looking for support for your device from the [[:Category:Community|sunxi community]] here, please take a look at our [[Identification_guide | guide to identifying your device]]. If you cannot find your device, then you might need to work through our [[New_Device_howto| new device howto]].<br />
<br />
If you are interested in buying an Allwinner SoC based device, then read through our [[Buying_guide | buying guide]].<br />
<br />
You can browse the already documented board here <br />
<categorytree mode=pages hideroot=off depth=0>Boards</categorytree><br />
<br />
= Documentation =<br />
== Quick reference guide ==<br />
<br />
{| class="wikitable"<br />
|- style="vertical-align: top; text-align:center;"<br />
!| Software<br />
!| Hardware<br />
|- style="vertical-align: top;"<br />
|<br />
* [[Bootable OS images]]: Complete ready-to-use SD card images<br />
* [[BSP|Board Support Package (BSP)]]: A scripted way to create images and SD-Cards.<br />
* [[Manual_build_howto|Manual build howto]]: Getting a specific U-Boot, Linux kernel, and a rootfs on an SD card.<br />
* [[sunxi-tools]]: Tools to help hacking sunxi devices<br />
* [[Packages]]: The linux-sunxi package repository<br />
* [[Linux Kernel]]: Kernel repositories and versions<br />
<categorytree mode=pages hideroot=off depth=0>Linux Distributions</categorytree><br />
<categorytree mode=pages hideroot=off depth=0>Android</categorytree><br />
<categorytree mode=pages hideroot=off depth=0>BSD</categorytree><br />
<categorytree mode=pages hideroot=off depth=0>Software</categorytree><br />
<categorytree mode=pages hideroot=off depth=0>Proprietary Software</categorytree><br />
<categorytree mode=pages hideroot=off depth=0>Development</categorytree><br />
|<br />
<categorytree mode=pages hideroot=on depth=2>Register guide</categorytree><br />
<categorytree mode=pages hideroot=off depth=0>CedarX</categorytree><br />
* [[Used IP cores]] - used IP cores in current generation of Allwinner devices<br />
* [[JTAG]] on A10 devices through µSD port<br />
* [[GPIO]] - General Purpose Input/Output on devices based on Allwinner SoCs<br />
* [[PIO]] - Programmed input/output (PIO) on devices based on Allwinner SoCs<br />
* [[MicroSD Breakout]]<br />
* [[Audio Codec]] - Audio Codec on devices based on Allwinner SoCs<br />
* [[CSI]] - Camera Sensor Interface on devices based on Allwinner SoCs<br />
* [[Cpufreq]] - cpufreq support on devices based on Allwinner SoCs<br />
* [[Wifi]] - 8192cu dropping connection workaround<br />
* [[I2Cdev]] - I2c communication in the userspace.<br />
* [[SPIdev]] - SPI communication in the userspace.<br />
* [[1-Wire]] - 1-Wire communication in the userspace.<br />
|}<br />
<br />
== Tutorials ==<br />
This wiki includes some fine tutorials. Please consider improving them.<br />
<categorytree mode=pages hideroot=off depth=0>Tutorial</categorytree></div>Rockerhttps://linux-sunxi.org/index.php?title=Main_Page&diff=9275Main Page2014-06-11T13:36:12Z<p>Rocker: </p>
<hr />
<div>Welcome to the wiki of the [[:Category:Community | linux-sunxi community]], an open source software community dedicated to Allwinner based [[:Category:Devices|devices]].<br />
<br />
<div style="float:right; margin-left:1em;">__TOC__</div><br />
<br />
= What is sunxi =<br />
<br />
'''sunxi''' represents the family of ARM [[System on Chip|SoC (System on Chip)]] designed for embedded systems, and design by [[Allwinner Tech.|Allwinner Technology]] fabless semiconductor company based in [http://en.wikipedia.org/wiki/Zhuhai Zhuhai (Guangdong, China)]. The most popular of Allwinner's '''sunxi''' SoC models are currently the [http://en.wikipedia.org/wiki/Pin_compatibility pin-compatible] A1''x'' and A2''x'' series which are the [[A10|Allwinner A10]], [[A13]], [[A20]], [[A23]], and [[A33]]. Their predecessor was an ARM9 named [[F20|Boxchip F20]] (<small>''sun3i''</small>), and their successors are Allwinner [[A31]] and [[A80]]. See [[Allwinner SoC Family]] for more information.<br />
<br />
Since March of 2014 [[Allwinner Tech.]] company is also an official member of the [[Linaro]] group, a not-for-profit engineering organization aimed at developing open source software for the ARM architecture.[http://www.linaro.org/news/linaro-announces-allwinner-technology-as-a-founding-member-of-the-new-linaro-digital-home-group/]<br />
<br />
= Community =<br />
The [[:Category:Community|sunxi community]] is a very active and advanced one. For more information, check our [[:Category:Community|linux-sunxi community page]]. It explains how to get help and how to contact us, and how you can contribute as well.<br />
<br />
= Allwinner based devices =<br />
Due to the popularity of the Allwinner SoCs, there are literally thousands of different devices out there.<br />
<br />
If you are looking for support for your device from the [[:Category:Community|sunxi community]] here, please take a look at our [[Identification_guide | guide to identifying your device]]. If you cannot find your device, then you might need to work through our [[New_Device_howto| new device howto]].<br />
<br />
If you are interested in buying an Allwinner SoC based device, then read through our [[Buying_guide | buying guide]].<br />
<br />
You can browse the already documented board here <br />
<categorytree mode=pages hideroot=off depth=0>Boards</categorytree><br />
<br />
= Documentation =<br />
== Quick reference guide ==<br />
<br />
{| class="wikitable"<br />
|- style="vertical-align: top; text-align:center;"<br />
!| Software<br />
!| Hardware<br />
|- style="vertical-align: top;"<br />
|<br />
* [[Bootable OS images]]: Complete ready-to-use SD card images<br />
* [[BSP|Board Support Package (BSP)]]: A scripted way to create images and SD-Cards.<br />
* [[Manual_build_howto|Manual build howto]]: Getting a specific U-Boot, Linux kernel, and a rootfs on an SD card.<br />
* [[sunxi-tools]]: Tools to help hacking sunxi devices<br />
* [[Packages]]: The linux-sunxi package repository<br />
* [[Linux Kernel]]: Kernel repositories and versions<br />
<categorytree mode=pages hideroot=off depth=0>Linux Distributions</categorytree><br />
<categorytree mode=pages hideroot=off depth=0>Android</categorytree><br />
<categorytree mode=pages hideroot=off depth=0>BSD</categorytree><br />
<categorytree mode=pages hideroot=off depth=0>Software</categorytree><br />
<categorytree mode=pages hideroot=off depth=0>Proprietary Software</categorytree><br />
<categorytree mode=pages hideroot=off depth=0>Development</categorytree><br />
|<br />
<categorytree mode=pages hideroot=on depth=2>Register guide</categorytree><br />
<categorytree mode=pages hideroot=off depth=0>CedarX</categorytree><br />
* [[Used IP cores]] - used IP cores in current generation of Allwinner devices<br />
* [[JTAG]] on A10 devices through µSD port<br />
* [[GPIO]] - General Purpose Input/Output on devices based on Allwinner SoCs<br />
* [[PIO]] - Programmed input/output (PIO) on devices based on Allwinner SoCs<br />
* [[MicroSD Breakout]]<br />
* [[Audio Codec]] - Audio Codec on devices based on Allwinner SoCs<br />
* [[CSI]] - Camera Sensor Interface on devices based on Allwinner SoCs<br />
* [[Cpufreq]] - cpufreq support on devices based on Allwinner SoCs<br />
* [[Wifi]] - 8192cu dropping connection workaround<br />
* [[I2Cdev]] - I2c communication in the userspace.<br />
* [[SPIdev]] - SPI communication in the userspace.<br />
* [[1-Wire]] - 1-Wire communication in the userspace.<br />
|}<br />
<br />
== Tutorials ==<br />
This wiki includes some fine tutorials. Please consider improving them.<br />
<categorytree mode=pages hideroot=off depth=0>Tutorial</categorytree></div>Rockerhttps://linux-sunxi.org/index.php?title=Main_Page&diff=9274Main Page2014-06-11T13:33:07Z<p>Rocker: /* Allwinner based Devices */</p>
<hr />
<div>Welcome to the wiki of the [[:Category:Community | linux-sunxi community]], an open source software community dedicated to Allwinner based [[:Category:Devices|devices]].<br />
<br />
<div style="float:right; margin-left:1em;">__TOC__</div><br />
<br />
= What is sunxi =<br />
<br />
'''sunxi''' represents the family of ARM [[System on Chip|SoC (System on Chip)]] designed for embedded systems, and design by [[Allwinner Tech.|Allwinner Technology]] fabless semiconductor company based in [http://en.wikipedia.org/wiki/Zhuhai Zhuhai (Guangdong, China)]. The most popular of Allwinner's '''sunxi''' SoC models are currently the [http://en.wikipedia.org/wiki/Pin_compatibility pin-compatible] A1''x'' and A2''x'' series which are the [[A10|Allwinner A10]], [[A13]], [[A20]], [[A23]], and [[A33]]. Their predecessor was an ARM9 named [[F20|Boxchip F20]] (<small>''sun3i''</small>), and their successors are Allwinner [[A31]] and [[A80]]. See [[Allwinner SoC Family]] for more information.<br />
<br />
= Community =<br />
The [[:Category:Community|sunxi community]] is a very active and advanced one. For more information, check our [[:Category:Community|linux-sunxi community page]]. It explains how to get help and how to contact us, and how you can contribute as well.<br />
<br />
= Allwinner based devices =<br />
Due to the popularity of the Allwinner SoCs, there are literally thousands of different devices out there. And since March of 2014 [[Allwinner Tech.]] company is also an official member of the [[Linaro]] group, a not-for-profit engineering organization aimed at developing open source software for the ARM architecture.<br />
<br />
If you are looking for support for your device from the [[:Category:Community|sunxi community]] here, please take a look at our [[Identification_guide | guide to identifying your device]]. If you cannot find your device, then you might need to work through our [[New_Device_howto| new device howto]].<br />
<br />
If you are interested in buying an Allwinner SoC based device, then read through our [[Buying_guide | buying guide]].<br />
<br />
You can browse the already documented board here <br />
<categorytree mode=pages hideroot=off depth=0>Boards</categorytree><br />
<br />
= Documentation =<br />
== Quick reference guide ==<br />
<br />
{| class="wikitable"<br />
|- style="vertical-align: top; text-align:center;"<br />
!| Software<br />
!| Hardware<br />
|- style="vertical-align: top;"<br />
|<br />
* [[Bootable OS images]]: Complete ready-to-use SD card images<br />
* [[BSP|Board Support Package (BSP)]]: A scripted way to create images and SD-Cards.<br />
* [[Manual_build_howto|Manual build howto]]: Getting a specific U-Boot, Linux kernel, and a rootfs on an SD card.<br />
* [[sunxi-tools]]: Tools to help hacking sunxi devices<br />
* [[Packages]]: The linux-sunxi package repository<br />
* [[Linux Kernel]]: Kernel repositories and versions<br />
<categorytree mode=pages hideroot=off depth=0>Linux Distributions</categorytree><br />
<categorytree mode=pages hideroot=off depth=0>Android</categorytree><br />
<categorytree mode=pages hideroot=off depth=0>BSD</categorytree><br />
<categorytree mode=pages hideroot=off depth=0>Software</categorytree><br />
<categorytree mode=pages hideroot=off depth=0>Proprietary Software</categorytree><br />
<categorytree mode=pages hideroot=off depth=0>Development</categorytree><br />
|<br />
<categorytree mode=pages hideroot=on depth=2>Register guide</categorytree><br />
<categorytree mode=pages hideroot=off depth=0>CedarX</categorytree><br />
* [[Used IP cores]] - used IP cores in current generation of Allwinner devices<br />
* [[JTAG]] on A10 devices through µSD port<br />
* [[GPIO]] - General Purpose Input/Output on devices based on Allwinner SoCs<br />
* [[PIO]] - Programmed input/output (PIO) on devices based on Allwinner SoCs<br />
* [[MicroSD Breakout]]<br />
* [[Audio Codec]] - Audio Codec on devices based on Allwinner SoCs<br />
* [[CSI]] - Camera Sensor Interface on devices based on Allwinner SoCs<br />
* [[Cpufreq]] - cpufreq support on devices based on Allwinner SoCs<br />
* [[Wifi]] - 8192cu dropping connection workaround<br />
* [[I2Cdev]] - I2c communication in the userspace.<br />
* [[SPIdev]] - SPI communication in the userspace.<br />
* [[1-Wire]] - 1-Wire communication in the userspace.<br />
|}<br />
<br />
== Tutorials ==<br />
This wiki includes some fine tutorials. Please consider improving them.<br />
<categorytree mode=pages hideroot=off depth=0>Tutorial</categorytree></div>Rockerhttps://linux-sunxi.org/index.php?title=Main_Page&diff=9273Main Page2014-06-11T13:26:51Z<p>Rocker: </p>
<hr />
<div>Welcome to the wiki of the [[:Category:Community | linux-sunxi community]], an open source software community dedicated to Allwinner based [[:Category:Devices|devices]].<br />
<br />
<div style="float:right; margin-left:1em;">__TOC__</div><br />
<br />
= What is sunxi =<br />
<br />
'''sunxi''' represents the family of ARM [[System on Chip|SoC (System on Chip)]] designed for embedded systems, and design by [[Allwinner Tech.|Allwinner Technology]] fabless semiconductor company based in [http://en.wikipedia.org/wiki/Zhuhai Zhuhai (Guangdong, China)]. The most popular of Allwinner's '''sunxi''' SoC models are currently the [http://en.wikipedia.org/wiki/Pin_compatibility pin-compatible] A1''x'' and A2''x'' series which are the [[A10|Allwinner A10]], [[A13]], [[A20]], [[A23]], and [[A33]]. Their predecessor was an ARM9 named [[F20|Boxchip F20]] (<small>''sun3i''</small>), and their successors are Allwinner [[A31]] and [[A80]]. See [[Allwinner SoC Family]] for more information.<br />
<br />
= Community =<br />
The [[:Category:Community|sunxi community]] is a very active and advanced one. For more information, check our [[:Category:Community|linux-sunxi community page]]. It explains how to get help and how to contact us, and how you can contribute as well.<br />
<br />
= Allwinner based Devices =<br />
Due to the popularity of the Allwinner SoCs, there are literally thousands of different devices out there.<br />
<br />
If you are looking for support for your device, please take a look at our [[Identification_guide | guide to identifying your device]]. If you cannot find your device, then you might need to work through our [[New_Device_howto| new device howto]].<br />
<br />
If you are interested in buying an allwinner based device, then read through our [[Buying_guide | buying guide]].<br />
<br />
You can browse the already documented board here <br />
<categorytree mode=pages hideroot=off depth=0>Boards</categorytree><br />
<br />
= Documentation =<br />
== Quick reference guide ==<br />
<br />
{| class="wikitable"<br />
|- style="vertical-align: top; text-align:center;"<br />
!| Software<br />
!| Hardware<br />
|- style="vertical-align: top;"<br />
|<br />
* [[Bootable OS images]]: Complete ready-to-use SD card images<br />
* [[BSP|Board Support Package (BSP)]]: A scripted way to create images and SD-Cards.<br />
* [[Manual_build_howto|Manual build howto]]: Getting a specific U-Boot, Linux kernel, and a rootfs on an SD card.<br />
* [[sunxi-tools]]: Tools to help hacking sunxi devices<br />
* [[Packages]]: The linux-sunxi package repository<br />
* [[Linux Kernel]]: Kernel repositories and versions<br />
<categorytree mode=pages hideroot=off depth=0>Linux Distributions</categorytree><br />
<categorytree mode=pages hideroot=off depth=0>Android</categorytree><br />
<categorytree mode=pages hideroot=off depth=0>BSD</categorytree><br />
<categorytree mode=pages hideroot=off depth=0>Software</categorytree><br />
<categorytree mode=pages hideroot=off depth=0>Proprietary Software</categorytree><br />
<categorytree mode=pages hideroot=off depth=0>Development</categorytree><br />
|<br />
<categorytree mode=pages hideroot=on depth=2>Register guide</categorytree><br />
<categorytree mode=pages hideroot=off depth=0>CedarX</categorytree><br />
* [[Used IP cores]] - used IP cores in current generation of Allwinner devices<br />
* [[JTAG]] on A10 devices through µSD port<br />
* [[GPIO]] - General Purpose Input/Output on devices based on Allwinner SoCs<br />
* [[PIO]] - Programmed input/output (PIO) on devices based on Allwinner SoCs<br />
* [[MicroSD Breakout]]<br />
* [[Audio Codec]] - Audio Codec on devices based on Allwinner SoCs<br />
* [[CSI]] - Camera Sensor Interface on devices based on Allwinner SoCs<br />
* [[Cpufreq]] - cpufreq support on devices based on Allwinner SoCs<br />
* [[Wifi]] - 8192cu dropping connection workaround<br />
* [[I2Cdev]] - I2c communication in the userspace.<br />
* [[SPIdev]] - SPI communication in the userspace.<br />
* [[1-Wire]] - 1-Wire communication in the userspace.<br />
|}<br />
<br />
== Tutorials ==<br />
This wiki includes some fine tutorials. Please consider improving them.<br />
<categorytree mode=pages hideroot=off depth=0>Tutorial</categorytree></div>Rockerhttps://linux-sunxi.org/index.php?title=Main_Page&diff=9144Main Page2014-06-03T16:07:39Z<p>Rocker: </p>
<hr />
<div>Welcome to the wiki of the [[:Category:Community | linux-sunxi community]], an open source software community dedicated to Allwinner based [[:Category:Devices|devices]].<br />
<br />
<div style="float:right; margin-left:1em;">__TOC__</div><br />
<br />
= What is sunxi =<br />
<br />
'''sunxi''' represents the family of ARM [[System on Chip|SoC (System on Chip)]] designed for embedded systems, and made by [[Allwinner Tech.]] in [http://en.wikipedia.org/wiki/Zhuhai Zhuhai (Guangdong, China)]. The most popular '''sunxi''' SoC model is the [[A10|Allwinner A10]] and the [[A13|Allwinner A13]]. Their predecessor was an ARM9 named [[F20|Boxchip F20]] (<small>''sun3i''</small>) and their successors are Allwinner [[A20]], [[A23]], [[A31]], [[A33]] and [[A80]]. See [[Allwinner SoC Family]] for more information.<br />
<br />
= Community =<br />
<br />
The [[:Category:Community|sunxi community]] is a very active and advanced one. For more information, check our [[:Category:Community|linux-sunxi community page]]. It explains how to get help and how to contact us, and how you can contribute as well.<br />
<br />
= Allwinner based Devices =<br />
<br />
Due to the popularity of the Allwinner SoCs, there are literally thousands of different devices out there.<br />
<br />
If you are looking for support for your device, please take a look at our [[Identification_guide | guide to identifying your device]]. If you cannot find your device, then you might need to work through our [[New_Device_howto| new device howto]].<br />
<br />
If you are interested in buying an allwinner based device, then read through our [[Buying_guide | buying guide]].<br />
<br />
You can browse the already documented board here <br />
<categorytree mode=pages hideroot=off depth=0>Boards</categorytree><br />
<br />
= Documentation =<br />
== Quick reference guide ==<br />
<br />
{| class="wikitable"<br />
|- style="vertical-align: top; text-align:center;"<br />
!| Software<br />
!| Hardware<br />
|- style="vertical-align: top;"<br />
|<br />
* [[Bootable OS images]]: Complete ready-to-use SD card images<br />
* [[BSP|Board Support Package (BSP)]]: A scripted way to create images and SD-Cards.<br />
* [[Manual_build_howto|Manual build howto]]: Getting a specific U-Boot, Linux kernel, and a rootfs on an SD card.<br />
* [[sunxi-tools]]: Tools to help hacking sunxi devices<br />
* [[Packages]]: The linux-sunxi package repository<br />
* [[Linux Kernel]]: Kernel repositories and versions<br />
<categorytree mode=pages hideroot=off depth=0>Linux Distributions</categorytree><br />
<categorytree mode=pages hideroot=off depth=0>Android</categorytree><br />
<categorytree mode=pages hideroot=off depth=0>BSD</categorytree><br />
<categorytree mode=pages hideroot=off depth=0>Software</categorytree><br />
<categorytree mode=pages hideroot=off depth=0>Proprietary Software</categorytree><br />
<categorytree mode=pages hideroot=off depth=0>Development</categorytree><br />
|<br />
<categorytree mode=pages hideroot=on depth=2>Register guide</categorytree><br />
<categorytree mode=pages hideroot=off depth=0>CedarX</categorytree><br />
* [[Used IP cores]] - used IP cores in current generation of Allwinner devices<br />
* [[JTAG]] on A10 devices through µSD port<br />
* [[GPIO]] - General Purpose Input/Output on devices based on Allwinner SoCs<br />
* [[PIO]] - Programmed input/output (PIO) on devices based on Allwinner SoCs<br />
* [[MicroSD Breakout]]<br />
* [[Audio Codec]] - Audio Codec on devices based on Allwinner SoCs<br />
* [[CSI]] - Camera Sensor Interface on devices based on Allwinner SoCs<br />
* [[Cpufreq]] - cpufreq support on devices based on Allwinner SoCs<br />
* [[Wifi]] - 8192cu dropping connection workaround<br />
* [[I2Cdev]] - I2c communication in the userspace.<br />
* [[SPIdev]] - SPI communication in the userspace.<br />
* [[1-Wire]] - 1-Wire communication in the userspace.<br />
|}<br />
<br />
== Tutorials ==<br />
This wiki includes some fine tutorials. Please consider improving them.<br />
<categorytree mode=pages hideroot=off depth=0>Tutorial</categorytree></div>Rockerhttps://linux-sunxi.org/index.php?title=A33&diff=9143A332014-06-03T16:07:04Z<p>Rocker: Created page with "{{Infobox SoC | image = | manufacturer = Allwinner | process = 40nm | cpu = Dual-Core ARM Cortex-A7 @ 1.5GHz | ltwo = | extensions = | memory = LPDDR3/DDR3 | gpu ..."</p>
<hr />
<div>{{Infobox SoC<br />
| image = <br />
| manufacturer = Allwinner<br />
| process = 40nm<br />
| cpu = Dual-Core ARM Cortex-A7 @ 1.5GHz<br />
| ltwo = <br />
| extensions = <br />
| memory = LPDDR3/DDR3<br />
| gpu = [[Mali400]] MP2<br />
| vpu = <br />
| apu = <br />
| video = CPU/RGB LCD, LVDS, MIPI DSI<br />
| audio = I2S, PCM, AC97<br />
| network = <br />
| storage = MMC, NAND<br />
| usb = OTG, 2x Host<br />
| other = <br />
| release_date = June 2014<br />
| website = <br />
}}<br />
<br />
Allwinner [[A33]] (sun?i) SoC features a Quad-Core Cortex-A7 ARM CPU, and a [[Mali400]] MP2 GPU from ARM. It is a Quad-Core Pin-to-Pin Compatible version of [[A23]], which in turn is a lower power cut-down version of the [[A23]].<br />
<br />
=Overview=<br />
Currently, there is no sunxi support available yet. No livesuite tool has been made available either.<br />
<br />
=A33 SoC Features=<br />
* CPU<br />
** ARM Cortex-A7 Quad-Core<br />
** 512KB L2-Cache (shared between four cores)<br />
** 256 KB (Instruction) / 32KiB (Data) L1-Cache per core<br />
** SIMD NEON, VFP4<br />
** Virtualization<br />
** Large Physical Address Extensions (LPAE) 1TB<br />
* GPU<br />
** ARM Mali400 MP2<br />
** Featuring 1 vertex shader (GP) and 2 fragment shaders (PP).<br />
** Complies with OpenGL ES 2.0<br />
* Memory<br />
** DDR3/DDR3L controller<br />
** NAND Flash controller and 64-bit ECC<br />
* Video<br />
** Full HD 1080p video decoding of MPEG-2, MPEG-4 SP/ASP GMC, H.263, H.264, WMV9/VC-1, and VP8<br />
** BD Directory, BD ISO and BD m2ts video decoding<br />
** H.264 High Profile 1080P@30fps encoding<br />
** 2160×1080@30fps 3D decoding<br />
** Complies with RTSP, HTTP,HLS,RTMP,MMS streaming media protocol<br />
* Display<br />
** CPU/RGB/LVDS LCD interface 1280x800 resolution<br />
** MIPI DSI interface up to 1280x800 resolution<br />
* Camera<br />
** Integrated parallel 8-bit I/F YUV sensor<br />
** Integrated 24-bit parallel YUV 444 I/F<br />
** 5M/8M CMOS sensor support<br />
** Dual-sensor support<br />
* Audio<br />
** Integrated HI-FI 100dB Audio Codec<br />
** Dual MIC noise cancellation<br />
* PMIC<br />
** X-Powers AXP223, designed for the A23, connected via Allwinner's [[Reduced Serial Bus | Reduced Serial Bus (RSB) ]]<br />
<br />
==Allwinner support==<br />
A33 will officially support Android 4.4 and above from AllWinner, so no official multi-OS support like some other higher-end AllWinner SoCs.<br />
<br />
= See also =<br />
* [[A23]]<br />
<br />
=References=<br />
<references /><br />
<br />
= External links =<br />
* ?<br />
<br />
[[Category:System on Chip]]<br />
[[Category:Allwinner]]<br />
[[Category:A33]]</div>Rockerhttps://linux-sunxi.org/index.php?title=Allwinner_SoC_Family&diff=9142Allwinner SoC Family2014-06-03T15:52:13Z<p>Rocker: /* "A"-Series */</p>
<hr />
<div>=== "A"-Series ===<br />
Based on ARMv7 Cortex-A cores (Cortex-A7,A8, and A15) targeted for hi-end devices like digital media player, tablets, and netbooks:<br />
* [[A10|Allwinner A10]] <small>(sun4i)</small> (Cortex-A8)<br />
* [[A13|Allwinner A13]] <small>(sun5i)</small> (Cortex-A8)<br />
* [[A10s|Allwinner A10s]]<small>(sun5i)</small>(Cortex-A8)<br />
* [[A20|Allwinner A20]] <small>(sun7i)</small> 2x(Cortex-A7)<br />
* [[A23|Allwinner A23]] <small>(sun8i)</small> 2x(Cortex-A7)<br />
* [[A31|Allwinner A31]] <small>(sun6i)</small> 4x(Cortex-A7)<br />
* [[A31s|Allwinner A31s]] <small>(sun6i)</small> 4x(Cortex-A7)<br />
* [[A33|Allwinner A33]] <small>(sun?i)</small> 4x(Cortex-A7)<br />
* [[A80|Allwinner A80]] <small>(sun?i)</small> 4x(Cortex-A7) + 4x(Cortex-A15)<br />
<br />
=== "A"- Series features: ===<br />
* CPU: ARMv7-A [http://en.wikipedia.org/wiki/ARM_Cortex-A7 Cortex-A7] or [http://en.wikipedia.org/wiki/ARM_Cortex-A8 Cortex-A8] Central Processor Unit which have [[NEON]], [[Vector Floating Point Unit|VFP]], [[TrustZone]], and [[Thumb-2]] co-processor extensions: <br />
** Advanced SIMD: [[NEON]] (ARM's extended general-purpose advanced SIMD vector processing extension engine)<br />
** Vector FPU: [[Vector Floating Point Unit]] - ARM VFPv3 lite (Cortex-A8) / VFPv4 (Cortex-A7) VFPU (Vector Floating Point Unit)<br />
** Security Extensions: <br />
*** TrustZone secure world<br />
*** [[Security_System|Security accelerator]] supporting AES, DES, 3DES, SHA-1, MD5 and pseudo-random number generation<br />
** [[Thumb2]] intruction set extension for optimized code to reduce memory footprint and improve performance<br />
* GPU: [[Mali400]] or SGX544 Graphics Procesor Unit, supporting OpenGL ES and [[Framebuffer]] <br />
* VPU: [[CedarX]] (Video Processor Unit for audio and video hardware decoding or encoding)<br />
* HDMI-transmitter with [[HDMI CEC (Consumer Electronics Control)]], (with exception of A13 which lacks HDMI-transmitter and SATA-controller<ref>[http://olimex.wordpress.com/2012/04/24/cortex-a8-in-tqfp-sure-allwinner-a13/ "Cortex A8 in TQFP? sure Allwinner A13"] ''Retrieved 23 September 2012''</ref>)<br />
* Hardware virtualization capabilities (Cortex-A7 only).<br />
* Up to 4GB memory (Cortex-A8), Up to 1TB memory with LPAE (Cortex-A7 only).<br />
<br />
=== Comparison table for "A"-Series Allwinner SoC's ===<br />
{| class="wikitable"<br />
|-<br />
! scope="row" | !! [[A10]] !! [[A10s]] !! [[A13]] !! [[A20]] !! [[A31]]!! [[A31s]] !! [[A23]] !! [[A80] preliminary ]<br />
|-<br />
! scope="row" | Generation <br />
| sun4i || sun5i || sun5i || sun7i || sun6i || || sun8i || sun??i<br />
|-<br />
! scope="row" | CPU<br />
| Cortex-A8 || Cortex-A8 || Cortex-A8 || Cortex-A7 || Cortex-A7 || Cortex-A7 || Cortex-A7 || 4xCortex-A7, 4xCortex-A15 <br />
|-<br />
! scope="row" | CPU Maximum frequency<br />
| 1GHz|| 1GHz || 1GHz|| 912MHz|| ?GHz || ?Ghz || ?Ghz || 2(??) Ghz<br />
|-<br />
! scope="row" | Cores<br />
| 1 || 1 || 1 || 2 || 4 || 4 || 2 || 2x4<br />
|-<br />
! scope="row" | Extensions<br />
| NEON, VFPv3, Thumb-2 || NEON, VFPv3, Thumb-2 || NEON, VFPv3, Thumb-2 || NEON, VFPv3 / VFPv4, Thumb-2 || NEON, VFPv3 / VFPv4, Thumb-2 || NEON, VFPv3 / VFPv4, Thumb-2 || NEON, VFPv3 / VFPv4, Thumb-2 || ?<br />
|-<br />
! scope="row" | Memory<br />
| DDR2, DDR3 (max 2GB @ DDR800) || DDR2, DDR3 (max 2GB @ DDR800) || DDR2, DDR3 (max 512MB @ DDR800) || LPDDR3/DDR3/LPDDR2 || 2-channel DDR3/LPDDR2, 2-channel DDR3L || || || 2-channel DDR3/DDR3L/LPDDR3/LPDDR2, up to 8GB<br />
|-<br />
! scope="row" | GPU<br />
| [[Mali400]] @ 320Mhz || [[Mali400]] @ 320Mhz || [[Mali400]] @ 320Mhz || [[Mali400]] MP2 @ 350Mhz per shader engine || SGX544 @ 200Mhz per shader engine || SGX544 @ 200Mhz per shader engine || Mali400 MP2 || 64-core PowerVR G6230<br />
|-<br />
! scope="row" | GPU API<br />
| OpenGL ES 2.0, OpenVG 1.1 || OpenGL ES 2.0, OpenVG 1.1 || OpenGL ES 2.0, OpenVG 1.1 || OpenGL ES 2.0, OpenVG 1.1 || OpenGL ES 2.0, OpenVG 1.1, OpenCL 1.1, and DirectX 9.3 || OpenGL ES 2.0, OpenVG 1.1, OpenCL 1.1, and DirectX 9.3 || OpenGL ES 2.0, OpenVG 1.1 || Open GL ES3.x, Open CL1.x, DirectX 11 level 9_3/10_0<br />
|-<br />
! scope="row" | [[CedarX|Video decoder]]<br />
| 2160P || 1080P || 1080P || 2160p, 4K×2K, 1080p 3D || 2160p, 4K×2K, 1080p 3D || || || ?<br />
|-<br />
! scope="row" | [[CedarX|Video encoder]]<br />
| H.264 1080P@30fps,JPEG || H.264 1080P@30fps,JPEG || H.264 1080P@30fps,JPEG || H.264 1080P@30fps,JPEG || H.264 1080P@30fps,JPEG || || || H.264 HP/VP8 4Kx2K@30fp<br />
|-<br />
! scope="row" | [[CedarX|Audio decoder]]<br />
| AC3,DTS || ?|| ? || AC3,DTS|| ? || || || ?<br />
|-<br />
! scope="row" | Video interfaces<br />
| HDMI 1.3, YPbPr, VGA, CPU/RGB/LVDS LCD || HDMI 1.3, RGB/LVDS LCD || RGB LCD, VGA|| HDMI 1.4, CVBS, YPbPr, VGA, CPU/RGB/LVDS LCD || HDMI 1.4, MIPI DSI, 2-channel LVDS, 2-channel RGB LCD || || || HDMI 4K , RGB LCD 2048x1536@60fps, dual-channel LVDS 1920x1080@60fps, 4-lane MIPI DSI 1920x1200@60fps, 4-lane eDP 2560x1600@60fps<br />
|-<br />
! scope="row" | Audio interfaces<br />
| I2S, SPDIF, AC97 || I2S, AC97 || I2S, AC97 || I2S, PCM, AC97 || I2S, PCM || || || ?<br />
|-<br />
! scope="row" | USB OTG<br />
| 1 || 1 || 1 || 1 || 1 || || || 1<br />
|-<br />
! scope="row" | USB Host<br />
| 2 || 1 || 1 || 2 || 2 || || ||2x USB Host, USB 3.0/2.0 Dual-Role (host/device)<br />
|-<br />
! scope="row" | Ethernet<br />
| EMAC || EMAC || - || EMAC/GMAC || EMAC/GMAC || || ||EMAC/GMAC (?)<br />
|-<br />
! scope="row" | Storage<br />
| NAND (max 64GB), SATA II, SD Card 3.0 || NAND (max 64GB), SD Card 3.0 || NAND (max 64GB), SD Card 3.0 || NAND, MMC, [http://olimex.wordpress.com/2013/04/05/allwinners-a10-and-a20-are-they-really-pin-to-pin-compatible-and-drop-in-replacement/#comment-5452 SATA] || 4x SD Card, eMMC NAND, 2-channel raw NAND || || || 4x SD/MMC<br />
|-<br />
! scope="row" | Package<br />
| BGA441 19mm × 19mm, 0.80mm Pitch || BGA336 14mm × 14mm, 0.65mm Pitch || eLQFP176 20mm × 20mm ||BGA441 19mm × 19mm, 0.80mm Pitch || BGA609 18mm × 18mm, 0.65mm Pitch || || ||<br />
|-<br />
! scope="row" | Litography<br />
| 55nm || 55nm|| 55nm || 40nm || 40nm|| 40nm ||40nm || 28nm HPM<br />
|}<br />
<ref>http://blog.thinkteletronics.com/all-mobile-socsolutions/ All Mobile Soc/Solutions.</ref><br />
<br />
=== "F"-Series ===<br />
'''NOTE: F series not supported by linux-sunxi community due lack of developers and hardware, sun3i have only offical linux port, sunii have no linux support only aw's melis RTOS'''<br />
<br />
<br />
Based on ARMv6 ARM926-EJS core and currenty targeted for low market devices such as cheap ebook readers, etc.<br />
<br />
* [[C100|Boxchip C100]] <small>(sun3i)</small><br />
* [[E200|Boxchip E200]] <small>(sun3i)</small><br />
* [[F20|Boxchip F20]] <small>(sun3i)</small><br />
* [[F10|Boxchip F10]] aka SoChip SC9800 aka Teclast T8100<small>(sunii)</small><br />
* [[F13|Boxchip F13]] <small>(sunii)</small><br />
* [[F13|Boxchip F15]] aka SoChip SC8600 aka Teclast T7200<small>(sunii)</small><br />
* [[F18|Boxchip F18]] <small>(sunii)</small><br />
<br />
==References==<br />
<references /><br />
<br />
[[Category:System_on_Chip]]</div>Rockerhttps://linux-sunxi.org/index.php?title=CedarX&diff=9085CedarX2014-05-30T12:29:40Z<p>Rocker: </p>
<hr />
<div>[[CedarX]] is Allwinner's multimedia co-processing technology for hardware accelerated video and image decoding, as used inside their [[A10]] and [[A20]] SoC series and others.<ref>http://www.j1nx.nl/buildroot-xbmc-on-mele-a1000-allwinner-a10/ Buildroot XBMC on the Mele A1000 (Allwinner A10)</ref><ref>http://www.cnx-software.com/2012/11/12/xbmc-for-linux-on-allwinner-a10-devices-it-works-sort-of/ XBMC for Linux on AllWinner A10 Devices? It Works! (Sort of)</ref><br />
<br />
=Overview=<br />
'''CedarX''' is composed of several parts, including:<br />
* A hardware video unit (video engine or "VE" for short)<br />
** Varous Features<br />
*** Adaptive Motion Filter<br />
*** 3D Anaglyph decoding<br />
** MPEG Decoder SubEngine <br />
*** MPEG1 <br />
*** MPEG2<br />
*** MPEG4<br />
*** MS-MPEG<br />
*** VP6<br />
*** MJPEG (JPEG)<br />
*** XDIV/DIVX (mpeg 3.11)<br />
*** Soreson<br />
** H264 Decoder SubEngine <br />
*** H264 <br />
*** VP8<br />
*** AVS Jizun<br />
** VC1 Decoder SubEngine<br />
*** WMV9<br />
** RMVB SubEngine<br />
*** Real Media<br />
** ISP Engine (Image signal processor) <br />
*** Alpha blending{need check}<br />
*** Non-integer resize<br />
** AVC Encoder SubEngine<br />
*** H264 Encode<br />
*** JPEG Encode<br />
*** MPEG Encode {need check}<br />
* A hardware audio codec engine (ACE) (only A10, modern A20,A13 have no this module)<br />
** Audio engines<br />
*** DTS Audio hardware decoder<br />
*** AC3 Audio hardware decoder<br />
** Codec engines<br />
*** PNG (zlib's deflate offload)<br />
*** TSCC Codec(zlib's deflate offload)<br />
<br />
==== Benefits to Allwinner's CedarX technology and libraries:====<br />
* Efficient use of system resources when decoding multimedia, offloading audio and video decoding to CedarX co-processor so that the CPU can be used for other things, (when CedarX is working as it as it should).<br />
* Allows small and low-powered ARM systems to playback high resolution/bitrate multimedia content, which would not be possible using software-only decoding using only the CPU.<br />
<br />
==== Disadvantages Allwinner's CedarX technology and libraries:====<br />
* Allwinner's own CedarX proprietary libraries have no clear usage license, so even if the source code for some versions is available the terms-of-use is unknown in open source software.<br />
* The Android glue code is implemented as a "media player" (parallel to the official Android's MediaCodec API and underlying Stagefright multimedia framework) instead of as standard OpenMAX (OMX) components and API's.<br />
* This "media player" has limitations when it comes to playing back content pointed to by Android URIs and some web-based content.<br />
* There is no glue code for any other multimedia frameworks on GNU/Linux systems. The use of OpenMAX (OMX) instead would have rendered this a non-issue, with existing projects like GstOpenMAX (GStreamer OpenMAX).<br />
<br />
= Reverse engineering =<br />
The video engine is current being reverse engineered with successful results. To the point of making possible an experimental vdpau implementation capable of be used to play videos.<br />
* [[CedarX/Reverse Engineering|Reverse engineering status]]<br />
* Video Engine (VE) [[VE Register guide]]<br />
* Audio Codec Engine (ACE) [[ACE Register guide]]<br />
* A basic tutorial to help get users started in using [[Cedrus|Cedrus/libvdpau-sunxi]].<br />
<br />
= Integration =<br />
* [[XBMC]]<br />
* [[VLC]]<br />
<br />
=CedarX official source code libraries and third-party forks=<br />
* https://github.com/allwinner-dev-team/android_external_cedarx Allwinner Dev Team Android external CedarX fork<br />
* https://github.com/linux-sunxi/cedarx-libs linux-sunxi team fork of the official Allwinner CedarX libcedar source code libraries<br />
* https://github.com/huceke/libcedar libcedar decoder library for libvecore by Edgar Hucek (a.k.a. Gimli) fork for [[XBMC]]<br />
* https://github.com/willswang/libcedarx Wills Wang libcedarx library for libvecore fork for [[VLC]]<br />
* https://github.com/mortaromarcello/android_external_cedarx Android external CedarX fork by mortaromarcello<br />
<br />
= Possibly irrelevant observations =<br />
* There seems to be a distinction in the Android code between audio decoding ("CedarA") and video decoding ("CedarV").<br />
<br />
=References=<br />
<references /><br />
<br />
= See also =<br />
* [[CedarX/Misc Docs]] - some useful facts from IRC chat conversations<br />
* [[CedarXVideoRenderingChart]] - Overview chart of working/ non working video files<br />
* [[CedarX/libve]] - Using the Android blob on linux via libhybris<br />
* [[XBMC]] - XBMC Media Center<br />
* [[VLC]] - VideoLAN Client<br />
* [[CedarXPlayerTest]] - Testing player from Ubuntu image<br />
[[Category:CedarX]]</div>Rockerhttps://linux-sunxi.org/index.php?title=CedarX&diff=9084CedarX2014-05-30T12:27:06Z<p>Rocker: /* Overview */</p>
<hr />
<div>[[CedarX]] is Allwinner's multimedia co-processing technology for hardware accelerated video and image decoding, as used inside their [[A10]] SoC's and others.<ref>http://www.j1nx.nl/buildroot-xbmc-on-mele-a1000-allwinner-a10/ Buildroot XBMC on the Mele A1000 (Allwinner A10)</ref><ref>http://www.cnx-software.com/2012/11/12/xbmc-for-linux-on-allwinner-a10-devices-it-works-sort-of/ XBMC for Linux on AllWinner A10 Devices? It Works! (Sort of)</ref><br />
<br />
=Overview=<br />
'''CedarX''' is composed of several parts, including:<br />
* A hardware video unit (video engine or "VE" for short)<br />
** Varous Features<br />
*** Adaptive Motion Filter<br />
*** 3D Anaglyph decoding<br />
** MPEG Decoder SubEngine <br />
*** MPEG1 <br />
*** MPEG2<br />
*** MPEG4<br />
*** MS-MPEG<br />
*** VP6<br />
*** MJPEG (JPEG)<br />
*** XDIV/DIVX (mpeg 3.11)<br />
*** Soreson<br />
** H264 Decoder SubEngine <br />
*** H264 <br />
*** VP8<br />
*** AVS Jizun<br />
** VC1 Decoder SubEngine<br />
*** WMV9<br />
** RMVB SubEngine<br />
*** Real Media<br />
** ISP Engine (Image signal processor) <br />
*** Alpha blending{need check}<br />
*** Non-integer resize<br />
** AVC Encoder SubEngine<br />
*** H264 Encode<br />
*** JPEG Encode<br />
*** MPEG Encode {need check}<br />
* A hardware audio codec engine (ACE) (only A10, modern A20,A13 have no this module)<br />
** Audio engines<br />
*** DTS Audio hardware decoder<br />
*** AC3 Audio hardware decoder<br />
** Codec engines<br />
*** PNG (zlib's deflate offload)<br />
*** TSCC Codec(zlib's deflate offload)<br />
<br />
==== Benefits to Allwinner's CedarX technology and libraries:====<br />
* Efficient use of system resources when decoding multimedia, offloading audio and video decoding to CedarX co-processor so that the CPU can be used for other things, (when CedarX is working as it as it should).<br />
* Allows small and low-powered ARM systems to playback high resolution/bitrate multimedia content, which would not be possible using software-only decoding using only the CPU.<br />
<br />
==== Disadvantages Allwinner's CedarX technology and libraries:====<br />
* Allwinner's own CedarX proprietary libraries have no clear usage license, so even if the source code for some versions is available the terms-of-use is unknown in open source software.<br />
* The Android glue code is implemented as a "media player" (parallel to the official Android's MediaCodec API and underlying Stagefright multimedia framework) instead of as standard OpenMAX (OMX) components and API's.<br />
* This "media player" has limitations when it comes to playing back content pointed to by Android URIs and some web-based content.<br />
* There is no glue code for any other multimedia frameworks on GNU/Linux systems. The use of OpenMAX (OMX) instead would have rendered this a non-issue, with existing projects like GstOpenMAX (GStreamer OpenMAX).<br />
<br />
= Reverse engineering =<br />
The video engine is current being reverse engineered with successful results. To the point of making possible an experimental vdpau implementation capable of be used to play videos.<br />
* [[CedarX/Reverse Engineering|Reverse engineering status]]<br />
* Video Engine (VE) [[VE Register guide]]<br />
* Audio Codec Engine (ACE) [[ACE Register guide]]<br />
* A basic tutorial to help get users started in using [[Cedrus|Cedrus/libvdpau-sunxi]].<br />
<br />
= Integration =<br />
* [[XBMC]]<br />
* [[VLC]]<br />
<br />
=CedarX official source code libraries and third-party forks=<br />
* https://github.com/allwinner-dev-team/android_external_cedarx Allwinner Dev Team Android external CedarX fork<br />
* https://github.com/linux-sunxi/cedarx-libs linux-sunxi team fork of the official Allwinner CedarX libcedar source code libraries<br />
* https://github.com/huceke/libcedar libcedar decoder library for libvecore by Edgar Hucek (a.k.a. Gimli) fork for [[XBMC]]<br />
* https://github.com/willswang/libcedarx Wills Wang libcedarx library for libvecore fork for [[VLC]]<br />
* https://github.com/mortaromarcello/android_external_cedarx Android external CedarX fork by mortaromarcello<br />
<br />
= Possibly irrelevant observations =<br />
* There seems to be a distinction in the Android code between audio decoding ("CedarA") and video decoding ("CedarV").<br />
<br />
=References=<br />
<references /><br />
<br />
= See also =<br />
* [[CedarX/Misc Docs]] - some useful facts from IRC chat conversations<br />
* [[CedarXVideoRenderingChart]] - Overview chart of working/ non working video files<br />
* [[CedarX/libve]] - Using the Android blob on linux via libhybris<br />
* [[XBMC]] - XBMC Media Center<br />
* [[VLC]] - VideoLAN Client<br />
* [[CedarXPlayerTest]] - Testing player from Ubuntu image<br />
[[Category:CedarX]]</div>Rockerhttps://linux-sunxi.org/index.php?title=Allwinner_SoC_Family&diff=9083Allwinner SoC Family2014-05-30T12:14:02Z<p>Rocker: /* "A"-Series */</p>
<hr />
<div>=== "A"-Series ===<br />
Based on ARMv7 Cortex-A cores (Cortex-A7,A8, and A15) targeted for hi-end devices like digital media player, tablets, and netbooks:<br />
* [[A10|Allwinner A10]] <small>(sun4i)</small> (Cortex-A8)<br />
* [[A13|Allwinner A13]] <small>(sun5i)</small> (Cortex-A8)<br />
* [[A10s|Allwinner A10s]]<small>(sun5i)</small>(Cortex-A8)<br />
* [[A20|Allwinner A20]] <small>(sun7i)</small> 2x(Cortex-A7)<br />
* [[A23|Allwinner A23]] <small>(sun8i)</small> 2x(Cortex-A7)<br />
* [[A31|Allwinner A31]] <small>(sun6i)</small> 4x(Cortex-A7)<br />
* [[A31s|Allwinner A31s]] <small>(sun6i)</small> 4x(Cortex-A7)<br />
* [[A80|Allwinner A80]] <small>(sun?i)</small> 4x(Cortex-A7) + 4x(Cortex-A15)<br />
<br />
=== "A"- Series features: ===<br />
* CPU: ARMv7-A [http://en.wikipedia.org/wiki/ARM_Cortex-A7 Cortex-A7] or [http://en.wikipedia.org/wiki/ARM_Cortex-A8 Cortex-A8] Central Processor Unit which have [[NEON]], [[Vector Floating Point Unit|VFP]], [[TrustZone]], and [[Thumb-2]] co-processor extensions: <br />
** Advanced SIMD: [[NEON]] (ARM's extended general-purpose advanced SIMD vector processing extension engine)<br />
** Vector FPU: [[Vector Floating Point Unit]] - ARM VFPv3 lite (Cortex-A8) / VFPv4 (Cortex-A7) VFPU (Vector Floating Point Unit)<br />
** Security Extensions: <br />
*** TrustZone secure world<br />
*** [[Security_System|Security accelerator]] supporting AES, DES, 3DES, SHA-1, MD5 and pseudo-random number generation<br />
** [[Thumb2]] intruction set extension for optimized code to reduce memory footprint and improve performance<br />
* GPU: [[Mali400]] or SGX544 Graphics Procesor Unit, supporting OpenGL ES and [[Framebuffer]] <br />
* VPU: [[CedarX]] (Video Processor Unit for audio and video hardware decoding or encoding)<br />
* HDMI-transmitter with [[HDMI CEC (Consumer Electronics Control)]], (with exception of A13 which lacks HDMI-transmitter and SATA-controller<ref>[http://olimex.wordpress.com/2012/04/24/cortex-a8-in-tqfp-sure-allwinner-a13/ "Cortex A8 in TQFP? sure Allwinner A13"] ''Retrieved 23 September 2012''</ref>)<br />
* Hardware virtualization capabilities (Cortex-A7 only).<br />
* Up to 4GB memory (Cortex-A8), Up to 1TB memory with LPAE (Cortex-A7 only).<br />
<br />
=== Comparison table for "A"-Series Allwinner SoC's ===<br />
{| class="wikitable"<br />
|-<br />
! scope="row" | !! [[A10]] !! [[A10s]] !! [[A13]] !! [[A20]] !! [[A31]]!! [[A31s]] !! [[A23]]<br />
|-<br />
! scope="row" | Generation <br />
| sun4i || sun5i || sun5i || sun7i || sun6i || || sun8i<br />
|-<br />
! scope="row" | CPU<br />
| Cortex-A8 || Cortex-A8 || Cortex-A8 || Cortex-A7 || Cortex-A7 || Cortex-A7 || Cortex-A7<br />
|-<br />
! scope="row" | CPU Maximum frequency<br />
| 1GHz|| 1GHz || 1GHz|| 912MHz|| ?GHz || ?Ghz || ?Ghz<br />
|-<br />
! scope="row" | Cores<br />
| 1 || 1 || 1 || 2 || 4 || 4 || 2<br />
|-<br />
! scope="row" | Extensions<br />
| NEON, VFPv3, Thumb-2 || NEON, VFPv3, Thumb-2 || NEON, VFPv3, Thumb-2 || NEON, VFPv3 / VFPv4, Thumb-2 || NEON, VFPv3 / VFPv4, Thumb-2 || NEON, VFPv3 / VFPv4, Thumb-2 || NEON, VFPv3 / VFPv4, Thumb-2<br />
|-<br />
! scope="row" | Memory<br />
| DDR2, DDR3 (max 2GB @ DDR800) || DDR2, DDR3 (max 2GB @ DDR800) || DDR2, DDR3 (max 512MB @ DDR800) || LPDDR3/DDR3/LPDDR2 || 2-channel DDR3/LPDDR2, 2-channel DDR3L<br />
|-<br />
! scope="row" | GPU<br />
| [[Mali400]] @ 320Mhz || [[Mali400]] @ 320Mhz || [[Mali400]] @ 320Mhz || [[Mali400]] MP2 @ 350Mhz per shader engine || SGX544 @ 200Mhz per shader engine || SGX544 @ 200Mhz per shader engine || Mali400 MP2 <br />
|-<br />
! scope="row" | GPU API<br />
| OpenGL ES 2.0, OpenVG 1.1 || OpenGL ES 2.0, OpenVG 1.1 || OpenGL ES 2.0, OpenVG 1.1 || OpenGL ES 2.0, OpenVG 1.1 || OpenGL ES 2.0, OpenVG 1.1, OpenCL 1.1, and DirectX 9.3 || OpenGL ES 2.0, OpenVG 1.1, OpenCL 1.1, and DirectX 9.3 || OpenGL ES 2.0, OpenVG 1.1<br />
|-<br />
! scope="row" | [[CedarX|Video decoder]]<br />
| 2160P || 1080P || 1080P || 2160p, 4K×2K, 1080p 3D || 2160p, 4K×2K, 1080p 3D<br />
|-<br />
! scope="row" | [[CedarX|Video encoder]]<br />
| H.264 1080P@30fps,JPEG || H.264 1080P@30fps,JPEG || H.264 1080P@30fps,JPEG || H.264 1080P@30fps,JPEG || H.264 1080P@30fps,JPEG<br />
|-<br />
! scope="row" | [[CedarX|Audio decoder]]<br />
| AC3,DTS || ?|| ? || AC3,DTS|| ?<br />
|-<br />
! scope="row" | Video interfaces<br />
| HDMI 1.3, YPbPr, VGA, CPU/RGB/LVDS LCD || HDMI 1.3, RGB/LVDS LCD || RGB LCD, VGA|| HDMI 1.4, CVBS, YPbPr, VGA, CPU/RGB/LVDS LCD || HDMI 1.4, MIPI DSI, 2-channel LVDS, 2-channel RGB LCD<br />
|-<br />
! scope="row" | Audio interfaces<br />
| I2S, SPDIF, AC97 || I2S, AC97 || I2S, AC97 || I2S, PCM, AC97 || I2S, PCM<br />
|-<br />
! scope="row" | USB OTG<br />
| 1 || 1 || 1 || 1 || 1<br />
|-<br />
! scope="row" | USB Host<br />
| 2 || 1 || 1 || 2 || 2<br />
|-<br />
! scope="row" | Ethernet<br />
| EMAC || EMAC || - || EMAC/GMAC || EMAC/GMAC<br />
|-<br />
! scope="row" | Storage<br />
| NAND (max 64GB), SATA II, SD Card 3.0 || NAND (max 64GB), SD Card 3.0 || NAND (max 64GB), SD Card 3.0 || NAND, MMC, [http://olimex.wordpress.com/2013/04/05/allwinners-a10-and-a20-are-they-really-pin-to-pin-compatible-and-drop-in-replacement/#comment-5452 SATA] || 4x SD Card, eMMC NAND, 2-channel raw NAND<br />
|-<br />
! scope="row" | Package<br />
| BGA441 19mm × 19mm, 0.80mm Pitch || BGA336 14mm × 14mm, 0.65mm Pitch || eLQFP176 20mm × 20mm ||BGA441 19mm × 19mm, 0.80mm Pitch || BGA609 18mm × 18mm, 0.65mm Pitch<br />
|-<br />
! scope="row" | Litography<br />
| 55nm || 55nm|| 55nm || 40nm || 40nm|| 40nm ||40nm<br />
|}<br />
<ref>http://blog.thinkteletronics.com/all-mobile-socsolutions/ All Mobile Soc/Solutions.</ref><br />
<br />
=== "F"-Series ===<br />
'''NOTE: F series not supported by linux-sunxi community due lack of developers and hardware, sun3i have only offical linux port, sunii have no linux support only aw's melis RTOS'''<br />
<br />
<br />
Based on ARMv6 ARM926-EJS core and currenty targeted for low market devices such as cheap ebook readers, etc.<br />
<br />
* [[C100|Boxchip C100]] <small>(sun3i)</small><br />
* [[E200|Boxchip E200]] <small>(sun3i)</small><br />
* [[F20|Boxchip F20]] <small>(sun3i)</small><br />
* [[F10|Boxchip F10]] aka SoChip SC9800 aka Teclast T8100<small>(sunii)</small><br />
* [[F13|Boxchip F13]] <small>(sunii)</small><br />
* [[F13|Boxchip F15]] aka SoChip SC8600 aka Teclast T7200<small>(sunii)</small><br />
* [[F18|Boxchip F18]] <small>(sunii)</small><br />
<br />
==References==<br />
<references /><br />
<br />
[[Category:System_on_Chip]]</div>Rockerhttps://linux-sunxi.org/index.php?title=Allwinner_SoC_Family&diff=9082Allwinner SoC Family2014-05-30T12:12:34Z<p>Rocker: /* "A"-Series */</p>
<hr />
<div>=== "A"-Series ===<br />
Based on ARMv7 Cortex-A cores (Cortex-A7,A8, and A15) targeted for hi-end devices like tablet PC, smartphones, and netbooks:<br />
* [[A10|Allwinner A10]] <small>(sun4i)</small> (Cortex-A8)<br />
* [[A13|Allwinner A13]] <small>(sun5i)</small> (Cortex-A8)<br />
* [[A10s|Allwinner A10s]]<small>(sun5i)</small>(Cortex-A8)<br />
* [[A20|Allwinner A20]] <small>(sun7i)</small> 2x(Cortex-A7)<br />
* [[A23|Allwinner A23]] <small>(sun8i)</small> 2x(Cortex-A7)<br />
* [[A31|Allwinner A31]] <small>(sun6i)</small> 4x(Cortex-A7)<br />
* [[A31s|Allwinner A31s]] <small>(sun6i)</small> 4x(Cortex-A7)<br />
* [[A80|Allwinner A80]] <small>(sun?i)</small> 4x(Cortex-A7) + 4x(Cortex-A15)<br />
<br />
=== "A"- Series features: ===<br />
* CPU: ARMv7-A [http://en.wikipedia.org/wiki/ARM_Cortex-A7 Cortex-A7] or [http://en.wikipedia.org/wiki/ARM_Cortex-A8 Cortex-A8] Central Processor Unit which have [[NEON]], [[Vector Floating Point Unit|VFP]], [[TrustZone]], and [[Thumb-2]] co-processor extensions: <br />
** Advanced SIMD: [[NEON]] (ARM's extended general-purpose advanced SIMD vector processing extension engine)<br />
** Vector FPU: [[Vector Floating Point Unit]] - ARM VFPv3 lite (Cortex-A8) / VFPv4 (Cortex-A7) VFPU (Vector Floating Point Unit)<br />
** Security Extensions: <br />
*** TrustZone secure world<br />
*** [[Security_System|Security accelerator]] supporting AES, DES, 3DES, SHA-1, MD5 and pseudo-random number generation<br />
** [[Thumb2]] intruction set extension for optimized code to reduce memory footprint and improve performance<br />
* GPU: [[Mali400]] or SGX544 Graphics Procesor Unit, supporting OpenGL ES and [[Framebuffer]] <br />
* VPU: [[CedarX]] (Video Processor Unit for audio and video hardware decoding or encoding)<br />
* HDMI-transmitter with [[HDMI CEC (Consumer Electronics Control)]], (with exception of A13 which lacks HDMI-transmitter and SATA-controller<ref>[http://olimex.wordpress.com/2012/04/24/cortex-a8-in-tqfp-sure-allwinner-a13/ "Cortex A8 in TQFP? sure Allwinner A13"] ''Retrieved 23 September 2012''</ref>)<br />
* Hardware virtualization capabilities (Cortex-A7 only).<br />
* Up to 4GB memory (Cortex-A8), Up to 1TB memory with LPAE (Cortex-A7 only).<br />
<br />
=== Comparison table for "A"-Series Allwinner SoC's ===<br />
{| class="wikitable"<br />
|-<br />
! scope="row" | !! [[A10]] !! [[A10s]] !! [[A13]] !! [[A20]] !! [[A31]]!! [[A31s]] !! [[A23]]<br />
|-<br />
! scope="row" | Generation <br />
| sun4i || sun5i || sun5i || sun7i || sun6i || || sun8i<br />
|-<br />
! scope="row" | CPU<br />
| Cortex-A8 || Cortex-A8 || Cortex-A8 || Cortex-A7 || Cortex-A7 || Cortex-A7 || Cortex-A7<br />
|-<br />
! scope="row" | CPU Maximum frequency<br />
| 1GHz|| 1GHz || 1GHz|| 912MHz|| ?GHz || ?Ghz || ?Ghz<br />
|-<br />
! scope="row" | Cores<br />
| 1 || 1 || 1 || 2 || 4 || 4 || 2<br />
|-<br />
! scope="row" | Extensions<br />
| NEON, VFPv3, Thumb-2 || NEON, VFPv3, Thumb-2 || NEON, VFPv3, Thumb-2 || NEON, VFPv3 / VFPv4, Thumb-2 || NEON, VFPv3 / VFPv4, Thumb-2 || NEON, VFPv3 / VFPv4, Thumb-2 || NEON, VFPv3 / VFPv4, Thumb-2<br />
|-<br />
! scope="row" | Memory<br />
| DDR2, DDR3 (max 2GB @ DDR800) || DDR2, DDR3 (max 2GB @ DDR800) || DDR2, DDR3 (max 512MB @ DDR800) || LPDDR3/DDR3/LPDDR2 || 2-channel DDR3/LPDDR2, 2-channel DDR3L<br />
|-<br />
! scope="row" | GPU<br />
| [[Mali400]] @ 320Mhz || [[Mali400]] @ 320Mhz || [[Mali400]] @ 320Mhz || [[Mali400]] MP2 @ 350Mhz per shader engine || SGX544 @ 200Mhz per shader engine || SGX544 @ 200Mhz per shader engine || Mali400 MP2 <br />
|-<br />
! scope="row" | GPU API<br />
| OpenGL ES 2.0, OpenVG 1.1 || OpenGL ES 2.0, OpenVG 1.1 || OpenGL ES 2.0, OpenVG 1.1 || OpenGL ES 2.0, OpenVG 1.1 || OpenGL ES 2.0, OpenVG 1.1, OpenCL 1.1, and DirectX 9.3 || OpenGL ES 2.0, OpenVG 1.1, OpenCL 1.1, and DirectX 9.3 || OpenGL ES 2.0, OpenVG 1.1<br />
|-<br />
! scope="row" | [[CedarX|Video decoder]]<br />
| 2160P || 1080P || 1080P || 2160p, 4K×2K, 1080p 3D || 2160p, 4K×2K, 1080p 3D<br />
|-<br />
! scope="row" | [[CedarX|Video encoder]]<br />
| H.264 1080P@30fps,JPEG || H.264 1080P@30fps,JPEG || H.264 1080P@30fps,JPEG || H.264 1080P@30fps,JPEG || H.264 1080P@30fps,JPEG<br />
|-<br />
! scope="row" | [[CedarX|Audio decoder]]<br />
| AC3,DTS || ?|| ? || AC3,DTS|| ?<br />
|-<br />
! scope="row" | Video interfaces<br />
| HDMI 1.3, YPbPr, VGA, CPU/RGB/LVDS LCD || HDMI 1.3, RGB/LVDS LCD || RGB LCD, VGA|| HDMI 1.4, CVBS, YPbPr, VGA, CPU/RGB/LVDS LCD || HDMI 1.4, MIPI DSI, 2-channel LVDS, 2-channel RGB LCD<br />
|-<br />
! scope="row" | Audio interfaces<br />
| I2S, SPDIF, AC97 || I2S, AC97 || I2S, AC97 || I2S, PCM, AC97 || I2S, PCM<br />
|-<br />
! scope="row" | USB OTG<br />
| 1 || 1 || 1 || 1 || 1<br />
|-<br />
! scope="row" | USB Host<br />
| 2 || 1 || 1 || 2 || 2<br />
|-<br />
! scope="row" | Ethernet<br />
| EMAC || EMAC || - || EMAC/GMAC || EMAC/GMAC<br />
|-<br />
! scope="row" | Storage<br />
| NAND (max 64GB), SATA II, SD Card 3.0 || NAND (max 64GB), SD Card 3.0 || NAND (max 64GB), SD Card 3.0 || NAND, MMC, [http://olimex.wordpress.com/2013/04/05/allwinners-a10-and-a20-are-they-really-pin-to-pin-compatible-and-drop-in-replacement/#comment-5452 SATA] || 4x SD Card, eMMC NAND, 2-channel raw NAND<br />
|-<br />
! scope="row" | Package<br />
| BGA441 19mm × 19mm, 0.80mm Pitch || BGA336 14mm × 14mm, 0.65mm Pitch || eLQFP176 20mm × 20mm ||BGA441 19mm × 19mm, 0.80mm Pitch || BGA609 18mm × 18mm, 0.65mm Pitch<br />
|-<br />
! scope="row" | Litography<br />
| 55nm || 55nm|| 55nm || 40nm || 40nm|| 40nm ||40nm<br />
|}<br />
<ref>http://blog.thinkteletronics.com/all-mobile-socsolutions/ All Mobile Soc/Solutions.</ref><br />
<br />
=== "F"-Series ===<br />
'''NOTE: F series not supported by linux-sunxi community due lack of developers and hardware, sun3i have only offical linux port, sunii have no linux support only aw's melis RTOS'''<br />
<br />
<br />
Based on ARMv6 ARM926-EJS core and currenty targeted for low market devices such as cheap ebook readers, etc.<br />
<br />
* [[C100|Boxchip C100]] <small>(sun3i)</small><br />
* [[E200|Boxchip E200]] <small>(sun3i)</small><br />
* [[F20|Boxchip F20]] <small>(sun3i)</small><br />
* [[F10|Boxchip F10]] aka SoChip SC9800 aka Teclast T8100<small>(sunii)</small><br />
* [[F13|Boxchip F13]] <small>(sunii)</small><br />
* [[F13|Boxchip F15]] aka SoChip SC8600 aka Teclast T7200<small>(sunii)</small><br />
* [[F18|Boxchip F18]] <small>(sunii)</small><br />
<br />
==References==<br />
<references /><br />
<br />
[[Category:System_on_Chip]]</div>Rockerhttps://linux-sunxi.org/index.php?title=Main_Page&diff=9081Main Page2014-05-30T12:06:59Z<p>Rocker: </p>
<hr />
<div>Welcome to the wiki of the [[:Category:Community | linux-sunxi community]], an open source software community dedicated to Allwinner based [[:Category:Devices|devices]].<br />
<br />
<div style="float:right; margin-left:1em;">__TOC__</div><br />
<br />
= What is sunxi =<br />
<br />
'''sunxi''' represents the family of ARM [[System on Chip|SoC (System on Chip)]] designed for embedded systems, and made by [[Allwinner Tech.]] in [http://en.wikipedia.org/wiki/Zhuhai Zhuhai (Guangdong, China)]. The most popular '''sunxi''' SoC model is the [[A10|Allwinner A10]] and the [[A13|Allwinner A13]]. Their predecessor was an ARM9 named [[F20|Boxchip F20]] (<small>''sun3i''</small>) and their successors are Allwinner [[A20]], [[A23]], [[A31]], and [[A80]]. See [[Allwinner SoC Family]] for more information.<br />
<br />
= Community =<br />
<br />
The [[:Category:Community|sunxi community]] is a very active and advanced one. For more information, check our [[:Category:Community|linux-sunxi community page]]. It explains how to get help and how to contact us, and how you can contribute as well.<br />
<br />
= Allwinner based Devices =<br />
<br />
Due to the popularity of the Allwinner SoCs, there are literally thousands of different devices out there.<br />
<br />
If you are looking for support for your device, please take a look at our [[Identification_guide | guide to identifying your device]]. If you cannot find your device, then you might need to work through our [[New_Device_howto| new device howto]].<br />
<br />
If you are interested in buying an allwinner based device, then read through our [[Buying_guide | buying guide]].<br />
<br />
You can browse the already documented board here <br />
<categorytree mode=pages hideroot=off depth=0>Boards</categorytree><br />
<br />
= Documentation =<br />
== Quick reference guide ==<br />
<br />
{| class="wikitable"<br />
|- style="vertical-align: top; text-align:center;"<br />
!| Software<br />
!| Hardware<br />
|- style="vertical-align: top;"<br />
|<br />
* [[Bootable OS images]]: Complete ready-to-use SD card images<br />
* [[BSP|Board Support Package (BSP)]]: A scripted way to create images and SD-Cards.<br />
* [[Manual_build_howto|Manual build howto]]: Getting a specific U-Boot, Linux kernel, and a rootfs on an SD card.<br />
* [[sunxi-tools]]: Tools to help hacking sunxi devices<br />
* [[Packages]]: The linux-sunxi package repository<br />
* [[Linux Kernel]]: Kernel repositories and versions<br />
<categorytree mode=pages hideroot=off depth=0>Linux Distributions</categorytree><br />
<categorytree mode=pages hideroot=off depth=0>Android</categorytree><br />
<categorytree mode=pages hideroot=off depth=0>BSD</categorytree><br />
<categorytree mode=pages hideroot=off depth=0>Software</categorytree><br />
<categorytree mode=pages hideroot=off depth=0>Proprietary Software</categorytree><br />
<categorytree mode=pages hideroot=off depth=0>Development</categorytree><br />
|<br />
<categorytree mode=pages hideroot=on depth=2>Register guide</categorytree><br />
<categorytree mode=pages hideroot=off depth=0>CedarX</categorytree><br />
* [[Used IP cores]] - used IP cores in current generation of Allwinner devices<br />
* [[JTAG]] on A10 devices through µSD port<br />
* [[GPIO]] - General Purpose Input/Output on devices based on Allwinner SoCs<br />
* [[PIO]] - Programmed input/output (PIO) on devices based on Allwinner SoCs<br />
* [[MicroSD Breakout]]<br />
* [[Audio Codec]] - Audio Codec on devices based on Allwinner SoCs<br />
* [[CSI]] - Camera Sensor Interface on devices based on Allwinner SoCs<br />
* [[Cpufreq]] - cpufreq support on devices based on Allwinner SoCs<br />
* [[Wifi]] - 8192cu dropping connection workaround<br />
* [[I2Cdev]] - I2c communication in the userspace.<br />
* [[SPIdev]] - SPI communication in the userspace.<br />
* [[1-Wire]] - 1-Wire communication in the userspace.<br />
|}<br />
<br />
== Tutorials ==<br />
This wiki includes some fine tutorials. Please consider improving them.<br />
<categorytree mode=pages hideroot=off depth=0>Tutorial</categorytree></div>Rockerhttps://linux-sunxi.org/index.php?title=A20&diff=9017A202014-05-26T17:17:13Z<p>Rocker: </p>
<hr />
<div>{{Infobox SoC<br />
| image = Allwinner_A20.jpg<br />
| manufacturer = Allwinner<br />
| process = <br />
| cpu = Dual-Core ARM Cortex-A7<br />
| ltwo = <br />
| extensions = <br />
| memory = LPDDR3/DDR3/LPDDR2<br />
| gpu = [[Mali400]] MP2<br />
| vpu = <br />
| apu = <br />
| video = HDMI 1.4, CVBS, YPbPr, VGA, CPU/RGB/LVDS LCD<br />
| audio = I2S, PCM, AC97<br />
| network = <br />
| storage = MMC, NAND<br />
| usb = OTG, 2x Host<br />
| other = <br />
| release_date = December 2012<br />
| website = [http://www.allwinnertech.com/en/product/A20.html Product Page]<br />
}}<br />
<br />
Allwinner [[A20]] (sun7i) SoC features a Dual-Core Cortex-A7 ARM CPU, and a [[Mali400]] MP2 GPU from ARM.<br />
<br />
Allwinner A20 is a low-end (budget) version of the [[A31]]. It shares its Cortex-A7 ARM CPU architecture, but at the same time it is also pin-to-pin compatible with [[A10]].<br />
<br />
A20 is fully supported by the community from linux-sunxi 3.4 kernel and later.<br />
<br />
=Overview=<br />
A20 CPU consists of dual ARM Cortex-A7 cores, and integrates the Mali400 MP2 GPU. Together with [[CedarX]] multimedia processing unit that is capable of up to 2160p (3840x1080@30fps 4k resolution or 1080p 3D decoding) video decoding, with integrated HDMI 1.4 output support, and H.264 HP (High Profile) in 1080p at 30fps video encoding.<br />
<br />
====Main components of the A10 ====<br />
* CPU: Dual-Core ARM [http://en.wikipedia.org/wiki/ARM_Cortex-A7 Cortex-A7 1GHz Processor] which have both VFP4 and NEON SIMD co-processors: <br />
** FPU: standard ARM VFPv4 FPU Floating Point Unit<br />
** SIMD: NEON (ARM's extended general-purpose SIMD vector processing extension engine)<br />
* GPU: [[Mali400|Mali400 MP2]], and [[Framebuffer]] <br />
* VPU: [[CedarX]] (Video Processor Unit for audio and video hardware decoding or encoding)<br />
* HDMI-transmitter: HDMI CEC (Consumer Electronics Control)<br />
<br />
==Cortex-A7==<br />
Cortex-A7 is 100% ISA compatible with the Cortex-A15, this includes the new virtualization instructions, integer divide support and 40-bit memory addressing. Any code running on an A15 can run on a Cortex A7, just slower. This is a very important feature as it enables SoC vendors to build chips with both Cortex A7 and Cortex A15 cores, switching between them depending on workload requirements. ARM calls this a big.LITTLE configuration.<ref>http://www.anandtech.com/show/4991/arms-cortex-a7-bringing-cheaper-dualcore-more-power-efficient-highend-devices</ref><ref>http://en.wikipedia.org/wiki/ARM_Cortex-A7_MPCore][http://www.arm.com/products/processors/cortex-a/cortex-a7.php</ref><br />
<br />
=== Virtualization ===<br />
Cortex A7 and A15 includes hardware virtualization support.<br />
<br />
* It is managed by Xen ([http://www-archive.xenproject.org/files/xensummit_seoul11/nov2/2_XSAsia11_JGoodacre_HW_accelerated_virtualization_in_the_ARM_Cortex_processors.pdf Presentation of Cortex A7 and A15 capabilities for virtualisation], [http://www-archive.xenproject.org/products/xen_arm.html Xen ARM] on xenproject.org, [http://blog.xen.org/index.php/2012/09/21/xensummit-sessions-new-pvh-virtualisation-mode-for-arm-cortex-a15arm-servers-and-x86/ PVH mode] on blog.xen.org, [http://wiki.xen.org/wiki/Xen_ARMv7_with_Virtualization_Extensions Xen ARMv7 with Vritualization Extensions] on xenproject.org wiki)<br />
<br />
* [http://wiki.xen.org/wiki/Xen_ARMv7_with_Virtualization_Extensions/Allwinner there is a guide about running xen on a20]<br />
<br />
* [http://www.virtualopensystems.com/ Some guides to deploy virtualization on Cotex-A15 and source for virtualization with KVM on Cortex-A15 on github]<br />
<br />
* [http://www.ok-labs.com/releases/release/open-kernel-labs-delivers-okl4-mobile-virtualization-for-arm-Cortex-A7 Open Kernel Labs Delivers OKL4 Mobile Virtualization for ARM Cortex-A7 Processors]<br />
<br />
On the kvm branch of kernel.org, there is description of Cortex-A15 Vitrualization extensions VGIC registers :<br />
<br />
* [https://git.kernel.org/cgit/virt/kvm/kvm.git/tree/Documentation/devicetree/bindings/arm/gic.txt GIC of ARM on kvm branch of the kernel]<br />
<br />
After the ARM Cortex-A7 documentation:<br />
<br />
* GIC memory MAP on Cortex-A7<ref>Cortex-A7 MPCore Technical Reference Manual - 8.2.1. GIC memory-map</ref>:<br />
0x4000-0x4FFF Virtual interface control, common base address<br />
0x5000-0x5FFF Virtual interface control, processor-specific base address<br />
0x6000-0x7FFF Virtual CPU interface<br />
* Virtual Maintenance Interrupt (PPI6)<ref>Cortex-A7 MPCore Technical Reference Manual - 8.2.2. Interrupt sources</ref> <br />
* 2 virtual interrupt signals, nVIRQ and nVFIQ<ref>Cortex-A7 MPCore Technical Reference Manual - 8.2.4. GIC configuration</ref><br />
* With MMU-400, Intermediate Physical Address (IPA) ca be used by guest OS<ref>CoreLink MMU-400 System Memory Management Unit Technical Reference Manual - 1.1. About the MMU-400</ref><br />
<br />
=A20 SoC Features=<br />
[[File:Allwinner A20.jpg|thumb|A20 SoC on a Cubieboard2]]<br />
* CPU<br />
** ARM Cortex-A7 Dual-Core<br />
** 256KiB L2-Cache (shared between two cores)<br />
** 32KiB (Instruction) / 32KiB (Data) L1-Cache per core<br />
** SIMD NEON, VFP4<br />
** Virtualization<br />
** Large Physical Address Extensions (LPAE) 1TB<br />
* GPU<br />
** ARM Mali400 MP2<br />
** Featuring 1 vertex shader (GP) and 2 fragment shaders (PP).<br />
** Complies with OpenGL ES 2.0<br />
* Memory<br />
** LPDDR2/DDR3/DDR3L controller<br />
** NAND Flash controller and 64-bit ECC<br />
* Video<br />
** HD H.264 2160P video decoding<br />
** Full HD video decoding<br />
** BD Directory, BD ISO and BD m2ts video decoding<br />
** H.264 High Profile 1080P@30fps encoding<br />
** 3840×1080@30fps 3D decoding<br />
** Complies with RTSP, HTTP,HLS,RTMP,MMS streaming media protocol<br />
* Display<br />
** Support multi-channel HD display<br />
** Integrated HDMI 1.4<br />
** CPU/RGB/LVDS LCD interface 1920×1080 resolution<br />
** CVBS/YPbPr/VGA support<br />
** Integrated TV decoder<br />
* Camera<br />
** Integrated parallel 8-bit I/F YUV sensor<br />
** Integrated 24-bit parallel YUV 444 I/F<br />
** 5M/8M CMOS sensor support<br />
** Dual-sensor support<br />
* Audio<br />
** Integrated HI-FI 100dB Audio Codec<br />
** Dual MIC noise cancellation<br />
<br />
= Documentation =<br />
* [http://dl.linux-sunxi.org/A20/A20%20Brief%202013-04-07.pdf A20 Product Brief]<br />
* [http://dl.linux-sunxi.org/A20/A20%20User%20Manual%202013-03-22.pdf A20 User Manual]<br />
<br />
= See also =<br />
* [[Mali400]]<br />
* [[A10]]<br />
* [[A10s]]<br />
* [[A13]]<br />
* [[A31]]<br />
<br />
=References=<br />
<references /><br />
<br />
= External links =<br />
* [http://www.allwinnertech.com/en/product/A20.html Product Page]<br />
* [https://github.com/amery/linux-allwinner/tree/import/lichee-3.3/a20-dev kernel source code for Allwinner A20]<br />
* [https://github.com/OLIMEX/OLINUXINO/blob/master/HARDWARE/A20-PDFs/A20_PAD_STD_V1_1.rar?raw=true Allwinner A20 EVB Schematics]<br />
* [https://github.com/OLIMEX/OLINUXINO/blob/master/HARDWARE/A20-PDFs/A20%20brief%2020130306.pdf?raw=true Allwinner A20 product brief]<br />
* [http://en.wikipedia.org/wiki/Allwinner_A20 Allwinner A20 article on wikipedia.org]<br />
<br />
[[Category:System on Chip]]<br />
[[Category:Allwinner]]<br />
[[Category:A20]]</div>Rockerhttps://linux-sunxi.org/index.php?title=A20&diff=9016A202014-05-26T17:16:44Z<p>Rocker: /* Overview */</p>
<hr />
<div>{{Infobox SoC<br />
| image = Allwinner_A20.jpg<br />
| manufacturer = Allwinner<br />
| process = <br />
| cpu = Dual-Core ARM Cortex-A7<br />
| ltwo = <br />
| extensions = <br />
| memory = LPDDR3/DDR3/LPDDR2<br />
| gpu = [[Mali400]] MP2<br />
| vpu = <br />
| apu = <br />
| video = HDMI 1.4, CVBS, YPbPr, VGA, CPU/RGB/LVDS LCD<br />
| audio = I2S, PCM, AC97<br />
| network = <br />
| storage = MMC, NAND<br />
| usb = OTG, 2x Host<br />
| other = <br />
| release_date = December 2012<br />
| website = [http://www.allwinnertech.com/en/product/A20.html Product Page]<br />
}}<br />
<br />
Allwinner [[A20]] (sun7i) SoC features a Dual-Core Cortex-A7 ARM CPU, and a [[Mali400]] MP2 GPU from ARM.<br />
<br />
Allwinner A20 is a low-end (budget) version of the [[A31]]. It shares its Cortex-A7 ARM CPU architecture, but at the same time it is also pin-to-pin compatible with [[A10]].<br />
<br />
=Overview=<br />
A20 CPU consists of dual ARM Cortex-A7 cores, and integrates the Mali400 MP2 GPU. Together with [[CedarX]] multimedia processing unit that is capable of up to 2160p (3840x1080@30fps 4k resolution or 1080p 3D decoding) video decoding, with integrated HDMI 1.4 output support, and H.264 HP (High Profile) in 1080p at 30fps video encoding.<br />
<br />
====Main components of the A10 ====<br />
* CPU: Dual-Core ARM [http://en.wikipedia.org/wiki/ARM_Cortex-A7 Cortex-A7 1GHz Processor] which have both VFP4 and NEON SIMD co-processors: <br />
** FPU: standard ARM VFPv4 FPU Floating Point Unit<br />
** SIMD: NEON (ARM's extended general-purpose SIMD vector processing extension engine)<br />
* GPU: [[Mali400|Mali400 MP2]], and [[Framebuffer]] <br />
* VPU: [[CedarX]] (Video Processor Unit for audio and video hardware decoding or encoding)<br />
* HDMI-transmitter: HDMI CEC (Consumer Electronics Control)<br />
<br />
==Cortex-A7==<br />
Cortex-A7 is 100% ISA compatible with the Cortex-A15, this includes the new virtualization instructions, integer divide support and 40-bit memory addressing. Any code running on an A15 can run on a Cortex A7, just slower. This is a very important feature as it enables SoC vendors to build chips with both Cortex A7 and Cortex A15 cores, switching between them depending on workload requirements. ARM calls this a big.LITTLE configuration.<ref>http://www.anandtech.com/show/4991/arms-cortex-a7-bringing-cheaper-dualcore-more-power-efficient-highend-devices</ref><ref>http://en.wikipedia.org/wiki/ARM_Cortex-A7_MPCore][http://www.arm.com/products/processors/cortex-a/cortex-a7.php</ref><br />
<br />
=== Virtualization ===<br />
Cortex A7 and A15 includes hardware virtualization support.<br />
<br />
* It is managed by Xen ([http://www-archive.xenproject.org/files/xensummit_seoul11/nov2/2_XSAsia11_JGoodacre_HW_accelerated_virtualization_in_the_ARM_Cortex_processors.pdf Presentation of Cortex A7 and A15 capabilities for virtualisation], [http://www-archive.xenproject.org/products/xen_arm.html Xen ARM] on xenproject.org, [http://blog.xen.org/index.php/2012/09/21/xensummit-sessions-new-pvh-virtualisation-mode-for-arm-cortex-a15arm-servers-and-x86/ PVH mode] on blog.xen.org, [http://wiki.xen.org/wiki/Xen_ARMv7_with_Virtualization_Extensions Xen ARMv7 with Vritualization Extensions] on xenproject.org wiki)<br />
<br />
* [http://wiki.xen.org/wiki/Xen_ARMv7_with_Virtualization_Extensions/Allwinner there is a guide about running xen on a20]<br />
<br />
* [http://www.virtualopensystems.com/ Some guides to deploy virtualization on Cotex-A15 and source for virtualization with KVM on Cortex-A15 on github]<br />
<br />
* [http://www.ok-labs.com/releases/release/open-kernel-labs-delivers-okl4-mobile-virtualization-for-arm-Cortex-A7 Open Kernel Labs Delivers OKL4 Mobile Virtualization for ARM Cortex-A7 Processors]<br />
<br />
On the kvm branch of kernel.org, there is description of Cortex-A15 Vitrualization extensions VGIC registers :<br />
<br />
* [https://git.kernel.org/cgit/virt/kvm/kvm.git/tree/Documentation/devicetree/bindings/arm/gic.txt GIC of ARM on kvm branch of the kernel]<br />
<br />
After the ARM Cortex-A7 documentation:<br />
<br />
* GIC memory MAP on Cortex-A7<ref>Cortex-A7 MPCore Technical Reference Manual - 8.2.1. GIC memory-map</ref>:<br />
0x4000-0x4FFF Virtual interface control, common base address<br />
0x5000-0x5FFF Virtual interface control, processor-specific base address<br />
0x6000-0x7FFF Virtual CPU interface<br />
* Virtual Maintenance Interrupt (PPI6)<ref>Cortex-A7 MPCore Technical Reference Manual - 8.2.2. Interrupt sources</ref> <br />
* 2 virtual interrupt signals, nVIRQ and nVFIQ<ref>Cortex-A7 MPCore Technical Reference Manual - 8.2.4. GIC configuration</ref><br />
* With MMU-400, Intermediate Physical Address (IPA) ca be used by guest OS<ref>CoreLink MMU-400 System Memory Management Unit Technical Reference Manual - 1.1. About the MMU-400</ref><br />
<br />
=A20 SoC Features=<br />
[[File:Allwinner A20.jpg|thumb|A20 SoC on a Cubieboard2]]<br />
* CPU<br />
** ARM Cortex-A7 Dual-Core<br />
** 256KiB L2-Cache (shared between two cores)<br />
** 32KiB (Instruction) / 32KiB (Data) L1-Cache per core<br />
** SIMD NEON, VFP4<br />
** Virtualization<br />
** Large Physical Address Extensions (LPAE) 1TB<br />
* GPU<br />
** ARM Mali400 MP2<br />
** Featuring 1 vertex shader (GP) and 2 fragment shaders (PP).<br />
** Complies with OpenGL ES 2.0<br />
* Memory<br />
** LPDDR2/DDR3/DDR3L controller<br />
** NAND Flash controller and 64-bit ECC<br />
* Video<br />
** HD H.264 2160P video decoding<br />
** Full HD video decoding<br />
** BD Directory, BD ISO and BD m2ts video decoding<br />
** H.264 High Profile 1080P@30fps encoding<br />
** 3840×1080@30fps 3D decoding<br />
** Complies with RTSP, HTTP,HLS,RTMP,MMS streaming media protocol<br />
* Display<br />
** Support multi-channel HD display<br />
** Integrated HDMI 1.4<br />
** CPU/RGB/LVDS LCD interface 1920×1080 resolution<br />
** CVBS/YPbPr/VGA support<br />
** Integrated TV decoder<br />
* Camera<br />
** Integrated parallel 8-bit I/F YUV sensor<br />
** Integrated 24-bit parallel YUV 444 I/F<br />
** 5M/8M CMOS sensor support<br />
** Dual-sensor support<br />
* Audio<br />
** Integrated HI-FI 100dB Audio Codec<br />
** Dual MIC noise cancellation<br />
<br />
= Documentation =<br />
* [http://dl.linux-sunxi.org/A20/A20%20Brief%202013-04-07.pdf A20 Product Brief]<br />
* [http://dl.linux-sunxi.org/A20/A20%20User%20Manual%202013-03-22.pdf A20 User Manual]<br />
<br />
= See also =<br />
* [[Mali400]]<br />
* [[A10]]<br />
* [[A10s]]<br />
* [[A13]]<br />
* [[A31]]<br />
<br />
=References=<br />
<references /><br />
<br />
= External links =<br />
* [http://www.allwinnertech.com/en/product/A20.html Product Page]<br />
* [https://github.com/amery/linux-allwinner/tree/import/lichee-3.3/a20-dev kernel source code for Allwinner A20]<br />
* [https://github.com/OLIMEX/OLINUXINO/blob/master/HARDWARE/A20-PDFs/A20_PAD_STD_V1_1.rar?raw=true Allwinner A20 EVB Schematics]<br />
* [https://github.com/OLIMEX/OLINUXINO/blob/master/HARDWARE/A20-PDFs/A20%20brief%2020130306.pdf?raw=true Allwinner A20 product brief]<br />
* [http://en.wikipedia.org/wiki/Allwinner_A20 Allwinner A20 article on wikipedia.org]<br />
<br />
[[Category:System on Chip]]<br />
[[Category:Allwinner]]<br />
[[Category:A20]]</div>Rockerhttps://linux-sunxi.org/index.php?title=Talk:CedarX/XBMC&diff=8851Talk:CedarX/XBMC2014-05-10T12:39:34Z<p>Rocker: /* VidOn.me released XBMC code for using CedarX on A10 and A20? */</p>
<hr />
<div>==VidOn.me released XBMC code for using CedarX on A10 and A20?==<br />
Have VidOn.me finally complied with the GPL now or? http://www.phoronix.com/scan.php?page=news_item&px=MTY4NjI I wonder if VidOn.me have finally complied with the GPL license for XBMC as they claim or? As you may already know from CNX-software article here http://www.cnx-software.com/2013/12/20/xbmc-arm-news-allwinner-a20-a31-apk-released-10-discount-on-ouya-console/ VidOn.me have an Allwinner A20 based media player called "VidOn.me AV100" that they are using a forked version for XBMC on, but like many Chinese companies they have previously not released all the source code changes and modification as they are required to as XBMC is licensed under GPLv2 (GPL version 2), but now it looks like they might have, see: https://github.com/vidonme/xbmc<br />
<br />
VidOn.me have updated their repository here https://github.com/vidonme/xbmc for their XBMC fork on GitHub.com with new source code, which looks to contain a new video player "core" for Allwinner A20 (and A10 too since both uses the same CedarX VPU). So now the question also remains if this now really is the full and up-to-date source code, then will the XBMC project xbmc.org accept this code for mainline and merge it upstream into XBMC master at https://github.com/xbmc/xbmc/<br />
<br />
==XBMC for armhf==<br />
While testing to cross compile xbmc for armhf, this list is a little brainstorming of the steps that i could remeber:<br />
The wiki page has to be rewritten. So the whole things has to be done a second time. With protocolling!!!<br />
<br />
My memos for armhf:<br />
* cross-compiled on a debian/sid-amd64(in vmware-virtual machine on windows vista;-)).<br />
* build your kernel, uboot, script.bin, boot.scr and debian armhf-rootfs like described in the rhomus-tech-"build-debian-for-mele-from-source"-wiki. adapt it do sid and armhf! <- be careful, current git-branches maybe broken due to heavy development?!<br />
* be sure to use components, that fit together!<br />
* you need a kernel with r3p0-mali-driver, to fit to binary mali-libs (i used stage/sunxi-3.0)<br />
* after setting up rootfs, chroot into rootfs and do all "apt-get build-dep xbmc" and other "apt-get install/remove"-things for needed packages in your chroot!<br />
* for newest (2012/10/30) xbmca10 you need to install libssh-4 and libssh-dev in chroot, if not already done by "apt-get build-dep xbmc"<br />
* "apt-get remove libegl1-mesa libegl1-mesa-dev libegl1-mesa-drivers libgles2-mesa libgles2-mesa-dev" isn't needed? no gl-stuff installed to be removed?<br />
* your includes for crosscompiling xbmc must point to the include dirs of your rootfs(SDKSTAGE)<br />
* you may the make/gcc -lines in config.log combined with a 'find / -name "....."' to check if -I"..."-parameters are set right etc.<br />
* set PKG_CONFIG_SYSROOT_DIR=$(SDKSTAGE) in depends.mk to let configure find the right pkg-config-things<br />
* check depends.mk and change dirs and USEARMHF=1!<br />
* follow empat0's instructions in depends.mk and set symlinks:<br />
I had to make symlinks for<br />
# /lib/arm-linux-gnueabi, /usr/lib/arm-linux-gnueabi<br />
# and /usr/include/arm-linux-gnueabi to their path in ${SDKSTAGE} <br />
* for cross-compilation remeber to do (not in chroot):<br />
apt-get install cmake shtool swig autoconf autotools-dev automake autopoint libtool default-jre gawk gperf zip g++-4.6-arm-linux-gnueabihf (maybe not complete listing)<br />
set all symlinks to version files (gcc -> gcc-4.6 etc...)<br />
* be sure to all the files/links/dirs named right and in the right place with *hf-ending like listed in depends.mk<br />
* follow configure errors (config.log) and install the needed packages (dev-packages: chroot and install in armhf)<br />
<br />
Finally edit the wiki page ;-)<br />
<br />
==Buildroot XBMC on the Mele A1000 and A2000 (Allwinner A10)==<br />
[http://www.j1nx.nl/buildroot-xbmc-on-mele-a1000-allwinner-a10/ http://www.j1nx.nl/buildroot-xbmc-on-mele-a1000-allwinner-a10/]<br />
<br />
http://www.cnx-software.com/2012/11/12/xbmc-for-linux-on-allwinner-a10-devices-it-works-sort-of/<br />
<br />
''"Gimli recently decided to push his XBMC port to the public, so we now have a Buildroot XBMC on the mele A1000. Some of you are already knew about the port empatzero decided to release. This port is around for a while now and it does look like the same decoding gitches appear to happen. For some reason sometimes the decoding times show peaks in decoding time, up to the point it results in glitches.''<br />
<br />
''As both ports show similar bugs, Gimli decided to push it out in the open. Communication with Allwinner was still going on but progress was at a very slow rate. Having two different ports / approaches showing similar bugs kind of proof it is most likely something in the cedarX libraries. Hence the reason Gimli decided to release it.''<br />
<br />
''Up till this point I have been following the progress from the sideline. I saw the port of empatzero popping up, but never actually decided to give it a go. I did not really liked the full blown linux OS for only one program (XBMC).''<br />
<br />
''I compiled the minimalistic buildroot envirnment (same as Gimli used for the RPi), compiled XBMC and merged them together with the necessary tweaks to get it running.''<br />
<br />
* ''3.0.42 kernel (just before the update to 3.0.52).''<br />
* ''Buildroot environment.''<br />
* ''No window manager (X11). XBMC runs straight onto the framebuffer.''<br />
* ''Couple of tweaks here and there as this is not even an alpha release.''<br />
* ''All armhf compild with Linaro toolchain.''<br />
<br />
''Created a bootable SD card with a ext2 partition containing the rootfs and xbmc binaries and started it up. There appears to be a memory leak in samba armhf compiled, so disabled that for now (server, not the client). Further more there is nothing really included. No LIRC remote support or other side hardware for that matter.''<br />
<br />
''Inserted the SD card and turned on the Mele A1000. After a good couple of seconds the XBMC start splash appeared and the GUI showed up. GUI speed is fast enough and rendered at around ~40 FPS, similar as Empatzero his port.''<br />
<br />
''Exactly the same performance and issues as Empatzero his port. The only difference is the AVI playback, but it should be noted that the test results on linux-sunxi (at this moment) are done without empatzero his last commit and support for AVI and other missing codecs.''<br />
<br />
''There are still small issues here and there, but all with all not bad for a initial pre-alpha release. I will to some more testing, tweaking and adjustments. People that want to do it themselfs can already do so. Everything can be found on Gimli his github account[https://github.com/huceke]."''<br />
== Extra patches ==<br />
No matter how I tried, HDMI audio was not working until I found this issue: https://github.com/rellla/xbmca10/issues/18<br />
<br />
It's a simple patch:<br />
--- a/xbmc/cores/AudioEngine/Sinks/AESinkALSA.cpp<br />
+++ b/xbmc/cores/AudioEngine/Sinks/AESinkALSA.cpp<br />
@@ -789,7 +789,7 @@ void CAESinkALSA::EnumerateDevicesEx(AEDeviceInfoList &list, bool force)<br />
{<br />
/* sun4i whilelist */<br />
std::string strDevice = std::string(name);<br />
- size_t found = strDevice.find("sun4i");<br />
+ size_t found = strDevice.find("sunxi");<br />
<br />
if(found != std::string::npos)<br />
EnumerateDevice(list, name, desc ? desc : name, config);<br />
@@ -896,7 +896,7 @@ AEDeviceType CAESinkALSA::AEDeviceTypeFromName(const std::string &name)<br />
return AE_DEVTYPE_IEC958;<br />
<br />
/* sun4i hdmi device */<br />
- if(name.find("sun4isndhdmi") != std::string::npos)<br />
+ if(name.find("sunxisndhdmi") != std::string::npos)<br />
return AE_DEVTYPE_HDMI;<br />
<br />
return AE_DEVTYPE_PCM;</div>Rockerhttps://linux-sunxi.org/index.php?title=Talk:CedarX/XBMC&diff=8770Talk:CedarX/XBMC2014-05-09T16:43:19Z<p>Rocker: </p>
<hr />
<div>==VidOn.me released XBMC code for using CedarX on A10 and A20?==<br />
Have VidOn.me finally complied with the GPL now or? I wonder if VidOn.me have finally complied with the GPL license for XBMC or? As you may already know from CNX-software article here http://www.cnx-software.com/2013/12/20/xbmc-arm-news-allwinner-a20-a31-apk-released-10-discount-on-ouya-console/ VidOn.me have an Allwinner A20 based media player called "VidOn.me AV100" that they are using a forked version for XBMC on, but like many Chinese companies they have previously not released all the source code changes and modification as they are required to as XBMC is licensed under GPLv2 (GPL version 2), but now it looks like they might have, see: https://github.com/vidonme/xbmc<br />
<br />
VidOn.me have updated their repository here https://github.com/vidonme/xbmc for their XBMC fork on GitHub.com with new source code, which looks to contain a new video player "core" for Allwinner A20 (and A10 too since both uses the same CedarX VPU). So now the question also remains if this now really is the full and up-to-date source code, then will the XBMC project xbmc.org accept this code for mainline and merge it upstream into XBMC master at https://github.com/xbmc/xbmc/<br />
<br />
==XBMC for armhf==<br />
While testing to cross compile xbmc for armhf, this list is a little brainstorming of the steps that i could remeber:<br />
The wiki page has to be rewritten. So the whole things has to be done a second time. With protocolling!!!<br />
<br />
My memos for armhf:<br />
* cross-compiled on a debian/sid-amd64(in vmware-virtual machine on windows vista;-)).<br />
* build your kernel, uboot, script.bin, boot.scr and debian armhf-rootfs like described in the rhomus-tech-"build-debian-for-mele-from-source"-wiki. adapt it do sid and armhf! <- be careful, current git-branches maybe broken due to heavy development?!<br />
* be sure to use components, that fit together!<br />
* you need a kernel with r3p0-mali-driver, to fit to binary mali-libs (i used stage/sunxi-3.0)<br />
* after setting up rootfs, chroot into rootfs and do all "apt-get build-dep xbmc" and other "apt-get install/remove"-things for needed packages in your chroot!<br />
* for newest (2012/10/30) xbmca10 you need to install libssh-4 and libssh-dev in chroot, if not already done by "apt-get build-dep xbmc"<br />
* "apt-get remove libegl1-mesa libegl1-mesa-dev libegl1-mesa-drivers libgles2-mesa libgles2-mesa-dev" isn't needed? no gl-stuff installed to be removed?<br />
* your includes for crosscompiling xbmc must point to the include dirs of your rootfs(SDKSTAGE)<br />
* you may the make/gcc -lines in config.log combined with a 'find / -name "....."' to check if -I"..."-parameters are set right etc.<br />
* set PKG_CONFIG_SYSROOT_DIR=$(SDKSTAGE) in depends.mk to let configure find the right pkg-config-things<br />
* check depends.mk and change dirs and USEARMHF=1!<br />
* follow empat0's instructions in depends.mk and set symlinks:<br />
I had to make symlinks for<br />
# /lib/arm-linux-gnueabi, /usr/lib/arm-linux-gnueabi<br />
# and /usr/include/arm-linux-gnueabi to their path in ${SDKSTAGE} <br />
* for cross-compilation remeber to do (not in chroot):<br />
apt-get install cmake shtool swig autoconf autotools-dev automake autopoint libtool default-jre gawk gperf zip g++-4.6-arm-linux-gnueabihf (maybe not complete listing)<br />
set all symlinks to version files (gcc -> gcc-4.6 etc...)<br />
* be sure to all the files/links/dirs named right and in the right place with *hf-ending like listed in depends.mk<br />
* follow configure errors (config.log) and install the needed packages (dev-packages: chroot and install in armhf)<br />
<br />
Finally edit the wiki page ;-)<br />
<br />
==Buildroot XBMC on the Mele A1000 and A2000 (Allwinner A10)==<br />
[http://www.j1nx.nl/buildroot-xbmc-on-mele-a1000-allwinner-a10/ http://www.j1nx.nl/buildroot-xbmc-on-mele-a1000-allwinner-a10/]<br />
<br />
http://www.cnx-software.com/2012/11/12/xbmc-for-linux-on-allwinner-a10-devices-it-works-sort-of/<br />
<br />
''"Gimli recently decided to push his XBMC port to the public, so we now have a Buildroot XBMC on the mele A1000. Some of you are already knew about the port empatzero decided to release. This port is around for a while now and it does look like the same decoding gitches appear to happen. For some reason sometimes the decoding times show peaks in decoding time, up to the point it results in glitches.''<br />
<br />
''As both ports show similar bugs, Gimli decided to push it out in the open. Communication with Allwinner was still going on but progress was at a very slow rate. Having two different ports / approaches showing similar bugs kind of proof it is most likely something in the cedarX libraries. Hence the reason Gimli decided to release it.''<br />
<br />
''Up till this point I have been following the progress from the sideline. I saw the port of empatzero popping up, but never actually decided to give it a go. I did not really liked the full blown linux OS for only one program (XBMC).''<br />
<br />
''I compiled the minimalistic buildroot envirnment (same as Gimli used for the RPi), compiled XBMC and merged them together with the necessary tweaks to get it running.''<br />
<br />
* ''3.0.42 kernel (just before the update to 3.0.52).''<br />
* ''Buildroot environment.''<br />
* ''No window manager (X11). XBMC runs straight onto the framebuffer.''<br />
* ''Couple of tweaks here and there as this is not even an alpha release.''<br />
* ''All armhf compild with Linaro toolchain.''<br />
<br />
''Created a bootable SD card with a ext2 partition containing the rootfs and xbmc binaries and started it up. There appears to be a memory leak in samba armhf compiled, so disabled that for now (server, not the client). Further more there is nothing really included. No LIRC remote support or other side hardware for that matter.''<br />
<br />
''Inserted the SD card and turned on the Mele A1000. After a good couple of seconds the XBMC start splash appeared and the GUI showed up. GUI speed is fast enough and rendered at around ~40 FPS, similar as Empatzero his port.''<br />
<br />
''Exactly the same performance and issues as Empatzero his port. The only difference is the AVI playback, but it should be noted that the test results on linux-sunxi (at this moment) are done without empatzero his last commit and support for AVI and other missing codecs.''<br />
<br />
''There are still small issues here and there, but all with all not bad for a initial pre-alpha release. I will to some more testing, tweaking and adjustments. People that want to do it themselfs can already do so. Everything can be found on Gimli his github account[https://github.com/huceke]."''<br />
== Extra patches ==<br />
No matter how I tried, HDMI audio was not working until I found this issue: https://github.com/rellla/xbmca10/issues/18<br />
<br />
It's a simple patch:<br />
--- a/xbmc/cores/AudioEngine/Sinks/AESinkALSA.cpp<br />
+++ b/xbmc/cores/AudioEngine/Sinks/AESinkALSA.cpp<br />
@@ -789,7 +789,7 @@ void CAESinkALSA::EnumerateDevicesEx(AEDeviceInfoList &list, bool force)<br />
{<br />
/* sun4i whilelist */<br />
std::string strDevice = std::string(name);<br />
- size_t found = strDevice.find("sun4i");<br />
+ size_t found = strDevice.find("sunxi");<br />
<br />
if(found != std::string::npos)<br />
EnumerateDevice(list, name, desc ? desc : name, config);<br />
@@ -896,7 +896,7 @@ AEDeviceType CAESinkALSA::AEDeviceTypeFromName(const std::string &name)<br />
return AE_DEVTYPE_IEC958;<br />
<br />
/* sun4i hdmi device */<br />
- if(name.find("sun4isndhdmi") != std::string::npos)<br />
+ if(name.find("sunxisndhdmi") != std::string::npos)<br />
return AE_DEVTYPE_HDMI;<br />
<br />
return AE_DEVTYPE_PCM;</div>Rockerhttps://linux-sunxi.org/index.php?title=Talk:CedarX/XBMC&diff=8769Talk:CedarX/XBMC2014-05-09T16:42:19Z<p>Rocker: /* Buildroot XBMC on the Mele A1000 and A0000 (Allwinner A10) */</p>
<hr />
<div>==VidOn.me released XBMC code for using CedarX on A10 and A20?==<br />
Have VidOn.me finally complied with the GPL now or? I wonder if VidOn.me have finally complied with the GPL license for XBMC or? As you may already know from CNX-software article here http://www.cnx-software.com/2013/12/20/xbmc-arm-news-allwinner-a20-a31-apk-released-10-discount-on-ouya-console/ VidOn.me have an Allwinner A20 based media player called "VidOn.me AV100" that they are using a forked version for XBMC on, but like many Chinese companies they have previously not released all the source code changes and modification as they are required to as XBMC is licensed under GPLv2 (GPL version 2), but now it looks like they might have, see: https://github.com/vidonme/xbmc<br />
<br />
VidOn.me have updated their repository here https://github.com/vidonme/xbmc for their XBMC fork on GitHub.com with new source code, which looks to contain a new video player "core" for Allwinner A20 (and A10 too since both uses the same CedarX VPU). So now the question also remains if this now really is the full and up-to-date source code, then will the XBMC project xbmc.org accept this code for mainline and merge it upstream into XBMC master at https://github.com/xbmc/xbmc/<br />
<br />
==XBMC for armhf==<br />
While testing to cross compile xbmc for armhf, this list is a little brainstorming of the steps that i could remeber:<br />
The wiki page has to be rewritten. So the whole things has to be done a second time. With protocolling!!!<br />
<br />
My memos for armhf:<br />
* cross-compiled on a debian/sid-amd64(in vmware-virtual machine on windows vista;-)).<br />
* build your kernel, uboot, script.bin, boot.scr and debian armhf-rootfs like described in the rhomus-tech-"build-debian-for-mele-from-source"-wiki. adapt it do sid and armhf! <- be careful, current git-branches maybe broken due to heavy development?!<br />
* be sure to use components, that fit together!<br />
* you need a kernel with r3p0-mali-driver, to fit to binary mali-libs (i used stage/sunxi-3.0)<br />
* after setting up rootfs, chroot into rootfs and do all "apt-get build-dep xbmc" and other "apt-get install/remove"-things for needed packages in your chroot!<br />
* for newest (2012/10/30) xbmca10 you need to install libssh-4 and libssh-dev in chroot, if not already done by "apt-get build-dep xbmc"<br />
* "apt-get remove libegl1-mesa libegl1-mesa-dev libegl1-mesa-drivers libgles2-mesa libgles2-mesa-dev" isn't needed? no gl-stuff installed to be removed?<br />
* your includes for crosscompiling xbmc must point to the include dirs of your rootfs(SDKSTAGE)<br />
* you may the make/gcc -lines in config.log combined with a 'find / -name "....."' to check if -I"..."-parameters are set right etc.<br />
* set PKG_CONFIG_SYSROOT_DIR=$(SDKSTAGE) in depends.mk to let configure find the right pkg-config-things<br />
* check depends.mk and change dirs and USEARMHF=1!<br />
* follow empat0's instructions in depends.mk and set symlinks:<br />
I had to make symlinks for<br />
# /lib/arm-linux-gnueabi, /usr/lib/arm-linux-gnueabi<br />
# and /usr/include/arm-linux-gnueabi to their path in ${SDKSTAGE} <br />
* for cross-compilation remeber to do (not in chroot):<br />
apt-get install cmake shtool swig autoconf autotools-dev automake autopoint libtool default-jre gawk gperf zip g++-4.6-arm-linux-gnueabihf (maybe not complete listing)<br />
set all symlinks to version files (gcc -> gcc-4.6 etc...)<br />
* be sure to all the files/links/dirs named right and in the right place with *hf-ending like listed in depends.mk<br />
* follow configure errors (config.log) and install the needed packages (dev-packages: chroot and install in armhf)<br />
<br />
Finally edit the wiki page ;-)<br />
<br />
==Buildroot XBMC on the Mele A1000 and A2000 (Allwinner A10)==<br />
[http://www.j1nx.nl/buildroot-xbmc-on-mele-a1000-allwinner-a10/ http://www.j1nx.nl/buildroot-xbmc-on-mele-a1000-allwinner-a10/]<br />
<br />
http://www.cnx-software.com/2012/11/12/xbmc-for-linux-on-allwinner-a10-devices-it-works-sort-of/<br />
<br />
''"Gimli recently decided to push his XBMC port to the public, so we now have a Buildroot XBMC on the mele A1000. Some of you are already knew about the port empatzero decided to release. This port is around for a while now and it does look like the same decoding gitches appear to happen. For some reason sometimes the decoding times show peaks in decoding time, up to the point it results in glitches.''<br />
<br />
''As both ports show similar bugs, Gimli decided to push it out in the open. Communication with Allwinner was still going on but progress was at a very slow rate. Having two different ports / approaches showing similar bugs kind of proof it is most likely something in the cedarX libraries. Hence the reason Gimli decided to release it.''<br />
<br />
''Up till this point I have been following the progress from the sideline. I saw the port of empatzero popping up, but never actually decided to give it a go. I did not really liked the full blown linux OS for only one program (XBMC).''<br />
<br />
''I compiled the minimalistic buildroot envirnment (same as Gimli used for the RPi), compiled XBMC and merged them together with the necessary tweaks to get it running.''<br />
<br />
* ''3.0.42 kernel (just before the update to 3.0.52).''<br />
* ''Buildroot environment.''<br />
* ''No window manager (X11). XBMC runs straight onto the framebuffer.''<br />
* ''Couple of tweaks here and there as this is not even an alpha release.''<br />
* ''All armhf compild with Linaro toolchain.''<br />
<br />
''Created a bootable SD card with a ext2 partition containing the rootfs and xbmc binaries and started it up. There appears to be a memory leak in samba armhf compiled, so disabled that for now (server, not the client). Further more there is nothing really included. No LIRC remote support or other side hardware for that matter.''<br />
<br />
''Inserted the SD card and turned on the Mele A1000. After a good couple of seconds the XBMC start splash appeared and the GUI showed up. GUI speed is fast enough and rendered at around ~40 FPS, similar as Empatzero his port.''<br />
<br />
''Exactly the same performance and issues as Empatzero his port. The only difference is the AVI playback, but it should be noted that the test results on linux-sunxi (at this moment) are done without empatzero his last commit and support for AVI and other missing codecs.''<br />
<br />
''There are still small issues here and there, but all with all not bad for a initial pre-alpha release. I will to some more testing, tweaking and adjustments. People that want to do it themselfs can already do so. Everything can be found on Gimli his github account[https://github.com/huceke]."''<br />
=== extra patches ===<br />
No matter how I tried, HDMI audio was not working until I found this issue: https://github.com/rellla/xbmca10/issues/18<br />
<br />
It's a simple patch:<br />
--- a/xbmc/cores/AudioEngine/Sinks/AESinkALSA.cpp<br />
+++ b/xbmc/cores/AudioEngine/Sinks/AESinkALSA.cpp<br />
@@ -789,7 +789,7 @@ void CAESinkALSA::EnumerateDevicesEx(AEDeviceInfoList &list, bool force)<br />
{<br />
/* sun4i whilelist */<br />
std::string strDevice = std::string(name);<br />
- size_t found = strDevice.find("sun4i");<br />
+ size_t found = strDevice.find("sunxi");<br />
<br />
if(found != std::string::npos)<br />
EnumerateDevice(list, name, desc ? desc : name, config);<br />
@@ -896,7 +896,7 @@ AEDeviceType CAESinkALSA::AEDeviceTypeFromName(const std::string &name)<br />
return AE_DEVTYPE_IEC958;<br />
<br />
/* sun4i hdmi device */<br />
- if(name.find("sun4isndhdmi") != std::string::npos)<br />
+ if(name.find("sunxisndhdmi") != std::string::npos)<br />
return AE_DEVTYPE_HDMI;<br />
<br />
return AE_DEVTYPE_PCM;</div>Rockerhttps://linux-sunxi.org/index.php?title=Talk:CedarX/XBMC&diff=8768Talk:CedarX/XBMC2014-05-09T16:41:18Z<p>Rocker: </p>
<hr />
<div>==VidOn.me released XBMC code for using CedarX on A10 and A20?==<br />
Have VidOn.me finally complied with the GPL now or? I wonder if VidOn.me have finally complied with the GPL license for XBMC or? As you may already know from CNX-software article here http://www.cnx-software.com/2013/12/20/xbmc-arm-news-allwinner-a20-a31-apk-released-10-discount-on-ouya-console/ VidOn.me have an Allwinner A20 based media player called "VidOn.me AV100" that they are using a forked version for XBMC on, but like many Chinese companies they have previously not released all the source code changes and modification as they are required to as XBMC is licensed under GPLv2 (GPL version 2), but now it looks like they might have, see: https://github.com/vidonme/xbmc<br />
<br />
VidOn.me have updated their repository here https://github.com/vidonme/xbmc for their XBMC fork on GitHub.com with new source code, which looks to contain a new video player "core" for Allwinner A20 (and A10 too since both uses the same CedarX VPU). So now the question also remains if this now really is the full and up-to-date source code, then will the XBMC project xbmc.org accept this code for mainline and merge it upstream into XBMC master at https://github.com/xbmc/xbmc/<br />
<br />
==XBMC for armhf==<br />
While testing to cross compile xbmc for armhf, this list is a little brainstorming of the steps that i could remeber:<br />
The wiki page has to be rewritten. So the whole things has to be done a second time. With protocolling!!!<br />
<br />
My memos for armhf:<br />
* cross-compiled on a debian/sid-amd64(in vmware-virtual machine on windows vista;-)).<br />
* build your kernel, uboot, script.bin, boot.scr and debian armhf-rootfs like described in the rhomus-tech-"build-debian-for-mele-from-source"-wiki. adapt it do sid and armhf! <- be careful, current git-branches maybe broken due to heavy development?!<br />
* be sure to use components, that fit together!<br />
* you need a kernel with r3p0-mali-driver, to fit to binary mali-libs (i used stage/sunxi-3.0)<br />
* after setting up rootfs, chroot into rootfs and do all "apt-get build-dep xbmc" and other "apt-get install/remove"-things for needed packages in your chroot!<br />
* for newest (2012/10/30) xbmca10 you need to install libssh-4 and libssh-dev in chroot, if not already done by "apt-get build-dep xbmc"<br />
* "apt-get remove libegl1-mesa libegl1-mesa-dev libegl1-mesa-drivers libgles2-mesa libgles2-mesa-dev" isn't needed? no gl-stuff installed to be removed?<br />
* your includes for crosscompiling xbmc must point to the include dirs of your rootfs(SDKSTAGE)<br />
* you may the make/gcc -lines in config.log combined with a 'find / -name "....."' to check if -I"..."-parameters are set right etc.<br />
* set PKG_CONFIG_SYSROOT_DIR=$(SDKSTAGE) in depends.mk to let configure find the right pkg-config-things<br />
* check depends.mk and change dirs and USEARMHF=1!<br />
* follow empat0's instructions in depends.mk and set symlinks:<br />
I had to make symlinks for<br />
# /lib/arm-linux-gnueabi, /usr/lib/arm-linux-gnueabi<br />
# and /usr/include/arm-linux-gnueabi to their path in ${SDKSTAGE} <br />
* for cross-compilation remeber to do (not in chroot):<br />
apt-get install cmake shtool swig autoconf autotools-dev automake autopoint libtool default-jre gawk gperf zip g++-4.6-arm-linux-gnueabihf (maybe not complete listing)<br />
set all symlinks to version files (gcc -> gcc-4.6 etc...)<br />
* be sure to all the files/links/dirs named right and in the right place with *hf-ending like listed in depends.mk<br />
* follow configure errors (config.log) and install the needed packages (dev-packages: chroot and install in armhf)<br />
<br />
Finally edit the wiki page ;-)<br />
<br />
==Buildroot XBMC on the Mele A1000 and A0000 (Allwinner A10)==<br />
[http://www.j1nx.nl/buildroot-xbmc-on-mele-a1000-allwinner-a10/ http://www.j1nx.nl/buildroot-xbmc-on-mele-a1000-allwinner-a10/]<br />
<br />
http://www.cnx-software.com/2012/11/12/xbmc-for-linux-on-allwinner-a10-devices-it-works-sort-of/<br />
<br />
''"Gimli recently decided to push his XBMC port to the public, so we now have a Buildroot XBMC on the mele A1000. Some of you are already knew about the port empatzero decided to release. This port is around for a while now and it does look like the same decoding gitches appear to happen. For some reason sometimes the decoding times show peaks in decoding time, up to the point it results in glitches.''<br />
<br />
''As both ports show similar bugs, Gimli decided to push it out in the open. Communication with Allwinner was still going on but progress was at a very slow rate. Having two different ports / approaches showing similar bugs kind of proof it is most likely something in the cedarX libraries. Hence the reason Gimli decided to release it.''<br />
<br />
''Up till this point I have been following the progress from the sideline. I saw the port of empatzero popping up, but never actually decided to give it a go. I did not really liked the full blown linux OS for only one program (XBMC).''<br />
<br />
''I compiled the minimalistic buildroot envirnment (same as Gimli used for the RPi), compiled XBMC and merged them together with the necessary tweaks to get it running.''<br />
<br />
* ''3.0.42 kernel (just before the update to 3.0.52).''<br />
* ''Buildroot environment.''<br />
* ''No window manager (X11). XBMC runs straight onto the framebuffer.''<br />
* ''Couple of tweaks here and there as this is not even an alpha release.''<br />
* ''All armhf compild with Linaro toolchain.''<br />
<br />
''Created a bootable SD card with a ext2 partition containing the rootfs and xbmc binaries and started it up. There appears to be a memory leak in samba armhf compiled, so disabled that for now (server, not the client). Further more there is nothing really included. No LIRC remote support or other side hardware for that matter.''<br />
<br />
''Inserted the SD card and turned on the Mele A1000. After a good couple of seconds the XBMC start splash appeared and the GUI showed up. GUI speed is fast enough and rendered at around ~40 FPS, similar as Empatzero his port.''<br />
<br />
''Exactly the same performance and issues as Empatzero his port. The only difference is the AVI playback, but it should be noted that the test results on linux-sunxi (at this moment) are done without empatzero his last commit and support for AVI and other missing codecs.''<br />
<br />
''There are still small issues here and there, but all with all not bad for a initial pre-alpha release. I will to some more testing, tweaking and adjustments. People that want to do it themselfs can already do so. Everything can be found on Gimli his github account[https://github.com/huceke]."''<br />
=== extra patches ===<br />
No matter how I tried, HDMI audio was not working until I found this issue: https://github.com/rellla/xbmca10/issues/18<br />
<br />
It's a simple patch:<br />
--- a/xbmc/cores/AudioEngine/Sinks/AESinkALSA.cpp<br />
+++ b/xbmc/cores/AudioEngine/Sinks/AESinkALSA.cpp<br />
@@ -789,7 +789,7 @@ void CAESinkALSA::EnumerateDevicesEx(AEDeviceInfoList &list, bool force)<br />
{<br />
/* sun4i whilelist */<br />
std::string strDevice = std::string(name);<br />
- size_t found = strDevice.find("sun4i");<br />
+ size_t found = strDevice.find("sunxi");<br />
<br />
if(found != std::string::npos)<br />
EnumerateDevice(list, name, desc ? desc : name, config);<br />
@@ -896,7 +896,7 @@ AEDeviceType CAESinkALSA::AEDeviceTypeFromName(const std::string &name)<br />
return AE_DEVTYPE_IEC958;<br />
<br />
/* sun4i hdmi device */<br />
- if(name.find("sun4isndhdmi") != std::string::npos)<br />
+ if(name.find("sunxisndhdmi") != std::string::npos)<br />
return AE_DEVTYPE_HDMI;<br />
<br />
return AE_DEVTYPE_PCM;</div>Rockerhttps://linux-sunxi.org/index.php?title=CedarX/XBMC&diff=8766CedarX/XBMC2014-05-09T16:13:18Z<p>Rocker: /* Building XBMC for A10 and A20 */</p>
<hr />
<div><div style="color:#6F0000; border: 3px dashed #BF4F4F; padding: 2em;"><big><br />
'''XBMC for linux on Allwinner devices is NOT READY FOR USE!'''<br />
<br />
This is only a hack intended for developers and curious users at the moment. Don't expect it to work as you want it! Hardware is capable to make it run quite good in the future, but software and drivers are not ready yet. The [[:Category:Community|sunxi-community]] is working towards making a smooth XBMC experience possible.<br />
<br />
If you want to help developing the needed components to have a stable XBMC in the future, join the [[:Category:Community|irc and mailing list]]. Developers wanted!</big></div><br />
<br/><br />
<br />
XBMC is a popular media center software with 10-foot interface designed for large-screen televisions, and it enables ARM-based media players and set-top boxes like those with Allwinner SoCs with [[CedarX]] to play and view high-definition videos, music, and other digital media files from local and network storage media, as well as stream podcasts, videocasts, and such of the internet.<br />
<br />
This article contain instructions on compiling and developing XBMC on and for Allwinner A10, A10s, A13, and A20 SoCs. Note that these instructions are specifically only meant for developers and advanced or expert Linux users that can actively assist with the porting process.<br />
<br />
=Overview=<br />
XBMC has already have an initial port for the A10 / A20 SoC with [[CedarX]] hardware accelerated video decoding, this experimental third-party port and the code patches have however not yet made it upstream into mainline XBMC.<ref>http://www.j1nx.nl/buildroot-xbmc-on-mele-a1000-allwinner-a10/ Buildroot XBMC on the Mele A1000 (Allwinner A10)</ref><ref>http://www.cnx-software.com/2012/11/12/xbmc-for-linux-on-allwinner-a10-devices-it-works-sort-of/ XBMC for Linux on AllWinner A10 Devices? It Works! (Sort of)</ref><br />
<br />
Pre-built application binaries of this port are not available so therefore you will need to compile XBMC yourself, at least until if and when the code makes it into the mainline XBMC upstream at http://xbmc.org<br />
<br />
Team-XBMC, the official development team of XBMC, does currently not recommend that any end-user buy Allwinner A10 or A20 based hardware for the specific purpose of only running XBMC since they do not have the resources to support this platform as of yet.<br />
<br />
More information about XBMC can be found on wikipedia http://en.wikipedia.org/wiki/XBMC and the XBMC wiki http://wiki.xbmc.org or http://forum.xbmc.org<br />
<br />
= Building XBMC for A10 and A20 =<br />
This is a little how-to of steps to compile XBMC for devices using Allwinner A10 and A20 SoCs (e.g. Mele A1000, Cubieboard, Banana Pi) based on Empat0's GitHub sources [http://github.com/empatzero/xbmca10 http://github.com/empatzero/xbmca10].<br />
The development work on the coding side was all done by Empat0 (a.k.a. empat zero). The used repository in the example below is however from [http://github.com/rellla/xbmca10 http://github.com/rellla/xbmca10] which is currently the newest and contains a few adaptions. It is a fork of empat0's work. <br />
<br />
The result should be a Debian armhf system with XBMC using [[CedarX]] for hardware accelerated video decoding.<br />
<br />
This version of XBMC runs directly on the framebuffer, and thus XServer is therefor not needed!<br />
<br />
== Prerequisites ==<br />
There are more ways to prepare a working rootfs for XBMC. You can either prepare the sdcard directly as described or you can chroot into the rootfs on your host system and sync it with your sdcard later when you have finished.<br />
So the following steps can also be done in a chroot on your host if you are cross-compiling.<br />
<br />
=== Prepare your SD-Card ===<br />
Create a bootable SD-Card follwing [[Manual_build_howto| our manual build howto]] and Debian. Be sure to use a kernel with mali-drivers-version r3p0 (sunxi-3.0 should be good).<br />
<br />
=== Boot into your target system ===<br />
Boot the new debian from the sd-card directly on the target and bring the system up to date:<br />
root@mele:~/# apt-get update<br />
root@mele:~/# apt-get upgrade<br />
<br />
=== Install the dependencies for XBMC (needs update!) ===<br />
root@mele:~/# apt-get build-dep xbmc<br />
<br />
this should install the following packages:<br />
autoconf automake autopoint autotools-dev binutils bsdmainutils build-essential bzip2 cmake cmake-data comerr-dev cpp cpp-4.4 cpp-4.6 curl<br />
debhelper dpkg-dev emacsen-common fontconfig-config g++ g++-4.4 g++-4.6 gawk gcc gcc-4.4 gcc-4.4-base gcc-4.6 gcc-4.6-base gettext<br />
gettext-base git git-man gperf groff-base html2text intltool-debian krb5-multidev libao-common libao-dev libao4 libarchive12 libasound2<br />
libasound2-dev libasprintf0c2 libass-dev libass4 libasyncns0 libavahi-client-dev libavahi-client3 libavahi-common-data libavahi-common-dev<br />
libavahi-common3 libavcodec-dev libavcodec53 libavfilter-dev libavfilter2 libavformat-dev libavformat53 libavutil-dev libavutil51<br />
libbluetooth-dev libbluetooth3 libbluray-dev libbluray1 libboost-date-time1.49-dev libboost-date-time1.49.0 libboost-dev<br />
libboost-serialization1.49-dev libboost-serialization1.49.0 libboost-thread-dev libboost-thread1.49-dev libboost-thread1.49.0<br />
libboost1.49-dev libbz2-dev libc-dev-bin libc6-dev libcaca-dev libcaca0 libcdio-dev libcdio13 libcec-dev libcec1 libcroco3 libcurl3<br />
libcurl3-gnutls libcurl4-gnutls-dev libcwiid-dev libcwiid1 libdbus-1-3 libdbus-1-dev libdirac-encoder0 libdirectfb-1.2-9 libdirectfb-dev<br />
libdirectfb-extra libdpkg-perl libdrm2 libelf1 libenca-dev libenca0 liberror-perl libexpat1 libexpat1-dev libflac-dev libflac8 libfontconfig1<br />
libfontconfig1-dev libfreetype6 libfreetype6-dev libfribidi-dev libfribidi0 libgcrypt11-dev libgettextpo0 libgl1-mesa-dev libgl1-mesa-glx<br />
libglapi-mesa libglew-dev libglew1.7 libglib2.0-bin libglib2.0-dev libglu1-mesa libglu1-mesa-dev libgmp10 libgnutls-dev libgnutls-openssl27<br />
libgnutlsxx27 libgomp1 libgpg-error-dev libgsm1 libgssrpc4 libhal-dev libhal-storage-dev libhal-storage1 libhal1 libice-dev libice6 libicu48<br />
libidn11-dev libiso9660-8 libiso9660-dev libjasper-dev libjasper1 libjbig-dev libjbig0 libjpeg8 libjpeg8-dev libjson0 libkadm5clnt-mit8<br />
libkadm5srv-mit8 libkdb5-6 libkrb5-dev liblcms1 libldap-2.4-2 libldap2-dev libltdl-dev libltdl7 liblzo2-2 liblzo2-dev libmad0 libmad0-dev<br />
libmicrohttpd-dev libmicrohttpd10 libmikmod2 libmikmod2-dev libmodplug-dev libmodplug1 libmp3lame-dev libmp3lame0 libmpc2 libmpeg2-4<br />
libmpeg2-4-dev libmpfr4 libmysqlclient-dev libmysqlclient18 libnettle4 libnfs-dev libnfs1 libogg-dev libogg0 libopencv-core2.3<br />
libopencv-imgproc2.3 libopenjpeg2 liborc-0.4-0 libp11-kit-dev libpcre3-dev libpcrecpp0 libpipeline1 libplist-dev libplist1 libpng12-0<br />
libpng12-dev libpopt0 libpostproc-dev libpostproc52 libpthread-stubs0 libpthread-stubs0-dev libpulse-dev libpulse-mainloop-glib0 libpulse0<br />
libpython2.7 librtmp-dev librtmp0 libsamplerate0 libsamplerate0-dev libsasl2-2 libschroedinger-1.0-0 libsdl-image1.2 libsdl-image1.2-dev<br />
libsdl-mixer1.2 libsdl-mixer1.2-dev libsdl1.2-dev libsdl1.2debian libshairport-dev libshairport1 libsigsegv2 libslang2-dev libsm-dev libsm6<br />
libsmbclient libsmbclient-dev libsndfile1 libspeex1 libsqlite3-0 libsqlite3-dev libssh2-1 libssh2-1-dev libssl-dev libstdc++6-4.4-dev<br />
libstdc++6-4.6-dev libswscale-dev libswscale2 libtalloc2 libtasn1-3-dev libtdb1 libtheora0 libtiff4 libtiff4-dev libtiffxx0c2<br />
libtimedate-perl libtinyxml-dev libtinyxml2.6.2 libtool libts-0.0-0 libts-dev libudev-dev libunistring0 libva-dev libva-egl1 libva-glx1<br />
libva-tpi1 libva-x11-1 libva1 libvdpau-dev libvdpau1 libvorbis-dev libvorbis0a libvorbisenc2 libvorbisfile3 libvpx1 libwbclient0 libwebp-dev<br />
libwebp2 libx11-dev libx11-xcb1 libx264-123 libxau-dev libxcb-glx0 libxcb1-dev libxdamage1 libxdmcp-dev libxext-dev libxfixes3 libxi6<br />
libxml2-dev libxmlrpc-core-c3 libxmu-dev libxmu-headers libxmu6 libxrandr-dev libxrandr2 libxrender-dev libxrender1 libxt-dev libxt6 libxtst6<br />
libxvidcore4 libxxf86vm1 libyajl-dev libyajl2 linux-libc-dev m4 make man-db mesa-common-dev mysql-common patch pkg-config po-debconf python<br />
python-dev python-imaging python-minimal python-support python2.7 python2.7-dev python2.7-minimal tsconf ttf-dejavu-core ucf x11-common<br />
x11proto-core-dev x11proto-input-dev x11proto-kb-dev x11proto-randr-dev x11proto-render-dev x11proto-xext-dev xorg-sgml-doctools xtrans-dev<br />
yasm zip zlib1g-dev<br />
<br />
need to install 3 more dependencies:<br />
root@mele:~/# apt-get install swig default-jre libgtk2.0-bin libssh-4 libssh-dev<br />
<br />
ensure you use hardware acceleration<br />
root@mele:~/# echo -e "\nA10HWR=1" >> /etc/environment (to set it permanently)<br />
<br />
Now go on with [[XBMC#Native_Compile_of_XBMC | Native Compile]] or [[XBMC#Cross_Compile_of_XBMC | Cross Compile]].<br />
<br />
== Native Compile of XBMC ==<br />
<br />
=== Prerequisites for native compile ===<br />
<br />
Create a swap-file, because otherwise the compiler runs out of memory during compiling and aborts<br />
root@mele:~/# dd if=/dev/zero of=/swap bs=1M count=384<br />
root@mele:~/# mkswap -c /swap<br />
root@mele:~/# swapon /swap<br />
<br />
Create your workspace directory:<br />
root@mele:~/# mkdir melehacking<br />
root@mele:~/# cd melehacking<br />
<br />
=== Checkout the source code ===<br />
root@mele:~/melehacking# apt-get install git<br />
root@mele:~/melehacking# git clone git://github.com/rellla/xbmca10.git<br />
root@mele:~/melehacking# cd xbmca10<br />
root@mele:~/melehacking/xbmca10# git checkout stage/Frodo<br />
<br />
=== Build ===<br />
The following external libs/ repos are used/ downloaded:<br />
* taglib: https://github.com/downloads/taglib/taglib/taglib-1.8.tar.gz<br />
* cedarx: https://github.com/linux-sunxi/cedarx-libs/tree/master/libcedarv/linux-armhf<br />
* libmad: ftp://ftp.mars.org/pub/mpeg/libmad-0.15.1b.tar.gz<br />
* mali: https://github.com/linux-sunxi/sunxi-mali-proprietary/tree/master/r3p0/armhf<br />
* mali-dev: https://github.com/linux-sunxi/sunxi-mali/tree/master/include<br />
<br />
Build dependencies<br />
root@mele:~/melehacking/xbmca10# cd tools/a10/depends<br />
root@mele:~/melehacking/xbmca10/tools/a10/depends# make<br />
Build xbmc itself<br />
root@mele:~/melehacking/xbmca10/tools/a10/depends# make -C xbmc<br />
root@mele:~/melehacking/xbmca10/tools/a10/depends# cd ../../../<br />
root@mele:~/melehacking/xbmca10# make install<br />
<br />
Move on to [[XBMC#Start_xbmc]] and start XBMC.<br />
<br />
== Cross Compile of XBMC ==<br />
This was tested with github.com/rellla/xbmca10 and built in Debian Sid as host. You will need several packages on the build system and a copy <br />
of the root file system of the target to build against. This howto assumes you are running off an SD card with the root file system in /dev/sdb2.<br />
=== Setup Cross Compiler ===<br />
* At first set up your [[Toolchain|toolchain]].<br />
<br />
=== Prerequisites for Cross Compiling ===<br />
* Sync and move SD card to build system<br />
* Mount the rootfs of the prepared SD Card<br />
root@debian:~/# mount /dev/sdb2 /mnt/rootfs-a10<br />
* Create symlinks to the mounted libraries<br />
root@debian:~/# ln -s /mnt/rootfs-a10/lib/arm-linux-gnueabihf /lib/arm-linux-gnueabihf<br />
root@debian:~/# ln -s /mnt/rootfs-a10/usr/lib/arm-linux-gnueabihf /usr/lib/arm-linux-gnueabihf<br />
root@debian:~/# ln -s /mnt/rootfs-a10/usr/include/arm-linux-gnueabihf /usr/include/arm-linux-gnueabihf<br />
* Install the dependencies for building XBMC on the host system<br />
root@debian:~/# apt-get build-dep xbmc<br />
root@debian:~/# apt-get install shtool swig default-jre<br />
* Create your workspace directory:<br />
root@debian:~/# mkdir melehacking<br />
root@debian:~/# cd melehacking<br />
<br />
=== Checkout the source code ===<br />
root@debian:~/melehacking# git clone git://github.com/rellla/xbmca10.git<br />
root@debian:~/melehacking# cd xbmca10<br />
root@debian:~/melehacking/xbmca10# git checkout stage/Frodo<br />
<br />
=== Update XBMC build config ===<br />
Update this section at line 48 of tools/a10/depends/depends.mk with your values, e.g.<br />
#where is your arm rootfs<br />
SDKSTAGE=/mnt/rootfs-a10<br />
#where is your xbmc install root <br />
XBMCPREFIX=/allwinner/xbmc-pvr-bin$(HF)<br />
#where is your toolchain<br />
TOOLCHAIN=/usr/arm-linux-gnueabi$(HF)<br />
<br />
=== Build ===<br />
At this point the settings are basically the same for the native build:<br />
Build dependencies<br />
root@debian:~/melehacking/xbmca10# cd tools/a10/depends<br />
root@debian:~/melehacking/xbmca10/tools/a10/depends# make<br />
Build xbmc itself<br />
root@debian:~/melehacking/xbmca10/tools/a10/depends# make -C xbmc<br />
root@debian:~/melehacking/xbmca10/tools/a10/depends# cd ../../../<br />
root@debian:~/melehacking/xbmca10# make install<br />
<br />
=== Move XBMC to target system ===<br />
You should copy from your install location on your build system to an identical location on the target system (may not vital that they have the same path) like so ...<br />
root@debian:~/melehacking/xbmca10/cp -r /allwinner/xbmc-pvr-binhf /mnt/rootfs-a10/allwinner/xbmc-pvr-binhf<br />
<br />
To redistribute it, you can also create a tarball:<br />
root@debian:~/melehacking/xbmca10/tools/a10/depends# make -C package tarball<br />
This results in a xbmca10.tar.gz which includes all needed (and stripped) files in /allwinner/xbmc-pvr-binhf. This can easily be copied and extracted on the target rootfs.<br />
<br />
Umount your SD Card<br />
root@debian:~/melehacking/xbmca10# umount /dev/sdb2<br />
and boot it on your A10 Device.<br />
<br />
== Start XBMC ==<br />
After a reboot you modprobe the needed modules (depending on the used kernel version):<br />
root@mele:~/# modprobe disp<br />
root@mele:~/# modprobe lcd<br />
root@mele:~/# modprobe hdmi<br />
root@mele:~/# modprobe mali<br />
root@mele:~/# export A10HWR=1 (ensure to have this set if not rebooting!)<br />
root@mele:~/# cd /allwinner/xbmc-pvr-bin/lib/xbmc<br />
root@mele:/allwinner/xbmc-pvr-bin/lib/xbmc# ./xbmc.bin<br />
<br />
== Using the Android libraries via libhybris ==<br />
Due to some bugs in the native linux binaries of cedarx, ssvb succeeded to use libhybris and the Android binaries instead. This is the recommended way.<br />
See [[CedarX/libve]].<br />
<br />
== Troubleshooting ==<br />
* (native) If you get a compiler error when processing h264.o or building xbmc.bin, then check, if swap is enabled. The compiler ran out of memory!<br />
* (native) If deb-building fails, check, if your tmp-directory has enough free space and is no tmpfs, because of the lack of memory an mele.<br />
* To use the bash-script bin/xbmc to start xbmc, you have to comment out the exec of FEH.py, because of a failing test of glxinfo -> no display found.<br />
* Depending on your setup you may have to change some things to build<br />
* If mysql_config is not found, even though it is clearly there you can set disable-mysql in Makefile under xbmca10/tools/a10/depends/xbmc<br />
* Header files might not be where they are expected, this can be fixed with symlinks and copying headers, for example...<br />
ln -s usr/include/dbus1.0/dbus usr/include/dbus <br />
* Once you get in trouble with some mesa conflicts, ensure to not have installed the following packages on your target system: <br />
libegl1-mesa libegl1-mesa-dev libegl1-mesa-drivers libgles2-mesa libgles2-mesa-dev<br />
* Check the discussion section for more notes.<br />
* Ensure that you have installed ALL of the dependencies, header files etc. in your target rootfs and ensure that they are available during build. The build script does not search for them on your host-rootfs!<br />
<br />
= Configuring XBMC dependencies for Linux on A10 based devices =<br />
== Getting IR (infrared) remotes working on A10 based media players ==<br />
For getting IR (infrared) remote controls working on the A10 based media players, please see the [[LIRC (Linux Infrared Remote Control) for the IR receivers and and remotes]] article in this wiki. Place a suitable [[Lircmap.xml]] in userdata-directory.<br />
<br />
= Enabling dirty regions (a.k.a. dirty textures) for XBMC =<br />
This dirty region (a.k.a. dirty texture) feature in XBMC is designed to improve XBMC's GUI renderer performance on the GPU by only drawing when something like a texture changes on the screen, that region is then marked as dirty by XBMC's GUI library and only that region is redraw region on the screen.<br />
<br />
This feature is however still a little buggy and therefor not enabled by default in XBMC, but all users of XBMC on A10 based devices can try enabling the hidden "dirty regions" (a.k.a. "dirty textures") rendering feature advanced setting themselves manually. <br />
<br />
* http://wiki.xbmc.org/index.php?title=HOW-TO:Enable_dirty_regions<br />
* http://xbmc.org/theuni/2011/06/19/working-with-dirty-regions/<br />
* http://wiki.xbmc.org/index.php?title=Advancedsettings.xml#.3Calgorithmdirtyregions.3E<br />
<br />
Dirty regions are any parts of the screen that have changed since the last frame. By not re-rendering what hasn't changed, big speed gains can be seen. Because all GPUs work differently, only Mode 3, combined with nofliptimeout=0, is guaranteed to be safe for everyone, but current timing issues with nofliptimeout keep this from being the default. Note that with "dirty regions" your system CPU usage might go up a little (because it is doing the dirty regions calculations) but your GPU usage will be much lower, and since it is the GPU and not CPU that is the bottleneck in XBMC for embedded systems your GUI performance will be better even though the CPU usage is higher.<br />
<br />
{| class="wikitable"<br />
! value !! result !! description<br />
|-<br />
! 0<br />
| Off<br />
| The entire viewport is always rendered, which is the same as having the dirty regions feature disabled. This is the default mode.<br />
|-<br />
! 1<br />
|Union<br />
|All dirty regions are grouped into the smallest possible rectangle. This is typically the fastest mode for slower GPUs due to only making one pass.<br />
|-<br />
! 2<br />
|Cost reduction<br />
| Each dirty region is presented separately, in as many passes as there are regions.<br />
|-<br />
! 3<br />
|Whole Screen<br />
| The entire screen is rendered if there are any dirty regions. This, combined with nofliptimeout is a safe default for drivers that clear buffer contents (manifests as blinking or vibrating images)<br />
|}<br />
<br />
To enable dirty regions manually you need to create a "advancedsettings.xml" text file youself and put the XML <algorithmdirtyregions> enabling tags in there and copying to your "/userdata/" folder (/home/username/.xbmc/userdata/).<br />
<br />
Example:<br />
<code><br />
<gui> <br />
<algorithmdirtyregions>1</algorithmdirtyregions><br />
</gui><br />
</code><br />
<br />
You could also try to enable the <nofliptimeout> feature but that is even more experimental so know that it can cause even more GUI rendering issues in XBMC<br />
<br />
Example: <br />
<code><br />
<gui> <br />
<nofliptimeout>1000</nofliptimeout><br />
</gui><br />
</code><br />
<br />
To have both of these enabled your "advancedsettings.xml" then the finished file should look something like this:<br />
<br />
<code><br />
<advancedsettings><br />
<gui> <br />
<algorithmdirtyregions>1</algorithmdirtyregions><br />
<nofliptimeout>1000</nofliptimeout><br />
</gui><br />
</advancedsettings><br />
</code><br />
<br />
=Sources implementing A10 on XBMC=<br />
* [https://github.com/empatzero/xbmca10 https://github.com/empatzero/xbmca10]<br />
** [https://github.com/rellla/xbmca10 https://github.com/rellla/xbmca10] Recommended fork of empatzero ([http://pastebin.com/M4Di5tha Diff to upstream])<br />
** [https://github.com/vidonme/xbmc/ https://github.com/vidonme/xbmc/] Sources of [http://www.vidon.me/download.html VidOn.Me Player]? Seems to be a fork from empatzero. ([http://pastebin.com/LuQ4AB9J Diff to upstream] and [https://github.com/vidonme/xbmc/compare/xbmc:7b9ab8a85fd2b6030e6cf2659ff16380afef3996...master Github Compare]) This repo is reported from VidOn.me to be the "official" source code for their Allwinner XBMC version. The only commit from VidOn.me is [https://github.com/vidonme/xbmc/commit/b2b1696e8eb6617da07e0a043ca6ef2219ca080d#diff-2c44bd39cfe6b4185fe6a51b78c46cd0R122 this one]. <br />
* [https://github.com/huceke/xbmc/tree/allwinner https://github.com/huceke/xbmc/tree/allwinner] Gimli's implementation ([http://pastebin.com/Nu3DrfNK Diff to upstream])<br />
<br />
=References=<br />
<references /><br />
<br />
= See also =<br />
* [[CedarX]] - Library for Allwinner A10 VPU (Video Processor Unit) used for audio and video decoding and encoding hardware off-loading.<br />
** [[CedarXVideoRenderingChart]] - Overview chart of working/ non working video files<br />
* [[LIRC (Linux Infrared Remote Control) for the IR receivers and and remotes]]<br />
* [[Tvheadend TV Tuner Server and PVR backend]]<br />
<br />
=External Links=<br />
* [http://forum.xbmc.org/showthread.php?tid=126995 XBMC Official Community Forum discussion about porting to Allwinner A10]<br />
* [http://jas-hacks.blogspot.co.uk/2012/11/hackberry-a10-xbmc.html Jas Hacks Hackberry A10 - XBMC on Ubuntu 12.10 image]<br />
* [http://www.j1nx.nl/buildroot-xbmc-on-mele-a1000-allwinner-a10/ Buildroot XBMC on the Mele A1000 (Allwinner A10)]<br />
* [http://www.cnx-software.com/2012/11/12/xbmc-for-linux-on-allwinner-a10-devices-it-works-sort-of/ XBMC for Linux on AllWinner A10 Devices? It Works! (Sort of)]<br />
<br />
[[Category:Software]]<br />
[[Category:Tutorial]]<br />
[[Category:CedarX]]</div>Rockerhttps://linux-sunxi.org/index.php?title=CedarX/XBMC&diff=8765CedarX/XBMC2014-05-09T16:11:04Z<p>Rocker: Mention that this applies on all CadarX based Allwinner SoCs including both A10 and A20</p>
<hr />
<div><div style="color:#6F0000; border: 3px dashed #BF4F4F; padding: 2em;"><big><br />
'''XBMC for linux on Allwinner devices is NOT READY FOR USE!'''<br />
<br />
This is only a hack intended for developers and curious users at the moment. Don't expect it to work as you want it! Hardware is capable to make it run quite good in the future, but software and drivers are not ready yet. The [[:Category:Community|sunxi-community]] is working towards making a smooth XBMC experience possible.<br />
<br />
If you want to help developing the needed components to have a stable XBMC in the future, join the [[:Category:Community|irc and mailing list]]. Developers wanted!</big></div><br />
<br/><br />
<br />
XBMC is a popular media center software with 10-foot interface designed for large-screen televisions, and it enables ARM-based media players and set-top boxes like those with Allwinner SoCs with [[CedarX]] to play and view high-definition videos, music, and other digital media files from local and network storage media, as well as stream podcasts, videocasts, and such of the internet.<br />
<br />
This article contain instructions on compiling and developing XBMC on and for Allwinner A10, A10s, A13, and A20 SoCs. Note that these instructions are specifically only meant for developers and advanced or expert Linux users that can actively assist with the porting process.<br />
<br />
=Overview=<br />
XBMC has already have an initial port for the A10 / A20 SoC with [[CedarX]] hardware accelerated video decoding, this experimental third-party port and the code patches have however not yet made it upstream into mainline XBMC.<ref>http://www.j1nx.nl/buildroot-xbmc-on-mele-a1000-allwinner-a10/ Buildroot XBMC on the Mele A1000 (Allwinner A10)</ref><ref>http://www.cnx-software.com/2012/11/12/xbmc-for-linux-on-allwinner-a10-devices-it-works-sort-of/ XBMC for Linux on AllWinner A10 Devices? It Works! (Sort of)</ref><br />
<br />
Pre-built application binaries of this port are not available so therefore you will need to compile XBMC yourself, at least until if and when the code makes it into the mainline XBMC upstream at http://xbmc.org<br />
<br />
Team-XBMC, the official development team of XBMC, does currently not recommend that any end-user buy Allwinner A10 or A20 based hardware for the specific purpose of only running XBMC since they do not have the resources to support this platform as of yet.<br />
<br />
More information about XBMC can be found on wikipedia http://en.wikipedia.org/wiki/XBMC and the XBMC wiki http://wiki.xbmc.org or http://forum.xbmc.org<br />
<br />
= Building XBMC for A10 and A20 =<br />
This is a little how-to of steps to compile XBMC for devices using Allwinner A10 and A20 SoCs (e.g. Mele A1000, Cubieboard) based on Empat0's GitHub sources [http://github.com/empatzero/xbmca10 http://github.com/empatzero/xbmca10].<br />
The development work on the coding side was all done by Empat0 (a.k.a. empat zero). The used repository in the example below is however from [http://github.com/rellla/xbmca10 http://github.com/rellla/xbmca10] which is currently the newest and contains a few adaptions. It is a fork of empat0's work. <br />
<br />
The result should be a Debian armhf system with XBMC using [[CedarX]] for hardware accelerated video decoding.<br />
<br />
This version of XBMC runs directly on the framebuffer, and thus XServer is therefor not needed!<br />
<br />
== Prerequisites ==<br />
There are more ways to prepare a working rootfs for XBMC. You can either prepare the sdcard directly as described or you can chroot into the rootfs on your host system and sync it with your sdcard later when you have finished.<br />
So the following steps can also be done in a chroot on your host if you are cross-compiling.<br />
<br />
=== Prepare your SD-Card ===<br />
Create a bootable SD-Card follwing [[Manual_build_howto| our manual build howto]] and Debian. Be sure to use a kernel with mali-drivers-version r3p0 (sunxi-3.0 should be good).<br />
<br />
=== Boot into your target system ===<br />
Boot the new debian from the sd-card directly on the target and bring the system up to date:<br />
root@mele:~/# apt-get update<br />
root@mele:~/# apt-get upgrade<br />
<br />
=== Install the dependencies for XBMC (needs update!) ===<br />
root@mele:~/# apt-get build-dep xbmc<br />
<br />
this should install the following packages:<br />
autoconf automake autopoint autotools-dev binutils bsdmainutils build-essential bzip2 cmake cmake-data comerr-dev cpp cpp-4.4 cpp-4.6 curl<br />
debhelper dpkg-dev emacsen-common fontconfig-config g++ g++-4.4 g++-4.6 gawk gcc gcc-4.4 gcc-4.4-base gcc-4.6 gcc-4.6-base gettext<br />
gettext-base git git-man gperf groff-base html2text intltool-debian krb5-multidev libao-common libao-dev libao4 libarchive12 libasound2<br />
libasound2-dev libasprintf0c2 libass-dev libass4 libasyncns0 libavahi-client-dev libavahi-client3 libavahi-common-data libavahi-common-dev<br />
libavahi-common3 libavcodec-dev libavcodec53 libavfilter-dev libavfilter2 libavformat-dev libavformat53 libavutil-dev libavutil51<br />
libbluetooth-dev libbluetooth3 libbluray-dev libbluray1 libboost-date-time1.49-dev libboost-date-time1.49.0 libboost-dev<br />
libboost-serialization1.49-dev libboost-serialization1.49.0 libboost-thread-dev libboost-thread1.49-dev libboost-thread1.49.0<br />
libboost1.49-dev libbz2-dev libc-dev-bin libc6-dev libcaca-dev libcaca0 libcdio-dev libcdio13 libcec-dev libcec1 libcroco3 libcurl3<br />
libcurl3-gnutls libcurl4-gnutls-dev libcwiid-dev libcwiid1 libdbus-1-3 libdbus-1-dev libdirac-encoder0 libdirectfb-1.2-9 libdirectfb-dev<br />
libdirectfb-extra libdpkg-perl libdrm2 libelf1 libenca-dev libenca0 liberror-perl libexpat1 libexpat1-dev libflac-dev libflac8 libfontconfig1<br />
libfontconfig1-dev libfreetype6 libfreetype6-dev libfribidi-dev libfribidi0 libgcrypt11-dev libgettextpo0 libgl1-mesa-dev libgl1-mesa-glx<br />
libglapi-mesa libglew-dev libglew1.7 libglib2.0-bin libglib2.0-dev libglu1-mesa libglu1-mesa-dev libgmp10 libgnutls-dev libgnutls-openssl27<br />
libgnutlsxx27 libgomp1 libgpg-error-dev libgsm1 libgssrpc4 libhal-dev libhal-storage-dev libhal-storage1 libhal1 libice-dev libice6 libicu48<br />
libidn11-dev libiso9660-8 libiso9660-dev libjasper-dev libjasper1 libjbig-dev libjbig0 libjpeg8 libjpeg8-dev libjson0 libkadm5clnt-mit8<br />
libkadm5srv-mit8 libkdb5-6 libkrb5-dev liblcms1 libldap-2.4-2 libldap2-dev libltdl-dev libltdl7 liblzo2-2 liblzo2-dev libmad0 libmad0-dev<br />
libmicrohttpd-dev libmicrohttpd10 libmikmod2 libmikmod2-dev libmodplug-dev libmodplug1 libmp3lame-dev libmp3lame0 libmpc2 libmpeg2-4<br />
libmpeg2-4-dev libmpfr4 libmysqlclient-dev libmysqlclient18 libnettle4 libnfs-dev libnfs1 libogg-dev libogg0 libopencv-core2.3<br />
libopencv-imgproc2.3 libopenjpeg2 liborc-0.4-0 libp11-kit-dev libpcre3-dev libpcrecpp0 libpipeline1 libplist-dev libplist1 libpng12-0<br />
libpng12-dev libpopt0 libpostproc-dev libpostproc52 libpthread-stubs0 libpthread-stubs0-dev libpulse-dev libpulse-mainloop-glib0 libpulse0<br />
libpython2.7 librtmp-dev librtmp0 libsamplerate0 libsamplerate0-dev libsasl2-2 libschroedinger-1.0-0 libsdl-image1.2 libsdl-image1.2-dev<br />
libsdl-mixer1.2 libsdl-mixer1.2-dev libsdl1.2-dev libsdl1.2debian libshairport-dev libshairport1 libsigsegv2 libslang2-dev libsm-dev libsm6<br />
libsmbclient libsmbclient-dev libsndfile1 libspeex1 libsqlite3-0 libsqlite3-dev libssh2-1 libssh2-1-dev libssl-dev libstdc++6-4.4-dev<br />
libstdc++6-4.6-dev libswscale-dev libswscale2 libtalloc2 libtasn1-3-dev libtdb1 libtheora0 libtiff4 libtiff4-dev libtiffxx0c2<br />
libtimedate-perl libtinyxml-dev libtinyxml2.6.2 libtool libts-0.0-0 libts-dev libudev-dev libunistring0 libva-dev libva-egl1 libva-glx1<br />
libva-tpi1 libva-x11-1 libva1 libvdpau-dev libvdpau1 libvorbis-dev libvorbis0a libvorbisenc2 libvorbisfile3 libvpx1 libwbclient0 libwebp-dev<br />
libwebp2 libx11-dev libx11-xcb1 libx264-123 libxau-dev libxcb-glx0 libxcb1-dev libxdamage1 libxdmcp-dev libxext-dev libxfixes3 libxi6<br />
libxml2-dev libxmlrpc-core-c3 libxmu-dev libxmu-headers libxmu6 libxrandr-dev libxrandr2 libxrender-dev libxrender1 libxt-dev libxt6 libxtst6<br />
libxvidcore4 libxxf86vm1 libyajl-dev libyajl2 linux-libc-dev m4 make man-db mesa-common-dev mysql-common patch pkg-config po-debconf python<br />
python-dev python-imaging python-minimal python-support python2.7 python2.7-dev python2.7-minimal tsconf ttf-dejavu-core ucf x11-common<br />
x11proto-core-dev x11proto-input-dev x11proto-kb-dev x11proto-randr-dev x11proto-render-dev x11proto-xext-dev xorg-sgml-doctools xtrans-dev<br />
yasm zip zlib1g-dev<br />
<br />
need to install 3 more dependencies:<br />
root@mele:~/# apt-get install swig default-jre libgtk2.0-bin libssh-4 libssh-dev<br />
<br />
ensure you use hardware acceleration<br />
root@mele:~/# echo -e "\nA10HWR=1" >> /etc/environment (to set it permanently)<br />
<br />
Now go on with [[XBMC#Native_Compile_of_XBMC | Native Compile]] or [[XBMC#Cross_Compile_of_XBMC | Cross Compile]].<br />
<br />
== Native Compile of XBMC ==<br />
<br />
=== Prerequisites for native compile ===<br />
<br />
Create a swap-file, because otherwise the compiler runs out of memory during compiling and aborts<br />
root@mele:~/# dd if=/dev/zero of=/swap bs=1M count=384<br />
root@mele:~/# mkswap -c /swap<br />
root@mele:~/# swapon /swap<br />
<br />
Create your workspace directory:<br />
root@mele:~/# mkdir melehacking<br />
root@mele:~/# cd melehacking<br />
<br />
=== Checkout the source code ===<br />
root@mele:~/melehacking# apt-get install git<br />
root@mele:~/melehacking# git clone git://github.com/rellla/xbmca10.git<br />
root@mele:~/melehacking# cd xbmca10<br />
root@mele:~/melehacking/xbmca10# git checkout stage/Frodo<br />
<br />
=== Build ===<br />
The following external libs/ repos are used/ downloaded:<br />
* taglib: https://github.com/downloads/taglib/taglib/taglib-1.8.tar.gz<br />
* cedarx: https://github.com/linux-sunxi/cedarx-libs/tree/master/libcedarv/linux-armhf<br />
* libmad: ftp://ftp.mars.org/pub/mpeg/libmad-0.15.1b.tar.gz<br />
* mali: https://github.com/linux-sunxi/sunxi-mali-proprietary/tree/master/r3p0/armhf<br />
* mali-dev: https://github.com/linux-sunxi/sunxi-mali/tree/master/include<br />
<br />
Build dependencies<br />
root@mele:~/melehacking/xbmca10# cd tools/a10/depends<br />
root@mele:~/melehacking/xbmca10/tools/a10/depends# make<br />
Build xbmc itself<br />
root@mele:~/melehacking/xbmca10/tools/a10/depends# make -C xbmc<br />
root@mele:~/melehacking/xbmca10/tools/a10/depends# cd ../../../<br />
root@mele:~/melehacking/xbmca10# make install<br />
<br />
Move on to [[XBMC#Start_xbmc]] and start XBMC.<br />
<br />
== Cross Compile of XBMC ==<br />
This was tested with github.com/rellla/xbmca10 and built in Debian Sid as host. You will need several packages on the build system and a copy <br />
of the root file system of the target to build against. This howto assumes you are running off an SD card with the root file system in /dev/sdb2.<br />
=== Setup Cross Compiler ===<br />
* At first set up your [[Toolchain|toolchain]].<br />
<br />
=== Prerequisites for Cross Compiling ===<br />
* Sync and move SD card to build system<br />
* Mount the rootfs of the prepared SD Card<br />
root@debian:~/# mount /dev/sdb2 /mnt/rootfs-a10<br />
* Create symlinks to the mounted libraries<br />
root@debian:~/# ln -s /mnt/rootfs-a10/lib/arm-linux-gnueabihf /lib/arm-linux-gnueabihf<br />
root@debian:~/# ln -s /mnt/rootfs-a10/usr/lib/arm-linux-gnueabihf /usr/lib/arm-linux-gnueabihf<br />
root@debian:~/# ln -s /mnt/rootfs-a10/usr/include/arm-linux-gnueabihf /usr/include/arm-linux-gnueabihf<br />
* Install the dependencies for building XBMC on the host system<br />
root@debian:~/# apt-get build-dep xbmc<br />
root@debian:~/# apt-get install shtool swig default-jre<br />
* Create your workspace directory:<br />
root@debian:~/# mkdir melehacking<br />
root@debian:~/# cd melehacking<br />
<br />
=== Checkout the source code ===<br />
root@debian:~/melehacking# git clone git://github.com/rellla/xbmca10.git<br />
root@debian:~/melehacking# cd xbmca10<br />
root@debian:~/melehacking/xbmca10# git checkout stage/Frodo<br />
<br />
=== Update XBMC build config ===<br />
Update this section at line 48 of tools/a10/depends/depends.mk with your values, e.g.<br />
#where is your arm rootfs<br />
SDKSTAGE=/mnt/rootfs-a10<br />
#where is your xbmc install root <br />
XBMCPREFIX=/allwinner/xbmc-pvr-bin$(HF)<br />
#where is your toolchain<br />
TOOLCHAIN=/usr/arm-linux-gnueabi$(HF)<br />
<br />
=== Build ===<br />
At this point the settings are basically the same for the native build:<br />
Build dependencies<br />
root@debian:~/melehacking/xbmca10# cd tools/a10/depends<br />
root@debian:~/melehacking/xbmca10/tools/a10/depends# make<br />
Build xbmc itself<br />
root@debian:~/melehacking/xbmca10/tools/a10/depends# make -C xbmc<br />
root@debian:~/melehacking/xbmca10/tools/a10/depends# cd ../../../<br />
root@debian:~/melehacking/xbmca10# make install<br />
<br />
=== Move XBMC to target system ===<br />
You should copy from your install location on your build system to an identical location on the target system (may not vital that they have the same path) like so ...<br />
root@debian:~/melehacking/xbmca10/cp -r /allwinner/xbmc-pvr-binhf /mnt/rootfs-a10/allwinner/xbmc-pvr-binhf<br />
<br />
To redistribute it, you can also create a tarball:<br />
root@debian:~/melehacking/xbmca10/tools/a10/depends# make -C package tarball<br />
This results in a xbmca10.tar.gz which includes all needed (and stripped) files in /allwinner/xbmc-pvr-binhf. This can easily be copied and extracted on the target rootfs.<br />
<br />
Umount your SD Card<br />
root@debian:~/melehacking/xbmca10# umount /dev/sdb2<br />
and boot it on your A10 Device.<br />
<br />
== Start XBMC ==<br />
After a reboot you modprobe the needed modules (depending on the used kernel version):<br />
root@mele:~/# modprobe disp<br />
root@mele:~/# modprobe lcd<br />
root@mele:~/# modprobe hdmi<br />
root@mele:~/# modprobe mali<br />
root@mele:~/# export A10HWR=1 (ensure to have this set if not rebooting!)<br />
root@mele:~/# cd /allwinner/xbmc-pvr-bin/lib/xbmc<br />
root@mele:/allwinner/xbmc-pvr-bin/lib/xbmc# ./xbmc.bin<br />
<br />
== Using the Android libraries via libhybris ==<br />
Due to some bugs in the native linux binaries of cedarx, ssvb succeeded to use libhybris and the Android binaries instead. This is the recommended way.<br />
See [[CedarX/libve]].<br />
<br />
== Troubleshooting ==<br />
* (native) If you get a compiler error when processing h264.o or building xbmc.bin, then check, if swap is enabled. The compiler ran out of memory!<br />
* (native) If deb-building fails, check, if your tmp-directory has enough free space and is no tmpfs, because of the lack of memory an mele.<br />
* To use the bash-script bin/xbmc to start xbmc, you have to comment out the exec of FEH.py, because of a failing test of glxinfo -> no display found.<br />
* Depending on your setup you may have to change some things to build<br />
* If mysql_config is not found, even though it is clearly there you can set disable-mysql in Makefile under xbmca10/tools/a10/depends/xbmc<br />
* Header files might not be where they are expected, this can be fixed with symlinks and copying headers, for example...<br />
ln -s usr/include/dbus1.0/dbus usr/include/dbus <br />
* Once you get in trouble with some mesa conflicts, ensure to not have installed the following packages on your target system: <br />
libegl1-mesa libegl1-mesa-dev libegl1-mesa-drivers libgles2-mesa libgles2-mesa-dev<br />
* Check the discussion section for more notes.<br />
* Ensure that you have installed ALL of the dependencies, header files etc. in your target rootfs and ensure that they are available during build. The build script does not search for them on your host-rootfs!<br />
<br />
= Configuring XBMC dependencies for Linux on A10 based devices =<br />
== Getting IR (infrared) remotes working on A10 based media players ==<br />
For getting IR (infrared) remote controls working on the A10 based media players, please see the [[LIRC (Linux Infrared Remote Control) for the IR receivers and and remotes]] article in this wiki. Place a suitable [[Lircmap.xml]] in userdata-directory.<br />
<br />
= Enabling dirty regions (a.k.a. dirty textures) for XBMC =<br />
This dirty region (a.k.a. dirty texture) feature in XBMC is designed to improve XBMC's GUI renderer performance on the GPU by only drawing when something like a texture changes on the screen, that region is then marked as dirty by XBMC's GUI library and only that region is redraw region on the screen.<br />
<br />
This feature is however still a little buggy and therefor not enabled by default in XBMC, but all users of XBMC on A10 based devices can try enabling the hidden "dirty regions" (a.k.a. "dirty textures") rendering feature advanced setting themselves manually. <br />
<br />
* http://wiki.xbmc.org/index.php?title=HOW-TO:Enable_dirty_regions<br />
* http://xbmc.org/theuni/2011/06/19/working-with-dirty-regions/<br />
* http://wiki.xbmc.org/index.php?title=Advancedsettings.xml#.3Calgorithmdirtyregions.3E<br />
<br />
Dirty regions are any parts of the screen that have changed since the last frame. By not re-rendering what hasn't changed, big speed gains can be seen. Because all GPUs work differently, only Mode 3, combined with nofliptimeout=0, is guaranteed to be safe for everyone, but current timing issues with nofliptimeout keep this from being the default. Note that with "dirty regions" your system CPU usage might go up a little (because it is doing the dirty regions calculations) but your GPU usage will be much lower, and since it is the GPU and not CPU that is the bottleneck in XBMC for embedded systems your GUI performance will be better even though the CPU usage is higher.<br />
<br />
{| class="wikitable"<br />
! value !! result !! description<br />
|-<br />
! 0<br />
| Off<br />
| The entire viewport is always rendered, which is the same as having the dirty regions feature disabled. This is the default mode.<br />
|-<br />
! 1<br />
|Union<br />
|All dirty regions are grouped into the smallest possible rectangle. This is typically the fastest mode for slower GPUs due to only making one pass.<br />
|-<br />
! 2<br />
|Cost reduction<br />
| Each dirty region is presented separately, in as many passes as there are regions.<br />
|-<br />
! 3<br />
|Whole Screen<br />
| The entire screen is rendered if there are any dirty regions. This, combined with nofliptimeout is a safe default for drivers that clear buffer contents (manifests as blinking or vibrating images)<br />
|}<br />
<br />
To enable dirty regions manually you need to create a "advancedsettings.xml" text file youself and put the XML <algorithmdirtyregions> enabling tags in there and copying to your "/userdata/" folder (/home/username/.xbmc/userdata/).<br />
<br />
Example:<br />
<code><br />
<gui> <br />
<algorithmdirtyregions>1</algorithmdirtyregions><br />
</gui><br />
</code><br />
<br />
You could also try to enable the <nofliptimeout> feature but that is even more experimental so know that it can cause even more GUI rendering issues in XBMC<br />
<br />
Example: <br />
<code><br />
<gui> <br />
<nofliptimeout>1000</nofliptimeout><br />
</gui><br />
</code><br />
<br />
To have both of these enabled your "advancedsettings.xml" then the finished file should look something like this:<br />
<br />
<code><br />
<advancedsettings><br />
<gui> <br />
<algorithmdirtyregions>1</algorithmdirtyregions><br />
<nofliptimeout>1000</nofliptimeout><br />
</gui><br />
</advancedsettings><br />
</code><br />
<br />
=Sources implementing A10 on XBMC=<br />
* [https://github.com/empatzero/xbmca10 https://github.com/empatzero/xbmca10]<br />
** [https://github.com/rellla/xbmca10 https://github.com/rellla/xbmca10] Recommended fork of empatzero ([http://pastebin.com/M4Di5tha Diff to upstream])<br />
** [https://github.com/vidonme/xbmc/ https://github.com/vidonme/xbmc/] Sources of [http://www.vidon.me/download.html VidOn.Me Player]? Seems to be a fork from empatzero. ([http://pastebin.com/LuQ4AB9J Diff to upstream] and [https://github.com/vidonme/xbmc/compare/xbmc:7b9ab8a85fd2b6030e6cf2659ff16380afef3996...master Github Compare]) This repo is reported from VidOn.me to be the "official" source code for their Allwinner XBMC version. The only commit from VidOn.me is [https://github.com/vidonme/xbmc/commit/b2b1696e8eb6617da07e0a043ca6ef2219ca080d#diff-2c44bd39cfe6b4185fe6a51b78c46cd0R122 this one]. <br />
* [https://github.com/huceke/xbmc/tree/allwinner https://github.com/huceke/xbmc/tree/allwinner] Gimli's implementation ([http://pastebin.com/Nu3DrfNK Diff to upstream])<br />
<br />
=References=<br />
<references /><br />
<br />
= See also =<br />
* [[CedarX]] - Library for Allwinner A10 VPU (Video Processor Unit) used for audio and video decoding and encoding hardware off-loading.<br />
** [[CedarXVideoRenderingChart]] - Overview chart of working/ non working video files<br />
* [[LIRC (Linux Infrared Remote Control) for the IR receivers and and remotes]]<br />
* [[Tvheadend TV Tuner Server and PVR backend]]<br />
<br />
=External Links=<br />
* [http://forum.xbmc.org/showthread.php?tid=126995 XBMC Official Community Forum discussion about porting to Allwinner A10]<br />
* [http://jas-hacks.blogspot.co.uk/2012/11/hackberry-a10-xbmc.html Jas Hacks Hackberry A10 - XBMC on Ubuntu 12.10 image]<br />
* [http://www.j1nx.nl/buildroot-xbmc-on-mele-a1000-allwinner-a10/ Buildroot XBMC on the Mele A1000 (Allwinner A10)]<br />
* [http://www.cnx-software.com/2012/11/12/xbmc-for-linux-on-allwinner-a10-devices-it-works-sort-of/ XBMC for Linux on AllWinner A10 Devices? It Works! (Sort of)]<br />
<br />
[[Category:Software]]<br />
[[Category:Tutorial]]<br />
[[Category:CedarX]]</div>Rockerhttps://linux-sunxi.org/index.php?title=Mainline_Kernel_Howto&diff=7156Mainline Kernel Howto2014-03-04T16:20:32Z<p>Rocker: /* See also */</p>
<hr />
<div>This articles describes how you can compile and use the Linux mainline kernel. For work done and to do read [[Linux mainlining effort]] please.<br />
<br />
== Warning ==<br />
<br />
The sunxi kernel mainlining effort is a massive task, and using upstream code today is very much a developer only undertaking. The upstream code does not support NAND, MMC or SATA, you can only boot off a USB harddisk. Similarly, it lacks sound, display, 3D, 2D and media support. If you simply want a more-or-less usable device now, then use [[Linux_Kernel|our own 3.4 branch]].<br />
<br />
For a detailed status of supported subsystems, please refer to the [[Linux mainlining effort]] page.<br />
<br />
== Prerequisites ==<br />
<br />
* An initramfs image (for example generated using buildroot)<br />
* An ARM [[Toolchain|toolchain]]<br />
* U-boot supporting device tree (if unsure, use a fresh build from the sunxi branch of u-boot-sunxi)<br />
<br />
== Supported boards ==<br />
<br />
As of 3.12, the boards and SoC supported are:<br />
* A10<br />
:* Cubieboard<br />
:* Melee A1000<br />
:* Mini X-plus<br />
:* Hackberry<br />
* A10s<br />
:* A10s-olinuxino<br />
* A13<br />
:* A13-olinuxino<br />
* A20<br />
:* A20-olinuxino<br />
:* Cubieboard2<br />
* A31<br />
:* A31 EVK<br />
<br />
For boards using these SoCs, adding a new device tree should be trivial.<br />
<br />
== Downloading the kernel source code ==<br />
=== Stable releases ===<br />
<br />
The stable releases are released by Linus Torvalds. Since Linux 3.8, the Allwinner support is added gradually. It is still quite sparse, but we are making good progress. This is probably what you should choose if you are looking for stability.<br />
<br />
git clone git://git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux.git<br />
<br />
=== Patches merged in the next stable release ===<br />
<br />
There is also a sunxi-next branch maintained with all the inclusions that have been accepted, merged and will included in the next stable release. If you want to do some development, it's probably the best pick.<br />
<br />
git clone [http://github.com/mripard/linux/tree/sunxi-next git://github.com/mripard/linux.git] -b sunxi-next<br />
<br />
=== Patches not yet merged in the next release ===<br />
<br />
You can find a sunxi-devel branch on linux-sunxi. This branch contains functional patches that are currently being reviewed on the kernel lists. If you want to do bleeding-edge mainline testing, this should probably be your pick. Please do not use this branch for development, as it is frequently rebased and the code is likely to change.<br />
<br />
git clone [http://github.com/linux-sunxi/linux-sunxi/tree/sunxi-devel git://github.com/linux-sunxi/linux-sunxi.git] -b sunxi-devel<br />
<br />
== Configuration ==<br />
<br />
ARCH=arm make sunxi_defconfig<br />
ARCH=arm make menuconfig<br />
<br />
Once there, fill the option '''General Setup / Initramfs source file(s)''' with a path to your initramfs image.<br />
<br />
== Compilation ==<br />
<br />
ARCH=arm CROSS_COMPILE=<toolchain-prefix> LOADADDR=0x40008000 make uImage dtbs<br />
<br />
After the compilation ended, you should have generated both the uImage in arch/arm/boot, and a device tree blob in arch/arm/boot/dts.<br />
<br />
This device tree blob (or simply dtb) gives to the kernel the description of the hardware it's currently running on. In its goal, it's pretty similar to the FEX scripts that Allwinner uses, yet far more generic. It allows to compile a single kernel image that will run on several platforms.<br />
<br />
Identify the dtb file for you board in arch/arm/boot/dts. You will need it in the next step.<br />
<br />
== Kernel Loading ==<br />
<br />
Now copy the relevant dtb and uImage somewhere that you can load it from on your board, like a tftp server, a SD Card, etc.<br />
<br />
Once you get to the U-boot prompt, stop the autoboot, and load the kernel image and device tree into memory making sure the will not overlap.<br />
<br />
Depending on where you store it, you will have something like<br />
fatload mmc 0 0x46000000 uImage<br />
fatload mmc 0 0x49000000 <board>.dtb<br />
<br />
'''Warning''': Before giving control to the kernel the U-Boot will move the loaded binaries to some different addresses and ignore the fact, the kernel needs much more space for extracting itselt. This causes a dtb to be overwritten and failure to boot. This of course should be fixed in U-Boot but a workaround for now is to set fdt_high:<br />
env set fdt_high ffffffff<br />
Once it's loaded into memory, you only need to tell U-Boot to boot the kernel using<br />
bootm 0x<kernel-address> 0x<initramfs-address> 0x<dtb-address><br />
if initramfs is built into the uImage, you just use "-" as a placeholder for its address. Taking all this into account your bootm might look like<br />
bootm 0x46000000 - 0x49000000<br />
<br />
The kernel should start booting up to a shell.<br />
<br />
Have fun.<br />
<br />
=References=<br />
<references /><br />
<br />
=See also=<br />
* [[Linux mainlining effort]]<br />
* [[Linux-tree-diff]] - list of kernel files modified or added ('+' sign) for allwinner SOCs.<br />
* [[Possible setups for hacking on mainline]]<br />
* [[Notes on Linux Kernel configuration]]<br />
* [[Linux Kernel]]<br />
**[[Toolchain]]<br />
<br />
=External Links=<br />
* [http://www.elinux.org/images/a/ad/Arm-soc-checklist.pdf Your new ARM SoC Linux support check-list! by Thomas Petazzoni of Free Electrons]<br />
*[http://www.cnx-software.com/2014/03/04/linux-kernel-upstreaming-how-to-linaro-connect-asia-2014/ Linux Kernel Upstreaming How-To (CNXSoft - Embedded Software Development)]<br />
**[http://www.youtube.com/watch?v=dY7fikYZ42c Matt Porter's YouTube video talk on “Upstreaming 101" (LCA14-111)]<br />
***[http://www.linaro.org/documents/download/65f888c674508efcf9bd5d90398a186a530d01c4c78db Matt Porter's presentation slides for “Upstreaming 101" (LCA14-111)]<br />
**[https://www.youtube.com/watch?v=FiQ5uV_Mm5c Matt Porter's YouTube video talk on “Upstreaming 201" (LCA14-112)]<br />
***[http://www.linaro.org/documents/download/7b9920fcc89589bad9063d87d9137f08530d020b71924 Matt Porter's presentation slides for “Upstreaming 201" (LCA14-112)]<br />
*[http://www.cnx-software.com/2011/08/19/how-to-write-and-submit-a-linux-kernel-patch/ How to Write and Submit a Linux Kernel Patch (CNXSoft - Embedded Software Development)]<br />
** [http://www.youtube.com/watch?v=LLBrBBImJt4 YouTube Video- Write and Submit your first Linux kernel Patch]<br />
** [http://www.cnx-software.com/pdf/kernel-tutorial/kernel_patch_tutorial.pdf Greg Kroah-Hartman Kernel Tutorial Write and Submit your first Linux Kernel Patch]<br />
*[http://www.linaro.org/connect-lca14/resources Linaro resources page from LCA (Linaro Connect Asia) 2014]<br />
<br />
[[Category:Tutorial]]</div>Rockerhttps://linux-sunxi.org/index.php?title=Linux_mainlining_effort&diff=7155Linux mainlining effort2014-03-04T16:20:11Z<p>Rocker: /* See also */</p>
<hr />
<div>The purpose of this page is to try and define sub-goals and milestones for the mainlining effort, containing goals and sub-goals with milestones for adding Allwinner support in the upstream mainline Linux Kernel.<br />
<br />
It is very important to note that this is intended as a rough set of minimal goals - it is not meant to collide with the huge effort of rewriting major drivers!<br />
<br />
=Overview=<br />
The idea is to submit the code needed to run the Linux kernel on Allwinner SoCs upstream, ie. to the official Linux kernel. Check out [[Linux-tree-diff]] for a rough idea of the differences.<br />
<br />
This can be achieved by following the concept outlined in the ''Your new ARM SoC Linux support check-list!'' article published by Thomas Petazzoni from Free Electrons.<ref>http://www.elinux.org/images/a/ad/Arm-soc-checklist.pdf</ref><ref>[http://www.cnx-software.com/2013/01/16/your-new-arm-soc-linux-support-check-list-elce-2012/ Your New ARM SoC Linux Support Check-List – ELCE 2012]</ref><br />
<br />
Where relevant, I have attempted to include who is currently working on an item, mostly separate from any particular mainlining goal.<br />
<br />
=Status=<br />
<br />
== Merged into 3.8 ==<br />
* Initial support for Allwinner SoCs [https://git.kernel.org/cgit/linux/kernel/git/torvalds/linux.git/commit/?id=3b52634f0b7adaaf2b29569025287b938b7c71a6 (commit)]<br />
* Timer [https://git.kernel.org/cgit/linux/kernel/git/torvalds/linux.git/commit/?id=b2ac5d7549710173ea0217bf8c7b3f71da5220d4 (commit)]<br />
* UART<br />
* Device Tree<br />
* Interrupt controller [https://git.kernel.org/cgit/linux/kernel/git/torvalds/linux.git/commit/?id=afd24e146826cec0f46929263a0c874406a19cd8 (commit)]<br />
<br />
Related merges: [https://git.kernel.org/?p=linux/kernel/git/arm/arm-soc.git;a=commit;h=5ffd785402c295328d3866d9f8630152f51d332a], [https://git.kernel.org/?p=linux/kernel/git/arm/arm-soc.git;a=commit;h=e9f6d13513ea9fd33b0184db8fc33cf51baa584b]<br />
<br />
Added board support: [[Cubieboard]], [[A13-OLinuXino]]<br />
<br />
== Merged into 3.9 ==<br />
* PINCTRL driver<br />
* GPIO-lib based driver<br />
<br />
Related merges: [https://git.kernel.org/cgit/linux/kernel/git/torvalds/linux.git/commit/drivers/pinctrl?id=8a3a11f91def34424b1995cb54ccd658efde8568]<br />
<br />
Added Board Support: [[Hackberry]]<br />
<br />
== Merged into 3.10 ==<br />
* LED support<br />
* Clock driver<br />
* Complete UART support<br />
<br />
Related merges: [https://git.kernel.org/cgit/linux/kernel/git/torvalds/linux.git/commit/?id=000a74f41e601bc4e36a760aa42f219a019c5391], [https://git.kernel.org/cgit/linux/kernel/git/torvalds/linux.git/commit/?id=362ed48dee509abe24cf84b7e137c7a29a8f4d2d], [https://git.kernel.org/cgit/linux/kernel/git/torvalds/linux.git/commit/?id=dfab34aa61a0f8c14a67d7b4c1dae28e57ba592d]<br />
<br />
Added Board Support: [[Mini X-Plus]]<br />
<br />
== Merged into 3.11 ==<br />
* IRQ support for the PIO<br />
* I2C Driver<br />
* EMAC Driver<br />
* A10s support<br />
<br />
Related merges: [https://git.kernel.org/cgit/linux/kernel/git/torvalds/linux.git/commit/?id=ee1a8d402e7e204d57fb108aa40003b6d1633036], [https://git.kernel.org/cgit/linux/kernel/git/torvalds/linux.git/commit/?id=3883cbb6c1bda013a3ce2dbdab7dc97c52e4a232], [https://git.kernel.org/cgit/linux/kernel/git/torvalds/linux.git/commit/?id=d2033f2c1d1de2239ded15e478ddb4028f192a15], [https://git.kernel.org/cgit/linux/kernel/git/torvalds/linux.git/commit/?id=3dbde57ad941c55345fd7fac0ee3f70f204b02d8], [https://git.kernel.org/cgit/linux/kernel/git/torvalds/linux.git/commit/?id=98f486f18d16e2214728d101ed8b6a12dce75539], [https://git.kernel.org/cgit/linux/kernel/git/torvalds/linux.git/commit/?id=496322bc91e35007ed754184dcd447a02b6dd685]<br />
<br />
Added board support: [[A10S-OLinuXino]]<br />
<br />
== Merged into 3.12 ==<br />
* A31 support<br />
:* Basic SoC + GPIO<br />
:* Clock support<br />
* A20 support<br />
:* Basic SoC + GPIO<br />
:* Clock support<br />
* A10s clocks<br />
* Clock Source and Clock Event rework<br />
* Mele A1000 device tree<br />
* Watchdog driver<br />
<br />
Related merges: [https://git.kernel.org/cgit/linux/kernel/git/torvalds/linux.git/commit/?id=aa7054f5a5a9ff728ce291cb103afa19f4f849eb], [https://git.kernel.org/cgit/linux/kernel/git/torvalds/linux.git/commit/?id=b4b50fd78b1e31989940dfc647e64453d0f7176a], [https://git.kernel.org/cgit/linux/kernel/git/torvalds/linux.git/commit/?id=dccfd1e439c11422d7aca0d834b0430d24650e85], [https://git.kernel.org/cgit/linux/kernel/git/torvalds/linux.git/commit/?id=ac3c1c4f1c77190408162aee559c655090597072], [https://git.kernel.org/cgit/linux/kernel/git/torvalds/linux.git/commit/?id=bef4a0ab984662d4ccd68d431a7c4ef3daebcb43], [https://git.kernel.org/cgit/linux/kernel/git/torvalds/linux.git/commit/?id=24ba40588fe50adce2a99e026fc0026872ebeb85]<br />
<br />
Added board support: [[A31 EVB]], [[A20-OLinuXino]], [[Cubieboard2]], [[Mele A1000]]<br />
<br />
== Merged into 3.13 ==<br />
* SID Driver<br />
* I2C for A20<br />
* sunxi_defconfig<br />
* Bug fixes [http://www.spinics.net/lists/arm-kernel/msg290495.html]<br />
<br />
Added board support: [[Cubietruck]]<br />
<br />
== Merged into 3.14 ==<br />
* A31<br />
:* Reset Controller Support<br />
:* SMP<br />
<br />
* A20<br />
:* SMP (via PSCI)<br />
:* External clock outputs<br />
<br />
* High Speed Timers<br />
* RTC driver<br />
* RTP (DT only)<br />
* GMAC support in stmmac driver<br />
* AP6210 WiFi (BCM43362) support in brcmfmac driver<br />
<br />
Related merges: [https://git.kernel.org/cgit/linux/kernel/git/torvalds/linux.git/commit/?id=dfd10e7ae60c6c1b24b5d601744b4fd1ecab2f31], [https://git.kernel.org/cgit/linux/kernel/git/torvalds/linux.git/commit/?id=9b6d351a75dae25430383b29a3764ae7921f6c47], [https://git.kernel.org/cgit/linux/kernel/git/torvalds/linux.git/commit/?id=0ba3307a8ec35252f7b1e222e32889a6f3d9ceb3], [https://git.kernel.org/cgit/linux/kernel/git/torvalds/linux.git/commit/?id=7e21774db5cc9cf8fe93a64a2f0c6cf47db8ab24], [https://git.kernel.org/cgit/linux/kernel/git/torvalds/linux.git/commit/?id=4ba9920e5e9c0e16b5ed24292d45322907bb9035]<br />
<br />
Added board support: [[A13-OLinuXino-Micro]]<br />
<br />
== Planned for 3.15 ==<br />
* A20<br />
:* GMAC<br />
<br />
* A31<br />
:* I2C<br />
:* SPI<br />
:* DMAengine<br />
:* GMAC (?)<br />
<br />
* RTP<br />
* OHCI<br />
* EHCI<br />
* AHCI (SATA) [http://www.spinics.net/lists/arm-kernel/msg310026.html]<br />
* SPI<br />
<br />
== Work In Progress ==<br />
=== Core Stuff ===<br />
<br />
=== Major drivers ===<br />
* DMAengine driver (WiP: Maxime Ripard (mripard) on the [[A31]])<br />
:* DMAengine driver handles slave dma clients including SPI, EMAC, USB, I2S, HDMI audio, and NAND<br />
:* Implementing slave SG transfers is the priority (for SPI to start), with cyclic transfers (for audio clients) following that<br />
:* Currently in [[A23]] SDK there AW driver for DMAEngine , it should be adapted to device tree, cleaned for mainline<br />
:* The [[A23]] shares the DMA controller with the [[A31]], only the number of channels differ (the [[A31]] has 16 channels, while the [[A23]] only has 8 of them)<br />
:* The [[A20]] and earlier SoCs have two mode of operations: Normal and Dedicated. The dedicated mode looks a lot like how the [[A31]] DMA controller works, only it supports only mem2dev transfers<br />
* SDIO Driver (WiP: Hans De Goede, David Lanzendörfer)<br />
* SATA Driver (WiP: Oliver Schinagl (oliv3r), Hans de Goede (hansg))<br />
* [[AXP209]] driver (WiP: Carlo Caione (ccaione))<br />
* NMI controller: (WiP: Carlo Caione (ccaione))<br />
* NAND Driver (WiP: Boris Brezillon (bbrezillon))<br />
<br />
=== Minor drivers ===<br />
* PWM Driver (WiP: Oliver Schinagl (oliv3r))<br />
* IR driver (WiP: Alexsey Shestacov (wingrime))<br />
* Touchpanel driver (WiP: Hans de Goede (hansg))<br />
* <strike>IIO LRADC driver (WiP: Carlo Caione (n01))</strike> Input LRADC driver (WiP: Hans de Goede (hansg))<br />
* USB OTG Driver (WiP CHen-Yu Tsai (wens))<br />
:* It seems to actually be a Mentor Graphics Inventra USB Controller (musb), that already support for it in mainline kernel, so it only needs a thin layer to adapt it to sunxi. Moreover, it's already supporting the PIO mode, so we could avoid relying on DMA to merge it. (Thanks to Arnd Bergmann for noticing)<br />
:* irc user jukivili works on getting this driver to work with sunxi-3.4<br />
:* Status 2013-10-02:<br />
::* OTG requires more work. Mode detection is working, but have not yet figured out how to reset MUSB core and hardware from host-mode to peripheral and other way around.<br />
::* Mode detection/USB-PHY stuff probably needs to be moved to new USB-PHY driver as is done with other MUSB hardware drivers.<br />
* Transport Stream (WiP: woprr)<br />
* Security System (Crypto Engine) (WiP: Corentin Labbe (Montjoie))<br />
:* Hardware Pseudo Random Number Generator<br />
:* Checksumming (MD5, SHA1)<br />
:* Crypto (AES, DES, 3DES)<br />
* CAN (WiP: Peter Chen [https://groups.google.com/forum/#!searchin/linux-sunxi/CAN/linux-sunxi/Wrj1uYO1xVo/rq_HYUW7PaIJ] [https://github.com/ryangithub/sunxi-can-driver])<br />
<br />
== Left to be done ==<br />
=== Achievable ===<br />
* Audio<br />
: A23 SDK has aSoC drivers for the first three:<br />
:* Audio Codec<br />
:* IIS/I<sup>2</sup>S (Audio transport)<br />
:* SPDIF (Audio transport)<br />
:* AC97 Interface<br />
:* We first need to support cyclic DMA transfers <br />
* CSI (Camera Input)<br />
* PS/2 (Keyboard/Mouse)<br />
* Smart Card Reader<br />
* Keypad<br />
* One wire<br />
:* A23(A31?) or higher SoCs<br />
<br />
=== Hard ===<br />
* Display<br />
:* TCON (LCD)<br />
:* HDMI<br />
:* TV Encoder (Analog output, VGA, Composite, SVHS)<br />
:* Display engine FE/BE<br />
:* Mixer<br />
* VPU (See [[Reverse Engineering]])<br />
:* Video Engine (See [[Reverse Engineering]])<br />
:* Audio Engine (See [[Reverse Engineering]])<br />
:* Audio Video Sync<br />
<br />
=== Troublesome ===<br />
* Memory Stick (has anybody actually got this hardware connected and a memory stick?)<br />
* TV Decoder (Analog in, no driver, no datasheet)<br />
* PATA (Old tech, while still interesting for Compact Flash, possibly removed from A20, though A20 memory map still mentions it)<br />
* GPS backend IP (Only [[A10]], not much interesting, as all modern GPS recivers have MCU with UART output, no documentation)<br />
<br />
=== Needing major rework ===<br />
<br />
These drivers need major rework AND lack documentation other than existing source pile.<br />
<br />
* Display driver (libv, techn also might be interested)<br />
<br />
=== Unlikely ===<br />
<br />
These are too far off the track third party drivers making it unlikely they will ever get accepted mainline.<br />
<br />
* Mali driver (will not happen unless libv gets a proper lima driver out)<br />
<br />
=== Related but separate ===<br />
* Device-specific drivers<br />
<br />
=References=<br />
<references /><br />
<br />
= See also =<br />
* [[Mainline Kernel Howto]]<br />
* [[Linux-tree-diff]] - list of kernel files modified or added ('+' sign) for allwinner SOCs.<br />
* [[Possible setups for hacking on mainline]]<br />
* [[Notes on Linux Kernel configuration]]<br />
* [[Linux Kernel]]<br />
**[[Toolchain]]<br />
<br />
=External Links=<br />
* [http://www.kernel.org kernel.org] - Official website for the Linux Kernel<br />
** [http://github.com/torvalds/linux http://github.com/torvalds/linux] - Linus Torvalds' GitHub account with the upstream Linux kernel<br />
* [http://www.kernel.org/doc/ Linux Kernel documentation index]<br />
* [http://www.kernel.org/doc/man-pages/ Linux Kernel man pages]<br />
* [http://kernelnewbies.org/ Kernel Newbies Site - Excellent source of information for people new to kernel]<br />
* [http://git.kernel.org/?p=linux/kernel/git/torvalds/linux-2.6.git;a=summary Linus' kernel tree for 2.6]<br />
* [https://bugzilla.kernel.org/ Kernel bugzilla] - [https://bugzilla.kernel.org/show_bug.cgi?id=15790 Regressions for each of recent versions]<br />
* [http://www.fsfla.org/svnwiki/selibre/linux-libre/ Linux-libre project - Maintains and distributes fully free kernel]<br />
* [http://lingrok.org/ LinGrok, Linux kernel source code cross-reference]<br />
* [http://lxr.free-electrons.com/source/?a=arm Free Electrons LXR (Linux Cross Reference)]<br />
* [http://lists.infradead.org/pipermail/linux-arm-kernel/ linux-arm-kernel - Mailing list archive]<br />
===How to upstream===<br />
* [http://www.elinux.org/images/a/ad/Arm-soc-checklist.pdf Your new ARM SoC Linux support check-list! by Thomas Petazzoni of Free Electrons]<br />
*[http://www.cnx-software.com/2014/03/04/linux-kernel-upstreaming-how-to-linaro-connect-asia-2014/ Linux Kernel Upstreaming How-To (CNXSoft - Embedded Software Development)]<br />
**[http://www.youtube.com/watch?v=dY7fikYZ42c Matt Porter's YouTube video talk on “Upstreaming 101" (LCA14-111)]<br />
***[http://www.linaro.org/documents/download/65f888c674508efcf9bd5d90398a186a530d01c4c78db Matt Porter's presentation slides for “Upstreaming 101" (LCA14-111)]<br />
**[https://www.youtube.com/watch?v=FiQ5uV_Mm5c Matt Porter's YouTube video talk on “Upstreaming 201" (LCA14-112)]<br />
***[http://www.linaro.org/documents/download/7b9920fcc89589bad9063d87d9137f08530d020b71924 Matt Porter's presentation slides for “Upstreaming 201" (LCA14-112)]<br />
*[http://www.cnx-software.com/2011/08/19/how-to-write-and-submit-a-linux-kernel-patch/ How to Write and Submit a Linux Kernel Patch (CNXSoft - Embedded Software Development)]<br />
** [http://www.youtube.com/watch?v=LLBrBBImJt4 YouTube Video- Write and Submit your first Linux kernel Patch]<br />
** [http://www.cnx-software.com/pdf/kernel-tutorial/kernel_patch_tutorial.pdf Greg Kroah-Hartman Kernel Tutorial Write and Submit your first Linux Kernel Patch]<br />
*[http://www.linaro.org/connect-lca14/resources Linaro resources page from LCA (Linaro Connect Asia) 2014]<br />
<br />
[[Category:Programming]]</div>Rockerhttps://linux-sunxi.org/index.php?title=Mainline_Kernel_Howto&diff=7154Mainline Kernel Howto2014-03-04T16:20:05Z<p>Rocker: /* See also */</p>
<hr />
<div>This articles describes how you can compile and use the Linux mainline kernel. For work done and to do read [[Linux mainlining effort]] please.<br />
<br />
== Warning ==<br />
<br />
The sunxi kernel mainlining effort is a massive task, and using upstream code today is very much a developer only undertaking. The upstream code does not support NAND, MMC or SATA, you can only boot off a USB harddisk. Similarly, it lacks sound, display, 3D, 2D and media support. If you simply want a more-or-less usable device now, then use [[Linux_Kernel|our own 3.4 branch]].<br />
<br />
For a detailed status of supported subsystems, please refer to the [[Linux mainlining effort]] page.<br />
<br />
== Prerequisites ==<br />
<br />
* An initramfs image (for example generated using buildroot)<br />
* An ARM [[Toolchain|toolchain]]<br />
* U-boot supporting device tree (if unsure, use a fresh build from the sunxi branch of u-boot-sunxi)<br />
<br />
== Supported boards ==<br />
<br />
As of 3.12, the boards and SoC supported are:<br />
* A10<br />
:* Cubieboard<br />
:* Melee A1000<br />
:* Mini X-plus<br />
:* Hackberry<br />
* A10s<br />
:* A10s-olinuxino<br />
* A13<br />
:* A13-olinuxino<br />
* A20<br />
:* A20-olinuxino<br />
:* Cubieboard2<br />
* A31<br />
:* A31 EVK<br />
<br />
For boards using these SoCs, adding a new device tree should be trivial.<br />
<br />
== Downloading the kernel source code ==<br />
=== Stable releases ===<br />
<br />
The stable releases are released by Linus Torvalds. Since Linux 3.8, the Allwinner support is added gradually. It is still quite sparse, but we are making good progress. This is probably what you should choose if you are looking for stability.<br />
<br />
git clone git://git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux.git<br />
<br />
=== Patches merged in the next stable release ===<br />
<br />
There is also a sunxi-next branch maintained with all the inclusions that have been accepted, merged and will included in the next stable release. If you want to do some development, it's probably the best pick.<br />
<br />
git clone [http://github.com/mripard/linux/tree/sunxi-next git://github.com/mripard/linux.git] -b sunxi-next<br />
<br />
=== Patches not yet merged in the next release ===<br />
<br />
You can find a sunxi-devel branch on linux-sunxi. This branch contains functional patches that are currently being reviewed on the kernel lists. If you want to do bleeding-edge mainline testing, this should probably be your pick. Please do not use this branch for development, as it is frequently rebased and the code is likely to change.<br />
<br />
git clone [http://github.com/linux-sunxi/linux-sunxi/tree/sunxi-devel git://github.com/linux-sunxi/linux-sunxi.git] -b sunxi-devel<br />
<br />
== Configuration ==<br />
<br />
ARCH=arm make sunxi_defconfig<br />
ARCH=arm make menuconfig<br />
<br />
Once there, fill the option '''General Setup / Initramfs source file(s)''' with a path to your initramfs image.<br />
<br />
== Compilation ==<br />
<br />
ARCH=arm CROSS_COMPILE=<toolchain-prefix> LOADADDR=0x40008000 make uImage dtbs<br />
<br />
After the compilation ended, you should have generated both the uImage in arch/arm/boot, and a device tree blob in arch/arm/boot/dts.<br />
<br />
This device tree blob (or simply dtb) gives to the kernel the description of the hardware it's currently running on. In its goal, it's pretty similar to the FEX scripts that Allwinner uses, yet far more generic. It allows to compile a single kernel image that will run on several platforms.<br />
<br />
Identify the dtb file for you board in arch/arm/boot/dts. You will need it in the next step.<br />
<br />
== Kernel Loading ==<br />
<br />
Now copy the relevant dtb and uImage somewhere that you can load it from on your board, like a tftp server, a SD Card, etc.<br />
<br />
Once you get to the U-boot prompt, stop the autoboot, and load the kernel image and device tree into memory making sure the will not overlap.<br />
<br />
Depending on where you store it, you will have something like<br />
fatload mmc 0 0x46000000 uImage<br />
fatload mmc 0 0x49000000 <board>.dtb<br />
<br />
'''Warning''': Before giving control to the kernel the U-Boot will move the loaded binaries to some different addresses and ignore the fact, the kernel needs much more space for extracting itselt. This causes a dtb to be overwritten and failure to boot. This of course should be fixed in U-Boot but a workaround for now is to set fdt_high:<br />
env set fdt_high ffffffff<br />
Once it's loaded into memory, you only need to tell U-Boot to boot the kernel using<br />
bootm 0x<kernel-address> 0x<initramfs-address> 0x<dtb-address><br />
if initramfs is built into the uImage, you just use "-" as a placeholder for its address. Taking all this into account your bootm might look like<br />
bootm 0x46000000 - 0x49000000<br />
<br />
The kernel should start booting up to a shell.<br />
<br />
Have fun.<br />
<br />
=See also=<br />
* [[Linux mainlining effort]]<br />
* [[Linux-tree-diff]] - list of kernel files modified or added ('+' sign) for allwinner SOCs.<br />
* [[Possible setups for hacking on mainline]]<br />
* [[Notes on Linux Kernel configuration]]<br />
* [[Linux Kernel]]<br />
**[[Toolchain]]<br />
<br />
=External Links=<br />
* [http://www.elinux.org/images/a/ad/Arm-soc-checklist.pdf Your new ARM SoC Linux support check-list! by Thomas Petazzoni of Free Electrons]<br />
*[http://www.cnx-software.com/2014/03/04/linux-kernel-upstreaming-how-to-linaro-connect-asia-2014/ Linux Kernel Upstreaming How-To (CNXSoft - Embedded Software Development)]<br />
**[http://www.youtube.com/watch?v=dY7fikYZ42c Matt Porter's YouTube video talk on “Upstreaming 101" (LCA14-111)]<br />
***[http://www.linaro.org/documents/download/65f888c674508efcf9bd5d90398a186a530d01c4c78db Matt Porter's presentation slides for “Upstreaming 101" (LCA14-111)]<br />
**[https://www.youtube.com/watch?v=FiQ5uV_Mm5c Matt Porter's YouTube video talk on “Upstreaming 201" (LCA14-112)]<br />
***[http://www.linaro.org/documents/download/7b9920fcc89589bad9063d87d9137f08530d020b71924 Matt Porter's presentation slides for “Upstreaming 201" (LCA14-112)]<br />
*[http://www.cnx-software.com/2011/08/19/how-to-write-and-submit-a-linux-kernel-patch/ How to Write and Submit a Linux Kernel Patch (CNXSoft - Embedded Software Development)]<br />
** [http://www.youtube.com/watch?v=LLBrBBImJt4 YouTube Video- Write and Submit your first Linux kernel Patch]<br />
** [http://www.cnx-software.com/pdf/kernel-tutorial/kernel_patch_tutorial.pdf Greg Kroah-Hartman Kernel Tutorial Write and Submit your first Linux Kernel Patch]<br />
*[http://www.linaro.org/connect-lca14/resources Linaro resources page from LCA (Linaro Connect Asia) 2014]<br />
<br />
[[Category:Tutorial]]</div>Rockerhttps://linux-sunxi.org/index.php?title=Mainline_Kernel_Howto&diff=7153Mainline Kernel Howto2014-03-04T16:19:00Z<p>Rocker: /* External Links */</p>
<hr />
<div>This articles describes how you can compile and use the Linux mainline kernel. For work done and to do read [[Linux mainlining effort]] please.<br />
<br />
== Warning ==<br />
<br />
The sunxi kernel mainlining effort is a massive task, and using upstream code today is very much a developer only undertaking. The upstream code does not support NAND, MMC or SATA, you can only boot off a USB harddisk. Similarly, it lacks sound, display, 3D, 2D and media support. If you simply want a more-or-less usable device now, then use [[Linux_Kernel|our own 3.4 branch]].<br />
<br />
For a detailed status of supported subsystems, please refer to the [[Linux mainlining effort]] page.<br />
<br />
== Prerequisites ==<br />
<br />
* An initramfs image (for example generated using buildroot)<br />
* An ARM [[Toolchain|toolchain]]<br />
* U-boot supporting device tree (if unsure, use a fresh build from the sunxi branch of u-boot-sunxi)<br />
<br />
== Supported boards ==<br />
<br />
As of 3.12, the boards and SoC supported are:<br />
* A10<br />
:* Cubieboard<br />
:* Melee A1000<br />
:* Mini X-plus<br />
:* Hackberry<br />
* A10s<br />
:* A10s-olinuxino<br />
* A13<br />
:* A13-olinuxino<br />
* A20<br />
:* A20-olinuxino<br />
:* Cubieboard2<br />
* A31<br />
:* A31 EVK<br />
<br />
For boards using these SoCs, adding a new device tree should be trivial.<br />
<br />
== Downloading the kernel source code ==<br />
=== Stable releases ===<br />
<br />
The stable releases are released by Linus Torvalds. Since Linux 3.8, the Allwinner support is added gradually. It is still quite sparse, but we are making good progress. This is probably what you should choose if you are looking for stability.<br />
<br />
git clone git://git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux.git<br />
<br />
=== Patches merged in the next stable release ===<br />
<br />
There is also a sunxi-next branch maintained with all the inclusions that have been accepted, merged and will included in the next stable release. If you want to do some development, it's probably the best pick.<br />
<br />
git clone [http://github.com/mripard/linux/tree/sunxi-next git://github.com/mripard/linux.git] -b sunxi-next<br />
<br />
=== Patches not yet merged in the next release ===<br />
<br />
You can find a sunxi-devel branch on linux-sunxi. This branch contains functional patches that are currently being reviewed on the kernel lists. If you want to do bleeding-edge mainline testing, this should probably be your pick. Please do not use this branch for development, as it is frequently rebased and the code is likely to change.<br />
<br />
git clone [http://github.com/linux-sunxi/linux-sunxi/tree/sunxi-devel git://github.com/linux-sunxi/linux-sunxi.git] -b sunxi-devel<br />
<br />
== Configuration ==<br />
<br />
ARCH=arm make sunxi_defconfig<br />
ARCH=arm make menuconfig<br />
<br />
Once there, fill the option '''General Setup / Initramfs source file(s)''' with a path to your initramfs image.<br />
<br />
== Compilation ==<br />
<br />
ARCH=arm CROSS_COMPILE=<toolchain-prefix> LOADADDR=0x40008000 make uImage dtbs<br />
<br />
After the compilation ended, you should have generated both the uImage in arch/arm/boot, and a device tree blob in arch/arm/boot/dts.<br />
<br />
This device tree blob (or simply dtb) gives to the kernel the description of the hardware it's currently running on. In its goal, it's pretty similar to the FEX scripts that Allwinner uses, yet far more generic. It allows to compile a single kernel image that will run on several platforms.<br />
<br />
Identify the dtb file for you board in arch/arm/boot/dts. You will need it in the next step.<br />
<br />
== Kernel Loading ==<br />
<br />
Now copy the relevant dtb and uImage somewhere that you can load it from on your board, like a tftp server, a SD Card, etc.<br />
<br />
Once you get to the U-boot prompt, stop the autoboot, and load the kernel image and device tree into memory making sure the will not overlap.<br />
<br />
Depending on where you store it, you will have something like<br />
fatload mmc 0 0x46000000 uImage<br />
fatload mmc 0 0x49000000 <board>.dtb<br />
<br />
'''Warning''': Before giving control to the kernel the U-Boot will move the loaded binaries to some different addresses and ignore the fact, the kernel needs much more space for extracting itselt. This causes a dtb to be overwritten and failure to boot. This of course should be fixed in U-Boot but a workaround for now is to set fdt_high:<br />
env set fdt_high ffffffff<br />
Once it's loaded into memory, you only need to tell U-Boot to boot the kernel using<br />
bootm 0x<kernel-address> 0x<initramfs-address> 0x<dtb-address><br />
if initramfs is built into the uImage, you just use "-" as a placeholder for its address. Taking all this into account your bootm might look like<br />
bootm 0x46000000 - 0x49000000<br />
<br />
The kernel should start booting up to a shell.<br />
<br />
Have fun.<br />
<br />
=See also=<br />
* [[Linux mainlining effort]]<br />
* [[Possible setups for hacking on mainline]]<br />
* [[Notes on Linux Kernel configuration]]<br />
* [[Linux Kernel]]<br />
**[[Toolchain]]<br />
<br />
=External Links=<br />
* [http://www.elinux.org/images/a/ad/Arm-soc-checklist.pdf Your new ARM SoC Linux support check-list! by Thomas Petazzoni of Free Electrons]<br />
*[http://www.cnx-software.com/2014/03/04/linux-kernel-upstreaming-how-to-linaro-connect-asia-2014/ Linux Kernel Upstreaming How-To (CNXSoft - Embedded Software Development)]<br />
**[http://www.youtube.com/watch?v=dY7fikYZ42c Matt Porter's YouTube video talk on “Upstreaming 101" (LCA14-111)]<br />
***[http://www.linaro.org/documents/download/65f888c674508efcf9bd5d90398a186a530d01c4c78db Matt Porter's presentation slides for “Upstreaming 101" (LCA14-111)]<br />
**[https://www.youtube.com/watch?v=FiQ5uV_Mm5c Matt Porter's YouTube video talk on “Upstreaming 201" (LCA14-112)]<br />
***[http://www.linaro.org/documents/download/7b9920fcc89589bad9063d87d9137f08530d020b71924 Matt Porter's presentation slides for “Upstreaming 201" (LCA14-112)]<br />
*[http://www.cnx-software.com/2011/08/19/how-to-write-and-submit-a-linux-kernel-patch/ How to Write and Submit a Linux Kernel Patch (CNXSoft - Embedded Software Development)]<br />
** [http://www.youtube.com/watch?v=LLBrBBImJt4 YouTube Video- Write and Submit your first Linux kernel Patch]<br />
** [http://www.cnx-software.com/pdf/kernel-tutorial/kernel_patch_tutorial.pdf Greg Kroah-Hartman Kernel Tutorial Write and Submit your first Linux Kernel Patch]<br />
*[http://www.linaro.org/connect-lca14/resources Linaro resources page from LCA (Linaro Connect Asia) 2014]<br />
<br />
[[Category:Tutorial]]</div>Rockerhttps://linux-sunxi.org/index.php?title=Linux_mainlining_effort&diff=7152Linux mainlining effort2014-03-04T16:18:54Z<p>Rocker: /* External Links */</p>
<hr />
<div>The purpose of this page is to try and define sub-goals and milestones for the mainlining effort, containing goals and sub-goals with milestones for adding Allwinner support in the upstream mainline Linux Kernel.<br />
<br />
It is very important to note that this is intended as a rough set of minimal goals - it is not meant to collide with the huge effort of rewriting major drivers!<br />
<br />
=Overview=<br />
The idea is to submit the code needed to run the Linux kernel on Allwinner SoCs upstream, ie. to the official Linux kernel. Check out [[Linux-tree-diff]] for a rough idea of the differences.<br />
<br />
This can be achieved by following the concept outlined in the ''Your new ARM SoC Linux support check-list!'' article published by Thomas Petazzoni from Free Electrons.<ref>http://www.elinux.org/images/a/ad/Arm-soc-checklist.pdf</ref><ref>[http://www.cnx-software.com/2013/01/16/your-new-arm-soc-linux-support-check-list-elce-2012/ Your New ARM SoC Linux Support Check-List – ELCE 2012]</ref><br />
<br />
Where relevant, I have attempted to include who is currently working on an item, mostly separate from any particular mainlining goal.<br />
<br />
=Status=<br />
<br />
== Merged into 3.8 ==<br />
* Initial support for Allwinner SoCs [https://git.kernel.org/cgit/linux/kernel/git/torvalds/linux.git/commit/?id=3b52634f0b7adaaf2b29569025287b938b7c71a6 (commit)]<br />
* Timer [https://git.kernel.org/cgit/linux/kernel/git/torvalds/linux.git/commit/?id=b2ac5d7549710173ea0217bf8c7b3f71da5220d4 (commit)]<br />
* UART<br />
* Device Tree<br />
* Interrupt controller [https://git.kernel.org/cgit/linux/kernel/git/torvalds/linux.git/commit/?id=afd24e146826cec0f46929263a0c874406a19cd8 (commit)]<br />
<br />
Related merges: [https://git.kernel.org/?p=linux/kernel/git/arm/arm-soc.git;a=commit;h=5ffd785402c295328d3866d9f8630152f51d332a], [https://git.kernel.org/?p=linux/kernel/git/arm/arm-soc.git;a=commit;h=e9f6d13513ea9fd33b0184db8fc33cf51baa584b]<br />
<br />
Added board support: [[Cubieboard]], [[A13-OLinuXino]]<br />
<br />
== Merged into 3.9 ==<br />
* PINCTRL driver<br />
* GPIO-lib based driver<br />
<br />
Related merges: [https://git.kernel.org/cgit/linux/kernel/git/torvalds/linux.git/commit/drivers/pinctrl?id=8a3a11f91def34424b1995cb54ccd658efde8568]<br />
<br />
Added Board Support: [[Hackberry]]<br />
<br />
== Merged into 3.10 ==<br />
* LED support<br />
* Clock driver<br />
* Complete UART support<br />
<br />
Related merges: [https://git.kernel.org/cgit/linux/kernel/git/torvalds/linux.git/commit/?id=000a74f41e601bc4e36a760aa42f219a019c5391], [https://git.kernel.org/cgit/linux/kernel/git/torvalds/linux.git/commit/?id=362ed48dee509abe24cf84b7e137c7a29a8f4d2d], [https://git.kernel.org/cgit/linux/kernel/git/torvalds/linux.git/commit/?id=dfab34aa61a0f8c14a67d7b4c1dae28e57ba592d]<br />
<br />
Added Board Support: [[Mini X-Plus]]<br />
<br />
== Merged into 3.11 ==<br />
* IRQ support for the PIO<br />
* I2C Driver<br />
* EMAC Driver<br />
* A10s support<br />
<br />
Related merges: [https://git.kernel.org/cgit/linux/kernel/git/torvalds/linux.git/commit/?id=ee1a8d402e7e204d57fb108aa40003b6d1633036], [https://git.kernel.org/cgit/linux/kernel/git/torvalds/linux.git/commit/?id=3883cbb6c1bda013a3ce2dbdab7dc97c52e4a232], [https://git.kernel.org/cgit/linux/kernel/git/torvalds/linux.git/commit/?id=d2033f2c1d1de2239ded15e478ddb4028f192a15], [https://git.kernel.org/cgit/linux/kernel/git/torvalds/linux.git/commit/?id=3dbde57ad941c55345fd7fac0ee3f70f204b02d8], [https://git.kernel.org/cgit/linux/kernel/git/torvalds/linux.git/commit/?id=98f486f18d16e2214728d101ed8b6a12dce75539], [https://git.kernel.org/cgit/linux/kernel/git/torvalds/linux.git/commit/?id=496322bc91e35007ed754184dcd447a02b6dd685]<br />
<br />
Added board support: [[A10S-OLinuXino]]<br />
<br />
== Merged into 3.12 ==<br />
* A31 support<br />
:* Basic SoC + GPIO<br />
:* Clock support<br />
* A20 support<br />
:* Basic SoC + GPIO<br />
:* Clock support<br />
* A10s clocks<br />
* Clock Source and Clock Event rework<br />
* Mele A1000 device tree<br />
* Watchdog driver<br />
<br />
Related merges: [https://git.kernel.org/cgit/linux/kernel/git/torvalds/linux.git/commit/?id=aa7054f5a5a9ff728ce291cb103afa19f4f849eb], [https://git.kernel.org/cgit/linux/kernel/git/torvalds/linux.git/commit/?id=b4b50fd78b1e31989940dfc647e64453d0f7176a], [https://git.kernel.org/cgit/linux/kernel/git/torvalds/linux.git/commit/?id=dccfd1e439c11422d7aca0d834b0430d24650e85], [https://git.kernel.org/cgit/linux/kernel/git/torvalds/linux.git/commit/?id=ac3c1c4f1c77190408162aee559c655090597072], [https://git.kernel.org/cgit/linux/kernel/git/torvalds/linux.git/commit/?id=bef4a0ab984662d4ccd68d431a7c4ef3daebcb43], [https://git.kernel.org/cgit/linux/kernel/git/torvalds/linux.git/commit/?id=24ba40588fe50adce2a99e026fc0026872ebeb85]<br />
<br />
Added board support: [[A31 EVB]], [[A20-OLinuXino]], [[Cubieboard2]], [[Mele A1000]]<br />
<br />
== Merged into 3.13 ==<br />
* SID Driver<br />
* I2C for A20<br />
* sunxi_defconfig<br />
* Bug fixes [http://www.spinics.net/lists/arm-kernel/msg290495.html]<br />
<br />
Added board support: [[Cubietruck]]<br />
<br />
== Merged into 3.14 ==<br />
* A31<br />
:* Reset Controller Support<br />
:* SMP<br />
<br />
* A20<br />
:* SMP (via PSCI)<br />
:* External clock outputs<br />
<br />
* High Speed Timers<br />
* RTC driver<br />
* RTP (DT only)<br />
* GMAC support in stmmac driver<br />
* AP6210 WiFi (BCM43362) support in brcmfmac driver<br />
<br />
Related merges: [https://git.kernel.org/cgit/linux/kernel/git/torvalds/linux.git/commit/?id=dfd10e7ae60c6c1b24b5d601744b4fd1ecab2f31], [https://git.kernel.org/cgit/linux/kernel/git/torvalds/linux.git/commit/?id=9b6d351a75dae25430383b29a3764ae7921f6c47], [https://git.kernel.org/cgit/linux/kernel/git/torvalds/linux.git/commit/?id=0ba3307a8ec35252f7b1e222e32889a6f3d9ceb3], [https://git.kernel.org/cgit/linux/kernel/git/torvalds/linux.git/commit/?id=7e21774db5cc9cf8fe93a64a2f0c6cf47db8ab24], [https://git.kernel.org/cgit/linux/kernel/git/torvalds/linux.git/commit/?id=4ba9920e5e9c0e16b5ed24292d45322907bb9035]<br />
<br />
Added board support: [[A13-OLinuXino-Micro]]<br />
<br />
== Planned for 3.15 ==<br />
* A20<br />
:* GMAC<br />
<br />
* A31<br />
:* I2C<br />
:* SPI<br />
:* DMAengine<br />
:* GMAC (?)<br />
<br />
* RTP<br />
* OHCI<br />
* EHCI<br />
* AHCI (SATA) [http://www.spinics.net/lists/arm-kernel/msg310026.html]<br />
* SPI<br />
<br />
== Work In Progress ==<br />
=== Core Stuff ===<br />
<br />
=== Major drivers ===<br />
* DMAengine driver (WiP: Maxime Ripard (mripard) on the [[A31]])<br />
:* DMAengine driver handles slave dma clients including SPI, EMAC, USB, I2S, HDMI audio, and NAND<br />
:* Implementing slave SG transfers is the priority (for SPI to start), with cyclic transfers (for audio clients) following that<br />
:* Currently in [[A23]] SDK there AW driver for DMAEngine , it should be adapted to device tree, cleaned for mainline<br />
:* The [[A23]] shares the DMA controller with the [[A31]], only the number of channels differ (the [[A31]] has 16 channels, while the [[A23]] only has 8 of them)<br />
:* The [[A20]] and earlier SoCs have two mode of operations: Normal and Dedicated. The dedicated mode looks a lot like how the [[A31]] DMA controller works, only it supports only mem2dev transfers<br />
* SDIO Driver (WiP: Hans De Goede, David Lanzendörfer)<br />
* SATA Driver (WiP: Oliver Schinagl (oliv3r), Hans de Goede (hansg))<br />
* [[AXP209]] driver (WiP: Carlo Caione (ccaione))<br />
* NMI controller: (WiP: Carlo Caione (ccaione))<br />
* NAND Driver (WiP: Boris Brezillon (bbrezillon))<br />
<br />
=== Minor drivers ===<br />
* PWM Driver (WiP: Oliver Schinagl (oliv3r))<br />
* IR driver (WiP: Alexsey Shestacov (wingrime))<br />
* Touchpanel driver (WiP: Hans de Goede (hansg))<br />
* <strike>IIO LRADC driver (WiP: Carlo Caione (n01))</strike> Input LRADC driver (WiP: Hans de Goede (hansg))<br />
* USB OTG Driver (WiP CHen-Yu Tsai (wens))<br />
:* It seems to actually be a Mentor Graphics Inventra USB Controller (musb), that already support for it in mainline kernel, so it only needs a thin layer to adapt it to sunxi. Moreover, it's already supporting the PIO mode, so we could avoid relying on DMA to merge it. (Thanks to Arnd Bergmann for noticing)<br />
:* irc user jukivili works on getting this driver to work with sunxi-3.4<br />
:* Status 2013-10-02:<br />
::* OTG requires more work. Mode detection is working, but have not yet figured out how to reset MUSB core and hardware from host-mode to peripheral and other way around.<br />
::* Mode detection/USB-PHY stuff probably needs to be moved to new USB-PHY driver as is done with other MUSB hardware drivers.<br />
* Transport Stream (WiP: woprr)<br />
* Security System (Crypto Engine) (WiP: Corentin Labbe (Montjoie))<br />
:* Hardware Pseudo Random Number Generator<br />
:* Checksumming (MD5, SHA1)<br />
:* Crypto (AES, DES, 3DES)<br />
* CAN (WiP: Peter Chen [https://groups.google.com/forum/#!searchin/linux-sunxi/CAN/linux-sunxi/Wrj1uYO1xVo/rq_HYUW7PaIJ] [https://github.com/ryangithub/sunxi-can-driver])<br />
<br />
== Left to be done ==<br />
=== Achievable ===<br />
* Audio<br />
: A23 SDK has aSoC drivers for the first three:<br />
:* Audio Codec<br />
:* IIS/I<sup>2</sup>S (Audio transport)<br />
:* SPDIF (Audio transport)<br />
:* AC97 Interface<br />
:* We first need to support cyclic DMA transfers <br />
* CSI (Camera Input)<br />
* PS/2 (Keyboard/Mouse)<br />
* Smart Card Reader<br />
* Keypad<br />
* One wire<br />
:* A23(A31?) or higher SoCs<br />
<br />
=== Hard ===<br />
* Display<br />
:* TCON (LCD)<br />
:* HDMI<br />
:* TV Encoder (Analog output, VGA, Composite, SVHS)<br />
:* Display engine FE/BE<br />
:* Mixer<br />
* VPU (See [[Reverse Engineering]])<br />
:* Video Engine (See [[Reverse Engineering]])<br />
:* Audio Engine (See [[Reverse Engineering]])<br />
:* Audio Video Sync<br />
<br />
=== Troublesome ===<br />
* Memory Stick (has anybody actually got this hardware connected and a memory stick?)<br />
* TV Decoder (Analog in, no driver, no datasheet)<br />
* PATA (Old tech, while still interesting for Compact Flash, possibly removed from A20, though A20 memory map still mentions it)<br />
* GPS backend IP (Only [[A10]], not much interesting, as all modern GPS recivers have MCU with UART output, no documentation)<br />
<br />
=== Needing major rework ===<br />
<br />
These drivers need major rework AND lack documentation other than existing source pile.<br />
<br />
* Display driver (libv, techn also might be interested)<br />
<br />
=== Unlikely ===<br />
<br />
These are too far off the track third party drivers making it unlikely they will ever get accepted mainline.<br />
<br />
* Mali driver (will not happen unless libv gets a proper lima driver out)<br />
<br />
=== Related but separate ===<br />
* Device-specific drivers<br />
<br />
=References=<br />
<references /><br />
<br />
= See also =<br />
[[Linux-tree-diff]] - list of kernel files modified or added ('+' sign) for allwinner SOCs.<br />
<br />
[[Mainline Kernel Howto]]<br />
<br />
=External Links=<br />
* [http://www.kernel.org kernel.org] - Official website for the Linux Kernel<br />
** [http://github.com/torvalds/linux http://github.com/torvalds/linux] - Linus Torvalds' GitHub account with the upstream Linux kernel<br />
* [http://www.kernel.org/doc/ Linux Kernel documentation index]<br />
* [http://www.kernel.org/doc/man-pages/ Linux Kernel man pages]<br />
* [http://kernelnewbies.org/ Kernel Newbies Site - Excellent source of information for people new to kernel]<br />
* [http://git.kernel.org/?p=linux/kernel/git/torvalds/linux-2.6.git;a=summary Linus' kernel tree for 2.6]<br />
* [https://bugzilla.kernel.org/ Kernel bugzilla] - [https://bugzilla.kernel.org/show_bug.cgi?id=15790 Regressions for each of recent versions]<br />
* [http://www.fsfla.org/svnwiki/selibre/linux-libre/ Linux-libre project - Maintains and distributes fully free kernel]<br />
* [http://lingrok.org/ LinGrok, Linux kernel source code cross-reference]<br />
* [http://lxr.free-electrons.com/source/?a=arm Free Electrons LXR (Linux Cross Reference)]<br />
* [http://lists.infradead.org/pipermail/linux-arm-kernel/ linux-arm-kernel - Mailing list archive]<br />
===How to upstream===<br />
* [http://www.elinux.org/images/a/ad/Arm-soc-checklist.pdf Your new ARM SoC Linux support check-list! by Thomas Petazzoni of Free Electrons]<br />
*[http://www.cnx-software.com/2014/03/04/linux-kernel-upstreaming-how-to-linaro-connect-asia-2014/ Linux Kernel Upstreaming How-To (CNXSoft - Embedded Software Development)]<br />
**[http://www.youtube.com/watch?v=dY7fikYZ42c Matt Porter's YouTube video talk on “Upstreaming 101" (LCA14-111)]<br />
***[http://www.linaro.org/documents/download/65f888c674508efcf9bd5d90398a186a530d01c4c78db Matt Porter's presentation slides for “Upstreaming 101" (LCA14-111)]<br />
**[https://www.youtube.com/watch?v=FiQ5uV_Mm5c Matt Porter's YouTube video talk on “Upstreaming 201" (LCA14-112)]<br />
***[http://www.linaro.org/documents/download/7b9920fcc89589bad9063d87d9137f08530d020b71924 Matt Porter's presentation slides for “Upstreaming 201" (LCA14-112)]<br />
*[http://www.cnx-software.com/2011/08/19/how-to-write-and-submit-a-linux-kernel-patch/ How to Write and Submit a Linux Kernel Patch (CNXSoft - Embedded Software Development)]<br />
** [http://www.youtube.com/watch?v=LLBrBBImJt4 YouTube Video- Write and Submit your first Linux kernel Patch]<br />
** [http://www.cnx-software.com/pdf/kernel-tutorial/kernel_patch_tutorial.pdf Greg Kroah-Hartman Kernel Tutorial Write and Submit your first Linux Kernel Patch]<br />
*[http://www.linaro.org/connect-lca14/resources Linaro resources page from LCA (Linaro Connect Asia) 2014]<br />
<br />
[[Category:Programming]]</div>Rockerhttps://linux-sunxi.org/index.php?title=Mainline_Kernel_Howto&diff=7151Mainline Kernel Howto2014-03-04T16:16:21Z<p>Rocker: /* See also */</p>
<hr />
<div>This articles describes how you can compile and use the Linux mainline kernel. For work done and to do read [[Linux mainlining effort]] please.<br />
<br />
== Warning ==<br />
<br />
The sunxi kernel mainlining effort is a massive task, and using upstream code today is very much a developer only undertaking. The upstream code does not support NAND, MMC or SATA, you can only boot off a USB harddisk. Similarly, it lacks sound, display, 3D, 2D and media support. If you simply want a more-or-less usable device now, then use [[Linux_Kernel|our own 3.4 branch]].<br />
<br />
For a detailed status of supported subsystems, please refer to the [[Linux mainlining effort]] page.<br />
<br />
== Prerequisites ==<br />
<br />
* An initramfs image (for example generated using buildroot)<br />
* An ARM [[Toolchain|toolchain]]<br />
* U-boot supporting device tree (if unsure, use a fresh build from the sunxi branch of u-boot-sunxi)<br />
<br />
== Supported boards ==<br />
<br />
As of 3.12, the boards and SoC supported are:<br />
* A10<br />
:* Cubieboard<br />
:* Melee A1000<br />
:* Mini X-plus<br />
:* Hackberry<br />
* A10s<br />
:* A10s-olinuxino<br />
* A13<br />
:* A13-olinuxino<br />
* A20<br />
:* A20-olinuxino<br />
:* Cubieboard2<br />
* A31<br />
:* A31 EVK<br />
<br />
For boards using these SoCs, adding a new device tree should be trivial.<br />
<br />
== Downloading the kernel source code ==<br />
=== Stable releases ===<br />
<br />
The stable releases are released by Linus Torvalds. Since Linux 3.8, the Allwinner support is added gradually. It is still quite sparse, but we are making good progress. This is probably what you should choose if you are looking for stability.<br />
<br />
git clone git://git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux.git<br />
<br />
=== Patches merged in the next stable release ===<br />
<br />
There is also a sunxi-next branch maintained with all the inclusions that have been accepted, merged and will included in the next stable release. If you want to do some development, it's probably the best pick.<br />
<br />
git clone [http://github.com/mripard/linux/tree/sunxi-next git://github.com/mripard/linux.git] -b sunxi-next<br />
<br />
=== Patches not yet merged in the next release ===<br />
<br />
You can find a sunxi-devel branch on linux-sunxi. This branch contains functional patches that are currently being reviewed on the kernel lists. If you want to do bleeding-edge mainline testing, this should probably be your pick. Please do not use this branch for development, as it is frequently rebased and the code is likely to change.<br />
<br />
git clone [http://github.com/linux-sunxi/linux-sunxi/tree/sunxi-devel git://github.com/linux-sunxi/linux-sunxi.git] -b sunxi-devel<br />
<br />
== Configuration ==<br />
<br />
ARCH=arm make sunxi_defconfig<br />
ARCH=arm make menuconfig<br />
<br />
Once there, fill the option '''General Setup / Initramfs source file(s)''' with a path to your initramfs image.<br />
<br />
== Compilation ==<br />
<br />
ARCH=arm CROSS_COMPILE=<toolchain-prefix> LOADADDR=0x40008000 make uImage dtbs<br />
<br />
After the compilation ended, you should have generated both the uImage in arch/arm/boot, and a device tree blob in arch/arm/boot/dts.<br />
<br />
This device tree blob (or simply dtb) gives to the kernel the description of the hardware it's currently running on. In its goal, it's pretty similar to the FEX scripts that Allwinner uses, yet far more generic. It allows to compile a single kernel image that will run on several platforms.<br />
<br />
Identify the dtb file for you board in arch/arm/boot/dts. You will need it in the next step.<br />
<br />
== Kernel Loading ==<br />
<br />
Now copy the relevant dtb and uImage somewhere that you can load it from on your board, like a tftp server, a SD Card, etc.<br />
<br />
Once you get to the U-boot prompt, stop the autoboot, and load the kernel image and device tree into memory making sure the will not overlap.<br />
<br />
Depending on where you store it, you will have something like<br />
fatload mmc 0 0x46000000 uImage<br />
fatload mmc 0 0x49000000 <board>.dtb<br />
<br />
'''Warning''': Before giving control to the kernel the U-Boot will move the loaded binaries to some different addresses and ignore the fact, the kernel needs much more space for extracting itselt. This causes a dtb to be overwritten and failure to boot. This of course should be fixed in U-Boot but a workaround for now is to set fdt_high:<br />
env set fdt_high ffffffff<br />
Once it's loaded into memory, you only need to tell U-Boot to boot the kernel using<br />
bootm 0x<kernel-address> 0x<initramfs-address> 0x<dtb-address><br />
if initramfs is built into the uImage, you just use "-" as a placeholder for its address. Taking all this into account your bootm might look like<br />
bootm 0x46000000 - 0x49000000<br />
<br />
The kernel should start booting up to a shell.<br />
<br />
Have fun.<br />
<br />
=See also=<br />
* [[Linux mainlining effort]]<br />
* [[Possible setups for hacking on mainline]]<br />
* [[Notes on Linux Kernel configuration]]<br />
* [[Linux Kernel]]<br />
**[[Toolchain]]<br />
<br />
=External Links=<br />
*[http://www.cnx-software.com/2014/03/04/linux-kernel-upstreaming-how-to-linaro-connect-asia-2014/ Linux Kernel Upstreaming How-To (CNXSoft - Embedded Software Development)]<br />
**[http://www.youtube.com/watch?v=dY7fikYZ42c Matt Porter's YouTube video talk on “Upstreaming 101" (LCA14-111)]<br />
***[http://www.linaro.org/documents/download/65f888c674508efcf9bd5d90398a186a530d01c4c78db Matt Porter's presentation slides for “Upstreaming 101" (LCA14-111)]<br />
**[https://www.youtube.com/watch?v=FiQ5uV_Mm5c Matt Porter's YouTube video talk on “Upstreaming 201" (LCA14-112)]<br />
***[http://www.linaro.org/documents/download/7b9920fcc89589bad9063d87d9137f08530d020b71924 Matt Porter's presentation slides for “Upstreaming 201" (LCA14-112)]<br />
*[http://www.cnx-software.com/2011/08/19/how-to-write-and-submit-a-linux-kernel-patch/ How to Write and Submit a Linux Kernel Patch (CNXSoft - Embedded Software Development)]<br />
** [http://www.youtube.com/watch?v=LLBrBBImJt4 YouTube Video- Write and Submit your first Linux kernel Patch]<br />
** [http://www.cnx-software.com/pdf/kernel-tutorial/kernel_patch_tutorial.pdf Greg Kroah-Hartman Kernel Tutorial Write and Submit your first Linux Kernel Patch]<br />
*[http://www.linaro.org/connect-lca14/resources Linaro resources page from LCA (Linaro Connect Asia) 2014]<br />
<br />
[[Category:Tutorial]]</div>Rockerhttps://linux-sunxi.org/index.php?title=Mainline_Kernel_Howto&diff=7150Mainline Kernel Howto2014-03-04T16:14:21Z<p>Rocker: /* See also */</p>
<hr />
<div>This articles describes how you can compile and use the Linux mainline kernel. For work done and to do read [[Linux mainlining effort]] please.<br />
<br />
== Warning ==<br />
<br />
The sunxi kernel mainlining effort is a massive task, and using upstream code today is very much a developer only undertaking. The upstream code does not support NAND, MMC or SATA, you can only boot off a USB harddisk. Similarly, it lacks sound, display, 3D, 2D and media support. If you simply want a more-or-less usable device now, then use [[Linux_Kernel|our own 3.4 branch]].<br />
<br />
For a detailed status of supported subsystems, please refer to the [[Linux mainlining effort]] page.<br />
<br />
== Prerequisites ==<br />
<br />
* An initramfs image (for example generated using buildroot)<br />
* An ARM [[Toolchain|toolchain]]<br />
* U-boot supporting device tree (if unsure, use a fresh build from the sunxi branch of u-boot-sunxi)<br />
<br />
== Supported boards ==<br />
<br />
As of 3.12, the boards and SoC supported are:<br />
* A10<br />
:* Cubieboard<br />
:* Melee A1000<br />
:* Mini X-plus<br />
:* Hackberry<br />
* A10s<br />
:* A10s-olinuxino<br />
* A13<br />
:* A13-olinuxino<br />
* A20<br />
:* A20-olinuxino<br />
:* Cubieboard2<br />
* A31<br />
:* A31 EVK<br />
<br />
For boards using these SoCs, adding a new device tree should be trivial.<br />
<br />
== Downloading the kernel source code ==<br />
=== Stable releases ===<br />
<br />
The stable releases are released by Linus Torvalds. Since Linux 3.8, the Allwinner support is added gradually. It is still quite sparse, but we are making good progress. This is probably what you should choose if you are looking for stability.<br />
<br />
git clone git://git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux.git<br />
<br />
=== Patches merged in the next stable release ===<br />
<br />
There is also a sunxi-next branch maintained with all the inclusions that have been accepted, merged and will included in the next stable release. If you want to do some development, it's probably the best pick.<br />
<br />
git clone [http://github.com/mripard/linux/tree/sunxi-next git://github.com/mripard/linux.git] -b sunxi-next<br />
<br />
=== Patches not yet merged in the next release ===<br />
<br />
You can find a sunxi-devel branch on linux-sunxi. This branch contains functional patches that are currently being reviewed on the kernel lists. If you want to do bleeding-edge mainline testing, this should probably be your pick. Please do not use this branch for development, as it is frequently rebased and the code is likely to change.<br />
<br />
git clone [http://github.com/linux-sunxi/linux-sunxi/tree/sunxi-devel git://github.com/linux-sunxi/linux-sunxi.git] -b sunxi-devel<br />
<br />
== Configuration ==<br />
<br />
ARCH=arm make sunxi_defconfig<br />
ARCH=arm make menuconfig<br />
<br />
Once there, fill the option '''General Setup / Initramfs source file(s)''' with a path to your initramfs image.<br />
<br />
== Compilation ==<br />
<br />
ARCH=arm CROSS_COMPILE=<toolchain-prefix> LOADADDR=0x40008000 make uImage dtbs<br />
<br />
After the compilation ended, you should have generated both the uImage in arch/arm/boot, and a device tree blob in arch/arm/boot/dts.<br />
<br />
This device tree blob (or simply dtb) gives to the kernel the description of the hardware it's currently running on. In its goal, it's pretty similar to the FEX scripts that Allwinner uses, yet far more generic. It allows to compile a single kernel image that will run on several platforms.<br />
<br />
Identify the dtb file for you board in arch/arm/boot/dts. You will need it in the next step.<br />
<br />
== Kernel Loading ==<br />
<br />
Now copy the relevant dtb and uImage somewhere that you can load it from on your board, like a tftp server, a SD Card, etc.<br />
<br />
Once you get to the U-boot prompt, stop the autoboot, and load the kernel image and device tree into memory making sure the will not overlap.<br />
<br />
Depending on where you store it, you will have something like<br />
fatload mmc 0 0x46000000 uImage<br />
fatload mmc 0 0x49000000 <board>.dtb<br />
<br />
'''Warning''': Before giving control to the kernel the U-Boot will move the loaded binaries to some different addresses and ignore the fact, the kernel needs much more space for extracting itselt. This causes a dtb to be overwritten and failure to boot. This of course should be fixed in U-Boot but a workaround for now is to set fdt_high:<br />
env set fdt_high ffffffff<br />
Once it's loaded into memory, you only need to tell U-Boot to boot the kernel using<br />
bootm 0x<kernel-address> 0x<initramfs-address> 0x<dtb-address><br />
if initramfs is built into the uImage, you just use "-" as a placeholder for its address. Taking all this into account your bootm might look like<br />
bootm 0x46000000 - 0x49000000<br />
<br />
The kernel should start booting up to a shell.<br />
<br />
Have fun.<br />
<br />
=See also=<br />
* [[Linux mainlining effort]]<br />
* [[Possible setups for hacking on mainline]]<br />
* [[Notes on Linux Kernel configuration]]<br />
<br />
=External Links=<br />
*[http://www.cnx-software.com/2014/03/04/linux-kernel-upstreaming-how-to-linaro-connect-asia-2014/ Linux Kernel Upstreaming How-To (CNXSoft - Embedded Software Development)]<br />
**[http://www.youtube.com/watch?v=dY7fikYZ42c Matt Porter's YouTube video talk on “Upstreaming 101" (LCA14-111)]<br />
***[http://www.linaro.org/documents/download/65f888c674508efcf9bd5d90398a186a530d01c4c78db Matt Porter's presentation slides for “Upstreaming 101" (LCA14-111)]<br />
**[https://www.youtube.com/watch?v=FiQ5uV_Mm5c Matt Porter's YouTube video talk on “Upstreaming 201" (LCA14-112)]<br />
***[http://www.linaro.org/documents/download/7b9920fcc89589bad9063d87d9137f08530d020b71924 Matt Porter's presentation slides for “Upstreaming 201" (LCA14-112)]<br />
*[http://www.cnx-software.com/2011/08/19/how-to-write-and-submit-a-linux-kernel-patch/ How to Write and Submit a Linux Kernel Patch (CNXSoft - Embedded Software Development)]<br />
** [http://www.youtube.com/watch?v=LLBrBBImJt4 YouTube Video- Write and Submit your first Linux kernel Patch]<br />
** [http://www.cnx-software.com/pdf/kernel-tutorial/kernel_patch_tutorial.pdf Greg Kroah-Hartman Kernel Tutorial Write and Submit your first Linux Kernel Patch]<br />
*[http://www.linaro.org/connect-lca14/resources Linaro resources page from LCA (Linaro Connect Asia) 2014]<br />
<br />
[[Category:Tutorial]]</div>Rockerhttps://linux-sunxi.org/index.php?title=Mainline_Kernel_Howto&diff=7149Mainline Kernel Howto2014-03-04T16:13:07Z<p>Rocker: /* See also */</p>
<hr />
<div>This articles describes how you can compile and use the Linux mainline kernel. For work done and to do read [[Linux mainlining effort]] please.<br />
<br />
== Warning ==<br />
<br />
The sunxi kernel mainlining effort is a massive task, and using upstream code today is very much a developer only undertaking. The upstream code does not support NAND, MMC or SATA, you can only boot off a USB harddisk. Similarly, it lacks sound, display, 3D, 2D and media support. If you simply want a more-or-less usable device now, then use [[Linux_Kernel|our own 3.4 branch]].<br />
<br />
For a detailed status of supported subsystems, please refer to the [[Linux mainlining effort]] page.<br />
<br />
== Prerequisites ==<br />
<br />
* An initramfs image (for example generated using buildroot)<br />
* An ARM [[Toolchain|toolchain]]<br />
* U-boot supporting device tree (if unsure, use a fresh build from the sunxi branch of u-boot-sunxi)<br />
<br />
== Supported boards ==<br />
<br />
As of 3.12, the boards and SoC supported are:<br />
* A10<br />
:* Cubieboard<br />
:* Melee A1000<br />
:* Mini X-plus<br />
:* Hackberry<br />
* A10s<br />
:* A10s-olinuxino<br />
* A13<br />
:* A13-olinuxino<br />
* A20<br />
:* A20-olinuxino<br />
:* Cubieboard2<br />
* A31<br />
:* A31 EVK<br />
<br />
For boards using these SoCs, adding a new device tree should be trivial.<br />
<br />
== Downloading the kernel source code ==<br />
=== Stable releases ===<br />
<br />
The stable releases are released by Linus Torvalds. Since Linux 3.8, the Allwinner support is added gradually. It is still quite sparse, but we are making good progress. This is probably what you should choose if you are looking for stability.<br />
<br />
git clone git://git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux.git<br />
<br />
=== Patches merged in the next stable release ===<br />
<br />
There is also a sunxi-next branch maintained with all the inclusions that have been accepted, merged and will included in the next stable release. If you want to do some development, it's probably the best pick.<br />
<br />
git clone [http://github.com/mripard/linux/tree/sunxi-next git://github.com/mripard/linux.git] -b sunxi-next<br />
<br />
=== Patches not yet merged in the next release ===<br />
<br />
You can find a sunxi-devel branch on linux-sunxi. This branch contains functional patches that are currently being reviewed on the kernel lists. If you want to do bleeding-edge mainline testing, this should probably be your pick. Please do not use this branch for development, as it is frequently rebased and the code is likely to change.<br />
<br />
git clone [http://github.com/linux-sunxi/linux-sunxi/tree/sunxi-devel git://github.com/linux-sunxi/linux-sunxi.git] -b sunxi-devel<br />
<br />
== Configuration ==<br />
<br />
ARCH=arm make sunxi_defconfig<br />
ARCH=arm make menuconfig<br />
<br />
Once there, fill the option '''General Setup / Initramfs source file(s)''' with a path to your initramfs image.<br />
<br />
== Compilation ==<br />
<br />
ARCH=arm CROSS_COMPILE=<toolchain-prefix> LOADADDR=0x40008000 make uImage dtbs<br />
<br />
After the compilation ended, you should have generated both the uImage in arch/arm/boot, and a device tree blob in arch/arm/boot/dts.<br />
<br />
This device tree blob (or simply dtb) gives to the kernel the description of the hardware it's currently running on. In its goal, it's pretty similar to the FEX scripts that Allwinner uses, yet far more generic. It allows to compile a single kernel image that will run on several platforms.<br />
<br />
Identify the dtb file for you board in arch/arm/boot/dts. You will need it in the next step.<br />
<br />
== Kernel Loading ==<br />
<br />
Now copy the relevant dtb and uImage somewhere that you can load it from on your board, like a tftp server, a SD Card, etc.<br />
<br />
Once you get to the U-boot prompt, stop the autoboot, and load the kernel image and device tree into memory making sure the will not overlap.<br />
<br />
Depending on where you store it, you will have something like<br />
fatload mmc 0 0x46000000 uImage<br />
fatload mmc 0 0x49000000 <board>.dtb<br />
<br />
'''Warning''': Before giving control to the kernel the U-Boot will move the loaded binaries to some different addresses and ignore the fact, the kernel needs much more space for extracting itselt. This causes a dtb to be overwritten and failure to boot. This of course should be fixed in U-Boot but a workaround for now is to set fdt_high:<br />
env set fdt_high ffffffff<br />
Once it's loaded into memory, you only need to tell U-Boot to boot the kernel using<br />
bootm 0x<kernel-address> 0x<initramfs-address> 0x<dtb-address><br />
if initramfs is built into the uImage, you just use "-" as a placeholder for its address. Taking all this into account your bootm might look like<br />
bootm 0x46000000 - 0x49000000<br />
<br />
The kernel should start booting up to a shell.<br />
<br />
Have fun.<br />
<br />
=See also=<br />
* [[Possible setups for hacking on mainline]]<br />
* [[Notes on Linux Kernel configuration]]<br />
<br />
=External Links=<br />
*[http://www.cnx-software.com/2014/03/04/linux-kernel-upstreaming-how-to-linaro-connect-asia-2014/ Linux Kernel Upstreaming How-To (CNXSoft - Embedded Software Development)]<br />
**[http://www.youtube.com/watch?v=dY7fikYZ42c Matt Porter's YouTube video talk on “Upstreaming 101" (LCA14-111)]<br />
***[http://www.linaro.org/documents/download/65f888c674508efcf9bd5d90398a186a530d01c4c78db Matt Porter's presentation slides for “Upstreaming 101" (LCA14-111)]<br />
**[https://www.youtube.com/watch?v=FiQ5uV_Mm5c Matt Porter's YouTube video talk on “Upstreaming 201" (LCA14-112)]<br />
***[http://www.linaro.org/documents/download/7b9920fcc89589bad9063d87d9137f08530d020b71924 Matt Porter's presentation slides for “Upstreaming 201" (LCA14-112)]<br />
*[http://www.cnx-software.com/2011/08/19/how-to-write-and-submit-a-linux-kernel-patch/ How to Write and Submit a Linux Kernel Patch (CNXSoft - Embedded Software Development)]<br />
** [http://www.youtube.com/watch?v=LLBrBBImJt4 YouTube Video- Write and Submit your first Linux kernel Patch]<br />
** [http://www.cnx-software.com/pdf/kernel-tutorial/kernel_patch_tutorial.pdf Greg Kroah-Hartman Kernel Tutorial Write and Submit your first Linux Kernel Patch]<br />
*[http://www.linaro.org/connect-lca14/resources Linaro resources page from LCA (Linaro Connect Asia) 2014]<br />
<br />
[[Category:Tutorial]]</div>Rockerhttps://linux-sunxi.org/index.php?title=User_talk:Rocker&diff=2532User talk:Rocker2013-02-22T14:05:12Z<p>Rocker: </p>
<hr />
<div>=WTF did User:Turl deleted my articles that are related to sunxi?=<br />
Why did [[User:Turl]] delete all these articles of mine without warning with the comment "''not relevant to sunxi''" when they are too related to sunxi?; specifically Allwinner [[A31]] (sun6i) SoC feature support for all these all these, which is sad that he can delete articles without having the knowledge about that fact. What is the point of contributing to a wiki where articles are deleted without warning? All other wiki's give a warning to explain then leave the article for several months actually deleting an article! I spent hours on writing and researching those articles! [[User:Rocker|Rocker]] ([[User talk:Rocker|talk]]) 09:56, 22 February 2013 (CET)<br />
<br />
http://linux-sunxi.org/Special:Log/delete<br />
* 17:06, 21 February 2013 Turl (Talk | contribs) deleted page [[Adobe Flash]] (not relevant to sunxi)<br />
* 16:58, 21 February 2013 Turl (Talk | contribs) deleted page [[SGX544]] (content was: "#redirect PowerVR SGX544" (and the only contributor was "Rocker"))<br />
* 16:55, 21 February 2013 Turl (Talk | contribs) deleted page [[OpenVG]] (not relevant to sunxi)<br />
* 16:53, 21 February 2013 Turl (Talk | contribs) deleted page [[OpenGL ES]] (not relevant to sunxi)<br />
* 16:52, 21 February 2013 Turl (Talk | contribs) deleted page [[OpenGL ES Shading Language]] (not relevant to sunxi)<br />
* 16:51, 21 February 2013 Turl (Talk | contribs) deleted page [[PowerVR SGX544]] (not relevant to sunxi)<br />
* 16:46, 21 February 2013 Turl (Talk | contribs) deleted page [[OpenCL]] (not relevant to sunxi)<br />
* 16:43, 21 February 2013 Turl (Talk | contribs) deleted page [[DirectX]] (not relevant to sunxi)<br />
<br />
<br />
:Hello Rocker,<br />
:is it possible for you to join #linux-sunxi on freenode? Better talking there.<br />
:Yesterday we talked about cleaning up the wiki and remove duplicated pages, that can be found on other pages on the web/wikipedia. There are many pages, that give info about possible features of sunxi, but are not that relevant atm. We agreed, that sunxi-wiki should not keep common infos about directx etc. Linking this sites and document the ''sunxi-specials'' of that feature (- if sunxi-related at all -)in this wiki should be enough!? Otherwise the wiki will blow up, which is not necessary.<br />
:Regards rellla -- [[User:Rellla|Rellla]] ([[User talk:Rellla|talk]]) 10:22, 22 February 2013 (CET)<br />
<br />
::Nope, can't be bothered with IRC to be honest. Can not see one reason for deleting articles like [[PowerVR SGX544]], etc., hours wasted for nothing. And since it now looks like Allwinner's official support for XBMC on sunxi and open source in general just seems like a lost cause in any case I think that I will just abandon all my interest in everything Allwinner anyway, I don't want to give them any more of my money or time so goning cut my loses and run. - Rocker out. [[User:Rocker|Rocker]] ([[User talk:Rocker|talk]]) 15:05, 22 February 2013 (CET)</div>Rockerhttps://linux-sunxi.org/index.php?title=User_talk:Rocker&diff=2519User talk:Rocker2013-02-22T08:59:32Z<p>Rocker: Created page with "=WTF did User:Turl deleted my articles that are related to sunxi?= Why did User:Turl delete all these articles of mine without warning with the comment "''not relevant to ..."</p>
<hr />
<div>=WTF did User:Turl deleted my articles that are related to sunxi?=<br />
Why did [[User:Turl]] delete all these articles of mine without warning with the comment "''not relevant to sunxi''" when they are too related to sunxi?; specifically Allwinner [[A31]] (sun6i) SoC feature support for all these all these, which is sad that he can delete articles without having the knowledge about that fact. What is the point of contributing to a wiki where articles are deleted without warning? All other wiki's give a warning to explain then leave the article for several months actually deleting an article! I spent hours on writing and researching those articles! [[User:Rocker|Rocker]] ([[User talk:Rocker|talk]]) 09:56, 22 February 2013 (CET)<br />
<br />
http://linux-sunxi.org/Special:Log/delete<br />
* 17:06, 21 February 2013 Turl (Talk | contribs) deleted page [[Adobe Flash]] (not relevant to sunxi)<br />
* 16:58, 21 February 2013 Turl (Talk | contribs) deleted page [[SGX544]] (content was: "#redirect PowerVR SGX544" (and the only contributor was "Rocker"))<br />
* 16:55, 21 February 2013 Turl (Talk | contribs) deleted page [[OpenVG]] (not relevant to sunxi)<br />
* 16:53, 21 February 2013 Turl (Talk | contribs) deleted page [[OpenGL ES]] (not relevant to sunxi)<br />
* 16:52, 21 February 2013 Turl (Talk | contribs) deleted page [[OpenGL ES Shading Language]] (not relevant to sunxi)<br />
* 16:51, 21 February 2013 Turl (Talk | contribs) deleted page [[PowerVR SGX544]] (not relevant to sunxi)<br />
* 16:46, 21 February 2013 Turl (Talk | contribs) deleted page [[OpenCL]] (not relevant to sunxi)<br />
* 16:43, 21 February 2013 Turl (Talk | contribs) deleted page [[DirectX]] (not relevant to sunxi)</div>Rockerhttps://linux-sunxi.org/index.php?title=User:Rellla/Debian&diff=2517User:Rellla/Debian2013-02-22T08:56:17Z<p>Rocker: </p>
<hr />
<div>* apt-get install cmake shtool swig autoconf autotool automake libtool default-jre gawk gperf zip<br />
* g++-4.6-arm-linux-gnueabihf<br />
* symlinks gcc -> gcc-4.6 etc...<br />
<br />
=Deleted pages that are related to sunxi=<br />
Hello Rellla! Why did [[User:Turl]] delete all these articles of mine without warning with the comment "''not relevant to sunxi''" when they are too related to sunxi?; specifically Allwinner [[A31]] (sun6i) SoC feature support for all these all these, which is sad that he can delete articles without having the knowledge about that fact. What is the point of contributing to a wiki where articles are deleted without warning? All other wiki's give a warning to explain then leave the article for several months actually deleting an article! [[User:Rocker|Rocker]] ([[User talk:Rocker|talk]]) 09:56, 22 February 2013 (CET)<br />
<br />
http://linux-sunxi.org/Special:Log/delete<br />
* 17:06, 21 February 2013 Turl (Talk | contribs) deleted page [[Adobe Flash]] (not relevant to sunxi)<br />
* 16:58, 21 February 2013 Turl (Talk | contribs) deleted page [[SGX544]] (content was: "#redirect PowerVR SGX544" (and the only contributor was "Rocker"))<br />
* 16:55, 21 February 2013 Turl (Talk | contribs) deleted page [[OpenVG]] (not relevant to sunxi)<br />
* 16:53, 21 February 2013 Turl (Talk | contribs) deleted page [[OpenGL ES]] (not relevant to sunxi)<br />
* 16:52, 21 February 2013 Turl (Talk | contribs) deleted page [[OpenGL ES Shading Language]] (not relevant to sunxi)<br />
* 16:51, 21 February 2013 Turl (Talk | contribs) deleted page [[PowerVR SGX544]] (not relevant to sunxi)<br />
* 16:46, 21 February 2013 Turl (Talk | contribs) deleted page [[OpenCL]] (not relevant to sunxi)<br />
* 16:43, 21 February 2013 Turl (Talk | contribs) deleted page [[DirectX]] (not relevant to sunxi)</div>Rockerhttps://linux-sunxi.org/index.php?title=LinkSprite_pcDuino&diff=2451LinkSprite pcDuino2013-02-20T16:44:09Z<p>Rocker: </p>
<hr />
<div>{{Languages|pcDuino}}<br />
<br />
{{Infobox Board<br />
| image = <br />
| manufacturer = pcDuino<br />
| dimensions = 12,5''cm'' x 5,2''cm''<br />
| release_date = <br />
| website = http://www.pcduino.com<br />
| soc = [[A10]] @ 1Ghz<br />
| dram = 1GB DDR3 @ 480MHz<br />
| nand = 2GB NAND Flash<br />
| video = HDMI<br />
| audio = HDMI<br />
| network = 10/100<br />
| storage = 2GB Flash + SD card slot for up to 32GB<br />
| usb = 2x USB 2.0 Host<br />
| other = <br />
| headers = Arduino Compatible Headers Expansion Ports<br />
}}<br />
<br />
pcDuino is a small (12,5x5,2cm), hacker friendly, low-cost while powerful ARM board with Allwinner [[A10]] SoC, with its major feature being that it has [http://en.wikipedia.org/wiki/Arduino Arduino] Compatible Headers as extendable ports.<ref>http://www.cnx-software.com/2013/02/20/59-pcduino-allwinner-a10-board-with-arduino-compatible-headers/ CNXSoft - $59 pcDuino – AllWinner A10 Board with Arduino Compatible Headers</ref><br />
<br />
=Overview=<br />
pcDuino is a new development board based on Allwinner A10 Cortex A8 SoC that comes with 1GB RAM and 2GB RAM, HDMI output, USB, as well as Ethernet RJ45 network interface ports, and is said to feature 2.54mm pin headers compatible with Arduino boards.<br />
<br />
The board comes preloaded with Ubuntu 12.10, but it also supports Android 4.0 (Ice Cream Sandwich) as operating-system. The “Arduino compatible header” allow you to connect any Arduino shield to pcDuino, and pcDuino developers have written C code to allow programming the I/O like an Arduino.<br />
<br />
The company provides Ubuntu and Android images, tools (liveSuite/Phoenix card), a user guide, and some hardware files for the board: mechanical drawings (PDF and DXF) and schematics (PDF). In their user manual, they compare pcDuino to the Raspberry Pi, but it’s actually much closer to the Cubieboard, albeit with less exposed I/O pins.<br />
<br />
The board is available now, and can be purchased for $59(US) retail price.<br />
<br />
=pcDuino specifications=<br />
* SoC – AllWinner A10 ARM Cortex A8 CPU @ 1GHz + Mali-400 GPU<br />
* System Memory – 1GB DRAM<br />
* Storage – 2GB Flash + SD card slot for up to 32GB<br />
* Video Output – HDMI<br />
* USB – 2x USB 2.0 Host<br />
* Connectivity:<br />
** Ethernet – 10/100 Mbps (RJ45)<br />
** Wi-Fi – Via USB Wi-Fi dongle (not included with the board)<br />
* Headers – 2.54mm pin headers: 1x UART, 6x ADCs, 2x PWMs up to 24MHz, 14x GPIOs, 1x I2C and 1x SPI.<br />
* Power Supply – 5V/2A<br />
* Dimensions – 125mm x 52mm<br />
<br />
= Community =<br />
* [http://www.pcduino.com/ pcduino.com - official homepage]<br />
<br />
=References=<br />
<references /><br />
<br />
== See also ==<br />
* [http://en.wikipedia.org/wiki/Arduino Arduino]<br />
* [[Cubieboard]]<br />
<br />
== External ==<br />
* [http://www.pcduino.com/ pcduino.com - official homepage]<br />
<br />
[[Category:pcDuino]]<br />
[[Category:A10 Boards]]<br />
[[Category:Devices with HDMI port]]<br />
[[Category:Devices with SATA port]]<br />
[[Category:Devices with Ethernet port]]<br />
[[Category:Devices]]<br />
[[Category:Hardware]]</div>Rocker