i.MX Processors Knowledge Base

cancel
Showing results for 
Show  only  | Search instead for 
Did you mean: 

i.MX Processors Knowledge Base

Discussions

Sort by:
In this post we see how to setup a Debian server, to allow booting the i.MX6 sabre sd platform (mostly) from the network. Booting from the network instead of e.g. the SD card is very handy for day to day development and testing, as it eliminates almost all physical interactions with the board and saves much time. Also, fortunately for us, both u-boot and Linux for i.MX6 support network booting out of the box. Boot sequence principles Before we setup the server, here are some more details on the boot sequence we will obtain in the end: i.MX6 boots, loads u-boot from SD card. u-boot starts, loads its environment (boot commands) from SD card. u-boot obtains its network address by DHCP, loads a Linux kernel uImage and a dtb by TFTP. Linux boots; obtains its network address by DHCP (again), mounts its root filesystem on NFS. Setting up DHCP and TFTP One can easily setup a Debian server to act as DHCP and TFTP server with Dnsmasq; just install the dnsmasq package. The default configuration is mostly empty; so we need to enhance it a bit. For the following we will assume that your Debian server has IP address 192.168.111.1 on the network where it sees the i.MX6 sabre sd platform. You can add some options to a dnsmasq config file such as e.g. /etc/dnsmasq.d/my-custom-config-file:   dhcp-range=192.168.111.50,192.168.111.150,12h   enable-tftp   tftp-root=/var/ftpd This informs dnsmasq to act as a DHCP server for addresses range 192.168.111.50-150 and act as TFTP server, which serves files under /var/ftpd. That means you will need to copy a Linux uImage and an imx6q-sabresd.dtb under /var/ftpd/. See this post for more details about compiling Linux to obtain those two files. Setting up NFS If we want the root filesystem to be mounted on the network we will need to export some folders with NFS from the Debian server. We need to install the nfs-kernel-server package and setup /etc/exports with a line such as:   /tftpboot       192.168.111.*(rw,no_root_squash,subtree_check) This allows clients on the 192.168.111.0 network to access filesystems under the /tftpboot folder. So you will need to create a /tftpboot folder on the server, and install some "filesystem" under there. For this example we assume you will have a busybox installed under a /tftpboot/busybox/ folder. That means we want to have under there all folders such as bin, dev, etc... See this post for details on how to compile busybox to populate this folder. Do not forget to restart the NFS server after configuration, with:   # /etc/init.d/nfs-kernel-server restart We are now setup on the server side. Setting up u-boot At the time of this writing we need to help u-boot a bit when booting the i.MX6 sabre sd platform from the network. Stop at u-boot prompt and configure a few things:   env default -a   setenv netargs $netargs rw   setenv serverip 192.168.111.1   setenv nfsroot /tftpboot/busybox   setenv bootcmd run netboot   saveenv Reset your board; it should now boot from the network:   U-Boot 2013.07-rc1-00210-gc623eb0 (Jun 27 2013 - 21:10:47)   (..)   Hit any key to stop autoboot:  0   Booting from net ...   BOOTP broadcast 1   DHCP client bound to address 192.168.111.121   Using FEC device   TFTP from server 192.168.111.1; our IP address is 192.168.111.121   Filename 'uImage'.   Load address: 0x12000000   Loading: #################################################################            #################################################################            #################################################################            #################################################################            ##########################            4 MiB/s   done   Bytes transferred = 4185600 (3fde00 hex)   BOOTP broadcast 1   DHCP client bound to address 192.168.111.121   Using FEC device   TFTP from server 192.168.111.1; our IP address is 192.168.111.121   Filename 'imx6q-sabresd.dtb'.   Load address: 0x11000000   Loading: ##            2.7 MiB/s   done   Bytes transferred = 22818 (5922 hex)   ## Booting kernel from Legacy Image at 12000000 ...      Image Name:   Linux-3.10.0-rc7   (..)   Starting kernel ...   Booting Linux on physical CPU 0x0   Linux version 3.10.0-rc7 (jenkins@debian) (gcc version 4.7.2 (Debian 4.7.2-5) ) #1 SMP Tue Jun 25 08:28:31 CEST 2013   (..)   Kernel command line: console=ttymxc0,115200 root=/dev/nfs ip=dhcp nfsroot=192.168.111.1:/tftpboot/busybox,v3,tcp rw   (..)   fec 2188000.ethernet eth0: Freescale FEC PHY driver [Generic PHY] (mii_bus:phy_addr=2188000.ethernet:01, irq=-1)   IPv6: ADDRCONF(NETDEV_UP): eth0: link is not ready   libphy: 2188000.ethernet:01 - Link is Up - 1000/Full   IPv6: ADDRCONF(NETDEV_CHANGE): eth0: link becomes ready   Sending DHCP requests ., OK   IP-Config: Got DHCP answer from 192.168.111.1, my address is 192.168.111.121   IP-Config: Complete:        device=eth0, hwaddr=00:04:9f:02:b7:fd, ipaddr=192.168.111.121, mask=255.255.255.0, gw=192.168.111.1        host=192.168.111.121, domain=, nis-domain=(none)        bootserver=192.168.111.1, rootserver=192.168.111.1, rootpath=        nameserver0=192.168.111.1   ALSA device list:     No soundcards found.   VFS: Mounted root (nfs filesystem) on device 0:11.   devtmpfs: mounted   Freeing unused kernel memory: 292K (806d5000 - 8071e000)   Please press Enter to activate this console. Enjoy! Bonus: updating u-boot by the network One last piece remains on the SD card: u-boot. If you do not want to move your SD card out of its slot any more, here is a method for you to update even u-boot from the network. You will need to copy u-boot.imx under /var/ftpd. See this post for details on how to compile u-boot and obtain u-boot.imx. Then, at u-boot prompt, do:   dhcp $loadaddr u-boot.imx   mmc dev 1   mmc write $loadaddr 2 600 This will download a new u-boot.imx from the network and flash it to your SD card; reboot your board and you are done. Note that we give 600 as the number of SD card blocks to write; this is a rough estimate of ~300KB, which should work in most of the cases as writing a bit "too much" blocks does not harm. If you are very picky, you can compute the exact number of blocks by dividing your u-boot.imx size by 512 and rounding it up. See also... Did you know that dnsmasq primary role is to be used to "relay" the DNS queries? A feature that come very handy when you want to let your i.MX6 platform "see" the internet.
View full article
In the old Android release R10.3.x for i.MX5x, I had followed the user guide instructions to install the USB driver and am able to setup the ADB connection successfully. Unfortunately, for the same PC, the ADB fails to detect my i.MX6SL EVK which is using R13.5. Updating the Android SDK tools cannot help. The reason is the new Android device is using a different USB VID from the old release. So, to solve this problem, we need to update the ADB configuration to scan for the new vendor ID. Below are the steps to update the ADB configuration for Windows PC. These steps (and the steps for Linux PC as well) can also be found in the R10,3.x user guide. 1. Run the SDK's tools to generate an ADB configure file: C:\Program Files\Android\android-sdk\tools> android.bat update adb 2. Modify the adb usb configure file to add the new vendor id 0x18d1. File: X:\Profile\<your account>\.android\adb_usb.ini # ANDROID 3RD PARTY USB VENDOR ID LIST -- DO NOT EDIT. # USE 'android update adb' TO GENERATE. # 1 USB VENDOR ID PER LINE. 0x15a2 0x18d1 3. Unpack the Freescale Android USB win driver "android_usb_fsl.zip" in your Android BSP release package. If you can't find this file in your current package, please get the R10.3.x release for i.MX5x and unpack it. 4. File "tetherxp.inf" in the unpacked "android_usb_fsl" may not be the updated one if the "android_usb_fsl.zip" is extracted from an old release. So, please overwrite the file "tetherxp.inf" in unpacked "android_usb_fsl.zip" by the new "tetherxp.inf" in your current Android BSP release. 5. Enable the "USB debugging" option on the i.MX6 device System settings -> Developer options -> USB debugging 6. Connect the Android Device into PC, uninstall your old driver named "Android Phone" in the device manager, then re-install driver by scanning and locating .inf file under the directory you unpack the android_usb_fsl.zip manually. 7. Restart the ADB server C:\Program Files\Android\android-sdk\platform-tools> adb kill-server C:\Program Files\Android\android-sdk\platform-tools> adb start-server 8. Finally, test your ADB connection C:\Program Files\Android\android-sdk\platform-tools> adb devices List of devices attached 0123456789ABCDEF     device Congratulations! Your ADB is now working. If you have additional information about this topic, please feel free to comment. This document was generated from the following discussion: i.MX6: Android connect to ADB
View full article
Here we show how to generate a minimal root filesystem fairly quickly with BusyBox, for the i.MX6 sabre sd platform. This document assumes you are able to boot a Linux kernel on your platform already. See this post for details on how to do it. This implies you already have a "working" Linux development environment with some ARM cross-compilers at hand (e.g. Debian + Emdebian). busybox is so small that we will go for a ramdisk as our main root filesystem. Get busybox sources We will use git to fetch busybox sources:   $ git clone git://git.busybox.net/busybox This should create a busybox directory with all the latest sources. Note that for more stability you might want to checkout a release instead of the latest version; to do so, list the available release tags with e.g. git tag -l, and git checkout <the-desired-tag>. Compile Assuming your cross compiler is called e.g. arm-linux-gnueabihf-gcc, you can compile by doing:   $ cd busybox   $ export ARCH=arm   $ export CROSS_COMPILE=arm-linux-gnueabihf-   $ make defconfig   $ sed -i.orig 's/^#.*CONFIG_STATIC.*/CONFIG_STATIC=y/' .config   $ make   $ make install This should create an _install folder hierarchy containing binaries and links. Note that we force the build of a static binary with the sed command. Configure the root filesystem We need to add some more configuration into the _install folder before we can call it a minimal filesystem. Create some folders We need to create some mountpoints and folders:   $ mkdir _install/dev   $ mkdir _install/proc   $ mkdir _install/sys   $ mkdir -p _install/etc/init.d Add some configuration files and scripts We need to prepare the main init configuration file, _install/etc/inittab, with this contents:   ::sysinit:/etc/init.d/rcS   ::askfirst:/bin/sh   ::ctrlaltdel:/sbin/reboot   ::shutdown:/sbin/swapoff -a   ::shutdown:/bin/umount -a -r   ::restart:/sbin/init This is very close to the default behavior busybox init has with no inittab file. It just suppresses some warnings about missing tty. We need to add some more configuration to mount a few filesystems at boot for convenience. This is done with an _install/etc/fstab file containing:   proc     /proc proc     defaults 0 0   sysfs    /sys  sysfs    defaults 0 0   devtmpfs /dev  devtmpfs defaults 0 0 We also need to actually trigger the mount in the _install/etc/init.d/rcS script, which is called from the inittab. It should contain:   #!/bin/sh   mount -a And we need to make it executable:   $ chmod +x _install/etc/init.d/rcS Generate the ramdisk contents Now that we have adapted the root filesystem contents, we can generate a busybox ramdisk image for u-boot with the following commands:   $ (cd _install ; find |cpio -o -H newc |gzip -c > ../initramfs.cpio.gz)   $ mkimage -A arm -T ramdisk -d initramfs.cpio.gz uInitrd This results in a uInitrd file, suitable for u-boot. Prepare a boot script The default u-boot commands are not sufficient to boot our system, so we need to edit a boot.txt file with the following contents:   run loaduimage   run loadfdt   setenv rdaddr 0x13000000   fatload mmc ${mmcdev}:$mmcpart $rdaddr uInitrd   setenv bootargs console=${console},${baudrate} rdinit=/sbin/init   bootm $loadaddr $rdaddr $fdt_addr Then we generate a boot.scr script, which can be loaded by u-boot with:   $ mkimage -A arm -T script -d boot.txt boot.scr Put on SD card Assuming you have prepared your SD card with u-boot and Linux as explained in this post, you have a single FAT partition on your card with your kernel and dtb. Our boot script and ramdisk image should be copied alongside:   $ mount /dev/<your-sd-card-first-partition> /mnt   $ cp uInitrd boot.scr /mnt/   $ umount /mnt Your SD card first partition is typically something in /dev/sd<X>1 or /dev/mmcblk<X>p1. Note that you need write permissions on the SD card for the command to succeed, so you might need to su - as root, or use sudo, or do achmod a+w as root on the SD card device node to grant permissions to users. Boot! Your SD card is ready for booting. Insert it in the SD card slot of your i.MX6 sabre sd platform, connect to the USB to UART port with a serial terminal set to 115200 baud, no parity, 8bit data and power up the platform. Your busybox system should boot to a prompt:   ...   Freeing unused kernel memory: 292K (806d5000 - 8071e000)   Please press Enter to activate this console. After pressing enter you should have a functional busybox shell on the target. Enjoy! See also... For a more featured root filesystem you might want to try a Debian filesystem in a second SD card partition, as explained in this post, or generate your filesystem with Buildroot. If you plan to compile busybox often, you might want to use a C compiler cache; see this post.
View full article
Here we show how to bootstrap the Debian Linux distribution from a PC to the i.MX6 sabre sd platform. While bootstrapping Debian on any architecture "natively" is pretty straightforward, "cross-bootstrapping" requires some techniques that we will explain. This document assumes you are able to boot a Linux kernel on your platform already. See this post for details on how to do it. Also, this document assumes you are using a Debian PC for preparing your SD card. You will require the following packages to be installed: binfmt-support qemu-user-static debootstrap Note: all the commands found in the following steps need to be run as root. Formatting the SD card We need to format the SD card with two partitions; one small FAT partition to contain the Linux kernel and its dtb, and one large ext4 partition, which will contain the root filesystem with the Debian userspace. Also, we need to make sure we leave some space for u-boot starting from offset 1024B. Here is an example SD card layout:   +-----+------+--------+-----+---------------+-----------------   | MBR |  ... | u-boot | ... | FAT partition | Linux partition ...   +-----+------+--------+-----+---------------+-----------------   0     512    1024           1M              ~257M (offsets in bytes) Here is an example SD card layout, as displayed by fdisk:   Device    Boot      Start         End      Blocks   Id  System   /dev/sdc1            2048      526335      262144    c  W95 FAT32 (LBA)   /dev/sdc2          526336     8054783     3764224   83  Linux (units: 512B sectors) You can format and mount the Linux partition with:   # mkfs.ext4 /dev/<your-sd-card-second-partition>   # mount /dev/<your-sd-card-second-partition> /mnt Your SD card second partition is typically something in /dev/sd<X>2 or /dev/mmcblk<X>p2. Do not forget to install u-boot and a Linux kernel as explained in those posts. Bootstrapping Debian First stage The first stage of Debian bootstrapping is done with:   # debootstrap --foreign --arch=armhf testing /mnt This will retrieve the base Debian packages from the internet, and perform a first stage of installation:   I: Retrieving Release   I: Retrieving Release.gpg   I: Checking Release signature   I: Valid Release signature (key id A1BD8E9D78F7FE5C3E65D8AF8B48AD6246925553)   I: Validating Packages   I: Resolving dependencies of required packages...   I: Resolving dependencies of base packages...   I: Found additional required dependencies: insserv libbz2-1.0 libcap2 libdb5.1 libsemanage-common libsemanage1 libslang2 libustr-1.0-1   I: Found additional base dependencies: libee0 libept1.4.12 libestr0 libgcrypt11 libgnutls-openssl27 libgnutls26 libgpg-error0 libidn11 libjson-c2 liblognorm0 libmnl0 libnetfilter-acct1 libnfnetlink0 libp11-kit0 libsqlite3-0 libtasn1-3 libxapian22   I: Checking component main on http://ftp.us.debian.org/debian...   (...)   I: Extracting util-linux...   I: Extracting liblzma5...   I: Extracting zlib1g... At this point, the necessary tools for second stage of installation are under /mnt/debootstrap/. Second stage The second stage needs to run natively; on an arm platform, that is. But we can use the combination of two techniques to perform this stage on the PC anyway:   # cp /usr/bin/qemu-arm-static /mnt/usr/bin/   # chroot /mnt /debootstrap/debootstrap --second-stage Those commands copy an arm emulator on the target filesystem, and use the chroot command to execute the second stage of the installation into the SD card, on the PC, with transparent emulation:   I: Installing core packages...   I: Unpacking required packages...   I: Unpacking libacl1:armhf...   I: Unpacking libattr1:armhf...   I: Unpacking base-files...   (...)   I: Configuring tasksel...   I: Configuring tasksel-data...   I: Configuring libc-bin...   I: Base system installed successfully. You can now remove /mnt/usr/bin/qemu-arm-static, or keep it for later, subsequent chroot under emulation. Finetuning the root filesystem For development it is handy to remove the root password on the target by removing the '*' from /mnt/etc/shadow on the SD card:   root::15880:0:99999:7::: Also, we can add the following line in /mnt/etc/inittab to obtain a login prompt on the UART:   T0:23:respawn:/sbin/getty -L ttymxc0 115200 vt100 You can now unmount the filesystem with:   # umount /mnt Boot! Your SD card is ready for booting. Insert it in the SD card slot of your i.MX6 sabre sd platform, connect to the USB to UART port with a serial terminal set to 115200 baud, no parity, 8bit data and power up the platform. At the time of writing u-boot tells the kernel to boot from the wrong partition by default, so we need to interrupt by pressing enter at u-boot prompt for the first boot and setup u-boot environment to fix this:   U-Boot > setenv mmcroot /dev/mmcblk0p2 rootwait rw   U-Boot > saveenv   Saving Environment to MMC...   Writing to MMC(1)... done As this is saved in the SD card it need only to be done once at first boot. You can reboot your board or type boot; your Debian system should boot to a prompt:   (...)   [ ok ] Starting periodic command scheduler: cron.   [ ok ] Running local boot scripts (/etc/rc.local).   Debian GNU/Linux jessie/sid debian ttymxc0   debian login: From there you may login as root. It is recommended to setup the network connection and install an ssh server inside the target for further development. Enjoy! See also... With the amounts of memory we have today in the systems, it is even possible to boot Debian in a ramdisk. See this post about busybox for the ramdisk generation. Another way of generating a root filesystem is by building it with buildroot. See and this post for details.
View full article
ccache is a C compiler cache. ccache can save a large amount of compilation time on recurring builds and builds restarted from a clean repository after make clean or git clean. It is well suited for e.g. u-boot and Linux compilation. Caching the host compiler Caching "native" builds is easily done by adding in the beginning of your $PATH a special directory, which contains links to ccache to override the usual compiler. On e.g. Debian this directory is readily available as /usr/lib/ccache, So you can do:   $ export PATH="/usr/lib/ccache:$PATH" Typical links found in this folder are:   c++ -> ../../bin/ccache   cc -> ../../bin/ccache   g++ -> ../../bin/ccache   gcc -> ../../bin/ccache etc... Caching the cross compiler Caching cross-compiled builds can be done in the same way as native builds, provided you create links of the form e.g. arm-linux-gnueabihf-gcc pointing to ccache. But there is an even more convenient way for those projects, which rely on a $CROSS_COMPILE environment variable (as is the case for e.g. u-boot and Linux). You can prefix the cross compiler with ccache there in e.g. the following way:   $ export CROSS_COMPILE="ccache arm-linux-gnueabihf-" Monitoring efficiency Now that your builds are cached, you might want to see how much is "spared" with this technique. ccache -s will tell you all sorts of statistics, such as:   cache directory                     /home/vstehle/.ccache   cache hit (direct)                 10852   cache hit (preprocessed)            3225   cache miss                         19000   called for link                    33267   called for preprocessing            9463   compile failed                         3   preprocessor error                     1   couldn't find the compiler           117   unsupported source language          921   unsupported compiler option         2167   no input file                      31681   files in cache                     51694   cache size                           1.3 Gbytes   max cache size                       4.0 Gbytes Here you see a somewhat typical 50%/50% hit/miss ratio. Enjoy! See Also ccache is usually supported natively by build systems, such as Buildroot or Yocto.
View full article
Here is a quick summary at booting Linux on the i.MX 6 sabre sd platform. This assumes you already have u-boot working on your platform as described here. This implies you already have a "working" Linux development environment with some ARM cross-compilers at hand (e.g. Debian + Emdebian). Get Linux sources We will use git to fetch Linux sources:   $ git clone git://git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux.git This should create a linux directory with all the latest sources (after a while). Note that for more stability you might want to checkout a release instead of the latest version; to do so, list the available release tags with e.g. git tag -l 'v*', and git checkout <the-desired-tag>. Compile Assuming your cross compiler is called e.g. arm-linux-gnueabihf-gcc, you can compile by doing:   $ cd linux   $ export ARCH=arm   $ export CROSS_COMPILE=arm-linux-gnueabihf-   $ make imx_v6_v7_defconfig   $ make You then need to supply a LOADADDR (as joowonkim pointed out); do:   $ make uImage LOADADDR=0x10008000 This should create a number of files, including arch/arm/boot/uImage and arch/arm/boot/dts/imx6q-sabresd.dtb. Put on SD We need a proper FAT partition on the SD card, from which u-boot will be able to load the kernel and dtb. Also, we need to make sure we leave some space for u-boot starting from offset 1024B. Here is an example SD card layout:   +-----+------+--------+-----+----------------   | MBR |  ... | u-boot | ... | FAT partition ...   +-----+------+--------+-----+----------------   0     512    1024           1M (offsets in bytes) Here is an example SD card layout, as displayed by fdisk:   Device    Boot      Start         End      Blocks   Id  System   /dev/sdc1            2048     8054783     4026368    c  W95 FAT32 (LBA) (units: 512B sectors) You can format the FAT partition, mount, copy and unmount with:   $ mkfs.vfat /dev/<your-sd-card-first-partition>   $ mount /dev/<your-sd-card-first-partition> /mnt   $ cp arch/arm/boot/uImage arch/arm/boot/dts/imx6q-sabresd.dtb /mnt/   $ umount /mnt Your SD card first partition is typically something in /dev/sd<X>1 or /dev/mmcblk<X>p1. Note that you need write permissions on the SD card for the command to succeed, so you might need to su - as root, or use sudo, or do a chmod a+w as root on the SD card device node to grant permissions to users. Also, be sure to have u-boot on the SD card as explained in this post. Boot! That's it; u-boot already knows how to deal with your kernel by default so you are good to go. Insert the SD card into the SD card slot of your i.MX6 sabre sd platform, connect to the USB to UART port with a serial terminal set to 115200 baud, no parity, 8bit data and power up the platform. You should see u-boot messages:   U-Boot 2013.07-rc1-00014-g74771f4 (Jun 21 2013 - 16:27:39) u-boot should load the uImage and dtb from SD card and boot the kernel:   (...)   reading uImage   4215344 bytes read in 449 ms (9 MiB/s)   Booting from mmc ...   reading imx6q-sabresd.dtb   22818 bytes read in 22 ms (1012.7 KiB/s)   ## Booting kernel from Legacy Image at 12000000 ...      Image Name:   Linux-3.10.0-rc6      Image Type:   ARM Linux Kernel Image (uncompressed)      Data Size:    4215280 Bytes = 4 MiB      Load Address: 10008000      Entry Point:  10008000      Verifying Checksum ... OK   ## Flattened Device Tree blob at 11000000      Booting using the fdt blob at 0x11000000      Loading Kernel Image ... OK   OK      Using Device Tree in place at 11000000, end 11008921   Starting kernel ... The kernel should boot:   Booting Linux on physical CPU 0x0   Linux version 3.10.0-rc6 (vstehle@debian) (gcc version 4.7.2 (Debian 4.7.2-5) ) #1 SMP Fri Jun 21 18:09:26 CEST 2013 By default, the kernel will try to mount a root filesystem from the SD card second partition, as can be read in the default kernel command line:   (...)   Kernel command line: console=ttymxc0,115200 root=/dev/mmcblk1p2 rootwait rw ...but we did not prepare a root filesystem partition, so after a number of boot messages the kernel will wait indefinitely:   (...)   mmc1: new SDHC card at address b368   (...)    mmcblk0: p1   (...)   Waiting for root device /dev/mmcblk1p2... We will see in another post how to prepare this root filesystem on the second SD card partition. Enjoy! See also... If you plan to compile Linux often, you might want to use a C compiler cache; see this post. Once you have Linux booting on your platform the next step is to give it a root filesystem. See this post for a Debian root filesystem, this post for a minimal busybox filesystem and this post for generating a root filesystem with buildroot.
View full article
Here is a quick summary at booting u-boot on the i.MX 6 sabre sd platform. This assumes you already have a "working" Linux development environment with some ARM cross-compilers at hand (e.g. Debian + Emdebian). Get u-boot sources We will use git to fetch the U-Boot sources:   $ git clone git://git.denx.de/u-boot.git This should create a u-boot directory with all the latest sources. Note that for more stability you might want to checkout a release instead of the latest version; to do so, list the available release tags with e.g. git tag -l 'v2*', and git checkout <the-desired-tag>. Compile Assuming your cross compiler is called e.g. arm-linux-gnueabihf-gcc, you can compile by doing:   $ cd u-boot   $ export CROSS_COMPILE=arm-linux-gnueabihf-   $ make mx6qsabresd_config   $ make This should create a number of files, including u-boot.imx. Put on SD U-boot should reside at offset 1024B of your SD card. To put it there, do:   $ dd if=u-boot.imx of=/dev/<your-sd-card> bs=1k seek=1   $ sync Your SD card device is typically something in /dev/sd<X> or /dev/mmcblk<X>. Note that you need write permissions on the SD card for the command to succeed, so you might need to su - as root, or use sudo, or do a chmod a+w as root on the SD card device node to grant permissions to users. Boot! Your SD card is ready for booting. Insert it in the SD card slot of your i.MX6 sabre sd platform, connect to the USB to UART port with a serial terminal set to 115200 baud, no parity, 8bit data, power up the platform and you should see something like:   U-Boot 2013.07-rc1-00014-g74771f4 (Jun 20 2013 - 19:05:09)   CPU:   Freescale i.MX6Q rev1.2 at 792 MHz   Reset cause: POR   Board: MX6Q-SabreSD   DRAM:  1 GiB   MMC:   FSL_SDHC: 0, FSL_SDHC: 1, FSL_SDHC: 2   *** Warning - bad CRC, using default environment   In:    serial   Out:   serial   Err:   serial   Net:   FEC [PRIME]   Warning: FEC using MAC address from net device   Hit any key to stop autoboot:  0 Enjoy! See also... u-boot most common mission is to boot the Linux kernel. See this post for details on how to do it. If you plan to compile u-boot often, you might want to use a C compiler cache; see this post. Running a Script in U-boot u-boot on the Vybrid tower board in a few commands
View full article
i.MX6Q PCIe EP/RC Validation and Throughput Hardware setup     * Two i.MX6Q SD boards, one is used as PCIe RC; the other one is used as PCIe EP. Connected by 2*mini_PCIe to standard_PCIe  adaptors, 2*PEX cable adaptors,  and one PCIe cable. Software configurations     * When building RC image, make sure that         CONFIG_IMX_PCIE=y         # CONFIG_IMX_PCIE_EP_MODE_IN_EP_RC_SYS is not set         CONFIG_IMX_PCIE_RC_MODE_IN_EP_RC_SYS=y     * When build EP image, make sure that         CONFIG_IMX_PCIE=y         CONFIG_IMX_PCIE_EP_MODE_IN_EP_RC_SYS=y         # CONFIG_IMX_PCIE_RC_MODE_IN_EP_RC_SYS is not set Features     * Set-up link between RC and EP by their stand-alone 125MHz running internally. * In EP's system, EP can access the reserved ddr memory    (default address:0x40000000) of PCIe RC's system, by the   interconnection between PCIe EP and PCIe RC. NOTE: The layout of the 1G DDR memory on SD boards is 0x1000_0000 ~ 0x4FFF_FFFF) Use mem=768M in the kernel command line to reserve the 0x4000_0000 ~ 0x4FFF_FFFF DDR memory  space used to do the EP access tests. (The example of the RC’s cmd-line: Kernel command line: noinitrd console=ttymxc0,115200 mem=768M root=/dev/nfs nfsroot=10.192.225.216:/home/r65037/nfs/rootfs_mx5x_10.11,v3,tcp ip=dhcp rw) Throughput results ARM core used as the bus master, and cache is disabled ARM core used as the bus master, and cache is enabled IPU used as the bus master(DMA) Data size in one write tlp 8 bytes 32 bytes 64 bytes Write speed ~109MB/s ~298MB/s ~344MB/s Data size in one read tlp 32 bytes 64 bytes 64 bytes Read speed ~29MB/s ~100MB/s ~211MB/s IPU used as the bus master(DMA) Here is the summary of the PCIe throughput results tested by IPU. Write speed is about 344 MB/s. Read speed is about 211MB/s ARM core used as the bus master (define EP_SELF_IO_TEST in pcie.c driver) write speed ~300MB/s. read speed ~100MB/s. Cache is enabled. PCIe EP: Starting data transfer... PCIe EP: Data transfer is successful, tv_count1 54840us, tv_count2 162814us. PCIe EP: Data write speed is 298MB/s. PCIe EP: Data read speed is 100MB/s. Regarding to the log, the data size of each TLP when cache is enabled, is about 4 times of the data size in write, and 2 times of the data size in read, when the cache is not enabled. Cache is disabled Cache is enabled Data size in one write tlp 8 bytes 32 bytes Write speed ~109MB/s ~298MB/s Data size in one read tlp 32 bytes 64 bytes Read speed ~29MB/s ~100MB/s Cache is not enabled PCIe EP: Starting data transfer... PCIe EP: Data transfer is successful, tv_count1 149616us, tv_count2 552099us. PCIe EP: Data write speed is 109MB/s. PCIe EP: Data read speed is 29MB/s. One simple method used to connect the imx6 pcie ep and rc View of the whole solution: HW materials: 2* iMX6Q SD boards,  2* Mini PCIe to STD PCIe adaptors, one SATA2 data cable. the mini-pcie to standard pcie exchange adaptor. Here is the URL: http://www.bplus.com.tw/Adapter/PM2C.html How to make it. signals connections Two adaptors, one is named as A, the other one is named as B. A                  B TXM <----> RXM TXN <----> RXN RXM <----> TXM RXN <----> TXN A1 connected to B3 A2 connected to B4 A3 connected to B1 A4 connected to B2 Connect the cable to the adaptor. Connect the SATA2 data cable to Mini PCIe to STD PCIe adaptor (A)    Connect the SATA2 data cable to Mini PCIe to STD PCIe adaptor (B) NOTE: * Please keep length of Cable as short as possible.  Our cable is about 12cm. * Please connect shield wire in SATA2 Cable to GND at both board. * Please boot up PCIe EP system before booting PCIe RC system. Base one imx_3.0.35 mainline, the patch, and the IPU test tools had been attached. NOTE: * IPU tests usage howto. Unzip the xxx.zip, and run xxx_r.sh to do read tests, run xxx_w.sh to do the write tests. Tests log: EP: root@freescale ~/pcie_ep_io_test$ ./pcie-r.sh pass cmdline 14, ./pcie_ipudev_test.out new option : c frame count set 1 new option : l loop count set 1 new option : i input w=1024,h=1024,fucc=RGB4,cpx=0,cpy=0,cpw=0,cph=0,de=0,dm=0 new option : O 640,480,RGB4,0,0,0,0,0 new option : s show to fb 0 new option : f output file name ipu1-1st-ovfb new option : ÿ show_to_buf:0, input_paddr:0x1000000, output.paddr0x18800000 ====== ipu task ====== input:         foramt: 0x34424752         width: 1024         height: 1024         crop.w = 1024         crop.h = 1024         crop.pos.x = 0         crop.pos.y = 0 output:         foramt: 0x34424752         width: 640         height: 480         roate: 0         crop.w = 640         crop.h = 480         crop.pos.x = 0         crop.pos.y = 0 total frame count 1 avg frame time 19019 us, fps 52.579000 root@freescale ~/pcie_ep_io_test$ ./pcie-w.sh pass cmdline 14, ./pcie_ipudev_test.out new option : c frame count set 1 new option : l loop count set 1 new option : i input w=640,h=480,fucc=RGB4,cpx=0,cpy=0,cpw=0,cph=0,de=0,dm=0 new option : O 1024,1024,RGB4,0,0,0,0,0 new option : s show to fb 1 new option : f output file name ipu1-1st-ovfb new option : ÿ show_to_buf:1, input_paddr:0x18a00000, output.paddr0x1000000 ====== ipu task ====== input:         foramt: 0x34424752         width: 640         height: 480         crop.w = 640         crop.h = 480         crop.pos.x = 0         crop.pos.y = 0 output:         foramt: 0x34424752         width: 1024         height: 1024         roate: 0         crop.w = 1024         crop.h = 1024         crop.pos.x = 0         crop.pos.y = 0 total frame count 1 avg frame time 11751 us, fps 85.099140 root@freescale ~$ ./memtool -32 01000000=deadbeaf Writing 32-bit value 0xDEADBEAF to address 0x01000000 RC: Before run "./memtool -32 01000000=deadbeaf" at EP. root@freescale ~$ ./memtool -32 40000000 10 Reading 0x10 count starting at address 0x40000000 0x40000000:  00000000 00000000 00000000 00000000 0x40000010:  00000000 00000000 00000000 00000000 0x40000020:  00000000 00000000 00000000 00000000 0x40000030:  00000000 00000000 00000000 00000000 After run "./memtool -32 01000000=deadbeaf" at EP. root@freescale ~$ ./memtool -32 40000000 10 Reading 0x10 count starting at address 0x40000000 0x40000000:  DEADBEAF 00000000 00000000 00000000 0x40000010:  00000000 00000000 00000000 00000000 0x40000020:  00000000 00000000 00000000 00000000 0x40000030:  00000000 00000000 00000000 00000000 Labels parameters
View full article
An i.MX50 customer encountered such kernel bug recently. Android UI has no response, because the suspend work queue is blocked:     suspend       pm_suspend         enter_state           suspend_prepare / suspend_finish             pm_prepare_console / pm_restore_console               vt_move_to_console                 vt_waitactive                   vt_event_wait                     wait_event_interruptible Confimed the same bug can also happen on imx6SL which is running linux 3.0.35. e.g. by echo standby/mem > /sys/power/state It takes over thousand suspend/resume cycles to reproduce the problem. The bug fix has been merged since linux 3.6: commit a7b12929be6cc55eab2dac3330fa9f5984e12dda
View full article
The attached patch enables HDMI overscan for Android JB, and tested by MX6Q SabreSD with Android_4.2.2_1.0.0-ga. The bootargs includes "video=mxcfb0:dev=ldb,bpp=32 video=mxcfb1:dev=hdmi,1920x1080M@60,if=RGB24,bpp=32 video=mxcfb2:off".
View full article
           This application note shows how to get i.MX6X development resources from Freescale website. Contents           We can enter Freescale i.MX website by the follow link http://www.freescale.com/imx, and after we input it into the IE address, it will remap to the new address of http://www.freescale.com/webapp/sps/site/homepage.jsp?code=IMX_HOME&tid=vanIMX. And the website page will have all the i.MX chipsets access web link like the follows:       And if we enter the i.MX6 serials Processors web link http://www.freescale.com/webapp/sps/site/taxonomy.jsp?code=IMX6X_SERIES , we will get the page like the follows:        Which have all the i.MX6 serials processors feature lists and website links. 1       i.MX6Q/D website guide. We enter the i.MX6D/Q web link http://www.freescale.com/webapp/sps/site/prod_summary.jsp?code=i.MX6Q&webpageId=129226228141673454B24A&nodeId=018rH3ZrDRB24A&fromPage=tax its main page as follows:    The Documentation and Software&Tools items is very important to get the design resource, and the Buy/Parametrics item will have the development board and chipset order information 1.1    i.MX6Q/D Documentation      We enter the Documentation item link: http://www.freescale.com/webapp/sps/site/prod_summary.jsp?code=i.MX6Q&nodeId=018rH3ZrDRB24A&fpsp=1&tab=Documentation_Tab, which will have our documentation materials include the Datasheet, Errata, Application Notes, Reference manual, User guides, Fact Sheets and related supporting information. 1.1.1  i.MX6Q/D DataSheet          We have i.MX6Q/D datasheets of automotive, consumer and industrial, the datasheet will have the chipset mark number, electrical, thermal and package information. IMX6DQAEC i.MX 6Dual/6Quad Automotive and Infotainment Applications Processors IMX6DQCEC i.MX 6Dual/6Quad Applications Processors for Consumer Products IMX6DQIEC i.MX 6Dual/6Quad Applications Processors for Industrial Products 1.1.2  i.MX6Q/D Errata       Chipset Errata will show us our current version chipset bugs and rework method. IMX6DQCE Chip Errata for the i.MX 6Dual/6Quad 1.1.3  i.MX6Q/D  Application Notes AN4724 i.MX 6Dual/6Quad Product Usage Lifetime Estimates AN4629 Fast Image Processing with i.MX 6 Series AN4671 i.MX 6 Series HDMI Test Method for Eye Pattern and Electrical Characteristics AN4397      //all the i.MX6 Serial can use the same PCB, this doc descript the hardware design difference Common Hardware Design for i.MX 6Dual/6Quad and i.MX 6Solo/6DualLite AN4581 Secure Boot on i.MX50, i.MX53, and i.MX 6 Series using HABv4 AN4509   //explan the i.MX6D/Q power consumption in every working features. i.MX 6Dual/6Quad Power Consumption Measurement AN4589 Configuring USB on i.MX 6 Series Processors AN4553 Using Open Source Debugging Tools for Linux on i.MX Processors AN4467 //explain the ddr calibration method, need check with FSL FAE for DDR test calibration tools i.MX 6 Series DDR Calibration AN4579 // explain the thermal design i.MX 6 Series Thermal Management Guidelines 1.1.4  i.MX6Q/D Chipset reference manual IMX6DQRM //i.MX6DQ reference manual for all the internal module description and registers define. i.MX 6Dual/6Quad Applications Processor Reference Manual IMX6DQ6SDLSRM   // i.MX6DQ security related reference manual, need NDA approve. Security Reference Manual for i.MX 6 1.1.5  i.MX6Q/D User guide IMX6DQ6SDLHDG //i.MX6DQ hardware design user guide, include the schematic layout check points, hardware bring up… Hardware Development Guide for i.MX 6Quad, 6Dual, 6DualLite, 6Solo Families of Applications EB792 i.MX 6 Series Standardized Signal Name Map EB793 MISRA Compliance in Freescale Automotive C Language Header Files - Engineering Bulletin 1.1.6  i.MX6Q/D Fact Sheet IMX6SRSFS i.MX 6 Series of Applications Processors - Fact Sheet 1.1.7  i.MX6Q/D BSP/Codec Software Document L3.0.35_4.0.0_LINUX_DOCS   i.MX 6Quad, i.MX 6Dual, i.MX 6DualLite and i.MX 6Solo Linux BSP Documentation. Includes Release Notes, Reference Manual,... MX6 folder include the BSP release notes, reference manual, user guide and other APIs doc. L3.0.35_4.0.0_LINUX_MMDOCS   i.MX 6Quad, i.MX 6Dual, i.MX 6DualLite and i.MX 6Solo Linux Multimedia Codecs Documentation. Includes CODECs Release... IMX6_JB422_100_ANDROID_DOCS   i.MX 6Quad, i.MX 6Dual, and i.MX 6DualLite Android jb4.2.2_1.0.0 BSP Documentation. Includes Release Notes, User's... 1.1.8  i.MX6Q/D InfoCTR IMX_INFOCTR //TIC support center i.MX Infocenter—Online Documentation 1.2    i.MX6Q/D  Software&Tools We enter into the Software&Tools item page: http://www.freescale.com/webapp/sps/site/prod_summary.jsp?code=i.MX6Q&nodeId=018rH3ZrDRB24A&fpsp=1&tab=Design_Tools_Tab 1.2.1  i.MX6Q/D  Reference Designs SABRE Platform for Smart Devices Based on the i.MX 6 Series  The Smart Application Blueprint for Rapid Engineering (SABRE) platform for smart devices allows you to hold in your hands and evaluate the full multimedia performance capabilities of i.MX 6 series applications processors based on ARM® Cortex™-A9 technology.  Targeted for any device ... Enter it: Press Buy: SABRE Board for Smart Devices Based on the i.MX 6 Series  Freescale's Smart Application Blueprint for Rapid Engineering (SABRE) board for smart devices introduces developers to quad-core processing, low-power consumption and leading-edge multimedia and graphics applications on the i.MX 6Quad ARM ® Cortex™ -A9 applications processor. The SABRE board for smart devices ... Enter it: Press Buy:   SDB board share the same PCB with SDP, but have no camera, LVDS and GPS moduel. SABRE for Automotive Infotainment Based on the i.MX 6 Series  The Smart Application Blueprint for Rapid Engineering (SABRE) for automotive infotainment offers a solid foundation for next-generation converged telematics and infotainment platform designs. Based on i.MX 6 series of applications processors, Freescale's most scalable implementation of the ARM® Cortex™-A9 CPU ... Enter it: Press Buy:    Which have the CPU board and automotive base board, And if need the automotive board LVDS display panel, we can enter the i.MX53 automotive board link to get the order name. SABRE Lite Development Kit: The SABRE Lite Development Kit includes one SABRE Lite board, one 5V power adapter, one customized serial cable, one cross serial cable (DB9-DB9), one USB cable, one net cable and one 4GByte micro SD... Format: html    Saber Lite board a mini system board which use the separate power design, which launch by 3 rd party. 1.2.2  i.MX6Q/D  PCB and Schematic i.MX6_SABRE_AI_DESIGNFILES   : Design files, including hardware schematics, layout files and BOM. Size (K): 39164 Format: zip Rev #: 1.0.2 Modified: 2/27/2013 i.MX6_SABRE_SDP_DESIGNFILES   : Design files, including hardware schematics, Gerbers, and OrCAD files.. Size (K): 11631 Format: zip Rev #: C3 Modified: 3/21/2013 iMX6_SABRE_SDB_DESIGNFILES   : Design files, including hardware schematics, Gerbers, and OrCAD files.. Size (K): 9541 Format: zip Rev #: C3 Modified: 3/21/2013 1.2.3  i.MX6Q/D  Programmers Tools IMX_6DQ_MFG_TOOL   : Tool and documentation for downloading OS images to the i.MX 6Quad and i.MX6Dual. Size (K): 69444 Format: gz Rev #: L3.0.35_4.0.0 Modified: 5/13/2013 IMX_MFG_TOOL_V2_SOURCE   : Source Code for the i.MX manufacturing tool used for downloading OS images to the i.MX 6 Processors. Size (K): 955 Format: zip Rev #: 2.1.1 Modified: 12/19/2012 1.2.4  i.MX6Q/D  Software IMX_6D_Q_VIVANTE_VDK_145_TOOLS   : Set of applications for the Linux L3.0.35_4.0.0 BSP, designed to be used by graphics application developers to rapidly develop and port graphics applications. Includes applications, GPU Driver with vprofiler enabled and documentation.. Size (K): 40113 Format: zip Rev #: 1.4.5 Modified: 5/13/2013 IMX6_GPU_SDK   : i.MX6 Graphics SDK – Includes sample, demo code, and documentation for working with the i.MX6X family graphics cores. Includes OpenVG, OpenGL ES, and GAL2D reference files. Size (K): 21065 Format: gz Rev #: 1.0.0 Modified: 1/25/2013 i.MX 6Series Platform SDK   : Bare-metal SDK for the i.MX 6 series, including reusable drivers and tests for many peripherals, and much example code. Also includes register definition headers files, and register definitions for debuggers. BSD open source license. Size (K): 29865 Format: tgz Rev #: 1.1 Modified: 2/11/2013      A non-OS i.MX6X driver test codes.  1.2.5  i.MX6Q/D  Tools IMX_CST_TOOL   : Freescale Code Signing Tool for the High Assurance Boot library. Provides software code signing support designed for use with i.MX processors that integrate the HAB library in the internal boot ROM. Size (K): 3855 Format: tgz Rev #: 2.0 Modified: 11/16/2012      Please still refer the document of i.MX6Q/D security RM and HAB application notes. IMX6_IOMUX_TOOL   : Interactive i.MX Pin Mux Tool.. Size (K): 5313 Format: zip Rev #: 3.4.0.3 Modified: 2/14/2013      Please still refer the document of i.MX6Q/D iomux table. 1.2.6  i.MX6Q/D  BSDL IMX6_DQ_BSDL   : i.MX 6Quad and i.MX 6Dual BSDL File. Size (K): 64 Format: zip Rev #: 2 Modified: 1/15/2013        A Boundary scan file for manufacture ICT test. 1.2.7  i.MX6Q/D  IBIS IMX6_DQ_IBIS   : i.MX 6Quad and i.MX 6Dual IBIS File. Size (K): 19173 Format: zip Rev #: 1 Modified: 11/9/2012       Use for signals simulation. 1.2.8  i.MX6Q/D  BSP IMX6_DQ_SABRE_AI_SD_DEMO_IMAGE   : Demo Image Flashed on the i.MX 6Quad SABRE AI SD Cards. Size (K): 1789607 Format: exe Rev #: L3.0.35_1.1.1 Modified: 4/23/2013 IMX6_DQ_SDB_SD_DEMO_IMAGE   : Demo Image Flashed on the i.MX 6Quad SDB SD Cards. Size (K): 1670416 Format: exe Rev #: R13.4.1 Modified: 4/24/2013 IMX6_DQ_SDP_SD_DEMO_IMAGE   : Demo Image Flashed on the i.MX 6Quad SDP SD Cards. Size (K): 1670892 Format: exe Rev #: R13.4.1 Modified: 4/24/2013 L3.0.35_4.0.0_DEMO_IMAGE   : i.MX 6Quad, i.MX 6Dual, i.MX 6DualLite and i.MX 6Solo Linux Binary Demo Files. Size (K): 359441 Format: gz Rev #: L3.0.35_4.0.0 Modified: 5/13/2013 IMX6_JB422_100_ANDROID_DEMO   : i.MX 6Quad, i.MX 6Dual, and i.MX 6DualLite Android jb4.2.2_1.0.0 BSP Binary Demo Files. Size (K): 836432 Format: gz Rev #: jb4.2.2_1.0.0 Modified: 5/8/2013 Demo image for customer to evaluate on Freescale’s board. IMX6_JB422_100_ANDROID_SOURCE   : i.MX 6Quad, i.MX 6Dual, and i.MX 6DualLite Android jb4.2.2_1.0.0 BSP, Documentation and Source Code for BSP and Codecs.. Size (K): 235533 Format: gz Rev #: jb4.2.2_1.0.0 Modified: 5/9/2013 Android JB422 source codes, still have the R13.41 android source codes in the same web folder. L3.0.35_4.0.0_ER_SOURCE   : i.MX 6Quad, i.MX 6Dual, i.MX 6DualLite and i.MX 6Solo Linux BSP Source Code Files. Size (K): 1064236 Format: gz Rev #: L3.0.35_4.0.0 Modified: 5/13/2013 Linux LTIB source codes package. L3.0.35_4.0.0_UBUNTU_RFS   : i.MX 6Quad, i.MX 6Dual, i.MX 6DualLite and i.MX 6Solo Linux File System for the Ubuntu Images. Size (K): 820076 Format: tgz Rev #: L3.0.35_4.0.0 Modified: 5/13/2013 Ubuntu rootfs working on our linux BSP. 1.2.9  i.MX6Q/D  Software Codecs IMX6_JB422_100_AACP_CODEC   : AAC Plus Codec for i.MX 6Quad, i.MX 6Dual, and i.MX 6DualLite Android jb4.2.2_1.0.0. Size (K): 84 Format: gz Rev #: jb4.2.2_1.0.0 Modified: 5/15/2013    Android have no codec package except AACP, have include in the BSP release codes. L3.0.35_4.0.0_AACP_CODECS   : i.MX 6Quad, i.MX 6Dual, i.MX 6DualLite and i.MX 6Solo Linux AAC Plus Codec. Size (K): 1377 Format: gz Rev #: L3.0.35_4.0.0 Modified: 5/13/2013 L3.0.35_4.0.0_MM_CODECS   : i.MX 6Quad, i.MX 6Dual, i.MX 6DualLite and i.MX 6Solo Linux Multimedia Codecs Sources. Size (K): 79197 Format: gz Rev #: L3.0.35_4.0.0 Modified: 5/13/2013    Linux have MM codec package. 1.2.10              i.MX6Q/D  Updates and Patches   Which have the older patch on L3.0.35 elder version, and Android R13.4/13.4.1. 2       i.MX6DL/S website guide. We enter the i.MX6DL/S web link http://www.freescale.com/webapp/sps/site/prod_summary.jsp?code=i.MX6DL&webpageId=129226228141673454B24A&nodeId=018rH3ZrDRB24A&fromPage=tax    its main page as follows: 2.1    i.MX6DL/S Documentation http://www.freescale.com/webapp/sps/site/prod_summary.jsp?code=i.MX6DL&nodeId=018rH3ZrDRB24A&fpsp=1&tab=Documentation_Tab 2.1.1  i.MX6DL/S DataSheet IMX6SDLAEC i.MX 6Solo/6DualLite Automotive and Infotainment Applications Processors IMX6SDLCEC i.MX 6Solo/6DualLite Applications Processors for Consumer Products IMX6SDLIEC i.MX 6Solo/6DualLite Applications Processors for Industrial Products 2.1.2  i.MX6DL/S Errata IMX6SDLCE Chip Errata for the i.MX 6Solo/6DualLite 2.1.3  i.MX6DL/S D  Application Notes IMX6SDLIEC i.MX 6Solo/6DualLite Applications Processors for Industrial Products AN4576 i.MX 6DualLite Power Consumption Measurement 2.1.4  i.MX6DL/S Chipset reference manual IMX6SDLRM i.MX 6Solo/6DualLite Applications Processor Reference Manual IMX6DQ6SDLSRM   Security Reference Manual for i.MX 6 2.1.5  i.MX6DL/S User Guide IMX6DQ6SDLHDG Hardware Development Guide for i.MX 6Quad, 6Dual, 6DualLite, 6Solo Families of Applications EB793 MISRA Compliance in Freescale Automotive C Language Header Files - Engineering Bulletin 2.1.6  i.MX6DL/S Fact Sheet IMX6SRSFS i.MX 6 Series of Applications Processors - Fact Sheet 2.1.7  i.MX6DL/S BSP/Codec Software Document L3.0.35_4.0.0_LINUX_DOCS   i.MX 6Quad, i.MX 6Dual, i.MX 6DualLite and i.MX 6Solo Linux BSP Documentation. Includes Release Notes, Reference Manual,... L3.0.35_4.0.0_LINUX_MMDOCS   i.MX 6Quad, i.MX 6Dual, i.MX 6DualLite and i.MX 6Solo Linux Multimedia Codecs Documentation. Includes CODECs Release... IMX6_JB422_100_ANDROID_DOCS   i.MX 6Quad, i.MX 6Dual, and i.MX 6DualLite Android jb4.2.2_1.0.0 BSP Documentation. Includes Release Notes, User's... 2.1.8  i.MX6DL/S InfoCTR IMX_INFOCTR i.MX Infocenter—Online Documentation 2.2    i.MX6DL/S Software&Tools http://www.freescale.com/webapp/sps/site/prod_summary.jsp?code=i.MX6DL&nodeId=018rH3ZrDRB24A&fpsp=1&tab=Design_Tools_Tab 2.2.1  i.MX6DL/S Reference Designs SABRE Platform for Smart Devices Based on the i.MX 6 Series  The Smart Application Blueprint for Rapid Engineering (SABRE) platform for smart devices allows you to hold in your hands and evaluate the full multimedia performance capabilities of i.MX 6 series applications processors based on ARM® Cortex™-A9 technology.  Targeted for any device ... SABRE for Automotive Infotainment Based on the i.MX 6 Series  The Smart Application Blueprint for Rapid Engineering (SABRE) for automotive infotainment offers a solid foundation for next-generation converged telematics and infotainment platform designs. Based on i.MX 6 series of applications processors, Freescale's most scalable implementation of the ARM® Cortex™-A9 CPU ... 2.2.2  i.MX6DL/S PCB and Schematic i.MX6_SABRE_AI_DESIGNFILES   : Design files, including hardware schematics, layout files and BOM. Size (K): 39164 Format: zip Rev #: 1.0.2 Modified: 2/27/2013 I.MX_6DL_S_VIVANTE_VDK_TOOLS   : i.MX6DL and i.MX6S Vivante VDK Tools. Size (K): 39752 Format: zip Rev #: 1.4.1 Modified: 1/4/2013 i.MX 6Series Platform SDK   : Bare-metal SDK for the i.MX 6 series, including reusable drivers and tests for many peripherals, and much example code. Also includes register definition headers files, and register definitions for debuggers. BSD open source license. Size (K): 29865 Format: tgz Rev #: 1.1 Modified: 2/11/2013 2.2.3  i.MX6DL/S Programmers Tools IMX_6DL_6S_MFG_TOOL   : Tool and documentation for downloading OS images to the i.MX 6DualLite and i.MX6Solo. Size (K): 67584 Format: gz Rev #: L3.0.35_4.0.0 Modified: 5/13/2013 2.2.4  i.MX6DL/S  Software 2.2.5  i.MX6DL/S BSDL IMX6_DL_S_BSDL   : i.MX 6DualLite and i.MX 6Solo BSDL File. Size (K): 81 Format: html Rev #: 1 Modified: 11/9/2012 2.2.6  i.MX6DL/S IBIS IMX6_DL_S_IBIS   : i.MX 6DualLIte and i.MX 6Solo IBIS File. Size (K): 15450 Format: zip Rev #: 1 Modified: 11/9/2012 2.2.7  i.MX6DL/S BSP IMX6_DL_SDP_SD_DEMO_IMAGE   : Demo Image Flashed on the i.MX 6DualLiteSDP SD Cards. Size (K): 367806 Format: zip Rev #: R13.4.1 Modified: 12/10/2012 IMX6_JB422_100_ANDROID_DEMO   : i.MX 6Quad, i.MX 6Dual, and i.MX 6DualLite Android jb4.2.2_1.0.0 BSP Binary Demo Files. Size (K): 836432 Format: gz Rev #: jb4.2.2_1.0.0 Modified: 5/8/2013 L3.0.35_4.0.0_DEMO_IMAGE   : i.MX 6Quad, i.MX 6Dual, i.MX 6DualLite and i.MX 6Solo Linux Binary Demo Files. Size (K): 359441 Format: gz Rev #: L3.0.35_4.0.0 Modified: 5/13/2013 IMX6_JB422_100_ANDROID_SOURCE   : i.MX 6Quad, i.MX 6Dual, and i.MX 6DualLite Android jb4.2.2_1.0.0 BSP, Documentation and Source Code for BSP and Codecs.. Size (K): 235533 Format: gz Rev #: jb4.2.2_1.0.0 Modified: 5/9/2013 L3.0.35_4.0.0_ER_SOURCE   : i.MX 6Quad, i.MX 6Dual, i.MX 6DualLite and i.MX 6Solo Linux BSP Source Code Files. Size (K): 1064236 Format: gz Rev #: L3.0.35_4.0.0 Modified: 5/13/2013 L3.0.35_4.0.0_UBUNTU_RFS   : i.MX 6Quad, i.MX 6Dual, i.MX 6DualLite and i.MX 6Solo Linux File System for the Ubuntu Images. Size (K): 820076 Format: tgz Rev #: L3.0.35_4.0.0 Modified: 5/13/2013 2.2.8  i.MX6DL/S Software Codecs IMX6_JB422_100_AACP_CODEC   : AAC Plus Codec for i.MX 6Quad, i.MX 6Dual, and i.MX 6DualLite Android jb4.2.2_1.0.0. Size (K): 84 Format: gz Rev #: jb4.2.2_1.0.0 Modified: 5/15/2013 L3.0.35_4.0.0_AACP_CODECS   : i.MX 6Quad, i.MX 6Dual, i.MX 6DualLite and i.MX 6Solo Linux AAC Plus Codec. Size (K): 1377 Format: gz Rev #: L3.0.35_4.0.0 Modified: 5/13/2013 L3.0.35_4.0.0_MM_CODECS   : i.MX 6Quad, i.MX 6Dual, i.MX 6DualLite and i.MX 6Solo Linux Multimedia Codecs Sources. Size (K): 79197 Format: gz Rev #: L3.0.35_4.0.0 Modified: 5/13/2013 2.2.9  i.MX6Q/D  Updates and Patches Which have the older patch on L3.0.35 elder version, and Android R13.4/13.4.1. 3       i.MX6SL website guide. http://www.freescale.com/webapp/sps/site/prod_summary.jsp?code=i.MX6SL&webpageId=129226228141673454B24A&nodeId=018rH3ZrDRB24A&fromPage=tax 3.1    i.MX6SL Documentation http://www.freescale.com/webapp/sps/site/prod_summary.jsp?code=i.MX6SL&nodeId=018rH3ZrDRB24A&fpsp=1&tab=Documentation_Tab 3.1.1  i.MX6SL DataSheet IMX6SLCEC i.MX 6SoloLite Applications Processors for Consumer Products 3.1.2  i.MX6SL Errata IMX6SLCE Chip Errata for the i.MX 6SoloLite 3.1.3  i.MX6SL Application Notes AN4726 i.MX 6SoloLite Product Usage Lifetime Estimates AN4580 i.MX 6SoloLite Power Consumption Measurement 3.1.4  i.MX6SL Chipset reference manual IMX6SLRM i.MX 6SoloLite Applications Processor Reference Manual 3.1.5  i.MX6SL User guide IMX6SLHDG Hardware Development Guide for i.MX 6SoloLite Applications Processors - User Guide 3.1.6  i.MX6SL Fact  Sheet IMX6SRSFS i.MX 6 Series of Applications Processors - Fact Sheet IMX6SLEVKFS i.MX 6SoloLite Evaluation Kit - Fact Sheet 3.1.7  i.MX6SL BSP/Codec Software Document L3.0.35_2.1.0_LINUX_DOCS   i.MX 6SoloLite Linux BSP Documentation. Includes Release Notes, Reference Manual, User guide. API Documentation L3.0.35_2.1.0_LINUX_MMDOCS   i.MX 6SoloLite Linux Multimedia Codecs Documentation. Includes CODECs Release Notes and User's Guide IMX6_R13.5_ANDROID_DOCS_BUNDLE   i.MX 6 Sololite Android GA BSP Documentation. 3.1.8  i.MX6SL INFOCTR IMX_INFOCTR i.MX Infocenter—Online Documentation 3.2    i.MX6SL Software&Tools http://www.freescale.com/webapp/sps/site/prod_summary.jsp?code=i.MX6SL&nodeId=018rH3ZrDRB24A&fpsp=1&tab=Design_Tools_Tab 3.2.1  i.MX6SL Reference Designs IMX6SLEVK: i.MX 6SoloLite Evaluation Kit. Freescale delivers the next installment in a line of highly-flexible, market-focused development tools with an Evaluation Kit (EVK) based on the i.MX 6SoloLite applications processor. The i.MX 6SoloLite is the first... Format: html Modified: 6/4/2013 3.2.2  i.MX6SL PCB and Schematics iMX6SL_EVK_DESIGNFILES   : Design files, including hardware schematics, Gerbers, and OrCAD files.. Size (K): 6034 Format: zip Rev #: 1 Modified: 11/12/2012 3.2.3  i.MX6SL Programmers Tools IMX_6SL_MFG_TOOL   : Tool and documentation for downloading OS images to the i.MX 6SoloLite. Size (K): 46502 Format: gz Rev #: L3.0.35_2.1.0 Modified: 5/24/2013 3.2.4  i.MX6SL Tools IMX_CST_TOOL   : Freescale Code Signing Tool for the High Assurance Boot library. Provides software code signing support designed for use with i.MX processors that integrate the HAB library in the internal boot ROM. Size (K): 3855 Format: tgz Rev #: 2.0 Modified: 11/16/2012 IMX6_IOMUX_TOOL   : Interactive i.MX Pin Mux Tool.. Size (K): 5313 Format: zip Rev #: 3.4.0.3 Modified: 2/14/2013 3.2.5  i.MX6SL Software i.MX 6Series Platform SDK   : Bare-metal SDK for the i.MX 6 series, including reusable drivers and tests for many peripherals, and much example code. Also includes register definition headers files, and register definitions for debuggers. BSD open source license. Size (K): 29865 Format: tgz Rev #: 1.1 Modified: 2/11/2013 3.2.6  i.MX6SL BSDL IMX6_SL_BSDL   : i.MX 6SoloLite BSDL File. Size (K): 54 Format: html Rev #: 1 Modified: 11/9/2012 3.2.7  i.MX6SL IBIS IMX6_SL_IBIS   : i.MX 6SoloLite IBIS File. Size (K): 25706 Format: zip Rev #: 1 Modified: 11/9/2012 3.2.8  i.MX6SL BSP IMX6_R13.5_ANDROID_DEMO_IMAGE   : i.MX 6Sololite GA BSP Binary Demo Files. Size (K): 372634 Format: gz Rev #: R13.5 Modified: 11/16/2012 L3.0.35_12.10.02_DEMO_IMAGE   : Linux Binary Demo Files for i.MX 6SoloLite Linux GA BSP. Size (K): 434356 Format: gz Rev #: 12.10.02 Modified: 11/9/2012 L3.0.35_2.1.0_DEMO_IMAGE   : i.MX 6SoloLite Linux Binary Demo Files. Size (K): 464844 Format: gz Rev #: L3.0.35_2.1.0. Modified: 6/4/2013 IMX6_R13.5_ANDROID_SOURCE_CODE   : i.MX 6 Sololite Android GA BSP Documentation and Source Code for BSP and Codecs.. Size (K): 100683 Format: gz Rev #: R13.5 Modified: 11/16/2012 L3.0.35_12.10.02_ER_SOURCE   : i.MX 6SoloLite Linux GA BSP 3.0.35 Source Code Files.. Size (K): 872027 Format: gz Rev #: 12.10.02 Modified: 11/9/2012 L3.0.35_12.10.02_UBUNTU_RFS   : File System for the Ubuntu Imagea for i.MX 6SoloLite Linux GA BSP. Size (K): 810816 Format: tgz Rev #: 12.10.02 Modified: 11/9/2012 L3.0.35_2.1.0_ER_SOURCE   : i.MX 6SoloLite Linux BSP Source Code Files. Size (K): 1064541 Format: gz Rev #: L3.0.35_2.1.0. Modified: 6/4/2013 3.2.9  i.MX6SL Software Codecs L3.0.35_2.1.0_AACP_CODECS   : i.MX 6SoloLite Linux AAC Plus Codec. Size (K): 1374 Format: gz Rev #: L3.0.35_2.1.0 Modified: 5/24/2013 L3.0.35_2.1.0_MM_CODECS   : i.MX 6SoloLite Linux Multimedia Codecs Sources. Size (K): 45883 Format: gz Rev #: L3.0.35_2.1.0 Modified: 5/24/2013 3.2.10              i.MX6SL Updates and Patches IMX6_R13.5_01_ANDROID_PATCHES   : Android 13.5.0-GA.01 patch release. It adds camera support (USB and CSI camera), provides some bug fixes, and includes some regular updates. The 13.5.0-GA.01 patch release is based on 13.5.0-GA.. Size (K): 186882 Format: gz Rev #: R13.5-GA.01 Modified: 1/4/2013 Which have the older patch on L3.0.35 elder version, and Android R13.5.         
