'[C-03] AT91SAM9260'에 해당되는 글 11건

  1. 2009.11.16 Linux4SAM - BuildRoot
  2. 2009.11.16 Linux4SAM - OpenEmbedded / Angstrom
  3. 2009.11.16 Linux4SAM - Linux Kernel
  4. 2009.11.15 Linux4SAM - U-Boot
  5. 2009.11.15 Linux4SAM - AT91Bootstrap
  6. 2009.11.15 Linux4SAM - Software Tools
  7. 2009.11.14 Linux4SAM - Getting Started
  8. 2009.11.10 AT91SAM Community
  9. 2009.11.10 KEIL ARM의 AT91SAM9260 Device Database site
  10. 2009.11.10 Free LinuxLink Trial
  11. 2009.10.24 AT91SAM9260

BuildRoot

Introduction

Buildroot is a configurable Makefile which downloads, configures, and builds cross compilers, the kernel, busybox, and most of the other stuff needed for a simple, small complete linux distribution and root file system based on uClibc C library.
Buildroot는 configurable Makefile이다. 그것은 download, configure  그리고 cross compiler, kernel, busybox 그리고 간단하고 작은 linux 배포판과 uClibc C library 기반의 root file system을 위해 필요한 요소를 build 할 수 있게 한다.

It uses the Linux KConfig configuration system, allowing easy selection of root fs contents. The Makefile will include the ".config" file generated by KConfig, and the contents of this file will determine what should be built, and which version should be used.
그것은  Linux KConfig configuration system을 사용하며 쉽게 root fs내용을 선택을 할 수 있다. Makefile은 KConfig에 의해 발생되는 ".config" 파일을 포함할 것이다. 그리고 이 파일의 내용은 구축되어야 하는것과, 그 버전이 사용되야만 하는 것을 결정한다.

It is relatively easy to go from there to adding your own programs and such to it so your entire build process is automated.
자신의 program을 추가하고 전체 build process를 자동화하는 것은 상대적을 쉽다.

Home website : http://buildroot.uclibc.org/

Buildroot - Usage and documentation can help you better understand how buildroot works.
Buildroot - Usage and documentation은 buildroot 작업 방법을 쉽게 이해하게 도와준다.

Buildroot will NOT run on Cygwin. You need a proper Linux installation. If you have Windows, you should consider installing a Virtual Machine allowing you to run Linux on top of Windows. We tested buildroot on Fedora 9/10, Debian GNU/Linux 4.0r5.
Buildroot는 Cygwin에서 동작하지 않는다. 적당한 Linux installation이 필요하다. Windows를 사용한다면 Virtual Machine을 installing하는 것을 고려해봐야 한다. 우리는 Fedora 9/10, Debian GNU/Linux 4.0r5 에서 buildroot를 test했다.

Currently the Buildroot for AT91 can build
현재 AT91을 위한 buildroot는 다음을 build 할 수 있다.

  • Cross-compiler
  • Root file systems of different types

It will take 3-4 hours to build the whole system on a P4-3.6 GHz.
P4-3.6 GHz에서 전체 system을 build하기 위해서는 3-4시간을 소요한다.


r17 - 03 Feb 2009 - 16:55:13 - NicolasFerre





'[C-03] AT91SAM9260' 카테고리의 다른 글

Linux4SAM - OpenEmbedded / Angstrom  (0) 2009.11.16
Linux4SAM - Linux Kernel  (0) 2009.11.16
Linux4SAM - U-Boot  (0) 2009.11.15
Linux4SAM - AT91Bootstrap  (0) 2009.11.15
Linux4SAM - Software Tools  (0) 2009.11.15
Posted by eoseontaek

OpenEmbedded / Angstrom

Introduction

OpenEmbedded is a powerful building environment. Angstrom uses this environment to bring up a whole embedded Linux distribution. The support for our AT91 products has been added permitting to offer a root file system with a wide range of applications.
OpenEmbedded 는 powerful한 building environment이다. Angstrom은 전체 embedded Linux 배포판을 배포하기 위해 이 환경을 사용한다. 우리의 AT91 제품군을 위해 제공되는 것은 광범위한 application에 root file system을 제공하기 위해 허용되는 것을 추가하는 것이다.

Binary images for both graphical and non graphical uses are provided to allow a quick overview. Once you have a basic root file system up an running, the package system allow you to fit application set to your need through an application feed.
graphical하거나 non graphical uses를 위한 binary image 모두 다 quick overview가 제공된다. 기본적인 root file system을 running 할 때, package system은 application feed를 통해 fit application set to your need를 제공한다.

This page will guide you through the comprehensive OpenEmbedded & Angstrom documentation without duplicating information. All you will need to use and build such material is available in those project websites. The golden links are listed below. 
이 페이지는 중복되는 정보없이 포괄적인 OpenEmbedded & Angstrom documentation를 통해 가이드의 역할을 한다.  그러한 자료들을 사용하고 build하기 위해 필요한 모든 것들은 이 project websites에서 사용할 수 있다. goledn link는 아래 정렬되어 있다.
  
 

OpenEmbedded & Angstrom golden links

Those websites will be referenced all along this page and are valuables resources for entering this environment.
이 웹사이트들은 이 페이지에 까라 모두 참조될 것이고 이 환경에 들어가기 위한 좋은 resource가 된다.


 

OpenEmbedded / Angstrom hands on

Get it

Use it

Build it


'[C-03] AT91SAM9260' 카테고리의 다른 글

Linux4SAM - BuildRoot  (0) 2009.11.16
Linux4SAM - Linux Kernel  (0) 2009.11.16
Linux4SAM - U-Boot  (0) 2009.11.15
Linux4SAM - AT91Bootstrap  (0) 2009.11.15
Linux4SAM - Software Tools  (0) 2009.11.15
Posted by eoseontaek

Linux Kernel

Ecosystem

Linux Kernel Archives is the primary site for the Linux kernel source. All Linux kernel versions, including latest snapshot or "release candidate" (-rc) can be easily found here.
Linux Kernel Archives는 Linux kernel source를 위한 primary site이다. 최신 snapshot 또는 "release candidate"(-rc)을 포함하는 모드 Linux kernel version은 여기서 쉽게 찾을 수 있다.

The ARM Linux Project lead by Russell King. Russell is in charge to ensure the ARM core support in the Kernel mainline and to integrate ARM based system on chip specific patch sets. Specific ARM Linux discussion groups, patches and information are also available.
The ARM Linux Project는 Russell King에 의해 지휘된다. Russell은 Kernel mainline에서 제공하는 ARM core를 보증하는 것과  chip에 특정화된 patch set에서 ARM based system을 통합하는 것을 담당한다.

You will find on ARM Linux website :
ARM Linux 웹사이트에서 아래 내용을 찾을 수 있다.

AT91 linux 2.6 patches maintained by Andrew Victor. Andrew is the official Linux kernel maintainer for AT91 machines. You can find patches against official Linux kernel releases and driver development status. All AT91 patches should be sent to Andrew except if it exists a specific development branch like SD/MMC, ALSA, netdev, etc...
AT91 linux 2.6 patches는 Andrew Victor에 의해 유지된다. Andrew는 AT91 machine을 위한 공식적인  Linux kernel  maintainer이다. 공식적인 Linux kernel release와 driver development status에 대한 patch를 찾을 수 있다. 모든 AT91의 patch는 Andrew 에게 보내져야 한다.

The provided patches, on this wiki, are always against the official kernel release and Andrew's patches. 
이 wiki에서 제공되는 patch는 공신적인 kernel release와 Andrew의 patch에  대한 것이다.
 

Pre-built images

2.6.30 (2.6.30-at91-exp.patch)
Board Description Binary Configuration file
at91sam9260ek linux-2.6.30 uImage linux-2.6.30-at91-exp-at91sam9260ek.bin at91sam9260ek_defconfig
at91sam9xeek linux-2.6.30 uImage linux-2.6.30-at91-exp-at91sam9xeek.bin at91sam9xeek_defconfig
at91sam9261ek linux-2.6.30 uImage linux-2.6.30-at91-exp-at91sam9261ek.bin at91sam9261ek_defconfig
at91sam9263ek linux-2.6.30 uImage linux-2.6.30-at91-exp-at91sam9263ek.bin at91sam9263ek_defconfig
at91sam9rlek linux-2.6.30 uImage linux-2.6.30-at91-exp-at91sam9rlek.bin at91sam9rlek_defconfig
at91sam9g20ek linux-2.6.30 uImage linux-2.6.30-at91-exp-at91sam9g20ek.bin at91sam9g20ek_defconfig
at91sam9g20ek_2mmc linux-2.6.30 uImage linux-2.6.30-at91-exp-at91sam9g20ek_2mmc.bin at91sam9g20ek_2mmc_defconfig
at91sam9g10ek linux-2.6.30 uImage linux-2.6.30-at91-exp-at91sam9g10ek.bin at91sam9g10ek_defconfig
at91sam9g45ekes linux-2.6.30 uImage linux-2.6.30-at91-exp-at91sam9g45ekes.bin at91sam9g45ekes_defconfig
2.6.27 (2.6.27-at91-exp.3.patch)
Board Description Binary Configuration file
at91sam9260ek linux-2.6.27 uImage linux-2.6.27-at91-exp.3-at91sam9260ek.bin at91sam9260ek_defconfig
at91sam9xeek linux-2.6.27 uImage linux-2.6.27-at91-exp.3-at91sam9xeek.bin at91sam9xeek_defconfig
at91sam9261ek linux-2.6.27 uImage linux-2.6.27-at91-exp.3-at91sam9261ek.bin at91sam9261ek_defconfig
at91sam9263ek linux-2.6.27 uImage linux-2.6.27-at91-exp.3-at91sam9263ek.bin at91sam9263ek_defconfig
at91sam9rlek linux-2.6.27 uImage linux-2.6.27-at91-exp.3-at91sam9rlek.bin at91sam9rlek_defconfig
at91sam9g20ek linux-2.6.27 uImage linux-2.6.27-at91-exp.3-at91sam9g20ek.bin at91sam9g20ek_defconfig
at91sam9g20ek_2mmc linux-2.6.27 uImage linux-2.6.27-at91-exp.3-at91sam9g20ek_2mmc.bin at91sam9g20ek_2mmc_defconfig
at91sam9g10ek linux-2.6.27 uImage linux-2.6.27-at91-exp.3-at91sam9g10ek.bin at91sam9g10ek_defconfig
at91sam9g45ekes linux-2.6.27 uImage linux-2.6.27-at91-exp.3-at91sam9g45ekes.bin at91sam9g45ekes_defconfig
2.6.27 (2.6.27-at91-exp.2.patch)
Board Description Binary Configuration file
at91sam9260ek linux-2.6.27 uImage linux-2.6.27-at91-exp.2-at91sam9260ek.bin at91sam9260ek_defconfig
at91sam9xeek linux-2.6.27 uImage linux-2.6.27-at91-exp.2-at91sam9xeek.bin at91sam9xeek_defconfig
at91sam9261ek linux-2.6.27 uImage linux-2.6.27-at91-exp.2-at91sam9261ek.bin at91sam9261ek_defconfig
at91sam9263ek linux-2.6.27 uImage linux-2.6.27-at91-exp.2-at91sam9263ek.bin at91sam9263ek_defconfig
at91sam9rlek linux-2.6.27 uImage linux-2.6.27-at91-exp.2-at91sam9rlek.bin at91sam9rlek_defconfig
at91sam9g20ek linux-2.6.27 uImage linux-2.6.27-at91-exp.2-at91sam9g20ek.bin at91sam9g20ek_defconfig
at91sam9g10ek linux-2.6.27 uImage linux-2.6.27-at91-exp.2-at91sam9g10ek.bin at91sam9g10ek_defconfig
at91sam9g45ekes linux-2.6.27 uImage linux-2.6.27-at91-exp.2-at91sam9g45ekes.bin at91sam9g45ekes_defconfig
2.6.27 (2.6.27-at91-exp.patch)
Board Description Binary Configuration file
at91sam9260ek linux-2.6.27 uImage linux-2.6.27-at91-exp-at91sam9260ek.bin at91sam9260ek_defconfig
at91sam9xeek linux-2.6.27 uImage linux-2.6.27-at91-exp-at91sam9xeek.bin at91sam9xeek_defconfig
at91sam9261ek linux-2.6.27 uImage linux-2.6.27-at91-exp-at91sam9261ek.bin at91sam9261ek_defconfig
at91sam9263ek linux-2.6.27 uImage linux-2.6.27-at91-exp-at91sam9263ek.bin at91sam9263ek_defconfig
at91sam9rlek linux-2.6.27 uImage linux-2.6.27-at91-exp-at91sam9rlek.bin at91sam9rlek_defconfig
at91sam9g20ek linux-2.6.27 uImage linux-2.6.27-at91-exp-at91sam9g20ek.bin at91sam9g20ek_defconfig
2.6.24 (2.6.24.at91.2-exp.patch)
Board Description Binary Configuration file
at91sam9260ek linux-2.6.24 uImage linux-2.6.24.at91.2-at91sam9260ek.bin at91sam9260ek_defconfig
at91sam9xeek linux-2.6.24 uImage linux-2.6.24.at91.2-at91sam9xeek.bin at91sam9xeek_defconfig
at91sam9261ek linux-2.6.24 uImage linux-2.6.24.at91.2-at91sam9261ek.bin at91sam9261ek_defconfig
at91sam9263ek linux-2.6.24 uImage linux-2.6.24.at91.2-at91sam9263ek.bin at91sam9263ek_defconfig
at91sam9rlek linux-2.6.24 uImage linux-2.6.24.at91.2-at91sam9rlek.bin at91sam9rlek_defconfig
2.6.24 (2.6.24-at91-exp.patch)
Board Description Binary Configuration file
at91sam9260ek linux-2.6.24 uImage linux-2.6.24-at91sam9260ek.bin at91sam9260ek_defconfig
at91sam9xeek linux-2.6.24 uImage linux-2.6.24-at91sam9xeek.bin at91sam9xeek_defconfig
at91sam9261ek linux-2.6.24 uImage linux-2.6.24-at91sam9261ek.bin at91sam9261ek_defconfig
at91sam9263ek linux-2.6.24 uImage linux-2.6.24-at91sam9263ek.bin at91sam9263ek_defconfig
at91sam9rlek linux-2.6.24 uImage linux-2.6.24-at91sam9rlek.bin at91sam9rlek_defconfig
2.6.22
Board Description Binary Configuration file
at91sam9260ek linux-2.6.22 uImage linux-2.6.22-at91sam9260ek.bin at91sam9260ek_defconfig
at91sam9xeek linux-2.6.22 uImage linux-2.6.22-at91sam9xeek.bin at91sam9xeek_defconfig
at91sam9261ek linux-2.6.22 uImage linux-2.6.22-at91sam9261ek.bin at91sam9261ek_defconfig
at91sam9263ek linux-2.6.22 uImage linux-2.6.22-at91sam9263ek.bin at91sam9263ek_defconfig

