SBC-i.MX51 Software User Manual

Aus BECOM Systems Support
Zur Navigation springen Zur Suche springen

NEWS

2011-11-11 - New Release v1.0
We have released a new version of the Linux BSP!
Highlights: Support for COMM and DISP extension boards; Bluetechnix ISM camera module drivers; Pre-configured SD card images for download. See here for details!
2011-07-07 - Third-party support for 2.6.35 Linux kernel
Thanks to Simon Vogl, who has brought the 2.6.35 kernel to the SBC-i.MX51! See #Development
2010-10-08 - New Release v0.9
We have released a new version of the Linux BSP!
Highlights: Linux 2.6.31 kernel, full hardware codecs support in GStreamer, accelerated X server. See here for details!
2010-09-28 - Public key no longer needed
Due to customer request we have ceased to require a public key for downloading software. All software is now freely available for the public.
2010-08-23 - OpenEmbedded Redboot recipe
Redboot can now be built with OpenEmbedded. Run
bitbake sbc-imx51-redboot
to build RedBoot. The files redboot.bin and redboot.bin_nopadding are placed into
btmxc/tmp/deploy/glibc/images/sbc-imx51
after building.
All the SBC-i.MX51 images build RedBoot automatically from now on.
2010-08-17 - Please re-check out the btmxc repository!
We've moved away the release files from the btmxc GIT repository to keep the size small. Because the repository ID changed, please make a fresh checkout of this repository as follows:
mv btmxc btmxc.bak
git clone ssh://gitosis@git.becom-group.com/btmxc
cd btmxc
git checkout origin/i.fly -b i.fly
mv ../btmxc.bak/tmp .
Do not make a "git pull" on the old repository!
To download release files, just follow the links on this page.

Quick Start

