CM-T3530: Linux: Angstrom

From Compulab Mediawiki
Jump to: navigation, search

Introduction

The example run-time Linux filesystem image for CM-T3530 is based on Angstrom Linux 2010. The CompuLab Linux package for CM-T3530 includes ready to run Angstrom Linux filesystem image, Linux kernel and source code patches.

The default Angstrom Linux image includes more than 1000 software packages. Among them:

  • Core system
  • X11 Windowing System
  • Enlightenment v0.16 desktop manager
  • Midory web browser
  • Totem and MPlayer media players
  • GStreamer with multiple plugins
  • The Graphics SDK version 4.05.00.03 including the Linux graphics (SGX) drivers and ready to run SGX functionality demos

The Getting started with Linux on CM-T3530 page provides a brief introduction on how to install the run-time Linux image. This article describes package structure and peripheral device options specific to the CM-T3530.

Package contents

version.txt

The contents of the version.txt identifies the package version.

images

  • uImage-cm-t3530 - ready to run Linux kernel image binary for CM-T3530
  • angstrom-image-cm-t3530.tar.bz2 - archive of Angstrom root file system
  • angstrom-image-cm-t3530.ubi - ready to run Angstrom Linux image for installation onto CM-T3530 NAND
  • bootscr.img - U-Boot script used for image installation
  • kernel.img - Kernel image required for CM-T3530 Linux and Angstrom images installation
  • ramdisk.img - Ramdisk image required for Linux and Angstrom images installation

kernel

  • uImage-3.0.87-cm-t35-4.bin - ready to run Linux kernel 3.0.87-cm-t35-4 for CM-T3530
  • linux-3.0.87-cm-t35-4.config - Linux kernel 3.0.87-cm-t35-4 configuration file
  • linux-3.0.87-cm-t35-4.patch - patch vs. Linux stable kernel 3.0.87 with support for CM-T3530 peripherals
  • patches - ordered collection of patches, that form the single patch above (linux-3.0.87-cm-t35-4.patch)

oe

The oe directory contains configuration files and CM-T3530 specific package definitions for OpenEmbedded.

  • base-revision - the OpenEmbedded commit id that was used to create the Angstrom root file system image.
  • local.conf - configuration file used to build Angstrom Linux image for CM-T3530. This file should be placed in ${OEBASE}/build/conf directory.
  • openembedded-cm-t3x30.patch - patch vs. OE commit id specified in the base-revision to support CM-T3530
  • patches - ordered collection of patches, that form the single patch above (openembedded-cm-t3x30.patch)
  • extra - directory contains miscellaneous files and examples
    • oe_sample_appl.zip - archive of a sample Bitbake recipe that allows building a basic "Hello world" application

utilities

The utilities directory contains miscellaneous utilities useful for development

  • angstrom-image.cfg - configuration file used by ubinize utility for angstrom-image-cm-t3530.ubi generation.
  • tftpd32.zip - TFTP server for Windows users
  • eeprom-util - CompuLab EEPROM utility for reading information found inside the EEPROM on CompuLab boards
  • bootscr.src - U-Boot script source used for booting into the installation environment.

extra

The extra files that are not directly connected to the Linux kernel or the OE framework

  • Graphics_SDK_4_05_00_03 - graphics (SGX) related files
    • graphics_sdk_04_05_00_03-cm-t3x30.patch - patch to fix the Graphics SDK v4.05.00.03 compile time errors
    • patches - ordered collection of patches, that form the single patch above (graphics_sdk_04_05_00_03-cm-t3x30.patch)

Using Angstrom Linux on CM-T3530

Installation

Angstrom Linux performs self configuration on the first boot. This process may take a few minutes.

On the fist boot the user will be prompted to create a new user profile:

  • Please, enter the new user name and password.
  • When prompted with the language selection dialogue box, please press Next button.
  • When prompted with the Angstrom profile selection dialogue box, please select Angstrom.

Display options

CM-T3530 evaluation platform has four video output interfaces: LCD, DVI, LVDS and TV-out. Default configuration of Angstrom Linux for CM-T3530 uses DVI as primary video output. It is possible to switch between the DVI and LCD interfaces on the fly. TV-out can be used simultaneously with LCD or DVI interface.
Linux implementation of the OMAP3 display subsystem is described in detail in Documentation/arm/OMAP/DSS file in the Linux kernel source tree.

Display resolutions

  • The Toppoly LCD supplied with CM-T3530 evaluation kit supports 480x640 resolution with 18 bits per color
  • The DataImage LCD supplied with CM-T3530 evaluation kit supports 480x800 resolution with 18 bits per color
  • DVI output can be configured for standard resolutions using kernel command line parameter omapfb.mode:
    1024x768 - omapfb.mode=dvi:1024x768-24@60
    800x600 - omapfb.mode=dvi:800x600-24@60
    640x480 - omapfb.mode=dvi:640x480-24@60
  • TV-out supports PAL and NTSC standards

Examples

Switch from LCD to DVI

mgr0=/sys/devices/platform/omapdss/manager0
lcd=/sys/devices/platform/omapdss/display0
dvi=/sys/devices/platform/omapdss/display1
fb0=/sys/class/graphics/fb0