Pre-built images are delivered into uImage U-Boot format. To download them on AT91 boards, see the section How to load Linux kernel with U-Boot in the U-Boot page.
Pre-built image는 uImgae U-Boot format으로 인도된다. AT91 보드에 download하기 위해 U-Boot page에서 How to load Linux kernel with U-Boot section을 보아라.

Linux4SAM Experimental Patches

The experimental AT91 patch set is built and contributed by people from the AT91 Linux community. These patches are against Andrew Victor patches. They contain unpublished or not yet included piece of code or driver.
실험적인 AT91 patch set은 AT91 Linux community로부터 사람들에 의해 built 되고 기부되었다. 이 patch들은 Andrew Victor patches에 대한 것이다.  그것들은 공개되지 않았거나 아직 code나 driver의 included 되지 않은 것을 포함한다.

2.6.30-at91-exp.patch

  • basically all support provided by previous 2.6.27-at91-exp patch
  • in comparison to previous experimental patch remove HW ECC and ISI driver (need rework)
  • updated LCD pixel clock for AT91SAM9G45 non ES parts
  • several gpio buttons, SD card detect and led support for AT91SAM9G20EK, AT91SAM9G20EK-2MMC and AT91SAM9RLEK
  • Linux kernel default configuration updated for all products (*_defconfig files)
  • update of the sound/soc directory from Linux 2.6.32-rc3 to update this part of ALSA to 1.0.21

2.6.27-at91-exp.3.patch

  • add support for AT91SAM9G20EK with dual SD/MMC slot
  • change default configuration for the use of 128MB of RAM on AT91SAM9G45EKES
  • All 2.6.27-at91-exp.2.patch enhancements included (see below)

2.6.27-at91-exp.2.patch

  • add support for new AT91SAM9G10 chip and AT91SAM9G10EK board
  • add support for new AT91SAM9G45 chip and AT91SAM9G45EKES board
  • ISI driver for AT91SAM9G45 & AT91SAM9263 (use OV9655 camera sensor)
  • DMA driver at_hdmac for AT91SAM9RL & AT91SAM9G45
  • atmel_mci MCI driver adaptation for DMA usage on AT91SAM9G45
  • USB high speed drivers for AT91SAM9G45 (both host and gadget)
  • atmel_lcd fix wrong FIFO size for some products
  • All 2.6.27-at91-exp.patch enhancements included (see below)

2.6.27-at91-exp.patch

  • AT91SAM9G20EK - add audio support
  • merge AT32 and AT91 ssc DAI (Digital Audio Interface)
  • AC97 playback and capture driver
  • DMA engine driver on AT91SAM9RL
  • AT91SAM9RLEK - fix touchscreen
  • LED - on AT91SAM9RLEK
  • AT91_MCI - fixes
  • ATMEL_MACB - Add SRAM Tx buffers capabilities for AT91SAM926[03]EK
  • ATMEL_LCD - fixes & RGB 555 wiring mode
  • new NandFlash partitioning
  • buttons (on AT91SAM9RLEK and AT91SAM9G20EK)
  • hardware ECC on NandFlash for AT91SAM9G20

2.6.24.at91.2-exp.patch

  • fix NandFlash timings
  • new NandFlash partitioning
  • atmel_lcd manage underflow error
  • pwm_led driver
  • buttons (& pullups conf.)

2.6.24-at91-exp.patch

  • Fix some typos on SSC, RTC
  • Enhancement in support for AT91SAM9RL : LCD fifo, USB HS, buttons, leds, AC97
  • Note that the touchscreen is not supported yet on AT91SAM9RL
  • LCD wiring mode : BGR or RGB selection
  • backlight for LCD panel
  • Power management support

2.6.22-at91-exp.patch

  • AT91SAM9261EK - Add button interface
  • AT91_MCI - Enhancements 1
  • ATMEL_LCD - Add STN and alpha in 32bpp mode support
  • AT91SAM9261Ek - Make NAND FLASH partition match those on AT91SAM926[03]EK
  • ATMEL_MACB - Add SRAM Tx buffers capabilities for AT91SAM926[03]EK
  • AT91_AC97 driver for AT91SAM9263EK (playback only)
  • AT73C213 (I2S DAC audio) support for AT91SAM926[01]EK

c Source : check the summary table below (last column).


Build

AT91 Linux kernel sources summary table

Linux Kernel revision Vanilla Linux Kernel AT91 Maintainer patchset Experimental patches
Linux 2.6.30 linux-2.6.30.tar.bz2 2.6.30-at91.patch.gz 2.6.30-at91-exp.tar.gz
Linux 2.6.28 linux-2.6.28.tar.bz2 2.6.28-at91.patch.gz Not ported to this revision
Linux 2.6.27 linux-2.6.27.tar.bz2 2.6.27-at91.patch.gz 2.6.27-at91-exp.3.patch.gz
Linux 2.6.27 linux-2.6.27.tar.bz2 2.6.27-at91.patch.gz 2.6.27-at91-exp.2.patch.gz
Linux 2.6.27 linux-2.6.27.tar.bz2 2.6.27-at91.patch.gz 2.6.27-at91-exp.patch.gz
Linux 2.6.26 linux-2.6.26.tar.bz2 Not ported to this revision Not ported to this revision
Linux 2.6.25 linux-2.6.25.tar.bz2 2.6.25-at91.patch.gz Not ported to this revision
Linux 2.6.24 linux-2.6.24.tar.bz2 2.6.24-at91.patch.gz 2.6.24.at91.2-exp.patch.gz
Linux 2.6.24 linux-2.6.24.tar.bz2 2.6.24-at91.patch.gz 2.6.24-at91-exp.patch.gz
Linux 2.6.23 linux-2.6.23.tar.bz2 2.6.23-at91.patch.gz Not ported to this revision
Linux 2.6.22 linux-2.6.22.tar.bz2 2.6.22-at91.patch.gz 2.6.22-at91-exp.patch.gz 2

hand From left to right, each patch applies on top of the previous source tree.
왼쪽에서 오른쪽으로 각 patch는 이전 source tree의 상단에 적용된다.

For the vanilla Linux kernel, do not forget to use preferably kernel.org mirrors found here : http://www2.kernel.org/mirrors/ 
평범한 Linux kernel을 위해, 되도록이면 kernel.org mirror를 사용하는 것을 잊지 말아라. : http://www2.kernel.org/mirrors/ 

tip We also advice you to use the powerful ketchup tool. You can thus easily get a Linux Kernel without having to consume bandwidth each time you update it.
또한 powerful한 ketchup tool을 사용하기를 권장한다. 쉽게 Linux Kernel을 얻을 수 있다.

Get and patch the Linux kernel

To get an experimental Linux4SAM kernel up and running on an AT91 product, you have to go through the following steps:
실험용 Linux4SAM kernel을 얻고 AT91 제품에 running하기 위해 아래 과정을 수행해야 한다.

    1. identify on which linux kernel revision the experimental patches will apply
    2. download the corresponding Linux kernel

    1.실험용 patch를 적용할 linux kernel revision을 확인한다.
    2. 관련 Linux kernel을 download 한다.

wget http://www.kernel.org/pub/linux/kernel/v2.6/linux-2.6.xx.tar.bz2
tar xvjf linux-2.6.xx.tar.bz2
cd linux-2.6.xx
 
    3. download the AT91 Maintainer's patch and apply it
    3. AT91 Maintainer의 path를 다운로드 하고 그것을 적용한다.
wget http://maxim.org.za/AT91RM9200/2.6/2.6.xx-at91.patch.gz
zcat 2.6.xx-at91.patch.gz | patch -p1
    
    4. take the experimental patchset and apply it on top of the AT91 one
    4. 실험용 patch를 얻고 AT91 제품의 상단에 그것을 적용한다.

