Getting Started SAM9
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.
Click on the image up above to select a topic.
Several pieces of software are involved to boot a linux kernel on SAM 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 :
- Boot Program - ROM Code - Checks if a valid application is present in FLASH and if it is the case downloads it into internal SRAM.
For more information on this topic, please check the Boot strategies section and particularly the Boot capabilities matrix.
- AT91Bootstrap - In charge of hardware configuration, downloads U-Boot / Barebox binary from FLASH to SDRAM / DDRAM, starts the bootloader (third level bootloader actually)
- U-Boot or Barebox - The bootloader, in charge of downloading kernel binaries from FLASH, network, SD card, etc. It then loads the Device Tree Binary and starts the Linux kernel.
- Linux kernel - The kernel of the Operating System.
- Root Filesystem - Contains applications which are executed on the target, using the OS kernel services.
Linux4SAM NandFlash demo - Memory map
- a Windows XP host (or later) or a Linux distribution to run the SAM-BA tool ;
- power supply stocked with the Evaluation Kit ;
- USB or micro-USB Device Cable ;
- serial Cross Cable (Female-Female) or a type A-micro-B USB cable ;
- the Evaluation Kit. Check below how kits look like and how to connect them :
- a serial terminal emulator (HyperTerminal, minicom, etc.) :
- sama5d2 revision A, only to access the ROMCode through serial interface and see the
RomBOOT message appearing, configure your serial line to 57600.
Change it back to 115200 for normal operation.
All components and demo binaries are now configured to work at
The usual serial communication parameters are
| Baud rate
|| 8 bits
|| 1 bit
| Flow control
- the SAM-BA tool => Check the SoftwareTools#SAM_BA page ;
- the demo archive provided just below. This archive contains :
- all components binaries : AT91Bootstrap, U-Boot, the Device Tree Binary, Linux kernel, root filesystem ;
- a TCL/SAM-BA script that interfaces with the SAM-BA tool to flash the demo ;
.sh script able to run the flashing script calling SAM-BA itself.
Flashing a demo on AT91 boards
Before flashing the demo, make sure that you have installed the SAM-BA tool
on your host computer.
Then you will have to choose the proper procedure depending on the Evaluation Kit that you have. Note however that the procedure is extremely similar whichever EK board you may choose.
- Older SAM9 boards
• USBGadget Config: Configure AT91 USB Gadget on Linux and Endpoint order management (composite USB). (Kernel, linux-4.4-at91)
• Real Time: Enable Real Time support for AT91SAM9 Soc. (Kernel)
• Audio Record On At 91sam 9g 20ek: Audio Record on At91sam9g20ek. ()
• SAM9 M10 Gstreamer: M10 Vdec support. ()