iWave iW-RainboW-G18D Linux User Manual

iWave iW-RainboW-G18D Linux User Manual

I.mx6ul/ull sodimm development platform
Hide thumbs Also See for iW-RainboW-G18D:
Table of Contents

Advertisement

Quick Links

iW-RainboW-G18D Linux User Guide
iW-RainboW-G18D
i.MX6UL/ULL SODIMM Development platform
Linux User Guide
REL 1.0
iWave Systems Technologies Pvt. Ltd.
Page 1 of 58

Advertisement

Table of Contents
loading
Need help?

Need help?

Do you have a question about the iW-RainboW-G18D and is the answer not in the manual?

Questions and answers

Subscribe to Our Youtube Channel

Summary of Contents for iWave iW-RainboW-G18D

  • Page 1 Linux User Guide iW-RainboW-G18D i.MX6UL/ULL SODIMM Development platform Linux User Guide REL 1.0 iWave Systems Technologies Pvt. Ltd. Page 1 of 58...
  • Page 2 If you are not the intended recipient (or authorized to receive for the recipient), you are hereby notified that any disclosure, copying distribution or use of any of the information contained within this document is STRICTLY PROHIBITED. Thank you. “iWave Systems Tech. Pvt. Ltd.” REL 1.0 iWave Systems Technologies Pvt.
  • Page 3 (including liability to any person by reason of negligence) will be accepted by iWave Systems, its subsidiaries or employees for any direct or indirect loss or damage caused by omissions from or inaccuracies in this document.
  • Page 4: Table Of Contents

    Linux User Guide Table of Contents INTRODUCTION ............................7 ................................7 URPOSE ................................7 COPE ............................7 IST OF CRONYMS BOARD SUPPORT PACKAGE ........................9 ............................9 BSP D RIVER DETAILS 2.1.1 BSP Supported Features ..........................9 2.1.2 Driver Source description ..........................9 2.1.3 Device tree source description ........................
  • Page 5 Linux User Guide ............................33 ASIC DEVICE ESTS 4.2.1 RAM Test ..............................33 4.2.2 SD Test ................................ 34 4.2.3 NAND Flash Test ............................35 4.2.4 I2C Test ............................... 35 4.2.5 Ethernet Test ............................... 36 4.2.6 USB Test ..............................39 4.2.7 Bmode Test ..............................
  • Page 6 Linux User Guide List of Figures ............................23 1: B IGURE OOT DEVICE MEMORY LAYOUT ) ......................24 2: B IGURE WITCH OSITIONS BEFORE PROGRAMMING ..............................25 3: P IGURE LATFORM ETECTION ............................ 26 4: B IGURE INARY ROGRAMMING UCCEED PC ..........................
  • Page 7: Introduction

    1. INTRODUCTION Purpose The purpose of this document is to help the software engineer to program and test the iW-RainboW-G18D-SM Linux development platform and this will also guide to configure the Linux development environment in the Host PC and build the board support package.
  • Page 8 Linux User Guide Acronyms Abbreviations UART Universal Asynchronous Receiver/Transmitter Universal Serial Bus USB OTG USB On The Go REL 1.0 iWave Systems Technologies Pvt. Ltd. Page 8 of 58...
  • Page 9: Board Support Package

    Linux User Guide 2. BOARD SUPPORT PACKAGE BSP Driver details This section explains about the features supported, the device driver details and path of the device drivers and device tree details in the i.MX6UL/i.MX6ULL SOM BSP. 2.1.1 BSP Supported Features Refer the Software release note for the supported features in the BSP 2.1.2 Driver Source description...
  • Page 10 Linux User Guide File Path Description drivers/usb/chipidea/udc.c Chipidea peripheral driver drivers/usb/chipidea/host.c Chipidea host driver drivers/usb/chipidea/ci_hdrc_imx.c i.MX glue layer drivers/usb/chipidea/usbmisc_imx.c i.MX SoC abstract layer drivers/usb/chipidea/ci.h Chipidea driver header files drivers/usb/chipidea/udc.h drivers/usb/chipidea/host.h Include/linux/usb/chipidea.h drivers/usb/phy/phy.c USB phy driver source file drivers/phy/phy-core.c Generic Phy framework include/linux/usb.h...
  • Page 11: Device Tree Source Description

    Linux User Guide File Path Description Include/linux/backlight.h 2.1.3 Device tree source description This section explains about the device tree source code configuration and organization for i.MX6UL/i.MX6ULL SOM. The device tree source codes will be available in below path of the Linux kernel.
  • Page 12: Bsp Yocto Compilation

     A Linux host PC with latest version (ex. Ubuntu version 12.04).  Root permission on the Development Host.  Cross compiler package for iW-RainboW-G18D-SM. 2.2.2 Host setup  This document assumes that Ubuntu PC is used. Not a requirement, but the packages may be named differently and the method of installing them may be different.
  • Page 13: Setting Up The Repo Utility

    Linux User Guide 2.2.4 Setting up the repo utility Repo is a tool built on top of Git that makes it easier to manage projects that contain multiple repositories, which do not need to be on the same server.
  • Page 14: Cross-Compiler Build

    Linux User Guide 2.2.6 Cross-compiler build This section provides the detailed information and process for building the cross-compiler and this cross- compiler can be used for standalone compilation of U-boot and Linux kernel.  Open a terminal window and change the directory to yocto setup path.
  • Page 15: Yocto Build

    Linux User Guide 2.2.7 Yocto build This section provides the detailed information and process for building the yocto binaries.  Open a terminal window and change the directory to yocto setup path. $ cd ~/<path to iwg18-release-bsp>/iwg18-release-bsp/  To setup environment build path, execute the below command. This is required only once on switching of every new terminal window.
  • Page 16: U-Boot

    Linux User Guide 2.2.8 U-boot This section provides the detailed information and process for building the u-boot binary image.  Open a terminal window and change the directory to yocto setup path. $ cd ~/<path to iwg18-release-bsp>/iwg18-release-bsp/  To setup environment build path, execute the below command. This is required only once on switching of every new terminal window.
  • Page 17: Linux Kernel

    Linux User Guide 2.2.9 Linux kernel This section provides the detailed information and process for building the kernel images.  Open a terminal window and change the directory to yocto setup path. $ cd ~/<path to iwg18-release-bsp>/iwg18-release-bsp/  To setup environment build path, execute the below command. This is required only once on switching of every new terminal window.
  • Page 18: U-Boot

     To export the Cross Compiler and tool chain path, execute the below command. host@host/<Directory>/u-boot-iwg18~$export ARCH=arm host@host/<Directory>/uboot-iwg18~$export PATH=$PATH:/opt/fsl-imx-x11/4.1.15- 2.0.3/sysroots/<processor>-pokysdk-linux/usr/bin/arm-poky-linux-gnueabi host@host/<Directory>/u-boot-iwg18~$export CROSS_COMPILE=arm-poky-linux-gnueabi-  To configure for iWave-G18M-SM platform, execute the below command. host@host/<directory>/u-boot-iwg18~$make mx6_iwg18m_sm_defconfig  To compile the u-boot source code, execute the below command. host@host/<directory>/u-boot-iwg18~$make CC="arm-poky-linux-gnueabi-gcc --sysroot=/opt/ fsl-imx-x11/4.1.15-2.0.3/sysroots/cortexa7hf-neon-poky-linux-gnueabi/"...
  • Page 19: Linux Kernel

    Linux User Guide 2.3.2 Linux kernel  Create a directory and open the directory in host to build the Linux. host@host~$mkdir <directory_name> host@host~$cd <directory_name>  The Linux kernel source code tar file from deliverables is located in the below path.
  • Page 20 Linux User Guide host@host/<Directory>/linux-iwg18~$mkdir ../<target_directory> host@host/<Directory>/linux-iwg18~$make modules_install INSTALL_MOD_PATH=../<target_directory>  After installation modules will be located in the below specified path <path_to_target_directory>/lib/modules/4.1.15/kernel/  To copy the kernel driver modules into the file system execute the below commands. –rf <path_to_target_directory>/lib/modules/4.1.15/kernel/ /lib/modules/4.1.15- 2.0.3+gb63f3f5/...
  • Page 21: Bsp Customization

     To test Ethernet2, configure as mentioned below in the file include/configs/mx6_iwg18m_sm.h in u-boot. #define CONFIG_FEC_ENET_DEV 1 2.4.2 Default Linux boot logo To Enable Default Linux Boot logo, deselect “Standard 224-color iWave logo” in make menuconfig and compile again. Device Drivers ---> Graphics support --->...
  • Page 22: Display Device On The Linux Image

    Linux User Guide 2.4.4 Display device on the Linux Image This chapter describes how to set up the display device in the device tree. Here, the LCD display is connected in LVDS0 channel. The LCD display supports 480x272 resolution, RGB666 pixel format and 16 bpp.
  • Page 23: Binary Programming

    Linux User Guide 3. BINARY PROGRAMMING MFG –Tool Programming This section explains the step by step procedure to flash the binaries using MFG tool. 3.1.1 Requirements To program the binaries for iW-RainboW-G18M-SM platform, following Items are required:  Binary files (u-boot.imx, zImage, imx6ul-iwg18m-sm.dtb, imx6ull-iwg18m-sm.dtb, rootfs.tar.bz2) ...
  • Page 24: Mfg-Tool

    Linux User Guide 3.1.2 MFG-Tool  The MFG-Tool is a manufacturing tool from Freescale that runs under Windows. It is designed to program firmware to iW-RainboW-G18M-SM platforms for mass production.  The MFG-Tool with this deliverables will divide the boot device’s space equally for VFAT and EXT4 partition after allocation of boot loader environment variables space.
  • Page 25: Binary Programming

    QuickStartGuide document for boot mode setting procedure.  Connect debug UART with host PC and Power ON the iW-RainboW-G18M-SM platform. Refer sections Debug UART Setting and Powering ON iW-RainboW-G18D in iW-RainboW-G18D-QuickStartGuide document to connect debug UART and power ON procedure.
  • Page 26: Limitations

    Linux User Guide  After successfully programming the Binaries to boot device, the progress bar will become Green colour and status box will be shown “Done”. Figure 4: Binary Programming Succeed  Click “Stop” to finish, and Click “Exit” to terminate the application.
  • Page 27: Manual Sd Card Programming

    Linux User Guide Manual SD Card Programming This section explains the step by step procedure to flash the binaries into micro SD card manually. 3.2.1 Requirements To program the binaries in SD card for iW-RainboW-G18M-SM platform, following Items are required: ...
  • Page 28 Linux User Guide  Press 'n' to create new partition (going to create first partition). Command (m for help): n Command action e extended p primary partition (1-4)  Press 'p' to create primary partition. Give 1 as partition number. Then give first cylinder as ‘7’(Based on the total cylinders we have to change the size) Because first 7 cylinders is for U-Boot.imx purpose and...
  • Page 29 Linux User Guide  List out partition types in SD. Press 'p' to view. Below message will be displayed Command (m for help): p Disk /dev/sdb: 1021 MB, 1021837312 bytes 31 heads, 62 sectors/track, 1038 cylinders Units = cylinders of 1922 * 512 = 984064 bytes...
  • Page 30: Binary Programming

    Linux User Guide 3.2.3 Binary Programming  Insert SD card using SD card reader to the PC. Execute mount command to see the attached nodes and mount points. $mount  SD card may attach to the dev nodes either sdb. Assume the SD card is attached to /dev/sdb node.
  • Page 31: U-Boot Testing And Boot Configuration

    Debug UART Setting and Powering ON iW-RainboW-G18D in iW-RainboW-G18D- QuickStartGuide document to connect debug UART and power ON procedure.  To enter in boot loader console, refer the section Linux Test Environment section in iW-RainboW-G18D Quick Start Guide document to get the boot loader console.
  • Page 32: Basic Commands

    Linux User Guide Basic commands  To find available commands and descriptions in U-Boot level type the below command. iWave-G18M >help  The available commands will be displayed in command prompt as shown below. bdinfo - print Board Info structure boot - boot default, i.e., run 'bootcmd'...
  • Page 33: Basic Device Tests

    Linux User Guide Basic device Tests In U-Boot level, the supported devices are  RAM  Micro SD  I2C  Ethernet1 Note: To know about the procedure for connecting the peripherals to iW-RainboW-G18M-SM platform, refer iW-RainboW-G18D-QuickStartGuide document. 4.2.1 RAM Test ...
  • Page 34: Sd Test

    Linux User Guide 4.2.2 SD Test  Initialize the particular SD/eMMC device by the below command. iWave-G18M>mmc dev <SD slot No>  The SD static slot numbers are below. Micro SD  To display the SD/eMMC device information, execute the below.
  • Page 35: Nand Flash Test

    Linux User Guide 4.2.3 NAND Flash Test Caution: Accessing the NAND Flash will corrupt the boot code, if NAND Flash is configured as the boot device.  To check the nand information, execute the below command iWave-G18M >nand info...
  • Page 36: Ethernet Test

    Linux User Guide 4.2.5 Ethernet Test  Development Platform supports two Ethernet ports and only one will work at a time in U-boot level. By default ENET1 is supported in the Uboot.  To set the MAC address and IP address for the platform and to save the environment variables, execute the below command.
  • Page 37 Linux User Guide 4.2.5.2 TFTP & NFS Host PC setup This section describes to setup a TFTP server and NFS server in Ubuntu Linux distributions Host PC.  The following host pc setup is required only once per host.
  • Page 38 Linux User Guide  Change the ownership of the directory. $ sudo mkdir /tftpboot $ sudo chmod -R 777 /tftpboot $ sudo chown -R <user_name>:<user_name> /tftpboot  Start the tftp services, $ sudo service xinetd stop $ sudo service xinetd start ...
  • Page 39: Usb Test

    Linux User Guide 4.2.6 USB Test  To scan the USB controller, execute the below command. iWave-G18M >usb start  To show the available USB devices, execute the below command. iWave-G18M >usb info  To show the USB storage devices details, execute the below command.
  • Page 40: Environment Variables Settings

    4.3.2 NAND boot  To load the kernel and file systems from the NAND, the environment variables should be set as shown below. iWave-G18M>setenv bootcmd_nand 'dynamicfdt;run bootargs_nand; nand read ${loadaddr} 0xA00000 0x800000; nand read ${fdt_addr} 0x1200000 0x100000; bootz ${loadaddr} - ${fdt_addr}' iWave-G18M >...
  • Page 41: Tftp & Nfs Boot

    Linux User Guide 4.3.3 TFTP & NFS boot  Kernel image (zImage) and rootfs (file systems) can be loaded through TFTP and NFS respectively. But the iW-RainboW-G18M-SM’s boot loader (u-boot) should be loaded from boot media. Note: To configure the host PC (under Linux OS) for TFTP and NFS server refer the TFTP & NFS Host PC setup section.
  • Page 42: Linux Peripheral Testing

    Debug UART Setting and Powering ON iW-RainboW-G18D in iW-RainboW-G18D- QuickStartGuide document to connect debug UART and power ON procedure.  To enter in boot loader console, refer the section Linux Test Environment section in iW-RainboW-G18D- QuickStartGuide document to get the boot loader console.
  • Page 43: Sd/ Usb Host/ Nand

    Linux User Guide 5.1.1 SD/ USB host/ NAND  The Micro USB (Host) / NAND will mount in below mentioned directories. Micro SD -/run /media/mmcblk0p1, /run /media/mmcblk0p2 …etc USB / USB OTG - /run /media/sdb1, /run /media/sdb2 …etc NAND ...
  • Page 44: Figure 5: Otg Device Detection On Host Pc

    Linux User Guide  After successful module registration, it shows the below debug message. g_mass_storage gadget: File-backed Storage Gadget, version: 20 November 2008 g_mass_storage gadget: Number of LUNs=1 g_mass_storage gadget-lun0: ro=0, file: /dev/sdb1 fsl-usb2-udc: bind to driver g_mass_storage.ko g_mass_storage gadget: high speed config #1 ...
  • Page 45: Network Devices Test

    Linux User Guide Network devices Test The iW-RainboW-G18M-SM platform will support the below network devices.  Ethernet1  Ethernet2  CAN Testing device Requirements To test the Network devices supported by iW-RainboW-G18M-SM platform, following Items are required.  Two Ethernet connection ...
  • Page 46: Ethernet Test

    Linux User Guide 5.2.1 Ethernet Test This section explains how to test the Ethernet with 100 Mbps speed in the iW-RainboW-G18M platform.  Connect the Ethernet cable and to enable the Ethernet device, execute the below command. root@iWave-G18M:~#ifconfig <eth0/eth1> up ...
  • Page 47 Folder mount from NFS  To mount any folder from NFS server (Host PC) to iW-RainboW-G18M-SM platform, execute the below command root@iWave-G18M:~#mount -o nolock -t nfs <server_ip>://<filepath> /mnt/floppy  To view the NFS mounted files and folders, execute below command. root@iWave-G18M:~#ls /mnt/floppy/ Note: To configure the host PC (under Linux OS) for TFTP and NFS server refer the TFTP &...
  • Page 48: Can Test

    (can0 port).  Set the bitrate and enable the CAN device, execute the below command. root@iWave-G18M:~#ip link set <CAN_DEVICE> up type can bitrate <bitrate>  The <CAN_DEVICE> depends upon the CAN port you have connected with another platform. It may be can0 or can1.
  • Page 49: Display Devices Test

    Linux User Guide Display devices Test The iW-RainboW-G18M-SM platform will support the below display devices.  LCD  PWM Testing device Requirements To test the display devices supported by iW-RainboW-G18M- platform, following Items are required.  LCD display (4.3 inch).
  • Page 50: Pwm Brightness Test

    Linux User Guide 5.3.2 PWM brightness Test The given BSP supports the PWM and to test the same PWM is connected with LVDS backlight. This section explains how to test the PWM brightness control in the iW-RainboW-G18M platform.  The LCD brightness has been controlled using PWM.
  • Page 51: Hid Devices Test

    Linux User Guide HID devices Test The iW-RainboW-G18M-SM platform will support the below Human Interface devices.  USB HID devices Testing device Requirements To test the Human Interface Devices supported by iW-RainboW-G18M-SM platform, following Items are required.  USB mouse and keyboard.
  • Page 52: Touch Screen Test

    Linux User Guide 5.4.2 Touch screen Test  To execute the touch test, execute the below command. root@iWave-G18M:~#ts_calibrate  Calibrate the touch screen by touching the cross hairs precisely. Figure 7: Touch screen calibration window REL 1.0 iWave Systems Technologies Pvt. Ltd.
  • Page 53: Uart Test

    Example root@iWave-G18M:~#cat /dev/ttymxc4  To set the Baud rate to a different value with CTS-RTS support, execute the below command root@iWave-G18M:~#stty -F /dev/<node> crtscts <Baud rate> Example root@iWave-G18M:~#stty -F /dev/ttymxc4 crtscts 115200  To set the Baud rate to a different value without CTS-RTS support, execute the below command root@iWave-G18M:~#stty -F /dev/<node>...
  • Page 54: Rtc Test

    Linux User Guide  The default UART baud rate is 9600bps and the tested Baud rates are given below: 300, 1200, 2400, 4800, 9600, 19200, 38400, 57600, 115200 & 230400 RTC Test The given BSP supports the built-in RTC. This section explains how to test RTC in the iW-RainboW-G18M platform.
  • Page 55: Wdog Test

     To list out the available options in overlay application, execute the below command. root@iWave-G18M:~#cd /unit_tests root@iWave-G18M:/unit_tests#./mx6s_v4l2_capture.out -help  To test the overlay application, execute the below command. root@iWave-G18M:/unit_tests#./mx6s_v4l2_capture.out -ow 480 -oh 272 -t 10 REL 1.0 iWave Systems Technologies Pvt. Ltd. Page 55 of 58...
  • Page 56: Audio Test

    Example root@iWave-G18M:~#aplay -D plughw:0,0 /unit_tests/audio8k16S.wav  To record an audio file, execute the below command. root@iWave-G18M:~#arecord -D plughw:<card>,<subdevice> -d <duration in sec> /<path to audio file>/<audiofile_name> Example root@iWave-G18M:~#arecord -D plughw:0,0 -d 10 /unit_tests/test.wav REL 1.0 iWave Systems Technologies Pvt. Ltd.
  • Page 57: Appendix

    Linux User Guide 6. APPENDIX Frequently Asked Question 1. How to power ON the iW-RainboW-G18D-SM platform? Refer the section Powering ON iW-RainboW-G18M-SM in iW-RainboW-G18M-QuickStartGuide for iW- RainboW-G18M-SM platform power ON procedure. 2. How to connect the Debug port of iW-RainboW-G18M-SM with host PC / What are the settings to be done in...
  • Page 58 $sudo apt-get install uboot-mkimage 9. Is the health of the file system maintained? If turn off the power of iW-RainboW-G18D-SM during Linux is booting normally / turned off the power without doing while running application. If you power off the platform while running any application, the running application may corrupt.

Table of Contents