before Linux 2.6.30 experimental patches
Download experimental patch:
wget ftp://www.linux4sam.org/pub/linux/2.6.xx-at91-exp.patch.gz
or
wget ftp://www.linux4sam.org/pub/linux/2.6.xx.at91.y/2.6.xx.at91.y-exp.patch.gz
And then:
zcat linux-2.6.xx-at91-exp.diff.gz | patch -p1
Linux 2.6.30 experimental patches and onwards
Download experimental patch archive:
wget ftp://www.linux4sam.org/pub/linux/2.6.xx.at91/2.6.xx-at91-exp.y.tar.gz
Decompress archive with:
tar xvzf 2.6.xx-at91-exp.y.tar.gz
And then apply patchset one patch after the other in proper order:
for p in 2.6.xx-at91-exp.y/*; do patch -p1 < $p ; done

You will now have an updated copy of the experimental Linux4SAM kernel.
실험용 Linux4SAM kernel의 updated copy를 갖게 된다.

Configure and Build the Linux kernel

Now you have to configure the Linux kernel according to your hardware. First identify your kernel revision, your board and then, download the corresponding configuration file. Default configuration files are provided here.
지금  하드웨어에 따라 Linux kernel을 configure 해야 한다. 먼저 kernel revision, 보드를 확인하고 관련 configuration file을 download 한다. default configuration file은 here에서 제공된다.

wget http://www.at91.com/linux4sam/pub/Linux4SAM/LinuxKernel/at91sam926yek_defconfig
cd linux-2.6.xx
cp at91sam926yek_defconfig .config
make ARCH=arm oldconfig 

At this step, you can modify default configuration
이 과정에서 default configuration을 modify할 수 있다.

make ARCH=arm menuconfig 

And build the Linux kernel image
그리고 Linux kernel image를 build한다.

make ARCH=arm  CROSS_COMPILE=<path_to_cross-compiler/cross-compiler-prefix->


Notes

1: at91_mci enhancement with those upstream patches :
- folow flowcharts
- disable handling of blocks with size not multiple of 4 bytes
- bug-in-at91-mci-suspend-routines.patch
- whitespace
- typo
- add multiwrite cap

2: For AT91SAM9XE chips, there is an additional tiny patch that locates TX Ethernet buffers in internal SRAM : adapt_macb_sam9xe.diff


  Attachment Action Size Date Who Comment
else adapt_macb_sam9xe.diff props, move 0.7 K 17 Jan 2008 - 16:24 NicolasFerre 2.6.22 - 9xe update
else at91sam9260ek_defconfig props, move 24.6 K 26 Sep 2007 - 12:44 RfoLnx4sam 2.6.22 - linux4sam_1.0_20070913
else at91sam9261ek_defconfig props, move 25.7 K 27 Sep 2007 - 08:16 RfoLnx4sam 2.6.22 - linux4sam_1.0_20070913
else at91sam9263ek_defconfig props, move 25.5 K 27 Sep 2007 - 08:17 RfoLnx4sam 2.6.22 - linux4sam_1.0_20070913
else at91sam9xeek_defconfig props, move 24.5 K 17 Jan 2008 - 16:23 NicolasFerre 2.6.22
r51 - 12 Nov 2009 - 11:27:34 - NicolasFerre

'[C-03] AT91SAM9260' 카테고리의 다른 글

Linux4SAM - BuildRoot  (0) 2009.11.16
Linux4SAM - OpenEmbedded / Angstrom  (0) 2009.11.16
Linux4SAM - U-Boot  (0) 2009.11.15
Linux4SAM - AT91Bootstrap  (0) 2009.11.15
Linux4SAM - Software Tools  (0) 2009.11.15
Posted by eoseontaek

U-Boot


Introduction

Das U-Boot - the Universal Boot Loader wiki website is the main entry point for this bootloader / debugging tool available on several processors. It is of course available for AT91 ARM processors.
Das U-Boot - the Universal Boot Loader wiki website는 여러 processors에서 사용할 수 있는 bootloader/debugging tool을 위한 main entry point이다. AT91 ARM processor에서도 사용 가능하다.

U-boot documentation is very rich ; in addition to the official u-boot website, several others are dealing with u-boot getting started or configuration. An article from http://www.linuxdevices.com also gives a good introduction to u-boot. Note however that a detailed documentation is simply available in the source code package as the README file. Thematic documentation is also available in the doc/ directory.
U-boot은 매우 풍부한 문서를 제공하며, 게다가 공식 u-boot website, 여러개의 자료는 u-boot getting started 또는 confiuration과 관계를 가지고 있다.
http://www.linuxdevices.com 로부터의 기사에는 u-boot을 좋게 소개하고 있다. 그러나 세부적인 문서화는 README 파일에서 처럼 source code package에서 간단하게 사용할 수 있다.  주제화된 문서화 또한 doc/ directory에서 사용할 수 있다.

U-boot takes place in the Linux demo as a second stage bootloader. It is responsible of configuring main interfaces and launching a Linux system. Note however that it is possible to avoid this step and to directly boot Linux from AT91Bootstrap, in a production phase for instance.
U-boot은 Linux demo에서 second stage bootloader로 동작한다. 그것은 main interface의 configuring과 Linux system의 launching을 책임지고 있다. 그러나 이러한 과정을 거치지 않고 직접 AT91Bootstrap로부터 Linux를 boot할 수 있다.

The u-boot Application note & flash prog on http://www.atmel.com describes the use of u-boot with the AT91rm9200 chip. The using of u-boot with SAM9 products is a bit different as AT91Bootstrap and the SAM-BA ISP are introduced for these devices.
http://www.atmel.comu-boot Application note & flash prog 는 AT91rm9200 chip에서 u-boot의 사용방법에 대하여 설명하고 있다. SAM9 제품군에서 u-boot을 사용하는 것은 AT91Bootstrap에 약간의 차이가 있고 SAMBA ISP는 이러한 devices를 위해 소개 되었다.

U-boot pre-built images

A revision of u-boot for AT91 boards is built from the official u-boot website and a patch against this revision of u-boot.
This patch is regularly updated.
AT91 boards를 위한 u-boot의 revision은 공식적으로 u-boot website로부터 build 되었고 u-boot의 revision별로 patch도 build 되었다. 이 patch는 정기적으로 updated 되었다.

U-boot environment

The u-boot environment is a little read/write persistent space that stores variables needed by the bootloader to configure itself properly and to adapt to its environment (network configuration, boot arguments, storage location, etc.). It is located in the same media that it has booted from. Check Boot capabilities matrix to know where the u-boot environment is located for the pre-built binary.
u-boot environment 은 조그마한 real/write 가능한 지속적인 공간이다. 이것은 그 자체를 알맞게 configure하고 그것의 환경(network configuration, boot arguments, storage location, etc.)에 적응하기 위해 bootloader에 의해 필요한 변수를 저장하는 공간이다. 그것은 booted되는 같은 media에 위치된다. pre-built binary를 위해 어디에 u-boot environment이 위치하는지 알기 위해 Boot capabilities matrix를 확인해라.

U-boot 1.3.4 experimental binaries

DataFlash

Board Description Binary
at91sam9260ek u-boot binary with environment in Dataflash chip (SPI 0 CS 1) u-boot-1.3.4-exp.3-at91sam9260ek-dataflash_cs1.bin
at91sam9xeek u-boot binary with environment in Dataflash chip (SPI 0 CS 1) u-boot-1.3.4-exp.3-at91sam9xeek-dataflash_cs1.bin
at91sam9261ek u-boot binary with environment in Dataflash chip (SPI 0 CS 0) u-boot-1.3.4-exp.3-at91sam9261ek-dataflash_cs0.bin
at91sam9263ek u-boot binary with environment in Dataflash card (SPI 0 CS 0) u-boot-1.3.4-exp.3-at91sam9263ek-dataflash_cs0.bin
at91sam9rlek u-boot binary with environment in Dataflash card (SPI 0 CS 0) u-boot-1.3.4-exp.3-at91sam9rlek-dataflash_cs0.bin
at91sam9g20ek u-boot binary with environment in Dataflash chip (SPI 0 CS 1) u-boot-1.3.4-exp.3-at91sam9g20ek-dataflash_cs1.bin
at91sam9g20ek_2mmc u-boot binary with environment in Dataflash chip (SPI 0 CS 1) u-boot-1.3.4-exp.3-at91sam9g20ek_2mmc-dataflash_cs1.bin
at91sam9g10ek u-boot binary with environment in Dataflash chip (SPI 0 CS 0) u-boot-1.3.4-exp.3-at91sam9g10ek-dataflash_cs0.bin
at91sam9g45ekes u-boot binary with environment in Dataflash chip (SPI 0 CS 0) u-boot-1.3.4-exp.3-at91sam9g45ekes-dataflash_cs0.bin

NandFlash

Board Description Binary
at91sam9260ek u-boot binary with environment in NandFlash u-boot-1.3.4-exp.3-at91sam9260ek-nandflash.bin
at91sam9xeek u-boot binary with environment in NandFlash u-boot-1.3.4-exp.3-at91sam9xeek-nandflash.bin
at91sam9261ek u-boot binary with environment in NandFlash u-boot-1.3.4-exp.3-at91sam9261ek-nandflash.bin
at91sam9263ek u-boot binary with environment in NandFlash u-boot-1.3.4-exp.3-at91sam9263ek-nandflash.bin
at91sam9rlek u-boot binary with environment in NandFlash u-boot-1.3.4-exp.3-at91sam9rlek-nandflash.bin
at91sam9g20ek u-boot binary with environment in NandFlash u-boot-1.3.4-exp.3-at91sam9g20ek-nandflash.bin
at91sam9g20ek_2mmc u-boot binary with environment in NandFlash u-boot-1.3.4-exp.3-at91sam9g20ek_2mmc-nandflash.bin
at91sam9g10ek u-boot binary with environment in NandFlash u-boot-1.3.4-exp.3-at91sam9g10ek-nandflash.bin
at91sam9g45ekes u-boot binary with environment in NandFlash u-boot-1.3.4-exp.3-at91sam9g45ekes-nandflash.bin

Old binaries U-Boot directory in Linux4sam FTP



Load u-boot on AT91 boards

This section describes How to load u-boot into the boot media with SAM-BA.
이 section은 SAM-BA를 가지고 u-boot을 boot media에 load에 load하는 방법에 대하여 설명한다.

  • Connect the USB Device Interface to your host machine using the USB Device Cable
  • USB Device Cable을 이용하여 host machine에 USB Device Interface를 연결한다.
  • Make sure that the chip can execute the bootROM monitor SAM-BA-boot :
  • chip이 bootROM monitor SAM-BA-boot를 실행할 수 있는지 확인한다 :

AT91SAM9260-EK AT91SAM9261-EK AT91SAM9263-EK (RevA)
  • J7 must be opened (BMS=1) to boot from the on-chip Boot ROM
  • follow the AT91SAM9260EKSamBaRecovery recovery method, if needed
  • power up the board
  • verify that the USB connection is established (ATMEL AT91xxxxx Test Board appears in taskbar notification area)
  • J4 must be opened (BMS=1) to boot from the on-chip Boot ROM
  • remove DataFlash Jumper (J21)
  • power up the board
  • verify that the USB connection is established (ATMEL AT91xxxxx Test Board appears in taskbar notification area)
  • plug DataFlash Jumper (J21) back in position 1-2
  • J5-6 must be opened (BMS=1) to boot from the on-chip Boot ROM
  • remove DataFlash Card (J9)
  • power up the board
  • verify that the USB connection is established (ATMEL AT91xxxxx Test Board appears in taskbar notification area)
  • reinsert the DataFlash Card in J9
AT91SAM9XE-EK AT91SAM9RL-EK AT91SAM9263-EK (RevB)
  • erase the content of the internal FLASH by putting the J7 jumper in position 1-2
  • power up the board
  • verify that the USB connection is established (ATMEL AT91xxxxx Test Board appears in taskbar notification area)
  • open now J7 (or put in position 2-3), to boot in normal operating mode
  • J11 must be on 1-2 position (BMS=1) to boot from the on-chip Boot ROM
  • remove DataFlash and NAND Flash Jumpers (J12 & J13)
  • power up the board
  • verify that the USB connection is established (ATMEL AT91xxxxx Test Board appears in taskbar notification area)
  • close DataFlash and NAND Flash Jumpers (J12 & J13)
  • J5-6 must be opened (BMS=1) to boot from the on-chip Boot ROM
  • remove DataFlash Card (J9)
  • remove NAND Flash Jumpers (J29)
  • power up the board
  • verify that the USB connection is established (ATMEL AT91xxxxx Test Board appears in taskbar notification area)
  • reinsert the DataFlash Card in J9 (only for DataFlash demo)
  • close NAND Flash Jumper (J29) 1
AT91SAMG20-EK AT91SAMG10-EK AT91SAM9G45-EKES
  • J7 must be opened (BMS=1) to boot from the on-chip Boot ROM
  • remove DataFlash and NAND Flash Jumpers (J33 & J34)
  • power up the board
  • verify that the USB connection is established (ATMEL AT91xxxxx Test Board appears in taskbar notification area)
  • close DataFlash and NAND Flash Jumpers (J33 & J34)
  • J4 must be opened (BMS=1) to boot from the on-chip Boot ROM
  • remove DataFlash and NAND Flash Jumpers (J21 & J24)
  • power up the board
  • verify that the USB connection is established (ATMEL AT91xxxxx Test Board appears in taskbar notification area)
  • close DataFlash (J21) back in position 1-2
  • close NAND Flash Jumper (J24)
  • Check and conform to the Default Jumpers Settings
  • First of all, be sure that the ROM code replacement is located in Dataflash to workaround the issue with SAM-BA access through USB. Please refer to the Errata on AT91SAM9G45 Engineering Sample Devices document
  • JP8 must be opened (BMS=1) to boot from the on-chip Boot ROM
  • remove NAND Flash Jumper (JP10)
  • power up the board
  • verify that the USB connection is established (ATMEL AT91xxxxx Test Board appears in taskbar notification area)
  • close NAND Flash Jumper (JP10)

  • Start SAM-BA GUI Application
  • SAM-BA GUI application을 시작한다.
  • Select the the board in the drop-down menu and choose the USB Connection
  • drop-down menu에서 board를 선택하고 USB connection을 선택한다.

SAM-BA_selectboard.jpg

  • Eventually plug back a jumper to access the media on which u-boot must be loaded to
  • 마지막으로 u-boot이 loaded 되어야만 하는 media에 access하기 위해 jumper 를 plug back 한다.
  • In the main SAM-BA window :
  • main SAM-BA window에서 :

SAM-BA_mainwin-uboot.png

  1. Choose the proper media tab (DataFlash, NandFlash, etc.) in the SAM-BA GUI interface
  2. Initialize the media choosing the Enable action in the Scripts rolling menu and press Execute
  3. Press on Send File Name Browse button
  4. Choose u-boot.bin binary file and press Open
  5. Enter the proper address on media in the Address text field. You can find a media map for each product in GettingStarted#Linux4SAM_DataFlash_demo_Memory and GettingStarted#Linux4SAM_NandFlash_demo_Memory
  6. Press Send File button
  7. On AT91SAM9260-EK or AT91SAM9XE-EK, If you have erased the booting media, do not forget to replace AT91Bootstrap in it
  8. Close SAM-BA, remove the USB cable

1. SAM-BA GUI interface에 알맞은 media tab(DataFlash, NandFlash, etc.) 을 선택한다.
2. Scripts rolling menu에서 Enable action 선택하여 media를 초기화하고 Execute를 누른다.
3. Send File Name Browse button을 누른다.
4. u-boot.bin binary 파일을 선택하고 Open을 누른다.
5. Address text field에서 media의 알맞은 address를 넣는다. 
GettingStarted#Linux4SAM_DataFlash_demo_MemoryGettingStarted#Linux4SAM_NandFlash_demo_Memory 에서 각 product의 media map 을 찾을 수 있다.
6. Send File button 을 누른다.
7. AT91SAM9260-EK 또는 AT91SAM9XE-EK에서, booting media를 erased했다면, AT91Bootstrap으로 booting media를 대체해야만 한다.
8. SAM-BA를 close하고 USB 케이블을 제거한다.

Ok, now you must have a running u-boot flashed on your board. To check, you can have a look at the DBGU serial interface once you have reset the board.
보드에서 flashed 된 u-boot을 running해야 한다. 보드를 reset했을 때 DBGU serial interface통해 확인 할 수 있다.


Use u-boot

Using a terminal software on your host system, you can connect to u-boot through the DBGU serial interface.
host system에서 terminal software를 사용함으로써, DBGU serial interface를 통해 u-boot가 연결할 수 있다.

Serial communication parameters 115200 8-N-1 :

Baud rate 115200
Data 8 bits
Parity None
Stop 1 bit
Flow control None

U-boot Main Commands

setenv this command is used to set variables
setenv        이 명령은 variables을 설정할 때 사용된다.
saveenv this command saves variables previously set in the environment permanent storage space
saveenv        이 명령은 영속적인 저장공간의 환경에서 미리 설정한 variables를 저장한다.
printenv this command print the current variables
printenv        이 명령은 현재 variables을 print한다.

The help command show a brief summary of the built-in commands of u-boot. Here is a selection of useful commands :
help 명령은 u-boot의 built-in command를 간략하게 보여준다. 사용할 명령을 선택한다.

U-Boot> help
?       - alias for 'help'
boot    - boot default, i.e., run 'bootcmd'
bootm   - boot application image from memory
cp      - memory copy
erase   - erase FLASH memory
flinfo  - print FLASH memory information
go      - start application at address 'addr'
help    - print online help
md      - memory display
mm      - memory modify (auto-incrementing)
nand    - NAND sub-system
printenv- print environment variables
protect - enable or disable FLASH write protection
run     - run commands in an environment variable
saveenv - save environment variables to persistent storage
setenv  - set environment variables
tftpboot- boot image via network using TFTP protocol
version - print monitor version
U-Boot>

Refer to the u-boot manual page for u-boot command line interface.
u-boot command line interface를 위해 u-boot manual page를 참조한다.

 

U-boot script capability

You can create script or complex variables, which prevents you to type commands. Here is a summary of several variables built to make a network loading of linux easier :
type commands를 방지하는 script나 복잡한 variables를 생성할 수 있다. 아래에 더 쉽게 linux를 network loading하게 built하는 여러 variable에 대해 간략하게 설명하고 있다. 

setenv boot_addr 0x21400000
setenv linux 'tftp $(boot_addr) linux-2.6.x.img'
setenv ramdisk_addr 0x21100000
setenv ramdisk 'tftp $(ramdisk_addr) sam9-ramdisk.gz'
setenv go 'run linux; run ramdisk; bootm $(boot_addr)'
saveenv

The setenv linux 'tftp $(boot_addr) linux-2.6.x.img' line is equivalent of typing tftp 0x21400000 linux-2.6.x.img but combined with others and stored in flash, it allows you to save time, and automate. For executing a Linux kernel bootup, using this snippet, simply type run go
setenv linux 'tftp $(boot_addr) linux-2.6.x.img' line은 tftp 0x21400000 linux-2.6.x.img로 치는 것과 동일하나 다른것과 결합하고 flash에 저장되며 time을 save하고 자동으로 작업을 수행한다. Linux kernel bootup을 실행하기 위해 간단하게 run go라고 치면 된다.

Boot pre-defined variables and command:

bootcmd when set, this variable content is executed automatically after the boot delay. It enables the u-boot autoboot mode
bootcmd        set하면,  이 variable의 내용은 boot delay 후에 자동으로 실행된다. u-boot autoboot mode를 enable한다.
bootargs this variable it used as an exchange area to pass information to the main application started by u-boot (Linux kernel for instance)
bootargs        u-boot에 의해 시작되는 main application으로 information을 전달하는 exchange area로서 사용되는 variable.
bootm this command executes an application generated by the mkimage tool
bootm        이 명령은 mkimage tool에 의해 발생되는 application을 실행한다.


Load Linux with u-boot on AT91 boards

This section describes the loading of a Linux kernel and it root file system. Keep in mind useful u-boot commands to setup your u-boot behavior.
이 section은 Linux kernel과 root file system의 loading을 설명한다. u-boot을 setup하기 위해 useful u-boot commands에 유의하라.

Preparing linux image

U-Boot does not support normal linux kernel images like zImage or Image (arch/arm/boot/), you have to create an uImage file with the mkimage tool which encapsulates kernel image with header information, CRC32 checksum, etc.
U-boot은 zImage나 Imgae와 같은 일반 linux kernel image를 제공하지는 않는다.  header iinformation, CRC32 cheksum 등과 함께 kernel image를 encapsulates하는 mkimage tool을 이용하여 uImage를 생성해야 한다.

mkimage
comes in source code with U-Boot distribution and it is built during U-Boot compilation (u-boot-source-dir/tools/mkimage), we provide also pre-built static version.
mkimage는 U-Boot 배포판에 source code를 가지고 있고 U-Boot compilation(u-boot-source-dir/tools/mkimage) 동안 built된다. 또한 pre-built static version도 제공한다.

See U-Boot README file for more information.
좀 더 많은 정보는 README 파일을 확인해라.

Command to generate an uncompressed uImage file 2 :
uncompressed uImage file을 생성하는 명령은 다음과 같다.

mkimage -A arm -O linux -C none -T kernel -a 20008000 -e 20008000 -n linux-2.6 -d arch/arm/boot/Image uImage

Commands to generate a compressed uImage file 2 :
compressed uImage file을 생성하는 명령은 다음과 같다.

mkimage -A arm -O linux -C none -T kernel -a 20008000 -e 20008000 -n linux-2.6 -d arch/arm/boot/zImage uImage

Loading through network

On a development system, it is useful to get the kernel and root file system through the network. U-boot provides support for loading binaries from a remote host on the network using the TFTP protocol.
개발 시스템에서, network를 통해 kernel과 root file system을 얻는 것은 유용한 작업이다. U-boot은 TFTP protocol을 이용하여 network에서 remote host로부터 binary를 loading 할 수 있다.

To manage to use TFTP with u-boot, you will have to configure a TFTP server on your host machine. Check your distribution manual or Internet resources to configure a Linux or Windows TFTP server on your host:
u-boot으로 TFTP 사용을 관리하기 위해서는 , host machine에 TFTP server가 configure 되어 있어야 한다. host에 TFTP server를 configure 하기 위해 배포 메뉴얼 또는 internet resource를 을 확인해라.

On the u-boot side, you will have to setup the networking parameters:
 u-boot side에서 networking parameters를 setup해야 한다.

  1. setup an Ethernet address (MAC address)
    Check this u-boot network BuildRootFAQ entry to choose a proper MAC address.
    setenv ethaddr 3e:36:65:ba:6f:be
  2. setup IP parameters
    • the board ip address
      setenv ipaddr 10.159.245.180
    • the server ip address where the TFTP server is running
      setenv serverip 10.159.245.186
  3. saving Environment to flash
    saveenv
  4. if Ethernet Phy has not been detected during former bootup, reset the board to reload u-boot : the Ethernet address and Phy initialization shall be ok, now
  5. download the Linux uImage and the root file system to a ram location using the u-boot tftp command (Cf. U-Boot script capability chapter).
  6. launch Linux issuing a bootm or boot command.

1. Ethernet address(MAC address)를 set-up한다.
   알맞은 MAC address 선택하기 위해
this u-boot network BuildRootFAQ entry 를 확인해라.

   setenv ethaddr 3e:36:65:ba:6f:be
2. IP parameter를 setup한다.
        - 보드 IP address
           setenv ipaddr 10.159.245.180
        - TFTP server가 running하는 server IP
           setenv serverip 10.159.245.186
3. flash하기 위해 environment를 저장한다.
   
saveenv
4. bootup 전에 Ethernet Phy가 감지되지 않으면, u-boot을 reload하기 위해 board를 reset한다. Ethernet address와 Phy 초기화가 
   ok 될 것이다.
 
5. u-boot tftp command를 이용하여 Linux와 root file system을 ram 위치로 download한다.
6. bootm또는 boot 명령을 쳐서 Linux를 launch한다.


Build u-boot from sources

To build the binary found above, you will have to go through the following steps.
위에서 찾은 binary를 build하기 위해 다음 과정을 거쳐야 한다.

Getting u-boot sources

Dedicated page on u-boot wiki : http://www.denx.de/wiki/U-Boot/SourceCode
u-boot wiki page : http://www.denx.de/wiki/U-Boot/SourceCode

To get the u-boot bootloader sources for AT91 product you have to go through the following steps (note that x.x.x and y.y must be replace by the corresponding revision numbers) :
AT91 제품군의 u-boot bootloader source 를 얻기 위해, 다음 단계를 거쳐야 한다.(note that x.x.x and y.y must be replace by the corresponding revision numbers) :

  • download the u-boot sources from the link in the second below and extract it:
  • 아래 두번째 link로부터 u-boot source를 download하고 그것을 extract한다.
wget ftp://ftp.denx.de/pub/u-boot/u-boot-x.x.x.tar.bz2
tar xvjf u-boot-x.x.x.tar.bz2
cd u-boot-x.x.x

  • take the corresponding AT91 u-boot patch set (check third column):
  • 관련 AT91 u-boot patch set을 받는다.
wget http://www.at91.com/linux4sam/pub/Linux4SAM/U-Boot/u-boot-x.x.x-exp.diff
# or, depending on u-boot revision, check the FTP directory:
wget ftp://www.at91.com/pub/uboot/u-boot-x.x.x-exp/u-boot-x.x.x-exp.diff

  • apply it on top of the original u-boot:
  • original u-boot에 덮어쓴다.(patch한다)
cat u-boot-x.x.x-exp.diff | patch -p1

You will have a fresh source copy of the AT91 u-boot.
AT91 u-boot의 fresh source copy를 갖을 수 있다.

U-boot 1.3.4 experimental sources

Description Source Patch  
Add experimental functions to AT91 u-boot u-boot 1.3.4 archive
u-boot 1.3.4 tag on git tree
u-boot-1.3.4-exp.3.diff U-BootAT91Maintainer

Old sources u-boot 1.1.5 archive u-boot-1.1.5_atmel_1.7.diff

Choosing where the u-boot environment resides

Above, we talked about the location of the u-boot environment. Here is a way to modify it to your needs :
위에서 location of the u-boot environment에 대하여 이야기 했다. 여기서는 필요에 따라 location을 modify하는 방법에 대해 알아본다.

hand With newer revisions of u-boot (u-boot-1.1.5_atmel_1.7.diff patch, u-boot-1.3.4 and later) you can choose location of environment variables at configuration step.
u-boot의 새 revision(u-boot-1.1.5_atmel_1.7.diff patch, u-boot-1.3.4 and later)을 가지고 configuration 단계에서 환경변수의 위치를 선택할 수 있다.

To put environment variables in dataflash (default):
dataflash에 환경변수를 위치시키기 위해 다음과 같이 한다.

   make at91sam9xxxek_dataflash_config
or
   make at91sam9xxxek_dataflash_cs0_config

To put environment variables in nandflash:
nandflash에 환경변수를 넣기 위해 다음과 같이 한다.
   make at91sam9xxxek_nandflash_config

Please go to the top-level Makefile or read the README.at91 file in the doc directory of u-boot to find the exact target when invoking make.
make를 invoking할때 정확한 target을 찾기 위해 top-level Makefile로 가거나 u-boot의 doc directory에서 README.at91 파일을 read한다.


With older revisions
, the environment configuration resides in a header file ; you just have to define or undef pre-compilation variables:
older revision은 environment configuration이 header file에 존재한다. 컴파일 전에 define 또는 undef 만 하면 된다.

Product Config file Piece of code involved
AT91rm9200ek include/configs/at91rm9200ek.h
#undef  CFG_ENV_IS_IN_DATAFLASH

#ifdef CFG_ENV_IS_IN_DATAFLASH
[..]
#else
#define CFG_ENV_IS_IN_FLASH  1
[..]
#endif
AT91sam9260ek include/configs/at91sam9260ek.h
#define CFG_ENV_IS_IN_DATAFLASH  1
#undef CFG_ENV_IS_IN_NAND
AT91sam9261ek include/configs/at91sam9261ek.h
#define CFG_ENV_IS_IN_DATAFLASH  1
AT91sam9263ek include/configs/at91sam9260ek.h
#define CFG_ENV_IS_IN_DATAFLASH  1

hand Note that CFG_ENV_IS_IN_FLASH means environment in NOR FLASH. This option is not supported "out of the box" for all products but certainly can be implemented.
CFG_ENV_IS_IN_FLASH는 NOR FLASH에서의 environment를 의미한다. 이 option은 모든 제품군을 위해 제공된 "out of the box" 는 아니지만 확실히 실험될 수 있다.

Additional information about those variables are availlable in the u-boot README (search "- CFG_ENV_IS_IN_FLASH").
이러한 variables에 대한 추가적인 정보는 u-boot README에서 사용될 수 있다(search "- CFG_ENV_IS_IN_FLASH").

Cross-compiling u-boot

Once the AT91 u-boot sources available, cross-compile u-boot is made in two steps : configuration and compiling. Check the Configuration chapter in u-boot reference manual.
AT91 u-boot sources를 사용하 때,  cross-compile은 두 단계로 이루어 진다. : configuration과 compiling이다. u-boot reference manual의 Configuration chapter를 확인해라.

Note that both arm-elf- and arm-linux- ARM GCC cross-compiler types are suitable for u-boot building.
arm-elf- 와 arm-linux- ARM GCC cross-compiler types 모두 u-boot building을 위해 적합하다. 

warning Some newer version of make produce errors while compiling old u-boot 1.1.5.
While using u-boot 1.1.5, we advice you to run an older make executable: check the SoftwareTools page.
어떤 새로운 versiondms old u-boot 1.1.5를 컴파일하는 동안 error가 발생한다.
u-boot 1.1.5를 사용할 때 older make executable를 run하는 것은 권장한다.
SoftwareTools page를 확인해라.

Here are the building steps for the AT91sam9263ek board:
AT91sam9263ek board를 building 하는 단계는 다음과 같다.

make distclean
make at91sam9263ek_config
make CROSS_COMPILE=<path_to_cross-compiler/cross-compiler-prefix->

path_to_cross-compiler is only needed if it is not in your PATH.
Usually cross-compiler-prefix- looks like arm-linux- or arm-elf-

The result of these operations is a fresh u-boot binary called u-boot.bin corresponding to the binary ELF file u-boot.
이 동작의 결과는 u-boot binary ELF file과 관련된 u-boot.bin으로 불리는 새로 생성된 u-boot binary이다.

  • u-boot.bin is the file you should store on the board
  • u-boot.bin은 보드에 저장할 file이다.
  • u-boot is the ELF format binary file you may use to debug u-boot through a JTag link for instance.
  • u-boot은 JTAG link를 통해 u-boot을 debug하기 위해 사용할 수 있는 ELF format binary file이다.


Notes

1: If you experience issues with NAND flash accesses,
please refer to the AT91SAM9263-EK Evaluation Board Rev. B User Guide chapter 1.5 NAND Flash Access Issue
만약 실험이 NAND flash access로 이루어진다면,
AT91SAM9263-EK Evaluation Board Rev. B User Guide chapter 1.5 NAND Flash Access Issue 를 참조한다.


2:
warning for at91sam9g45 family: use proper location for RAM: 0x70000000 instead of 0x20000000
at91sam9g45 family에서 RAM의 위치는 0x20000000 대신에 0x70000000을 사용한다.


  Attachment Action Size Date Who Comment
png SAM-BA_mainwin-uboot.png props, move 253.9 K 11 Sep 2007 - 11:45 NicolasFerre SAM-BA main window flashing u-boot
jpg SAM-BA_selectboard.jpg props, move 8.6 K 05 Jul 2007 - 11:50 NicolasFerre SAM-BA select board & connexion
r65 - 27 Oct 2009 - 14:18:40 - NicolasFerre


'[C-03] AT91SAM9260' 카테고리의 다른 글

Linux4SAM - OpenEmbedded / Angstrom  (0) 2009.11.16
Linux4SAM - Linux Kernel  (0) 2009.11.16
Linux4SAM - AT91Bootstrap  (0) 2009.11.15
Linux4SAM - Software Tools  (0) 2009.11.15
Linux4SAM - Getting Started  (0) 2009.11.14
Posted by eoseontaek

AT91Bootstrap

Introduction

AT91Bootstrap is a first step bootloader providing a set of algorithms to manage hardware initialization (GPIO, Clock, SDRAM, etc), to download your main application from specified FLASH media to main memory and to start it.
AT91Bootstrap은 첫번째 단계의 bootloader이다. 그것은 hardware initialization (GPIO, Clock, SDRAM, etc)을 관리하고, 특정 FLASH media에서 main memory로 main application을 download하고 그것을 시작하기 위한 algorithms의 set을 제공한다.

In the linux4SAM pre-built demo it is used to configure the hardware and to load and start the standard U-Boot bootloader, it can also be configured to start directly the linux kernel.
linux4SAM pre-built demo에서 그것은 hardware를 configure하고, standard U-Boot bootloader를 load하고 start하기위해 사용된다. 또한 직접 linux kernel을 start하도록 configure 할 수도 있다.

More information see the AT91Bootstrap application note.
추가 정보는 the AT91Bootstrap application note에 설명되어 있다.

  

Pre-built binaries

DataFlash

Board Description Binary
at91sam9260ek AT91Bootstrap binary with 2nd level application in Dataflash chip (SPI 0 CS 1) dataflash_at91sam9260ek.bin
at91sam9xeek AT91Bootstrap binary with 2nd level application in Dataflash chip (SPI 0 CS 1) dataflash_at91sam9xeek.bin
at91sam9261ek AT91Bootstrap binary with 2nd level application in Dataflash chip (SPI 0 CS 0) dataflash_at91sam9261ek.bin
at91sam9263ek AT91Bootstrap binary with 2nd level application in Dataflash card (SPI 0 CS 0) dataflash_at91sam9263ek.bin
at91sam9rlek AT91Bootstrap binary with 2nd level application in Dataflash card (SPI 0 CS 0) dataflash_at91sam9rlek.bin
at91sam9g20ek AT91Bootstrap binary with 2nd level application in Dataflash chip (SPI 0 CS 1) dataflash_at91sam9g20ek.bin
at91sam9g10ek AT91Bootstrap binary with 2nd level application in Dataflash chip (SPI 0 CS 0) dataflash_at91sam9g10ek.bin
at91sam9g45ekes ROM Code replacement 2

NandFlash

Board Description Binary
at91sam9260ek AT91Bootstrap binary with 2nd level application in NandFlash nandflash_at91sam9260ek.bin
at91sam9xeek AT91Bootstrap binary with 2nd level application in NandFlash nandflash_at91sam9xeek.bin
at91sam9261ek AT91Bootstrap binary with 2nd level application in NandFlash nandflash_at91sam9261ek.bin
at91sam9263ek AT91Bootstrap binary with 2nd level application in NandFlash nandflash_at91sam9263ek.bin
at91sam9rlek AT91Bootstrap binary with 2nd level application in NandFlash nandflash_at91sam9rlek.bin
at91sam9g20ek AT91Bootstrap binary with 2nd level application in NandFlash nandflash_at91sam9g20ek.bin
at91sam9g10ek AT91Bootstrap binary with 2nd level application in NandFlash nandflash_at91sam9g10ek.bin
at91sam9g45ekes AT91Bootstrap binary with 2nd level application in NandFlash nandflash_at91sam9g45ekes.bin

Old binaries AT91Bootstrap directory on Linux4sam FTP


 

Load AT91Bootstrap on SAM9 boards

This section describes How to load AT91Bootstrap into the boot media with SAM-BA.
이 section은 SAM-BA를 가지고 AT91Bootstrap를 boot media로 load하는 방법을 설명한다.

  • Connect the USB Device Interface to your host machine using the USB Device Cable
  • host machine에 USB Device Cable을 이용하여 USB Device Interface를 연결한다.
  • Make sure that the chip can execute the bootROM monitor SAM-BA-boot :
  • chip이 bootROM monitor SAM-BA-boot를 실행할 수 있는지 확인한다.

AT91SAM9260-EK AT91SAM9261-EK AT91SAM9263-EK (RevA)
  • J7 must be opened (BMS=1) to boot from the on-chip Boot ROM
  • follow the AT91SAM9260EKSamBaRecovery recovery method, if needed
  • power up the board
  • verify that the USB connection is established (ATMEL AT91xxxxx Test Board appears in taskbar notification area)
  • J4 must be opened (BMS=1) to boot from the on-chip Boot ROM
  • remove DataFlash Jumper (J21)
  • power up the board
  • verify that the USB connection is established (ATMEL AT91xxxxx Test Board appears in taskbar notification area)
  • plug DataFlash Jumper (J21) back in position 1-2
  • J5-6 must be opened (BMS=1) to boot from the on-chip Boot ROM
  • remove DataFlash Card (J9)
  • power up the board
  • verify that the USB connection is established (ATMEL AT91xxxxx Test Board appears in taskbar notification area)
  • reinsert the DataFlash Card in J9
AT91SAM9XE-EK AT91SAM9RL-EK AT91SAM9263-EK (RevB)
  • erase the content of the internal FLASH by putting the J7 jumper in position 1-2
  • power up the board
  • verify that the USB connection is established (ATMEL AT91xxxxx Test Board appears in taskbar notification area)
  • open now J7 (or put in position 2-3), to boot in normal operating mode
  • J11 must be on 1-2 position (BMS=1) to boot from the on-chip Boot ROM
  • remove DataFlash and NAND Flash Jumpers (J12 & J13)
  • power up the board
  • verify that the USB connection is established (ATMEL AT91xxxxx Test Board appears in taskbar notification area)
  • close DataFlash and NAND Flash Jumpers (J12 & J13)
  • J5-6 must be opened (BMS=1) to boot from the on-chip Boot ROM
  • remove DataFlash Card (J9)
  • remove NAND Flash Jumpers (J29)
  • power up the board
  • verify that the USB connection is established (ATMEL AT91xxxxx Test Board appears in taskbar notification area)
  • reinsert the DataFlash Card in J9 (only for DataFlash demo)
  • close NAND Flash Jumper (J29) 1
AT91SAMG20-EK AT91SAMG10-EK AT91SAM9G45-EKES
  • J7 must be opened (BMS=1) to boot from the on-chip Boot ROM
  • remove DataFlash and NAND Flash Jumpers (J33 & J34)
  • power up the board
  • verify that the USB connection is established (ATMEL AT91xxxxx Test Board appears in taskbar notification area)
  • close DataFlash and NAND Flash Jumpers (J33 & J34)
  • J4 must be opened (BMS=1) to boot from the on-chip Boot ROM
  • remove DataFlash and NAND Flash Jumpers (J21 & J24)
  • power up the board
  • verify that the USB connection is established (ATMEL AT91xxxxx Test Board appears in taskbar notification area)
  • close DataFlash (J21) back in position 1-2
  • close NAND Flash Jumper (J24)
  • Check and conform to the Default Jumpers Settings
  • First of all, be sure that the ROM code replacement is located in Dataflash to workaround the issue with SAM-BA access through USB. Please refer to the Errata on AT91SAM9G45 Engineering Sample Devices document
  • JP8 must be opened (BMS=1) to boot from the on-chip Boot ROM
  • remove NAND Flash Jumper (JP10)
  • power up the board
  • verify that the USB connection is established (ATMEL AT91xxxxx Test Board appears in taskbar notification area)
  • close NAND Flash Jumper (JP10)

  • Start SAM-BA GUI Application
  • SAM-BA GUI Application을 시작한다.
  • Select the the board in the drop-down menu and choose the USB Connection
  • drop-down menu에서 board를 선택하고 USB connection을 선택한다.
    SAM-BA_selectboard.jpg
  • Eventually plug back a jumper to access the media on which u-boot must be loaded to
  • 마지막으로 u-boot이 loaded되야만 하는 media에 access 하기 윟 plug back한다..
  • In the main SAM-BA window :
  • main SAM-BA window에서

SAM-BA_mainwin-bootstrap.png

  1. Choose the proper media tab (DataFlash, NandFlash, etc.) in the SAM-BA GUI interface
  2. Initialize the media choosing the Enable action in the Scripts rolling menu and press Execute
  3. Choose Send boot file, press Execute
  4. Select the at91bootstrap binary file and press Open ; the media is written down
  5. Close SAM-BA, remove the USB cable

1. SAM-BA GUI에서 알맞은 media tab(DataFlash, NandFlash, etc.)을 선택한다.
2. Script rolling menu에서 Enable action을 선택하여 media를 초기화한다. 그리고 Execute를 누른다.
3. Send boot file을 선택하고, Execute를 누른다.
4. at91bootstrap binary file을 선택하고 Open을 누른다, media는 기록(write-down)된다.
5. SAM-BA를 닫고, USB cable을 제거한다.


Boot strategies

AT91 chips embed a boot ROM code. It is enabled depending on BMS (Boot Mode Select) pin state on reset. This ROM code scans the contents of different media like SPI DATAFLASH, NAND FLASH or SDCARD to determine if a valid application is available then it download the application into SAM9 internal SRAM and run it. To determine if a valid application is present the ROM code checks the eight ARM exception vectors.
 AT91 chips은 boot ROM code를 내장한다. 그것은 reset시 BMS(Boot  Mode Select) pin 상태에 따라 Enable 여부가 결정된다. 이 ROM code는  SPI DATAFLASH, NAND FLASH 또는 SDCARD와 같은 다른 media의 내용을 scan하고 유효한 application을 사용할 수 있는지 결정한다.  그 다음에 application을 SAM9 internal SRAM으로 그것을 download하고, run한다. 유효한 application이 있는지를 결정하는 것은 ROM code가 8번째 ARM exception vectors를 check하는 것이다.

If no application is available then SAM-BA application is executed. It waits for transactions either on the USB device, or on the DBGU serial port, Then the SAM-BA tool can be used to program FLASH or EEPROM present on your board.

만약 어떤 application도 사용할 수 없다면 SAM-BA applicaiton은 실행된다. 그것은 USB device나 DBGU serial port에서의 transaction을 기다린다.
그 때 SAM-BA tool은 보드에  FLASH, EEPROM에 program 할 수 있게 된다.

For more information on this topic, please check the corresponding SAM product datasheet section Boot Program . You can find a valuable summary in the document named SAM9 Boot Strategies or see the cross matrix below..
이 topic의 추가 정보는 관련 SAM 제품군의 datasheet에 section Boot Program을 확인해라. SAM Boot Strategies라는 document에서 유용한 정보를 찾을 수 있다. 또한 아래의 cross matrix를 통해서도 얻을 수 있다.

ROM Code boot Sequence example

9263_rom_boot_sequence.png

Boot capabilities matrix

Here is :
led-aqua a summary of the boot feature for each board
led-green the solution chosen for the Linux4SAM pre-built binaries.

Product Boot from
DataFlash (SPI0 CS0)
Boot from
DataFlash (SPI0 CS1)
Boot from
NAND Flash
Boot from
SD card
Boot from
NOR Flash
Boot from
Internal Flash 3
at91rm9200ek led-aqua          led-green    
at91sam9260ek led-aqua    led-green 4 led-green 5      
at91sam9xeek           led-green   
at91sam9261ek led-green 4 led-aqua    led-green 6 led-aqua 6    
at91sam9263ek led-green 7   led-green 8 led-aqua 8    
at91sam9rlek led-green 4   led-green    led-aqua       
at91sam9g20ek led-aqua    led-green 4 led-green         
at91sam9g10ek led-green 4 led-aqua    led-green    led-aqua       
at91sam9g45ekes led-aqua 4   led-green         

Known issues with old AT91Bootstrap

The Dataflash version of AT91Bootstrap (version 1.10 or older) will load a second level bootloader or application from the address 0x8000. Dataflash memories have page size of 1056 bytes, (0x420 hex) and the load address 0x8000 is thus in the middle of a page.
AT91Bootstrap(version 1.10 or older)의 Dataflash version은 second level bootloader 또는 address 0x8000번지부터 application을 load할 것이다.
Dataflash memory는 1056(0x420 hex)bytes page size를 갖는다. 그리고 load address 0x8000은 page의 중간이 된다.

hand Newer version of AT91Bootstrap (from version 1.11) will load a second level bootloader or application from the address 0x8400.
새 버전은 second level bootloader  또는 address 0x8400번지부터 application을 load 할 것이다.


Build AT91Bootstrap from sources

Sources and build process are described in the AT91Bootstrap application note page on http://www.atmel.com .
Sources와 build 처리는 AT91Bootstrap application note에 설명되어 있다.

You can also retrieve them from ftp://www.at91.com/pub/at91bootstrap .
 ftp://www.at91.com/pub/at91bootstrap 로부터 복구할 수도 있다.

A rewritten version of AT91bootstrap that supports some more options is available as part of the buildroot project at http://buildroot.uclibc.org/
좀 더 많은 option을 제공하는 AT91bootstrap 버전은 http://buildroot.uclibc.org/ 에서 buildroot project의 part로서 사용할 수 있다.
 

In brief

To compile an AT91Bootstrap project:

  1. go into the board directory
  2. select your board by going into the corresponding board directory
  3. select your media by going into the corresponding directory
  4. run make

AT91Bootstrap project를 compile 하기 위해
    1. boar directory로 간다.
    2. 관련 board directory로 가서 board를 선택한다.
    3. 관련 directory로 가서 media를 찾는다.
    4. make 한다.

Example: To compile a DataFlash boot project for AT91SAM9260-EK board, type the following commands:
예시 : AT91SAM9260-EK board를 위한 DataFlash boot project를 compile하기 위해, 아래의 명령은 친다.

cd board/at91sam9260ek/dataflash
make clean

and

make

or if you want to specify the cross-compiler :

make CROSS_COMPILE=<path_to_cross-compiler/cross-compiler-prefix->

path_to_cross-compiler is only needed if it is not in your PATH.
Usually cross-compiler-prefix- looks like arm-linux- or arm-elf-


Notes

1: If you experience issues with NAND flash accesses,
please refer to the AT91SAM9263-EK Evaluation Board Rev. B User Guide chapter 1.5 NAND Flash Access Issue

2: To workaround the issue with SAM-BA access through USB, a ROM code replacement is located in Dataflash. Please refer to the Errata on AT91SAM9G45 Engineering Sample Devices document

3: Only available on products with embedded Flash

4: On board DataFlash chip

5: Please check at91sam9260 errata # 44.2.1.1

6: Supported on SAM9261 rev B and onward

7: Removable DataFlash card

8: Supported on SAM9263 rev B and onward




'[C-03] AT91SAM9260' 카테고리의 다른 글

Linux4SAM - Linux Kernel  (0) 2009.11.16
Linux4SAM - U-Boot  (0) 2009.11.15
Linux4SAM - Software Tools  (0) 2009.11.15
Linux4SAM - Getting Started  (0) 2009.11.14
AT91SAM Community  (0) 2009.11.10
Posted by eoseontaek

Software Tools

 

SAM-BA

The SAM Boot Assistant (SAM-BA) comes with the AT91 In-system Programmer (ISP). It allows to program flash media through RS232, USB or Jtag SAM-ICE link. SAM-BA only runs on Windows.

Description Binary FAQ applicable
SAM Boot Assistant (SAM-BA) on http://www.atmel.com AT91 In-system Programmer (ISP) for at91sam9xe (SAM-BA 2.8),
for at91sam9g20 (SAM-BA 2.8),
for at91sam9263 (SAM-BA 2.7)


SAM Boot Assistant(SAM-BA)는 AT91 In-system Programmer (ISP) 함께 제공된다. 그것은 RS232, USB, Jtag SAM-ICE link를 통해 flash media에 program을 가능하게 한다. SAM-BA는 Windows에서만 동작한다.

SAM-BA Linux initiative

A revision of SAM-BA is ported to Linux. It is at the side of the official SAM-BA ISP revision.
SAM-BA revision은 Linux에 ported되었다. 그것은 공식적인 SAM-BA revision 중 하나다.

SAM-BA Linux uses the USB connexion through CDC usbserial driver to communicate with the device.
SAM-BA Linux는 USB connection을 사용하며, device와 통신하기 위해 CDC usbserial driver를 통한다.

USB CDC Serial driver mount procedure :
USB CDC Serial driver의 mount 과정은 다음과 같다.

  • Login with administrator rights
  • administrator계정으로 login한다.

  • Unload usbserial module if it is already running
  • 이미 running 중이라면 usbserial module을 unload한다.
rmmod usbserial

  • Load usbserial kernel module
  • usbserial kernel module을 load한다.
modprobe usbserial vendor=0x03eb product=0x6124

  • Verify that the USB connection is established
  • USB connection이 연결되었는지 확인한다.
lsusb -d 03eb:6124    Bus 004 Device 006: ID 03eb:6124 Atmel Corp

  • Know which USB connection is established
  • USB conneciton이 연결되었음을 알린다.
dmesg    ...    kernel: usb 4-2: new full speed USB device using uhci_hcd and address 5    kernel: usb 4-2: configuration #1 chosen from 1 choice    kernel: usbserial_generic 4-2:1.0: generic converter detected    kernel: usbserial_generic: probe of 4-2:1.0 failed with error -5    kernel: usbserial_generic 4-2:1.1: generic converter detected    kernel: usb 4-2: generic converter now attached to ttyUSBx

=> you will have to use /dev/ttyUSBx instead of \usb\ARM0 to connect to your board
     보드에 연결하기 위해 \usb\ARM0 대신 /dev/ttyUSBx를 사용해야 한다.

info You can also use .tcl scripts from this flavor of SAM-BA. This is useful if you want to run GettingStarted#DemoArchiveBinaries demos.

Description Binary FAQ applicable
SAM Boot Assistant (SAM-BA 2.9) Linux port initiative using CDC sam-ba_2.9_cdc_linux.zip  
SAM Boot Assistant (SAM-BA 2.8) Linux port initiative using CDC sam-ba_cdc_2.8.linux_01.zip for at91sam9xe, for at91sam9g20
SAM Boot Assistant (SAM-BA 2.7) Linux port initiative using CDC sam-ba_cdc_2.7.linux_01.zip for at91sam9263

 다른 방법으로 SAM-BA의 flavor로부터 .tcl scripts를 사용할 수 있다. 이것은  GettingStarted#DemoArchiveBinaries demo를 구동할 때 유용하다.



Cross Toolchain

CodeSourcery provides regular, validated releases of the GNU Toolchain for arm processor.
This document refers to arm2007q1-10 version of CodeSourcery toolchain.
CodeSourcery는 arm processor의 GNU Toolchain의 releases를 제공한다.
이 문서는 CodeSourcery toolchain의 arm2007q1-10 version을 참조한다.

Features in this release include:
이 release의 특징은 다음과 같다.

  • Based on GCC 4.2
  • Support EABI
  • Support for uClinux
  • Support for Cortex-M1 (ARMV6-M) CPUs
  • Improved code generation for Cortex-A8 and Cortex-R4 CPUs
  • Thumb-2 GLIBC binaries

Links:

Description Binary
CodeSourcery GNU cross-toolchain for ARM arm-2007q1-10-arm-none-linux-gnueabi-i686-pc-linux-gnu.tar.bz2

mkimage (U-Boot)

The mkimage U-Boot tool is used to convert a standard kernel image into uImage format needed by bootm U-Boot command.

Description Sources Binary
Pre-built static version of the u-boot mkimage tool u-boot sources directory mkimage

mkimage U-Boot tool은 standard kernel image를  bootm U-Boot command를 사용하기 위한 uImage format로 변환하기 위해 사용된다.


Make

warning Not needed for newer U-Boot.

Some newer version of make produce errors while compiling some older revision of U-Boot. The compiling of this old code has been validated
with make-3.80 : Take it and compile it on your host machine (pace in /usr/local directory for example). You can use it calling the right
binary while issuing the cross-compile command:

어떤  make의 새 버전은 U-Boot의 older revision을 컴파일하는 동안 errors가 발생한다. old code의 컴파일은 make-3.80 일때 유효하다.
그것을 받은 후, host machine에서 컴파일해라(pace in /usr/local directory for example). cross-compile command를 issuing
하는 동안 정확한 binary를 호출함으로써 사용
가능하다. 
/usr/local/bin/make-3.80 CROSS_COMPILE=<path_to_cross-compiler/cross-compiler-prefix->
 

Description Sources Binary
Pre-built static version of the make tool make sources directory make-3.80

  Attachment Action Size Date Who Comment
else make-3.80.bin props, move 931.9 K 16 Nov 2007 - 10:10 NicolasFerre  
else mkimage.bin props, move 460.7 K 17 Jul 2007 - 13:11 PatriceVilchez  
r25 - 05 Nov 2009 - 09:22:05 - RfoLnx4sam



 

'[C-03] AT91SAM9260' 카테고리의 다른 글

Linux4SAM - U-Boot  (0) 2009.11.15
Linux4SAM - AT91Bootstrap  (0) 2009.11.15
Linux4SAM - Getting Started  (0) 2009.11.14
AT91SAM Community  (0) 2009.11.10
KEIL ARM의 AT91SAM9260 Device Database site  (0) 2009.11.10
Posted by eoseontaek

Getting Started

 

Introduction

This page is a starting point for the Linux4SAM offer and allows you to easily get a running embedded Linux distribution on AT91 products.

This Getting started describes also how a Linux4SAM system boots and how binaries are installed on FLASH memories. For each topic a more detailed section exists with in-depth description, valuables web links, source code how to rebuild used binaries.

이 페이지는 Linux4SAM offer를 위한 시작점이고, AT91 제품군에서 쉽게 embedded Linux 배포를 구동할 수 있게 한다.
이 Getting started는 FLASH memory에 Linux4SAM system을 boot 하고, binaries를 install하는 방법에 대하여 설명한다. 각각의 topic을 위해 더 세부적인 section이 존재하며 사용된 binaries를 rebuild하는 방법인 심오한 설명과,  볼만한 웹 링크, 소스코드를 제공한다.



Boot sequence

Several pieces of software are involved to boot a linux kernel on SAM9 products. First is the ROM code which is in charge to check if a valid application is present on supported media (FLASH, DATAFLASH, NANDFLASH, SDCARD).

The boot sequence of linux4SAM is done in several steps :

  1. Boot Program - Check if a valid application is present in FLASH and if it is the case download it into internal SRAM.
    For more information on this topic, please check the Boot strategies section and particularly the Boot capabilities matrix.
  2. AT91Bootstrap - In charge of hardware configuration, download U-Boot binary frome FLASH to SDRAM, start the bootloader
  3. U-Boot - The bootloader, in charge of download kernel binaries from FLASH, network, USB key, etc. Start the kernel.
  4. Linux kernel - The operating system kernel.
  5. Root Filesystem - Contains applications which are executed on the target, using the OS kernel services.

여러개의 소프트웨어 pieces가 SAM9 제품군의 linux kernel boot를 위해 포함된다. 먼저 ROM code가 있으며, 이것은  유효한 Application이 제공된 media(FLASH, DATAFLASH, NANDFLASH, SDCARD) 에서 present 되는 것을 확인하는 것을 담당한다.

linux4SAM의 boot sequence는 여러 단계로 수행된다.
1. Boot Program - 유효한 application이 FLASH 존재하고 있는지 check하고 존재한다면 내부 SRAM으로 그것을 다운로든 한다.
   추가정보는
Boot strategies section and particularly the Boot capabilities matrix 를 확인해라.
2.
AT91Bootstrap - hardware configuration을 담당,  FLASH에서 SDRAM으로 U-Boot  binary를 다운로드 하고, bootloader를 시작한다.
3. U-Boot - bootloader, FLASH, network, USB key 등으로부터 kernel binaries를 다운로드 하는것을 담당.
4.
Linux kernel - The operating system kernel.
5. Root Filesystem - target에서 실행되고, OS kernel service를 사용하는 application을 포함한다.




  1. Processor comes out of reset and branches to the ROM startup code.
  2. The ROM startup code initializes the CPU and memory controller, performing only minimal initialization of on-chip devices, such as the console serial port to provide boot diagnostic messages. It also sets up the memory map for the kernel to use in a format that is consistent across platforms, and then jumps to the boot loader.
  3. The boot loader decompresses the kernel into RAM, and jumps to it.
  4. The kernel sets up the caches, initializes each of the hardware devices via the init function in each driver, mounts the root filesystem and execs the init process, which is the ultimate parent of all user mode processes, typically /sbin/initd.
  5. Executing the first program linked against the shared C runtime library (often init) causes the shared runtime library to be loaded. In a typical Linux system, init reads /etc/inittab to execute the appropriate run control script from /etc/rc.d, which execute the start scripts to initialize networking and other system services


1. Processor는 reset을 내보내고 ROM startup code로 분기한다.
2. ROM startup code는 CPU와 memory controller를 초기화 한다. boot diagnostic message를 제공하기 위한 console serial port 같은 on-chip
   devices의 최소 초기화만을 수행한다. 또한 consistent across platforms에서 사용하기 위한 kernel을 위한 memory map을 setup한다. 그리고
   bootloader로 jump한다.
3. boot loader는 RAM으로  kernel을 decompresse하고, 그곳으로 jump한다.
4. kernel은 cache를 setup하고, 각 driver에서 init function을 거쳐 hardware devices를 각각 초기화하고, root filesystem을 mount하고 init process를
    exec한다. 모드 user mode process의 ultimate parent는 보통 /sbin/initd 이다.
5. shared C runtime library(often init) 대한  링크된 첫번째 프로그램을 실행하는 것은 shared runtime libary를 loaded되게 하는 원인이 된다. 보통
    linux system에서, init는 /etc/rc.d로부터 적절한 run control script를 실행하기 위한 /etc/inittab을 read한다. 그리고 그것은 networking과 다른
    system service 를 초기화하기 위한 start script를 실행한다.


Linux4SAM DataFlash demo - Memory map



Linux4SAM NandFlash demo - Memory map


 Requirements

 

Hardware

  • a Windows XP host (or later) or a Linux distribution to run the SAM-BA tool ;
  • power supply stocked with the Evaluation Kit ;
  • USB Device Cable ;
  • serial Cross Cable (Female-Female) ;
  • eventually a DataFlash Card => check Boot capabilities matrix (for AT91SAM9263-EK for example) ;
  • AT91SAM9-EK Evaluation Kit. Check below how kits look like and how to connect them :

AT91SAM9260-EK AT91SAM9261-EK AT91SAM9263-EK (REV-A)
AT91SAM9260-EK AT91SAM9261-EK AT91SAM9263-EK (REV-A)
AT91SAM9XE-EK AT91SAM9RL-EK AT91SAM9263-EK (REV-B) 2
AT91SAM9XE-EK AT91SAM9RL-EK AT91SAM9263-EK (REV-B)
AT91SAM9G20-EK AT91SAM9G10-EK AT91SAM9G45-EKES and AT91SAM9M10G45-EK
AT91SAM9G20-EK AT91SAM9G10-EK AT91SAM9G45-EKES and AT91SAM9M10G45-EK

                                    AT91SAM9260-EK

Software

  • a serial terminal emulator (HyperTerminal, minicom, etc.) :

Serial communication parameters 115200 8-N-1 :

Baud rate 115200
Data 8 bits
Parity None
Stop 1 bit
Flow control None

  • AT91 ISP 1.10 (or later) ; containing the SAM-BA tool => Check the SoftwareTools page ;
  • the demo archive provide just below. This archive contains :
    • all 4 components binaries : AT91Bootstrap, u-boot, Linux kernel, root filesystem ;
    • a TCL/SAM-BA script that interfaces with the SAM-BA tool to flash the demo ;
    • a .bat script able to run the flashing script calling SAM-BA itself.

Demo binaries

Board Description Binary Sources location
at91sam9260ek Linux4SAM console demo archive linux4sam-angstrom-at91sam9260ek.zip (~ 18 MB) AT91Bootstrap
U-Boot
Linux Kernel
OpenEmbedded-Angstrom
at91sam9xeek Linux4SAM console demo archive linux4sam-angstrom-at91sam9xeek.zip (~ 18 MB)
at91sam9261ek Linux4SAM graphical demo archive linux4sam-angstrom-at91sam9261ek.zip (~ 27 MB)
at91sam9263ek Linux4SAM graphical demo archive linux4sam-angstrom-at91sam9263ek.zip (~ 27 MB)
at91sam9rlek Linux4SAM graphical demo archive linux4sam-angstrom-at91sam9rlek.zip (~ 27 MB)
at91sam9g20ek3 Linux4SAM console demo archive linux4sam-angstrom-at91sam9g20ek.zip (~ 19 MB)
at91sam9g10ek Linux4SAM graphical demo archive linux4sam-angstrom-at91sam9g10ek.zip (~ 27 MB)
at91sam9g45ekes Linux4SAM graphical demo archive linux4sam-angstrom-at91sam9g45ekes.zip (~ 27 MB)

Board Description Binary Sources location
at91sam9260ek Linux4SAM console demo archive linux4sam-buildroot-at91sam9260ek.zip (~ 14 MB) AT91Bootstrap
U-Boot
Linux Kernel
Buildroot
at91sam9xeek Linux4SAM console demo archive linux4sam-buildroot-at91sam9xeek.zip (~ 14 MB)
at91sam9261ek Linux4SAM console demo archive linux4sam-buildroot-at91sam9261ek.zip (~ 14 MB)
at91sam9263ek Linux4SAM console demo archive linux4sam-buildroot-at91sam9263ek.zip (~ 14 MB)
at91sam9rlek Linux4SAM console demo archive linux4sam-buildroot-at91sam9rlek.zip (~ 14 MB)
at91sam9g20ek3 Linux4SAM console demo archive linux4sam-buildroot-at91sam9g20ek.zip (~ 16 MB)
at91sam9g10ek Linux4SAM console demo archive linux4sam-buildroot-at91sam9g10ek.zip (~ 14 MB)
at91sam9g45ekes Linux4SAM console demo archive linux4sam-buildroot-at91sam9g45ekes.zip (~ 14 MB)

Old binaries linux4sam demo v1.4 through v1.6


 

Flashing a demo on AT91 boards

Before flashing the demo, make sure that you have installed the SAM-BA tool on your host computer.

demo를 flashing하기 전에, host computer에 SAM-BA tool이 installed되었는지 확인한다.

  • connect a USB cable on the board 
  • connect a serial link on DBGU connector and open the terminal emulator program 
  • choose the proper procedure depending on your chip through the following table : 

보드에 USB cable을 연결한다.
DBGU에 serial link을 연결하고 터미널 에뮬레이터 프로그램을 open한다.
아래의 테이블을 통해 chip에 맞는 적절한 과정을 선택한다.

    AT91SAM9260-EK

        + J7 must be opened (BMS=1) to boot from the on-chip Boot ROM
        + follow the AT91SAM9260EKSamBaRecovery recovery method, if needed
        + power up the board
        + verify that the USB connection is established (ATMEL AT91xxxxx Test Board appears in taskbar notification area)

        + on-chip Boot ROM으로부터 boot하기 위해 J7은 open 되어야만 한다. (BMS=1)
        +
AT91SAM9260EKSamBaRecovery
 복구 방법을 따른다.
        + 보드를 power-up 한다.
        + USB가 연결되었는지 확인한다. (ATMEL AT91xxxxx Test Board appears in taskbar notification area)


 

  • launch the proper .bat file : this script will run SAM-BA with proper parameters ; on a Linux host, run the .tcl script form the SAM-BA GUI
  • when the logfile.log appears (this will take a few minutes), remove the USB cable
  • power cycle the board
  • look the system booting on the LCD screen or trough the serial line
  • calibrate accurately the LCD screen (if needed)


적당한 .bat 파일을 launch한다 : 이 script는 적당한 parameter를 갖는 SAM-BA를 run할 것이다. Linux host에서 SAM-BA로부터 .tcl script를 run한다.
logfile.log 가 나타나면(this will take a few minutes), USB cable을 뺀다.
power는 board를 순환함.
LCD screen과 serial line을 통해 system booting을 확인한다.
LCD screen을 calibrate한다 (if needed).


Playing with the demo

Ok, now you should have the Linux demo up'n running on your board ! Have a walk through applications of this demo.
You can also access the Linux console through the serial line plugged on DBGU port.
Use the root login account without password.




Going Forward

If you want to rebuild this demo from sources, go through each component topic and you will have a comprehensive explanation of it role and how to build it.

 

Notes

1: Embedded FLASH available on AT91SAM9XE for instance.

2: AT91SAM9263 MRLA or MRLB could be soldered on this board revision. To identity which chip revision you have, check AT91SAM9263-EK user guide at http://atmel.com/dyn/products/tools_card.asp?tool_id=4057

3: In addition to single slot AT91SAM9G20EK demo files, it contains also demo files for dual SD/MMC slot AT91SAM9G20EK.

  • at91sam9g20ek_demo_linux_<media>.* apply to at91sam9g20ek rev. A and rev. B
  • at91sam9g20ek_2mmc_demo_linux_<media>.* apply to at91sam9g20ek rev. C and onwards

4: If you experience issues with NAND flash accesses,
please refer to the AT91SAM9263-EK Evaluation Board Rev. B User Guide chapter 1.5 NAND Flash Access Issue


 

'[C-03] AT91SAM9260' 카테고리의 다른 글

Linux4SAM - AT91Bootstrap  (0) 2009.11.15
Linux4SAM - Software Tools  (0) 2009.11.15
AT91SAM Community  (0) 2009.11.10
KEIL ARM의 AT91SAM9260 Device Database site  (0) 2009.11.10
Free LinuxLink Trial  (0) 2009.11.10
Posted by eoseontaek


Linux & Open Source related information for AT91 Smart ARM Microcontrollers

'[C-03] AT91SAM9260' 카테고리의 다른 글

Linux4SAM - Software Tools  (0) 2009.11.15
Linux4SAM - Getting Started  (0) 2009.11.14
KEIL ARM의 AT91SAM9260 Device Database site  (0) 2009.11.10
Free LinuxLink Trial  (0) 2009.11.10
AT91SAM9260  (0) 2009.10.24
Posted by eoseontaek

'[C-03] AT91SAM9260' 카테고리의 다른 글

Linux4SAM - Software Tools  (0) 2009.11.15
Linux4SAM - Getting Started  (0) 2009.11.14
AT91SAM Community  (0) 2009.11.10
Free LinuxLink Trial  (0) 2009.11.10
AT91SAM9260  (0) 2009.10.24
Posted by eoseontaek
Atmel AT91SAM9260-EK 용 Embedded Linux Kernel, Toolchain Limited  version을 받을 수 있는 곳



 

'[C-03] AT91SAM9260' 카테고리의 다른 글

Linux4SAM - Software Tools  (0) 2009.11.15
Linux4SAM - Getting Started  (0) 2009.11.14
AT91SAM Community  (0) 2009.11.10
KEIL ARM의 AT91SAM9260 Device Database site  (0) 2009.11.10
AT91SAM9260  (0) 2009.10.24
Posted by eoseontaek
2009. 10. 24. 14:34
Datasheet
Link : http://www.atmel.com/dyn/resources/prod_documents/doc6221.pdf




AT91SAM9260-EK
The AT91SAM9260-EK Evaluation Kit enables the evaluation of and code development for applications running on an AT91SAM9260 device.

Link : http://www.atmel.com/dyn/products/tools_card.asp?tool_id=3933






'[C-03] AT91SAM9260' 카테고리의 다른 글

Linux4SAM - Software Tools  (0) 2009.11.15
Linux4SAM - Getting Started  (0) 2009.11.14
AT91SAM Community  (0) 2009.11.10
KEIL ARM의 AT91SAM9260 Device Database site  (0) 2009.11.10
Free LinuxLink Trial  (0) 2009.11.10
Posted by eoseontaek
이전버튼 1 이전버튼