3.1 Building and Flashing the Linux System Image for SAMA5D27-SOM1-EK1
To build and flash the Linux system image for the SAMA5D27-SOM1-EK1, the user needs to clone the Buildroot and Buildroot-external repositories, load the appropriate configuration file, build the system image, and use Etcher to flash the image onto an SD card.
The following are steps to build and flash the Linux system image for the SAMA5D27-SOM1-EK1:
Step 1: Cloning the Buildroot File System and Packages
- Clone the
Buildroot repository from the linux4sam GitHub using
the following
command:
git clone https://github.com/linux4microchip/buildroot-mchp.git
- The Buildroot repository is cloned to the
\buildroot-mchp
directory. The user needs to switch to the desired branch of the Buildroot repository using the following commands:$ cd buildroot-mchp/ $ git checkout linux4microchip-2024.10 -b linux4microchip-2024.10
- Clone the Buildroot-external repository from the
Linux4Microchip GitHub using the following
command:
git clone https://github.com/linux4microchip/buildroot-external-microchip.git
- The Buildroot-external repository is cloned to the
buildroot-external-microchip
directory. The user needs to switch to the desired branch of the buildroot-external repository using the following commands:$ cd buildroot-external-microchip/ $ git checkout linux4microchip-2024.10 -b linux4microchip-2024.10
Step 2: Loading SAMA5D27-SOM1-EK1 Configuration File
- Use the predefined
defconfig
file to create the required.config
configuration file. Thedefconfig
file is available in theconfigs
folder of thebuildroot-external-microchip
directory. For the SAMA5D27-SOM1-EK1 evaluation board, use thesama5d27_som1_ek_headless_wilcs02_defconfig
file. - To build the root file system with the Linux kernel,
browse to the directory
buildroot-at
and create the.config
file by using the following commands:$ BR2_EXTERNAL=../wilcs02-buildroot-external-microchip/ make sama5d27_som1_ek_headless_wilcs02_defconfig
Step 3: Building the Linux System Image
- Start the build operation using the
$ make
command from thebuildroot-mchp
directory.Note: Ensure that the host PC is connected to the internet before starting the build operation and do not use any build options. - The build operation generates files in the
buildroot-mchp/output/images
directory when completed. Thesdcard.img
file is the whole image file that contains all necessary modules to boot up the board. The following figure illustrates the list of the generated files. - The user can find the driver source files at
build/linux-custom/drivers/net/wireless/microchip/wilc1000
.Note: The driver directory name is WILC1000 only for legacy reasons.
Step 3: Flashing the SD Card Image Using Etcher
The SD card image (
sdcard.img
) contains all the
necessary modules required to boot up the board. Flash the image
into the microSD card using the Etcher application.- To download and install the Etcher application on the
Linux host machine, go to Etcher.Note: Ensure to download the correct version of Etcher based on the version and operating system.
- Flashing using Etcher requires the following two simple
steps:
- Double-click the downloaded
.exe
file to install and run Etcher application. - Click Select image to choose the
sdcard.img
file or files. - Click Select target to download the
sdcard.img
file into target microSD card. - Click Flash! to start the flashing process.
- Double-click the downloaded