DART Ubuntu GS: Difference between revisions

From Variscite Wiki
(Created page with "=OMAP4DART - Ubuntu Precise = __toc__ == Introduction == Below instructions corresponds to <span style="color: rgb(255, 0, 0);">Ubuntu_12.04-DART.VAR10</span> release.&...")
 
No edit summary
Line 1: Line 1:
=OMAP4DART - Ubuntu Precise =
=OMAP4DART - Ubuntu Precise =
__toc__
__toc__
== Introduction  ==
= Introduction  =


Below instructions corresponds to&nbsp;<span style="color: rgb(255, 0, 0);">Ubuntu_12.04-DART.VAR10</span> release.&nbsp;  
Below instructions corresponds to&nbsp;<span style="color: rgb(255, 0, 0);">Ubuntu_12.04-DART.VAR10</span> release.&nbsp;  
Line 13: Line 13:
You must use Ubuntu 12.04LTS workstation as your build system.  
You must use Ubuntu 12.04LTS workstation as your build system.  


== Install Ubuntu on eMMC<br>  ==
= Install Ubuntu on eMMC<br>  =


OMAP4 DART board includes an on-SOM 4G eMMC which is the default boot device.  
OMAP4 DART board includes an on-SOM 4G eMMC which is the default boot device.  
Line 37: Line 37:
$&nbsp;sudo /root/eMMC/emmc-flasher.sh
$&nbsp;sudo /root/eMMC/emmc-flasher.sh
</pre>  
</pre>  
== Build Ubuntu Kernel from sources  ==
= Build Ubuntu Kernel from sources  =


To retrieving the kernel sources use git:  
To retrieving the kernel sources use git:  
Line 74: Line 74:
Note: After compiling and installing new debian packages, rename uImage and uInitrd in /dev/sdX1 to uImage.var and uInitrd.var  
Note: After compiling and installing new debian packages, rename uImage and uInitrd in /dev/sdX1 to uImage.var and uInitrd.var  


== Build U-Boot from sources  ==
= Build U-Boot from sources  =


To retrieve the U-Boot sources use git:  
To retrieve the U-Boot sources use git:  
Line 92: Line 92:
$ make ARCH=arm CROSS_COMPILE=arm-none-linux-gnueabi- omap4_dart_board_sd # boot from external SD card
$ make ARCH=arm CROSS_COMPILE=arm-none-linux-gnueabi- omap4_dart_board_sd # boot from external SD card
</pre>  
</pre>  
== Apply your kernel<br>  ==
= Apply your kernel<br>  =


On the target.<br>  
On the target.<br>  
Line 113: Line 113:
Reboot your target to get new kernel changes.  
Reboot your target to get new kernel changes.  


== Install U-Boot on eMMC  ==
= Install U-Boot on eMMC  =


<span style="line-height: 1.5em;">Flash images to the eMMC device:</span>  
<span style="line-height: 1.5em;">Flash images to the eMMC device:</span>  
<pre>$ dd if=MLO of=/dev/mmcblk0 seek=131072 bs=1
<pre>$ dd if=MLO of=/dev/mmcblk0 seek=131072 bs=1
$ dd if=u-boot.img of=/dev/mmcblk0 seek=393216 bs=1</pre>
$ dd if=u-boot.img of=/dev/mmcblk0 seek=393216 bs=1</pre>

Revision as of 11:19, 14 January 2014

OMAP4DART - Ubuntu Precise

Introduction

Below instructions corresponds to Ubuntu_12.04-DART.VAR10 release. 

Variscite supports its OMAP4 DART4460 with TI Ubuntu Linux kernel and Ubuntu Precise (12.04) distribution.

The Linux kernel provides support for all on-board peripherals.

Your Ubuntu folder in the FTP contains ready-to-run pre-built image which contain:Kernel, U-boot, Xloader and Ubuntu File system.

You must use Ubuntu 12.04LTS workstation as your build system.

Install Ubuntu on eMMC

OMAP4 DART board includes an on-SOM 4G eMMC which is the default boot device.

To burn the eMMC for the first time you need to boot from the external SD card and burn the eMMC from Linux shell.

To install Ubuntu on external SD card plug microSD card to your Linux host machine, run dmesg and see what device is added (for example:  /dev/sdX, /dev/mmcblk0).