w=`cat $dvi/timings | cut -d "," -f 2 | cut -d "/" -f 1`
h=`cat $dvi/timings | cut -d "," -f 3 | cut -d "/" -f 1`

echo "0" > $lcd/enabled
echo "" > $mgr0/display
fbset -fb /dev/fb0 -xres $w -yres $h -vxres $w -vyres $h
echo "dvi" > $mgr0/display
echo "1" > $dvi/enabled

Clone GFX overlay to LCD and TV

ovl0=/sys/devices/platform/omapdss/overlay0
ovl1=/sys/devices/platform/omapdss/overlay1
tv=/sys/devices/platform/omapdss/display2
fb0=/sys/class/graphics/fb0
fb1=/sys/class/graphics/fb1

w=`cat $tv/timings | cut -d "," -f 2 | cut -d "/" -f 1`
h=`cat $tv/timings | cut -d "," -f 3 | cut -d "/" -f 1`

echo "0" > $ovl0/enabled
echo "0" > $ovl1/enabled

echo "" > $fb1/overlays
echo "0,1" > $fb0/overlays

echo "$w,$h" > $ovl1/output_size
echo "tv" > $ovl1/manager

echo "1" > $ovl0/enabled
echo "1" > $ovl1/enabled

echo "1" > $tv/enabled

Switch TV-out from PAL to NTSC

tv=/sys/devices/platform/omapdss/display2
echo "0" $tv/enabled
echo "ntsc" $tv/timings
echo "1" $tv/enabled

Touchscreen

CM-T3530 Evaluation Kit can be equipped with either of the following LCD touch panels: Toppoly TDO35S or DataImage SCF0403. See Select LCD model to enable support for the particular LCD touch panel. The X Windows system of CM-T3530 uses tslib X server input driver to get the input from the touchscreen.

Touchscreen calibration

Touchscreen calibration can be performed with xinput_calibrator utility. To calibrate the touchscreen run the following commands:

root@cm-t3530:~# export DISPLAY=:0
root@cm-t3530:~# xinput_calibrator
  • Follow the calibration utility instructions and touch the touchscreen corners.
  • Add the calibration output results into /etc/X11/xorg.conf configuration file.

GPIO access

Linux provides simple and convenient GPIO access via sysfs interface. A GPIO should be exported using /sys/class/gpio/export. After the GPIO is exported it is possible to change its direction and value using /sys/class/gpio/gpioX/direction and /sys/class/gpio/gpioX/value attributes.

Example

The following example demonstrates how to configure GPIO 140 as output and produce a 1usec pulse:

echo 140 > /sys/class/gpio/export
echo out > /sys/class/gpio/gpio140/direction
echo 0 > /sys/class/gpio/gpio140/value
echo 1 > /sys/class/gpio/gpio140/value
usleep 1
echo 0 > /sys/class/gpio/gpio140/value


Angstrom Linux package management

Angstrom Linux for CM-T3530 includes opkg package manager. It can be run from terminal command line.

Digital Video SDK

The TI DM3530 platform includes a built-in TMS320C64X+ DSP Core that provides advanced hardware acceleration support for media encoding / decoding.
For further details, refer to the OMAP35x Technical Reference Manual. The Digital Video SDK (DVSDK) version 4.01.00.09 provides multiple resources for evaluation and application development for the TI DM3530 platform.

Admolition note.png Although TI DVSDK is known to work with Linux kernel version 2.6.32, it is NOT compatible with kernel version 3.0.y.

Graphics SDK

The CM-T3530 Linux package contains pre-built and ready to run SGX functionality demo programs. The SGX configuration script must be run on CM-T3530 before first use:

root@cm-t3530:~# /etc/init.d/omap-demo
  • The SGX kernel modules must be loaded prior running the demos:
root@cm-t3530:~# /etc/init.d/rc.pvr start

Running Graphics SDK OpenGL ES1.x Demos

To run OpenGL ES1.x demos, perform the following:

root@cm-t3530:~# cd /opt/gfxsdkdemos/ogles
root@cm-t3530:/opt/gfxsdkdemos/ogles# ./OGLESSkybox

This will execute the OGLESSkybox demo. Press ‘q’ on the CM-T3530 console to stop the demo execution. Similarly, any other OpenGL ES1.x demo can be executed.

For more information and command line options of the OpenGL ES1.x demos, please refer to the SDK user guide: Graphics_SDK_4_05_00_03/GFX_Linux_SDK/OGLES/SDKPackage/OpenGL ES SDK.User Guide.1.20f.External.pdf.

Running Graphics SDK OpenGL ES2.0 Demos

To run OpenGL ES2.x demos, perform the following:

root@cm-t3530:~# cd /opt/gfxsdkdemos/ogles2
root@cm-t3530:/opt/gfxsdkdemos/ogle2s# ./OGLES2Coverflow

This will execute the OGLES2Coverflow demo. Press ‘q’ on the CM-T3530 console to stop the demo execution. Similarly, any other OpenGL ES2.0 demo can be executed.

For more information and command line options on the OpenGL ES2.0 demos, please refer to the SDK user guide: Graphics_SDK_4_05_00_03/GFX_Linux_SDK/OGLES2/SDKPackage/OpenGL ES 2.x SDK.User Guide.1.20f.External.pdf.

See also