You have just received your SBC-i.MX51. It comes with Linux software installed in the NAND flash.

  1. Connect a monitor to the HDMI connector.
  2. Connect USB mouse and keyboard to the USB-A plugs.
  3. Make sure that the DIP switches are set for NAND boot: {{#if: 0 | | }}{{#if: 0 | | }}{{#if: 1 | | }}{{#if: 1 | | }}{{#if: 0 | | }}{{#if: 1 | | }}{{#if: 1 | | }}{{#if: 0 | | }}{{#if: | | }}{{#if: | | }}{{#if: 0 | {{#ifeq: 0 | 1 | | {{#ifeq: 0 | X | | }} }} | }}{{#if: 0 | {{#ifeq: 0 | 1 | | {{#ifeq: 0 | X | | }} }} | }}{{#if: 1 | {{#ifeq: 1 | 1 | | {{#ifeq: 1 | X | | }} }} | }}{{#if: 1 | {{#ifeq: 1 | 1 | | {{#ifeq: 1 | X | | }} }} | }}{{#if: 0 | {{#ifeq: 0 | 1 | | {{#ifeq: 0 | X | | }} }} | }}{{#if: 1 | {{#ifeq: 1 | 1 | | {{#ifeq: 1 | X | | }} }} | }}{{#if: 1 | {{#ifeq: 1 | 1 | | {{#ifeq: 1 | X | | }} }} | }}{{#if: 0 | {{#ifeq: 0 | 1 | | {{#ifeq: 0 | X | | }} }} | }}{{#if: | {{#ifeq: {{{9}}} | 1 | | {{#ifeq: {{{9}}} | X | | }} }} | }}{{#if: | {{#ifeq: {{{10}}} | 1 | | {{#ifeq: {{{10}}} | X | | }} }} | }}{{#if: 0 | {{#ifeq: 0 | 0 | | {{#ifeq: 0 | X | | }} }} | }}{{#if: 0 | {{#ifeq: 0 | 0 | | {{#ifeq: 0 | X | | }} }} | }}{{#if: 1 | {{#ifeq: 1 | 0 | | {{#ifeq: 1 | X | | }} }} | }}{{#if: 1 | {{#ifeq: 1 | 0 | | {{#ifeq: 1 | X | | }} }} | }}{{#if: 0 | {{#ifeq: 0 | 0 | | {{#ifeq: 0 | X | | }} }} | }}{{#if: 1 | {{#ifeq: 1 | 0 | | {{#ifeq: 1 | X | | }} }} | }}{{#if: 1 | {{#ifeq: 1 | 0 | | {{#ifeq: 1 | X | | }} }} | }}{{#if: 0 | {{#ifeq: 0 | 0 | | {{#ifeq: 0 | X | | }} }} | }}{{#if: | {{#ifeq: {{{9}}} | 0 | | {{#ifeq: {{{9}}} | X | | }} }} | }}{{#if: | {{#ifeq: {{{10}}} | 0 | | {{#ifeq: {{{10}}} | X | | }} }} | }}{{#if: 0 | | }}{{#if: 0 | | }}{{#if: 1 | | }}{{#if: 1 | | }}{{#if: 0 | | }}{{#if: 1 | | }}{{#if: 1 | | }}{{#if: 0 | | }}{{#if: | | }}{{#if: | | }}
    1234567890
  4. Connect 6-24V to the power plug (v1.2 Boards: 6-12V). You should immediately see either the blue or the red LED.
  5. The first boot takes about 15 minutes, subsequent boots are faster. Don't worry if the screen gets blank during first boot, the board is not dead!! (With 2.6.31 Linux, you may unblank the screen with a USB keyboard. However, current boards are delivered with BSP v0.2.)
  6. Login: Try one of: "root"/"sbc", "sbc"/"sbc", "root"/empty (depends on the BSP version)

Setting up your development environment

  • Set up a Serial console. (WARNING: Do not connect the USB cable for the serial terminal if the SBC-i.MX51 is not powered!)
  • Install a TFTP Server.
  • It is recommended to set up an NFS Server to be able to mount the target's root file system via NFS.
  • Optionally, you may set up a DHCP Server.

JTAG devices

Software Releases

Overview

  • Redboot boot loader
  • Linux kernel, Freescale and Bluetechnix patches
  • Angstrom Linux distribution, built with OpenEmbedded
  • GNU Toolchain, built with OpenEmbedded

Disclaimer

Software is provided AS-IS with no warranties.

Access to the software source is granted through our GIT repositories. Please note that although most parts are bound to license agreements defined by the GPL, there are some packages which are licensed through Freescale proprietary licenses or other license models. When applicable, the license agreement can be found in the according bitbake recipe. Bluetechnix does not guarantee that the list of licenses is exhaustive or complete.

By connecting to our GIT repositories, you agree to the terms and conditions outlined above.

Releases

v1.0

Release date
2011-11-11
Supported Hardware Revision
v2.1
Linux kernel version
2.6.31
based on Freescale's Linux BSP L2.6.31_10.07.11
Available images
sbc-imx51-gnome-image: GNOME v2.30 demo image
sbc-imx51-qtembedded-image: Qt4 Embedded v4.6.2 demo image (Start qtdemo -qws to start QT DEMO!)
sbc-imx51-console-image: Console demo image
Files
Download location: https://support.becom-group.com/releases/imx/sbc-imx51/v1.0-hw2.1/
File Content
redboot.bin Redboot boot loader (with padding); for copying to NAND boot partition
redboot.bin_nopadding Redboot boot loader (no padding); for SD card setup
zImage.bin Linux kernel 2.6.31 image
console-image-sbc-imx51.jffs2 JFFS2 image of root file system; for copying to NAND flash partition
console-image-sbc-imx51.tar.bz2 TAR/BZIP2 archive of root file system; for unpacking to SD card or for NFS
qtembedded-image-sbc-imx51.jffs2 JFFS2 image of root file system; for copying to NAND flash partition
qtembedded-image-sbc-imx51.tar.bz2 TAR/BZIP2 archive of root file system; for unpacking to SD card or for NFS
GNOME-image-sbc-imx51.tar.bz2 TAR/BZIP2 archive of root file system; for unpacking to SD card and NAND or for NFS
console-sdcard-1gb.img.bz2 SD card image containing the CONSOLE demo image and also the files for NAND setup. Decompress it with bunzip2 and copy it to an SD card with dd if=console-sdcard-1gb.img.bz2 of=/dev/sdX.
qtembedded-sdcard-1gb.img.bz2 SD card image containing the QtEmbedded demo image and also the files for NAND setup. Decompress it with bunzip2 and copy it to an SD card with dd if=qtembedded-sdcard-1gb.img.bz2 of=/dev/sdX.
gnome-sdcard-1gb.img.bz2 SD card image containing the GNOME demo image and also the files for NAND setup. Decompress it with bunzip2 and copy it to an SD card with dd if=gnome-sdcard-1gb.img.bz2 of=/dev/sdX.
GIT tag
sbc-imx51-v1.0-hw2.1, available in repositories btmxc, btmxc-linux, redboot-i.fly, openembedded
New features
Added Freescale i.MX51 PLL patch (Redboot; Linux)
Support for Bluetooth, GPS, GSM/GPRS modules on EXT-SBC-i.MX51-COMM (Linux)
ISM-MT9M131 camera module device driver (Linux)
ISM-MT9M024 camera module device driver, including capture (capture-mt9m024) and BAYER-to-UYVY applications (Linux)
SD card setup scripts now supports /dev/mmcblkX device files (Build)
Switch liveness LED to red during shutdown, and switch off LED at shutdown (Linux)
Changes
Default configuration of SD cards sets a fixed IP address instead of waiting for a DHCP address (Redboot)
Improved PMIC (Power Management IC) initialization sequence (Slower I2C speed; try harder) to fix the rare failure that some voltages are not turned on at boot (Redboot)
Smooth blinking of the liveness LED (Linux)
Fixed unintentional blanking of PWM backlight with DI0 framebuffer output (Linux)
Ready-to-use SD card images contain pre-configured rootfs and do not need additional time for configuration at first boot; also the packed rootfs used for NAND setup on these SD cards is pre-configured (Build)
Open issues
Camera on EXT-SBC-i.MX51-DISP is not supported by Cheese, Gnome's webcam application
Audio recording does not work with Gnome's audio recorder, but with arecord.

v0.9

Release date
2010-10-08
Supported Hardware Revision
v2.1
(v1.2: Use v0.2 Redboot)
Linux kernel version
2.6.31
based on Freescale's Linux BSP L2.6.31_10.07.11
Available images
sbc-imx51-gnome-image: GNOME v2.30 demo image
sbc-imx51-qtembedded-image: Qt4 Embedded v4.6.2 demo image
sbc-imx51-console-image: Console demo image
Files
File Size Content
console-image-sbc-imx51.jffs2 39 MiB JFFS2 image of root file system; for copying to NAND flash partition
console-image-sbc-imx51.tar.bz2 29 MiB TAR/BZIP2 archive of root file system; for unpacking to SD card or for NFS
GNOME-image-sbc-imx51.tar.bz2 171 MiB TAR/BZIP2 archive of root file system; for unpacking to SD card and NAND or for NFS
qtembedded-image-sbc-imx51.jffs2 92 MiB JFFS2 image of root file system; for copying to NAND flash partition
qtembedded-image-sbc-imx51.tar.bz2 70 MiB TAR/BZIP2 archive of root file system; for unpacking to SD card or for NFS
redboot.bin 197 KiB Redboot boot loader (with padding); for copying to NAND boot partition
redboot.bin_nopadding 196 KiB Redboot boot loader (no padding); for SD card setup
zImage.bin 2.2 MiB Linux kernel 2.6.31 image
sdcard-gnome-2gb.img.bz2 347 MiB SD card image containing the GNOME demo image and also the files for NAND setup. Decompress it with bunzip2 and copy it to an SD card with dd if=sdcard-gnome-2gb.img.bz2 of=/dev/sdX.
GIT tag
sbc-imx51-v0.9-hw2.1, available in repositories btmxc, btmxc-linux, redboot-i.fly, openembedded
New features
Linux kernel 2.6.31
Updated GStreamer framework that supports the i.MX51 VPU and IPU. Totem supports the hardware codecs now and is the default media player.
Accelerated X video driver that uses the i.MX51 internal GPU
Support of EXT-DISP extension board (1 TFT, 1 LVDS display, 1 camera)
Redboot displays logo onto HDMI at boot
Liveness LED
Time synchronization works now
Open issues
Camera on EXT-SBC-i.MX51-DISP is not supported by Cheese, Gnome's webcam application
Audio recording does not work with Gnome's audio recorder, but with arecord.
SBC V1.x compatibility
The BSP is compatible to SBC V1.x, but you have to use Redboot from the v0.2 release (because of different SDRAM chips)

v0.3

This release equals v0.2, but supports hardware revision 2.1. The only difference is the DDR-RAM setup in Redboot.

No binary packages are available from this release.

v0.2

Release date
2010-07-08
Supported Hardware Revision
v1.2
Linux kernel version
2.6.28
Available images
sbc-imx51-gnome-image: GNOME v2.30 demo image
sbc-imx51-qtembedded-image: Qt4 Embedded v4.6.2 demo image
sbc-imx51-console-image: Console demo image
Files
File Size Content
console-image-sbc-imx51.jffs2 40 MiB JFFS2 image of root file system; for copying to NAND flash partition
console-image-sbc-imx51.tar.bz2 29 MiB TAR/BZIP2 archive of root file system; for unpacking to SD card or for NFS
GNOME-image-sbc-imx51.jffs2 268 MiB JFFS2 image of root file system; for copying to NAND flash partition
GNOME-image-sbc-imx51.tar.bz2 182 MiB TAR/BZIP2 archive of root file system; for unpacking to SD card or for NFS
qtembedded-image-sbc-imx51.jffs2 93 MiB JFFS2 image of root file system; for copying to NAND flash partition
qtembedded-image-sbc-imx51.tar.bz2 70 MiB TAR/BZIP2 archive of root file system; for unpacking to SD card or for NFS
redboot.bin 189 KiB Redboot boot loader (with padding); for copying to NAND boot partition
redboot.bin_nopadding 188 KiB Redboot boot loader (no padding); for SD card setup
zImage.bin 1.8 MiB Linux kernel 2.6.28 image
GIT tag
sbc-imx51-v0.2-hw1.2, available in repositories btmxc, btmxc-linux, redboot-i.fly, openembedded
Open issues
FSL Gstreamer playbin not available; Players like Totem do not work yet.
If using .jffs2 Gnome image on NAND, Network Manager refuses to start and some icons in menus are missing

v0.1

Release date
2010-05-27
Supported Hardware Revision
v1.2
Linux kernel version
2.6.28
Available images
sbc-imx51-gnome-image: GNOME v2.30 demo image
Files
File Size Content
GNOME-image-big-sbc-imx51.jffs2 284 MiB JFFS2 image of root file system; for copying to NAND flash partition
GNOME-image-big-sbc-imx51.tar.bz2 194 MiB TAR/BZIP2 archive of root file system; for unpacking to SD card or for NFS
redboot.bin 189 KiB Redboot boot loader (with padding); for copying to NAND boot partition
redboot.bin_nopadding 188 KiB Redboot boot loader (no padding); for SD card setup
zImage.bin 1.8 MiB Linux kernel 2.6.28 image
GIT tag
sbc-imx51-v0.1-hw1.2, available in repositories btmxc, btmxc-linux, redboot-i.fly, openembedded
Open issues
No mtdblock devices available
Gnome media players: FSL Gstreamer plug-ins not yet integrated
X server: Framebuffer console cursor visible
AD9889: Rare flickering
Long first boot time

Setting up OpenEmbedded (OE) [1]

Development

Building, NFS root file system

Build Linux packages and images with OpenEmbedded

Configure the target network and set up an NFS root file system

Redboot and Linux

Modify the Linux kernel according to your needs

Modify the RedBoot boot loader according to your needs

FAQ

A collection of frequently asked questions

Supported Hardware

Hardware documentation

Please follow this link.

On-Chip/On-Board components

Each page contains information about hardware, device drivers, tests, etc.

Extension boards

  • EXT-SBC-i.MX51-COMM, featuring
    • two connectors for TFT displays
    • a connector for a Bluetechnix Image Sensor Module
    • a Bluetooth module
    • a GPS module
    • a GSM/GPRS module
  • EXT-SBC-i.MX51-DISP, featuring
    • two connectors for TFT displays
    • a connector for a Bluetechnix Image Sensor Module

Software Description

There are some important and i.MX51-specific libraries and applications in the SBC board support package in order to employ the i.MX51 hardware features (IPU, VPU, etc). Libraries and/or source code come from Freescale in their Linux BSP. We have re-integrated the required packages into OpenEmbedded. They are installed by default as needed in the SBC demo images.

i.MX specific support in Linux

How-Tos

Watchdog

The i.MX51 has an integrated watchdog timer that can be enabled to reset the processor once the application or the board crashes.

Typically, one wants to enable the watchdog already in the boot loader (Redboot). If the Linux kernel is not booted correctly, the watchdog timer will reset the processor and run the boot loader again. Therefore, in the Linux kernel, a small daemon is needed which continuously resets the timer. You may also add this functionality directly into your application.

Enable the watchdog in Redboot

  • Set the watchdog register in the boot script
fconfig boot_script_data
  • As the first command, enter the following:
mfill -b 0x73f98000 -l 2 -p 0x5077 -2

The MSB of the above 16-bit value is the timeout (value is seconds * 2). Hence, the above command sets the watchdog timeout to 0x50/2 = 40 seconds. Note that within these 40 seconds, the Linux kernel plus the Linux application that resets the watchdog timer must be started! Adapt the timeout according to your needs.

  • Once enabled, the i.MX51 watchdog cannot be disabled!

Set the watchdog timeout of Linux

  • The default timeout within Linux is 60 seconds.
  • To change it, you must supply an additional kernel argument in Redboot. Run
fconfig boot_script_data
  • Then copy line after line, and add the following to the e or exec line:
e -c "... mxc_wdt.timer_margin=<seconds>"
  • Once the watchdog timer driver is loaded in Linux, it will use the specified timeout.

Linux watchdog daemon

A simple daemon application that resets the watchdog timer periodically:

#include <stdio.h>
#include <stdlib.h>
#include <string.h>
#include <linux/watchdog.h>
#include <sys/ioctl.h>
#include <unistd.h>
#include <sys/types.h>
#include <sys/stat.h>
#include <fcntl.h>

int main(int argc, char **argv)
{
	int watchdog;
	FILE *log;
	int keepalive = 0;
	const char *logmsg = "Start wdt-daemon at ";
	int ret;

	if (argc != 2) {
		fprintf(stderr, "Usage: %s <keep-alive-interval>\n",argv[0]);
		return 0;
	}
	
	watchdog = open("/dev/watchdog",O_NONBLOCK,O_RDWR);
	log = fopen("/home/root/wdt-daemon-log.txt","a");
	fwrite(logmsg, strlen(logmsg), 1, log);
	fclose(log);
	system("date >> /home/root/wdt-daemon-log.txt");
	system("sync");
	
	keepalive = strtol(argv[1], NULL, 10);

	while (1) {
		ret = ioctl(watchdog, WDIOC_KEEPALIVE, 0);
               sleep(keepalive);
        }

	return 0;
}
Compilation
arm-angstrom-linux-gnueabi-gcc -o wdt_daemon wdt_daemon.c
Usage
For example, set mxc_wdt.timer_margin=10 and let the daemon wake up each 5 seconds to reset the timer.
Autostart
Assuming, the daemon is at /wdt_daemon, add the following line to /etc/inittab (bottom):
5:2345:respawn:/wdt_daemon 5