You can identify your device name by using dmesg and looking at the end of the system log.

Install the pre-build Ubuntu image on the SD card.

$ gunzip Ubuntu_12.04_core-DART-EVM.VAR10.img.gz
$ dd if=Ubuntu_12.04_core-DART-EVM.VAR10.img of=/dev/sdX bs=128k

Plug the microSD to DART MMC port, press and hold the boot select button and power on the DART board.

This will boot Ubuntu from extrnal SD card.

login: username: variscite, password: password

To burn eMMC

$ umount /dev/mmcblk0p2 /dev/mmcblk0p1
$ sudo /root/eMMC/emmc-flasher.sh

Build Ubuntu Kernel from sources

To retrieving the kernel sources use git:

$ git clone git://dev.omapzoom.org/pub/scm/integration/kernel-ubuntu.git
$ cd kernel-ubuntu 
$ git checkout -b working d8a13c28e3ddc1f7cb098823b883dbc6a02bcb43

To apply Variscite kernel patch:

$ git apply omap4dart-ubuntu-12.04.TI_GLP168-VAR9-armhf-omap4.patch

Install tools:

$ sudo apt-get install gcc-arm-linux-gnueabihf cpp-arm-linux-gnueabihf
$ sudo apt-get build-dep linux-image-$(uname -r)
$ sudo apt-get install dpkg-dev kernel-wedge

Set tools enviroment variables:

$ export ARCH=arm
$ export CROSS_COMPILE=arm-linux-gnueabihf-

Make changes to the kernel (optional):

$ fakeroot debian/rules clean
$ fakeroot debian/rules editconfigs

Build the kernel and generate a kernel package:

$ fakeroot debian/rules clean
$ do_tools=false skipabi=true skipmodule=true dpkg-buildpackage -B -aarmhf -uc -us

You should have in the directory above the kernel-ubuntu 3 .deb pacakges.

For example:

linux-headers-3.4.0-1489_3.4.0-1489.28_armhf.deb
linux-headers-3.4.0-1489-omap4_3.4.0-1489.28_armhf.deb
linux-image-3.4.0-1489-omap4_3.4.0-1489.28_armhf.deb


Note: After compiling and installing new debian packages, rename uImage and uInitrd in /dev/sdX1 to uImage.var and uInitrd.var

Build U-Boot from sources

To retrieve the U-Boot sources use git:

$ git clone git://git.linaro.org/boot/u-boot-linaro-stable.git
$ cd u-boot-linaro-stable
$ git checkout -b working 5b752a1e0528aa29f5bd4cde0905c8b604c56255

To apply Variscite U-Boot patch:

git apply omap4dart-u-boot-linaro-VAR10.patch

To build U-Boot sources(OMAP4 DART EVM):

$ make ARCH=arm CROSS_COMPILE=arm-none-linux-gnueabi- omap4_dart_evm    # boot from eMMC
$ make ARCH=arm CROSS_COMPILE=arm-none-linux-gnueabi- omap4_dart_evm_sd # boot from external SD card

To build U-Boot sources(OMAP4 DART Board):

$ make ARCH=arm CROSS_COMPILE=arm-none-linux-gnueabi- omap4_dart_board    # boot from eMMC
$ make ARCH=arm CROSS_COMPILE=arm-none-linux-gnueabi- omap4_dart_board_sd # boot from external SD card

Apply your kernel

On the target.

make sure your are connected to the network with lan or wireless lan. Use ifconfig for that.
Copy files from your build system:

$ cd ~/var-som-om44.deb/
$ scp <yourname>@<your build system ip>:<your build folder>/*.deb ./

Unmount your boot partition

sudo umount /dev/mmcblk0p1

Install Debian pacakges:

sudo dpkg -i *3.4.0-1489.28_armhf.deb

Rename the images name

$ sudo mv /media/emmcboot/uInitrd /media/emmcbootbbb/uInitrd.var
$ sudo mv /media/emmcboot/uImage /media/emmcboot/uImage.var
$ sync

Reboot your target to get new kernel changes.

Install U-Boot on eMMC

Flash images to the eMMC device:

$ dd if=MLO of=/dev/mmcblk0 seek=131072 bs=1
$ dd if=u-boot.img of=/dev/mmcblk0 seek=393216 bs=1