View full article
The i.MX6 Multi-Mode DDR Controller (MMDC) has profiling capabilities to monitor the operation of the controller. The profiling capability counts certain events related to a specified AXI-ID during a profiling period. The events that can be counted are: The number of read accesses during the profiling period (MMDCx_MADPSR2[RD_ACC_COUNT] register field) The number of write accesses during the profiling period (MMDCx_MADPSR3[WR_ACC_COUNT] register field) The number of bytes read during the profiling period (MMDCx_MADPSR4[RD_BYTES_COUNT] register field) The number of bytes written during the profiling period (MMDCx_MADPSR5[WR_BYTES_COUNT] register field) The number of MMDC clock cycles during which the MMDC state machine is busy (MMDCx_MADPSR1[BUSY_COUNT] register field) BUSY_COUNT is the number of MMDC clock cycles during the profiling period in which the MMDC state machine is not idle. So this is the time the MMDC spends doing any activity, not just read or write data transfers. The MMDC state machine is active whenever there are any read or write requests in the read and write FIFOs. The MMDC is active during many operations that are not reading or writing data such as arbitration of requests, control cycles, bank open/close, etc. So BUSY_COUNT represents the number of cycles when the controller is busy, not just the number of cycles when the external bus is busy. The number of bytes read and bytes written can be used to determine data throughput and the BUSY_COUNT can be used to determine what part of the time the controller is active/idle. Together these can be used to determine the controller efficiency for a particular application. For detailed information, see the "MMDC profiling" section of the MMDC chapter in the reference manual for the SoC being used.
View full article
Share my test procedure in the attachment.
View full article
When to improve kernel booting using hibernation [1], I found kernel initialized each component [2] took too much time. One solution is to remove unnecessary module to save time. Another approach is to delay those modules until user space up. Then it won’t lost some features just because hopes to gain benefit on booting speed. This is very useful since hibernation’s trigger point is at the late_initcall [3]. Kernel doesn't need do much module initialize since hibernate will restore those module status later. The detailed implementation is in the attached patch. [1]: hibernation is a technique to store system memory content to storage. Then the device can be shutdown and read the content back after power on. [2]: component means subsystem or driver. [3]: Consult kernel/power/hibernate.c, software_resume
View full article
Change ambient graphic - Ambient Grafic:      Fluxbox (low memory and fast initialization) - Install (root):      apt-get update      apt-get install fluxbox - After instalation, edit file /etc/lightdm/lightdm.conf and change line:      "greeter-session=unity-grreter"  for  "greeter-session=fluxbox"   if, preference auto login comment this line:      "autologin-user=user"  for  "#autologin-user=user" - Reboot and try fluxbox  🙂
View full article
Notes: First run the playback pipeline then the streaming pipeline. The above example streams H263 video and AMR audio data. Change codec format to your needs. In case where the iMX is the streaming machine, the audio encoder 'amrnbenc' must be installed before. This scenario has not been tested Shell variables and pipelines Playback machine (receiver) # On playback machine, set either IMX2PC or PC2IMX variables, then run the pipeline ## IMX2PC: Case where PC does the playback     AUDIO_DEC_SINK="rtpamrdepay ! amrnbdec ! alsasink "     VIDEO_CAPS="\"application/x-rtp,media=(string)video,clock-rate=(int)90000,encoding-name=(string)H263-1998\""     VIDEO_DEC_SINK="rtph263pdepay ! ffdec_h263 ! autovideosink" ## End of IMX2PC Settings ## PC2IMX: Case where iMX does the playback     AUDIO_DEC_SINK="rtpamrdepay ! mfw_amrdecoder ! alsasink "     VIDEO_CAPS="\"application/x-rtp,media=(string)video,clock-rate=(int)90000,encoding-name=(string)H263-1998\""     VIDEO_DEC_SINK="rtph263pdepay ! vpudec ! mfw_v4lsink " ## End of PC2IMX Settings PLAYBACK_AUDIO="udpsrc caps=\"application/x-rtp,media=(string)audio,clock-rate=(int)8000,encoding-name=(string)AMR,encoding-params=(string)1,octet-align=(string)1\" \             port=5002 ! rtpbin.recv_rtp_sink_1 \         rtpbin. ! $AUDIO_DEC_SINK \      udpsrc port=5003 ! rtpbin.recv_rtcp_sink_1 \      rtpbin.send_rtcp_src_1 ! udpsink port=5007 sync=false async=false" PLAYBACK_VIDEO="udpsrc caps=$VIDEO_CAPS port=5000 ! rtpbin.recv_rtp_sink_0 \         rtpbin. ! $VIDEO_DEC_SINK \         udpsrc port=5001 ! rtpbin.recv_rtcp_sink_0 \         rtpbin.send_rtcp_src_0 ! udpsink port=5005 sync=false async=false" PLAYBACK_AV="$PLAYBACK_VIDEO $PLAYBACK_AUDIO" # Playback pipeline gst-launch -v gstrtpbin name=rtpbin $PLAYBACK_AV Streaming Machine (sender) # On Streaming machine, set either IMX2PC or PC2IMX variables, then run the pipeline ## IMX2PC: Case where iMX does the streaming     IP=x.x.x.x # IP address of the playback machine     VIDEO_SRC="mfw_v4lsrc"     VIDEO_ENC="vpuenc codec=h263 ! rtph263ppay "    AUDIO_ENC="audiotestsrc ! amrnbenc ! rtpamrpay " ## END IMX2PC settings ## PC2IMX: Case where PC does the streaming     IP=y.y.y.y # IP address of the playback machine     VIDEO_SRC="v4l2src"     VIDEO_ENC="ffenc_h263 ! rtph263ppay "     AUDIO_ENC="audiotestsrc ! amrnbenc ! rtpamrpay " # END PC2PC settings STREAM_AUDIO="$AUDIO_ENC ! rtpbin.send_rtp_sink_1 \         rtpbin.send_rtp_src_1 ! udpsink host=$IP port=5002 \         rtpbin.send_rtcp_src_1 ! udpsink host=$IP port=5003 sync=false async=false \         udpsrc port=5007 ! rtpbin.recv_rtcp_sink_1" STREAM_VIDEO="$VIDEO_SRC ! $VIDEO_ENC ! rtpbin.send_rtp_sink_0 \         rtpbin.send_rtp_src_0 ! queue ! udpsink host=$IP port=5000 \         rtpbin.send_rtcp_src_0 ! udpsink host=$IP port=5001 sync=false async=false \         udpsrc port=5005 ! rtpbin.recv_rtcp_sink_0" STREAM_AV="$STREAM_VIDEO $STREAM_AUDIO" # Stream pipeline gst-launch -v gstrtpbin name=rtpbin $STREAM_AV
View full article
Hi all,      I have a problem about usb mass storage driver, that's it can't enumerate my mass storage device.      but it can enumerate my mouse, keyboard...etc hid device.      anyone have idea about it ?      I always get below messages when my mass storage device plugs in.      and below is my dmesg information      My hardware -->      Type A receptacle on otg controller ~
View full article
Gst-entrans.spec GStreamer gst-inspect Tool GStreamer gst-launch Tool i.MX27 Video GST Caps i.MX27 ADS Board Video GST Play i.MX27 ADS Board Video GST Encode Gst-inspect mfw vpuencoder 1109 2.0.2 GStreamer Miscellaneous GStreamer i.MX6 Decoding GStreamer i.MX6 Multi-Display GStreamer i.MX6 Encoding GStreamer i.MX6 Image Display GStreamer i.MX6 Camera Streaming GStreamer i.MX6 Image Capture GStreamer i.MX6 Multi-Overlay GStreamer i.MX6 Pipelines GStreamer ffmpeg GStreamer Streaming GStreamer Transcoding and Scaling Testing GStreamer Tracing GStreamer Pipelines Useful Gstreamer Commands Using a USB Camera with GStreamer
View full article
Installation, patching and building the SDK The i.MX 6 Series Platform SDK v1.1.0 does not enable neither the MMU nor L1/L2 Caches (depending on the benchmark you are running, enabling these yield much better numbers), so there is a need to patch the code to enable these. Please download the SDK from the Freescale portal and the patch attached on this document, then follow these instructions: $ tar zxvf imx6_platform_sdk_v1.1.0.tgz $ cd iMX6_Platform_SDK $ patch -p1 < 0001-add-L2-cache-enable-to-mx6-SDK-1.1.0.patch $ export PATH=$PATH:<toolchain_install_path>/bin $ ./tools/build_sdk For more help, please look at the README.pdf and documents inside the doc folder.
View full article
Qt Creator can be a very good IDE in order to develop great QT applications. This IDE does not only helps with syntax highlighting, access to examples and tutorials, but also helps you to configure different toolchains Qt binary versions and target options. First download the binary installer from: For 32 bits: $ wget http://releases.qt-project.org/qtcreator/2.6.2/qt-creator-linux-x86-opensource-2.6.2.bin For 64 bits: $ wget http://releases.qt-project.org/qtcreator/2.6.2/qt-creator-linux-x86_64-opensource-2.6.2.bin execute the binary $ ./qt-creator-linux-x86_64-opensource-2.6.2.bin Follow the Installer GUI and choose a location. Default options should be OK. in my case the installation was done here: $ /home/b35153/qtcreator-2.6.2/bin Open Qt Creator (in my case from command line, use "&" to regain control of the terminal) $./qtcreator & Open Tools -> Options Choose Build & Run  on the menu of the left. and Select the Compilers Tab Here you can add the toolchain GCC compiler of your convenience. It will appear in the "Manual"  section. Now click on Qt Version Tab.  Here you can add the Qmake that you had created with your Qt installation; for example, the Qt5 installation described here: Building QT for i.MX6 It will appear in the Manual section. In my case I have Qmake for PC and Qmake for i.MX6. Now click on Kits Tab Here you can create combinations of Compilers and Qmake, and also specify where do you want the executables to go. In my case here I combined the i.MX6 toolchain and the Qmake for I.MX6 i had created. I did not set up device configuration since the sysroot is already shared to my device via NFS, but you can configure it so the files are sent via ssh to your device. And that's It! Next time you load a project you can choose which Kit you want to work on, and it will be compiled just as you need.
View full article