Meego Wiki
Views

ARM/Meego on Beagleboard from scratch

From MeeGo wiki
< ARM(Difference between revisions)
Jump to: navigation, search
(Related links)
(Undo revision 49820 by Shanieley (talk) Spam)
 
(35 intermediate revisions not shown)
Line 1: Line 1:
-
<strong>This document describes how to create a MeeGo image for the beagleboard. </strong>
+
<strong>May 31st 2011: The instructions on this page don't work anymore!</strong>
 +
 
 +
These instructions require the integration of closed third party code into MeeGo to enable the video acceleration required for a decent MeeGo user experience. Recently, MeeGo for the arm CPU (MeeGo/ARM) has switched to hardware floating point support (hardfp/armv7hl). This needs to be explicitly supported by all code supposed to be used on MeeGo/ARM. The previous software floating point based setup (armv7l) is not officially supported by MeeGo anymore.
 +
 
 +
Unfortunately, all closed source drivers incl. the SGX video acceleration drivers provided by TI for the beagle board are not available with hardfp/armv7hl support. This fact breaks the beagle board setup presented here and probably also all other arm based meego ports. Currently, the only exception is the n900, which is supported by nokia with matching closed source drivers.
 +
 
 +
 
 +
This document describes how to create a MeeGo image for the beagleboard.
More information regarding MeeGo on the Beagleboard can be found at [[ARM/Meego_on_the_Beagle]].
More information regarding MeeGo on the Beagleboard can be found at [[ARM/Meego_on_the_Beagle]].
-
[[http://www.youtube.com/watch?v=LdKcNOrC5e4 Youtube video of BeagleBoard running MeeGo handset UX]]
+
= News =
 +
 
 +
* The set of supported UX now includes the tablet UX (See, for example, [[#Screenshots]]).
 +
 
 +
* We now provide ready-to-run SD card images [http://bug10738.openaos.org/images/beagleboard/ here]
 +
(For details read [[#Prepared_images]]).
= Introduction =
= Introduction =
 +
 +
[[http://www.youtube.com/watch?v=LdKcNOrC5e4 Youtube video of BeagleBoard running MeeGo handset UX]]
== Tested distros ==
== Tested distros ==
-
Creating this image has been tested on Ubuntu 10.10, other distros may require some things to be done
+
Creating this image has been tested on Ubuntu 10.10.  Other distros may require some things to be done
-
differently.  Several people have tried and failed to make this work on Ubuntu 9.04 and Ubuntu 9.10. Ubuntu 10.04 requires some tweaks when installing the cross compilers. It is recommended to use Ubuntu 10.10, if you want the best chance of success.  Conversely, if you have made this work for other versions of Ubuntu or other distros,  
+
differently.  Several people have tried and failed to make this work on Ubuntu 9.04 and Ubuntu 9.10. Ubuntu 10.04 requires some tweaks when installing the cross compilers. It is recommended to use Ubuntu 10.10, if you want the best chance of success.  Conversely, if you have made this work for other versions of Ubuntu or other distros, please add to this page any information that will help others achieve the same success.
-
please add to this page any information that will help others achieve the same success.
+
* Debian Lenny (you'll need to install some packages from Sid and you'll need to build some software.)
* Debian Lenny (you'll need to install some packages from Sid and you'll need to build some software.)
Line 24: Line 37:
Working:
Working:
* Same features as MeeGo on n900
* Same features as MeeGo on n900
-
* MeeGo handset UX with touchscreen
+
* MeeGo UX with touchscreen and 800x480 video
* 2D/3D video acceleration
* 2D/3D video acceleration
* Audio
* Audio
* Various USB add-ons incl. ethernet, mass-storage and bluetooth
* Various USB add-ons incl. ethernet, mass-storage and bluetooth
* Setup toolchain known working on Ubuntu 10.04/10.10
* Setup toolchain known working on Ubuntu 10.04/10.10
 +
* Support for handset, IVI and tablet UX
Todo:
Todo:
-
* Make mouse cursor visible under MeeGo HX for users without touchscreen
+
* Make mouse cursor visible under handset and tablet UX for users without touchscreen
* Definitive works / does not work on other distros and other versions
* Definitive works / does not work on other distros and other versions
Known issues:
Known issues:
-
* No beagleboard specific problems known, all known n900 problems still apply
+
* <s>[https://bugs.meego.com/show_bug.cgi?id=5616 Bug #5616]</s>
 +
* <s>[https://bugs.meego.com/show_bug.cgi?id=14480 Bug #14480]</s>
 +
* All known n900 problems probably still apply (unless they are related to the n900 specific kernel/video drivers)
== Supported BeagleBoard versions ==
== Supported BeagleBoard versions ==
-
The '''RevA''' and '''RevB''' boards have only 128MB RAM. This is not enough for the handset distribution of MeeGo. With swap enabled the UX boots, but is barely usable. Tested board revisions: B7
+
The '''RevA''' and '''RevB''' boards have only 128 MB RAM. This is not enough for the handset distribution of MeeGo. With swap enabled the UX boots, but is barely usable. Tested board revisions: B7
-
The '''RevC''' boards are the best choice at this moment as their hardware is fully supported by the Linux kernel and since their 256MB RAM allow for a more fluid UX experience. Tested board revisions: C4
+
The '''RevC''' boards are the best choice at this moment, as their hardware is fully supported by the Linux kernel and since their 256 MB RAM allow for a more fluid UX experience. Tested board revisions: C3, C4
-
The '''XM RevA''' boots into handset UX and is very fast and responsive. The stock kernel doesn't yet fully support this board (CPU only runs at 800Mhz) and most important, the USB hub doesn't work under the MeeGo kernel. Tested board revisions: XM-A2
+
The '''XM RevA''' boots into handset UX and is very fast and responsive. The stock kernel doesn't yet fully support this board (CPU only runs at 800 Mhz) and, most important, the USB hub doesn't work under the MeeGo kernel. Tested board revisions: XM-A2
'''The only board currently fully supported is the BeagleBoard RevC!'''
'''The only board currently fully supported is the BeagleBoard RevC!'''
 +
 +
== Prepared images ==
 +
 +
Ready-to-run SD card images can be found on [http://bug10738.openaos.org/images/beagleboard/ bug10738]. These images can be copied directly onto a 2 GB SD card:
 +
 +
<pre>
 +
dd if=<image name> of=/dev/<sd card device> bs=64k
 +
</pre>
 +
 +
It is possible that your SD card is slighty smaller than these images. In this case you can, for example, use fdisk to adjust the size of the 512 MB swap partition on the card and, afterwards, use mkswap to reformat that partition.
 +
 +
The root password for this image is "meego" as usual.
== Prerequisites ==
== Prerequisites ==
This document assumes that you have worked with the beagleboard
This document assumes that you have worked with the beagleboard
-
before and it may be helpful if you e.g. know how to format a memory card to boot from.
+
before and it may be helpful if you, for example, know how to format a memory card to boot from.
-
If you are new to BeagleBoard you might want to learn the basics using the following resources:
+
If you are new to BeagleBoard, you might want to learn the basics using the following resources:
-
* [http://code.google.com/p/beagleboard/wiki/LinuxBootDiskFormat Step by Step SD card formatting from scratch].
+
* [http://code.google.com/p/beagleboard/wiki/LinuxBootDiskFormat step-by-step SD card formatting from scratch].
* [http://elinux.org/BeagleBoardBeginners eLinux.org BeagleBoard beginners guide]
* [http://elinux.org/BeagleBoardBeginners eLinux.org BeagleBoard beginners guide]
* [http://elinux.org/BeagleBoard eLinux BeagleBoard main page]
* [http://elinux.org/BeagleBoard eLinux BeagleBoard main page]
* [http://beagleboard.org/ BeagleBoard.org home page]
* [http://beagleboard.org/ BeagleBoard.org home page]
-
The following instructions assume that your beagleboard boots from sd card. Xloader and uboot versions stored in beagleboard internal nand memory might prevent the following setup from working properly. If a bootloader is installed, you'll usually get its command prompt on the serial console when booting without sd card inserted. Entering  
+
The following instructions assume that your beagleboard boots from sd card. Xloader and uboot versions stored in beagleboard internal nand memory might prevent the following setup from working properly. If a bootloader is installed, you'll usually get its command prompt on the serial console when booting, without an sd card inserted. Entering  
<pre>
<pre>
Line 64: Line 92:
</pre>
</pre>
-
there will erase the entire nand memory and reset the beagleboard into the state expected in the following instructions. Warning: Other beagleboard sd cards you might be using may rely on certain parts being store in nand and might not work anymore afterwards.
+
there will erase the entire nand memory and reset the beagleboard into the state expected in the following instructions. Warning: Other beagleboard sd cards you might be using may rely on certain parts being stored in nand and might not work afterwards.
-
Please use a memory card of at least 2GB size for the following experiments. Otherwise the generated image may not fit onto the card.
+
Please use a memory card of at least 2 GB size for the following experiments. Otherwise, the generated image may not fit onto the card.
= Building MeeGo for the BeagleBoard =
= Building MeeGo for the BeagleBoard =
Line 75: Line 103:
* Installation of bootloader, kernel and root file system on sd card
* Installation of bootloader, kernel and root file system on sd card
-
Shell scripts have been created to automate all of these steps as much as possible. You can download an archive containing those scripts [http://wiki.meego.com/images/Meego_beagle.tgz here]. Unpack the contents of this somewhere into your hard disk. The following steps will require about 4GB of additional free disk space.
+
Shell scripts have been created to automate all of these steps as much as possible. You can get all necessary files [http://bug10738.openaos.org/images/beagleboard/ here]. These steps will require about 4 GB of additional free disk space.
-
This archive contains three shell scripts, each of them performing one of the three steps outlined before:
 
* build_kernel.sh build the kernel and the modules,
* build_kernel.sh build the kernel and the modules,
* build_image.sh assembles the root file system, and
* build_image.sh assembles the root file system, and
Line 90: Line 117:
</pre>
</pre>
 +
The kernel used in this project is not the MeeGo kernel (which doesn't include any beagleboard specific patches) but a port of the ubuntu kernel which is being maintained especially for the beagleboard and related boards.
-
The MeeGo kernel source code is downloaded and compiled using the build_kernel.sh shell script:
+
You can get the build scripts from [https://launchpad.net/~beagleboard-kernel https://launchpad.net/~beagleboard-kernel]. Follow the instructions there to build a Ubuntu kernel. There are only two MeeGo specific things:
 +
 
 +
* Set the CPUFreq governor to "userspace"
 +
* Add support for a 800x480 video mode
 +
 
 +
The CPUFreq governor can be adjusted in the kernel config dialog that will automatically open when you run the build_kernel.sh script from the 2.6.38-devel package. You need to set
<pre>
<pre>
-
./build_kernel.sh
+
CPU Power Management --> Default CPUFreq governor (ondemand)  ---> userspace
</pre>
</pre>
-
All downloaded files go into the ./downloads directory, temporary build files are created in ./build and the resulting kernel will be placed in the ./deploy directory. If you are low on disk space, you can delete the ./downloads and ./build directories after the kernel has successfully been built.
+
The 2.6.38-devel package allows for local patch directory which can be specified in the system.sh file. Just place the [http://bug10738.openaos.org/images/beagleboard/800x480.patch 800x480.patch] there and it will automatically be included into the resulting kernel.
 +
 
 +
You should end up with a uImage and modules tarball in 2.6.28-devel/deploy.
=== Setup for Ubuntu 10.04 LTS Lucid Lynx ===
=== Setup for Ubuntu 10.04 LTS Lucid Lynx ===
Line 113: Line 148:
== Assembly of the root file system ==
== Assembly of the root file system ==
-
The root file system (rootfs) is assembled from binary packages available in the MeeGo ARM repositories. The tool used to assemble the rootfs is called mic (MeeGo image creator).
+
The root file system (rootfs) is assembled from binary packages available in the MeeGo ARM repositories. The tool used to assemble the rootfs is called mic (MeeGo image creator). You need at least mic version 0.24.6 and you might have to grab the latest version from git following the instructions at [[Image_Creation#From_Development_Git_Tree]].
-
Follow the instructions at [[Image_Creation#From_Development_Git_Tree]] to install the latest version from git. Older versions will probably not work.
+
When using ubuntu 10.04/10.10 you'll need to install qemu using the
When using ubuntu 10.04/10.10 you'll need to install qemu using the
Line 122: Line 156:
restarting the scratchbox services makes scratchbox work again.
restarting the scratchbox services makes scratchbox work again.
-
The rootfs will also include the kernel modules. Thus the kernel has already to be built before starting the rootfs image assembly.
+
The rootfs image creation itself is started using the [http://bug10738.openaos.org/images/beagleboard/build_image.sh build_image.sh script] the following way:
-
 
+
-
The rootfs image creation itself is started by the following command:
+
<pre>
<pre>
Line 130: Line 162:
</pre>
</pre>
-
This will download all packages required to build the root file system from the internet into the ./mycachedir directory and assemble the root file system image in the ./daily directory.
+
This will download all packages required to build the root file system from the internet into the ./mycachedir directory and assemble the root file system image.
-
If you need to save hard disk space you can remove the ./mycachedir directory once the image has successfully been built.
+
If you need to save hard disk space, you can remove the ../mycachedir directory once the image has successfully been built.
 +
 
 +
If you want to build an ivi or tablet images, instead use
 +
 
 +
<pre>
 +
sudo TYPE=ivi ./build_image.sh
 +
</pre>
 +
 
 +
or
 +
 
 +
<pre>
 +
sudo TYPE=tablet ./build_image.sh
 +
</pre>
== Installation on sd card ==
== Installation on sd card ==
-
The last step is to put the kernel and the rootfs onto an sd card together with an xloader and uboot boot loader as required to boot the beagleboard. This is accomplished by invoking the third shell script. This script has to be given the device name of the sd card you are intending to use. On my system the sd card is /dev/sdd, so i have to invoke the script as follows:
+
The last step is to put the kernel and the rootfs onto an sd card together with an xloader and uboot boot loader, as required to boot the beagleboard. This is accomplished by invoking the [http://bug10738.openaos.org/images/beagleboard/setup_sdcard.sh setup_sdcard.sh shell script]. This script has to be given the device name of the sd card you are intending to use. On my system, the sd card is /dev/sdd, so i have to invoke the script as follows:
<pre>
<pre>
Line 142: Line 186:
</pre>
</pre>
-
The script will as you to acknowledge this. Please watch the output carefully. Specifying e.g. your systems hard drive will wipe your entire hard disk instead of the sd card.  
+
The script will ask you to acknowledge this. Please watch the output carefully. Specifying, for example, your system's hard drive will wipe your entire hard disk, instead of the sd card.  
This will take some time as the sd card is reformatted, all bootloaders are installed, file systems are created and the kernel and the contents of the root file system are copied onto the sd card.
This will take some time as the sd card is reformatted, all bootloaders are installed, file systems are created and the kernel and the contents of the root file system are copied onto the sd card.
 +
 +
Again, if you intend to use the IVI or tablet image, use a slightly modified command:
 +
<pre>
 +
TYPE=ivi ./setup_sdcard.sh --mmc /dev/sdd
 +
</pre>
 +
 +
or
 +
 +
<pre>
 +
TYPE=tablet ./setup_sdcard.sh --mmc /dev/sdd
 +
</pre>
== Boot ==
== Boot ==
-
Plug the resulting SD card into your beagleboard and power on. After a few seconds the video will switch to 800x480 pixels and the MeeGo handset UX should appear on the screen. The first boot will always take several minutes as some media files are copied forth and back on the card.
+
Plug the resulting SD card into your beagleboard and power on. After a few seconds, the video will switch to 800x480 pixels and the MeeGo handset UX should appear on the screen. The first boot will always take several minutes, as some media files are copied forth and back on the card.
[[File:Meego_beagle.jpg]]
[[File:Meego_beagle.jpg]]
Line 160: Line 215:
These just work, nothing to configure.
These just work, nothing to configure.
-
 
-
On the BB-XM the built-in USB hub is not detected and not working. This is currently being investigated as this worked well with previous non-MeeGo kernel versions and is broken since we switched to the MeeGo kernel line. The OTG port works and can be equipped with an external hub as a temporary work-around.
 
== Bluetooth keyboard ==
== Bluetooth keyboard ==
-
My CSR bluetooth dongle works out of the box. Hcitool is present to scan for devices as well
+
A CSR bluetooth dongle works out of the box. Hcitool is present to scan for devices, as well
as hidd to connect to bluetooth HID devices. This has been tested with a bluetooth
as hidd to connect to bluetooth HID devices. This has been tested with a bluetooth
keyboard.
keyboard.
Line 171: Line 224:
== Touchscreen ==
== Touchscreen ==
-
My 7 inch egalax based touchscreen worked nearly perfectly out of the box. It was just a little bit mis-calibrated.
+
A 7 inch egalax based touchscreen worked nearly perfectly out of the box. It was just a little bit mis-calibrated.
The latest hal driven xorg can be given a input configuration file to deal with this.An example setup is already included at /etc/X11/xorg.conf.d/50-input-touch.conf. If you don't have a touchscreen this file is ignored.
The latest hal driven xorg can be given a input configuration file to deal with this.An example setup is already included at /etc/X11/xorg.conf.d/50-input-touch.conf. If you don't have a touchscreen this file is ignored.
Line 179: Line 232:
== Ethernet ==
== Ethernet ==
-
A D-Link DUB-E100 ethernet dongle works out of the box and gets an IP address via DHCP. With this network connection i was able to verify that zypper and the package management also work. A "zypper up" successfully updated a few packages.
+
A D-Link DUB-E100 ethernet dongle works out of the box and gets an IP address via DHCP. With this network connection, I was able to verify that zypper and the package management work, also. A "zypper up" successfully updated a few packages.
-
The beagleboard XM's onboard Ethernet (a SMSC95xx based USB device) cannot be tested with the MeeGo kernel since the USB hub it is connected to currently isn't supported.
+
The beagleboard XM's onboard Ethernet (a SMSC95xx based USB device) works, also.
== WLAN ==
== WLAN ==
Line 195: Line 248:
== Starting X programs from the serial console ==
== Starting X programs from the serial console ==
-
If you have a keyboard and mouse you can skip this section. If you don't have a keyboard connected and want to run X programs from the console, you need to set the DISPLAY environment variable. Also it's required to change to the meego user before doing so:
+
If you have a keyboard and mouse you can skip this section. If you don't have a keyboard connected and want to run X programs from the console, you need to set the DISPLAY environment variable. Also, it's required to change to the meego user before doing so:
<pre>
<pre>
[root@localhost ~]# su meego
[root@localhost ~]# su meego
[meego@localhost root]$ export DISPLAY=:0
[meego@localhost root]$ export DISPLAY=:0
-
[meego@localhost root]$ widgetsgallery
+
[meego@localhost root]$ xeyes
</pre>
</pre>
Line 228: Line 281:
Screenshot of IVI UX on beagle (nov 2010)
Screenshot of IVI UX on beagle (nov 2010)
 +
 +
[[File:Beagle-Tablet.png]]
 +
 +
Screenshot of tablet UX on beagle (apr 2011)
= Related links =
= Related links =

Latest revision as of 10:25, 12 April 2012

May 31st 2011: The instructions on this page don't work anymore!

These instructions require the integration of closed third party code into MeeGo to enable the video acceleration required for a decent MeeGo user experience. Recently, MeeGo for the arm CPU (MeeGo/ARM) has switched to hardware floating point support (hardfp/armv7hl). This needs to be explicitly supported by all code supposed to be used on MeeGo/ARM. The previous software floating point based setup (armv7l) is not officially supported by MeeGo anymore.

Unfortunately, all closed source drivers incl. the SGX video acceleration drivers provided by TI for the beagle board are not available with hardfp/armv7hl support. This fact breaks the beagle board setup presented here and probably also all other arm based meego ports. Currently, the only exception is the n900, which is supported by nokia with matching closed source drivers.


This document describes how to create a MeeGo image for the beagleboard. More information regarding MeeGo on the Beagleboard can be found at ARM/Meego_on_the_Beagle.

Contents

News

  • The set of supported UX now includes the tablet UX (See, for example, #Screenshots).
  • We now provide ready-to-run SD card images here

(For details read #Prepared_images).

Introduction

[Youtube video of BeagleBoard running MeeGo handset UX]

Tested distros

Creating this image has been tested on Ubuntu 10.10. Other distros may require some things to be done differently. Several people have tried and failed to make this work on Ubuntu 9.04 and Ubuntu 9.10. Ubuntu 10.04 requires some tweaks when installing the cross compilers. It is recommended to use Ubuntu 10.10, if you want the best chance of success. Conversely, if you have made this work for other versions of Ubuntu or other distros, please add to this page any information that will help others achieve the same success.

  • Debian Lenny (you'll need to install some packages from Sid and you'll need to build some software.)

This is a work in progress. However, if you think these instructions are incomplete or lack some important aspect, feel free to edit this page or ask for help on IRC in #meego-arm on irc.freenode.net.

What works, what remains to be done

Please keep in mind that MeeGo is a work in progress. Things which already worked may be broken again and you might not end up with a working setup even though you followed the instructions precisely. Everything up to the running TI demos will likely be stable, but the MeeGo UI itself is still broken every now and then.

Working:

  • Same features as MeeGo on n900
  • MeeGo UX with touchscreen and 800x480 video
  • 2D/3D video acceleration
  • Audio
  • Various USB add-ons incl. ethernet, mass-storage and bluetooth
  • Setup toolchain known working on Ubuntu 10.04/10.10
  • Support for handset, IVI and tablet UX

Todo:

  • Make mouse cursor visible under handset and tablet UX for users without touchscreen
  • Definitive works / does not work on other distros and other versions

Known issues:

  • Bug #5616
  • Bug #14480
  • All known n900 problems probably still apply (unless they are related to the n900 specific kernel/video drivers)

Supported BeagleBoard versions

The RevA and RevB boards have only 128 MB RAM. This is not enough for the handset distribution of MeeGo. With swap enabled the UX boots, but is barely usable. Tested board revisions: B7

The RevC boards are the best choice at this moment, as their hardware is fully supported by the Linux kernel and since their 256 MB RAM allow for a more fluid UX experience. Tested board revisions: C3, C4

The XM RevA boots into handset UX and is very fast and responsive. The stock kernel doesn't yet fully support this board (CPU only runs at 800 Mhz) and, most important, the USB hub doesn't work under the MeeGo kernel. Tested board revisions: XM-A2

The only board currently fully supported is the BeagleBoard RevC!

Prepared images

Ready-to-run SD card images can be found on bug10738. These images can be copied directly onto a 2 GB SD card:

dd if=<image name> of=/dev/<sd card device> bs=64k

It is possible that your SD card is slighty smaller than these images. In this case you can, for example, use fdisk to adjust the size of the 512 MB swap partition on the card and, afterwards, use mkswap to reformat that partition.

The root password for this image is "meego" as usual.

Prerequisites

This document assumes that you have worked with the beagleboard before and it may be helpful if you, for example, know how to format a memory card to boot from.

If you are new to BeagleBoard, you might want to learn the basics using the following resources:

The following instructions assume that your beagleboard boots from sd card. Xloader and uboot versions stored in beagleboard internal nand memory might prevent the following setup from working properly. If a bootloader is installed, you'll usually get its command prompt on the serial console when booting, without an sd card inserted. Entering

nand erase

there will erase the entire nand memory and reset the beagleboard into the state expected in the following instructions. Warning: Other beagleboard sd cards you might be using may rely on certain parts being stored in nand and might not work afterwards.

Please use a memory card of at least 2 GB size for the following experiments. Otherwise, the generated image may not fit onto the card.

Building MeeGo for the BeagleBoard

The beagleboard sd card image generation consists of three major steps:

  • Build of kernel and kernel modules
  • Assembly of root file system
  • Installation of bootloader, kernel and root file system on sd card

Shell scripts have been created to automate all of these steps as much as possible. You can get all necessary files here. These steps will require about 4 GB of additional free disk space.

  • build_kernel.sh build the kernel and the modules,
  • build_image.sh assembles the root file system, and
  • setup_sdcard.sh creates an sd card from these

Build of kernel and kernel modules

To build the kernel and its modules, you'll need to cross compile for the ARM platform. The most convenient option under Ubuntu is to install the arm cross compiler that comes with ubuntu:

sudo apt-get install gcc-4.5-arm-linux-gnueabi

The kernel used in this project is not the MeeGo kernel (which doesn't include any beagleboard specific patches) but a port of the ubuntu kernel which is being maintained especially for the beagleboard and related boards.

You can get the build scripts from https://launchpad.net/~beagleboard-kernel. Follow the instructions there to build a Ubuntu kernel. There are only two MeeGo specific things:

  • Set the CPUFreq governor to "userspace"
  • Add support for a 800x480 video mode

The CPUFreq governor can be adjusted in the kernel config dialog that will automatically open when you run the build_kernel.sh script from the 2.6.38-devel package. You need to set

CPU Power Management --> Default CPUFreq governor (ondemand)  ---> userspace

The 2.6.38-devel package allows for local patch directory which can be specified in the system.sh file. Just place the 800x480.patch there and it will automatically be included into the resulting kernel.

You should end up with a uImage and modules tarball in 2.6.28-devel/deploy.

Setup for Ubuntu 10.04 LTS Lucid Lynx

The gnueabi cross compiler is not available by default on the Lucid Lynx distribution. But you can get access to it using either the natty or maverick universe repositories (just be careful to disable them when you are done getting what you need).

Add the following line to your /etc/apt/sources.list. Or use the Synaptic package manager (sudo synaptic, Settings->Repositories, Other Software->Add). You may choose your own mirror if xmission is slow or doesn't work for you.

deb http://mirrors.xmission.com/ubuntu/ maverick main universe >> /etc/apt/sources.list

Do an update (hit Reload in synaptic or sudo apt-get update) and then install the gnueabi cross compiler + a few other programs that might be missing:

sudo apt-get install gcc-4.5-arm-linux-gnueabi rpm2cpio uboot-mkimage

Assembly of the root file system

The root file system (rootfs) is assembled from binary packages available in the MeeGo ARM repositories. The tool used to assemble the rootfs is called mic (MeeGo image creator). You need at least mic version 0.24.6 and you might have to grab the latest version from git following the instructions at Image_Creation#From_Development_Git_Tree.

When using ubuntu 10.04/10.10 you'll need to install qemu using the qemu-kvm-extras-static package. If you have an existing scratchbox setup, this will collide with qemu-kvm-extras-static. After installing that package scratchbox arm will not work anymore. Removing that package and restarting the scratchbox services makes scratchbox work again.

The rootfs image creation itself is started using the build_image.sh script the following way:

sudo ./build_image.sh

This will download all packages required to build the root file system from the internet into the ./mycachedir directory and assemble the root file system image.

If you need to save hard disk space, you can remove the ../mycachedir directory once the image has successfully been built.

If you want to build an ivi or tablet images, instead use

sudo TYPE=ivi ./build_image.sh

or

sudo TYPE=tablet ./build_image.sh

Installation on sd card

The last step is to put the kernel and the rootfs onto an sd card together with an xloader and uboot boot loader, as required to boot the beagleboard. This is accomplished by invoking the setup_sdcard.sh shell script. This script has to be given the device name of the sd card you are intending to use. On my system, the sd card is /dev/sdd, so i have to invoke the script as follows:

./setup_sdcard.sh --mmc /dev/sdd

The script will ask you to acknowledge this. Please watch the output carefully. Specifying, for example, your system's hard drive will wipe your entire hard disk, instead of the sd card.

This will take some time as the sd card is reformatted, all bootloaders are installed, file systems are created and the kernel and the contents of the root file system are copied onto the sd card.

Again, if you intend to use the IVI or tablet image, use a slightly modified command:

TYPE=ivi ./setup_sdcard.sh --mmc /dev/sdd

or

TYPE=tablet ./setup_sdcard.sh --mmc /dev/sdd

Boot

Plug the resulting SD card into your beagleboard and power on. After a few seconds, the video will switch to 800x480 pixels and the MeeGo handset UX should appear on the screen. The first boot will always take several minutes, as some media files are copied forth and back on the card.

Meego beagle.jpg

Peripheral hardware

I have tested various peripheral devices on this setup and most of them are working out of the box.

USB hubs, mice and keyboards

These just work, nothing to configure.

Bluetooth keyboard

A CSR bluetooth dongle works out of the box. Hcitool is present to scan for devices, as well as hidd to connect to bluetooth HID devices. This has been tested with a bluetooth keyboard.

Touchscreen

A 7 inch egalax based touchscreen worked nearly perfectly out of the box. It was just a little bit mis-calibrated.

The latest hal driven xorg can be given a input configuration file to deal with this.An example setup is already included at /etc/X11/xorg.conf.d/50-input-touch.conf. If you don't have a touchscreen this file is ignored.

This configuration is automatically applied to all touchscreen devices that map to /dev/input/event*. You may have to adjust the calibration values in that file to match your device.

Ethernet

A D-Link DUB-E100 ethernet dongle works out of the box and gets an IP address via DHCP. With this network connection, I was able to verify that zypper and the package management work, also. A "zypper up" successfully updated a few packages.

The beagleboard XM's onboard Ethernet (a SMSC95xx based USB device) works, also.

WLAN

A Ralink RT2501 based USB dongle works, is detected and can scan for networks. But it isn't provided an address via dhcp.

Audio

Audio works out of the box. Appropriate configuration files for the beagleboard have been included.

Troubleshooting/hints

Starting X programs from the serial console

If you have a keyboard and mouse you can skip this section. If you don't have a keyboard connected and want to run X programs from the console, you need to set the DISPLAY environment variable. Also, it's required to change to the meego user before doing so:

[root@localhost ~]# su meego
[meego@localhost root]$ export DISPLAY=:0
[meego@localhost root]$ xeyes

Making screenshots

Do you like what you see? Want to share it? Make a screenshot! This doesn't need any special software. Just copy the framebuffer contents into some file:

cp /dev/fb0 screenshot.raw

The resulting file should have a size of exactly 770048 bytes (800x480x2) if you are using a 800x480 display size at 16 bits per pixel.

On your host use ffmpeg to convert this into some standard format like png:

ffmpeg -vcodec rawvideo -f rawvideo -pix_fmt rgb565 -s 800x480 -i screenshot.raw -f image2 -vcodec png screenshot.png

Beagle-Main.jpg

Screenshot of an early handset UX on beagle (jul 2010)

Beagle-Ivi.png

Screenshot of IVI UX on beagle (nov 2010)

Beagle-Tablet.png

Screenshot of tablet UX on beagle (apr 2011)

Related links

Personal tools