Share E-Book
Scan to open this page

Scan with your phone to open this page

Author: Chris Simmonds

Rating No ratings yet

Key Features Discover how to build and configure reliable embedded Linux devices This book has been updated to include Linux 4.9 and Yocto Project 2.2 (Morty) This comprehensive guide covers the remote update of devices in the field and power management Book Description Embedded Linux runs many of the devices we use every day, from smart TVs to WiFi routers, test equipment to industrial controllers - all of them have Linux at their heart. Linux is a core technology in the implementation of the inter-connected world of the Internet of Things. The comprehensive guide shows you the technologies and techniques required to build Linux into embedded systems. You will begin by learning about the fundamental elements that underpin all embedded Linux projects: the toolchain, the bootloader, the kernel, and the root filesystem. You'll see how to create each of these elements from scratch, and how to automate the process using Buildroot and the Yocto Project. Moving on, you'll find out how to implement an effective storage strategy for flash memory chips, and how to install updates to the device remotely once it is deployed. You'll also get to know the key aspects of writing code for embedded Linux, such as how to access hardware from applications, the implications of writing multi-threaded code, and techniques to manage memory in an efficient way. The final chapters show you how to debug your code, both in applications and in the Linux kernel, and how to profile the system so that you can look out for performance bottlenecks. By the end of the book, you will have a complete overview of the steps required to create a successful embedded Linux system. What you will learn Evaluate the Board Support Packages offered by most manufacturers of a system on chip or embedded module Use Buildroot and the Yocto Project to create embedded Linux systems quickly and efficiently Update IoT devices in the field without compromising security Reduce the power budget of devices to make batte

AI Reading Assistant

Whole-book reading guide from stratified index samples; jump to passages in the text

AI guide
【One-Line Pitch】 A practical, end-to-end guide to building embedded Linux devices from scratch—toolchain, bootloader, kernel, root filesystem, and beyond—for engineers who want to understand what happens under the hood rather than just accept a vendor's board support package. 【Book Arc】 - **Opening (~0%–10%)**: Frames the five core elements of every embedded Linux system (toolchain, bootloader, kernel, root filesystem, plus your application) and explains the open-source licensing context you'll be working within. - **Early (~10%–35%)**: Builds the foundation hands-on—constructing a cross toolchain with crosstool-NG, understanding bootloaders (U-Boot, barebox, UEFI), device trees, and configuring/compiling the kernel. - **Middle (~35%–55%)**: Moves into the root filesystem: what a minimal rootfs needs, init and shell basics, and how the kernel hands off control to user space. - **Late (~55%–80%)**: Covers build automation with Buildroot and the Yocto Project, storage strategies for flash memory, and remote field updates for deployed devices. - **Ending (~80%–100%)**: Focuses on writing and hardening embedded code—hardware access from applications, multi-threaded programming, memory management, scheduling, and debugging/profiling applications and the kernel. 【Key Takeaways】 - **Embedded Linux is five composable elements, not a monolith** (Opening): toolchain, bootloader, kernel, root filesystem, and your application. Understanding each separately lets you replace vendor defaults with better choices. - **A cross toolchain is the first thing you build, and crosstool-NG is the practical path** (Early): Binutils, GCC, and a C library (glibc, musl, uClibc) form the standard GNU toolchain; crosstool-NG generates a standalone one from source. - **Bootloaders are staged and board-specific** (Early): U-Boot, barebox, and UEFI each follow a multi-phase boot sequence; device trees (compiled with `dtc`) describe hardware and let you layer board variants without duplicating code. - **Kernel configuration is where vendor support matters most** (Middle): Mainline Linux supports only a subset of devices, so you often depend on SoC vendor kernels—choose vendors who upstream their changes. - **The kernel's job ends at `init`** (Middle): A minimal root filesystem needs only `init`, a shell, and daemons; everything else is your responsibility to assemble. - **Buildroot and Yocto automate the whole pipeline** (Late): These build systems handle toolchain, kernel, rootfs, and package integration so you don't hand-roll every step. - **Field updates and power management are deployment concerns, not afterthoughts** (Late): Remote update strategy and power budgeting must be designed in, not bolted on. - **Debugging and profiling span both user space and kernel** (Ending): Application-level debugging, kernel debugging, and system profiling are distinct skills you'll need to find performance bottlenecks. 【Reading Tips】 - **Deep-read the early chapters on toolchain and bootloader**—these are the hardest to get right and the most vendor-specific; skimming them will cost you later. - **Skim the licensing discussion** if you already understand GPL v2 and kernel module implications; it's context, not technique. - **Treat the build-system chapters (Buildroot/Yocto) as reference**—read once for the workflow, then return when you actually configure a build. - **The debugging/profiling chapters are best read with a real target board in hand**; the techniques only stick when applied. - **Watch for version-specific details** (Linux 4.9, Yocto 2.2 Morty)—commands and configs may differ in newer releases. 【Coverage Limits】 The excerpts cover the book's structure, foundational concepts, and early-to-mid technical detail well, but the later chapters on remote updates, power management, and debugging are only summarized here—specific techniques and examples from those sections are not covered in depth.
Excerpt 1
y most manufacturers of a system on chip or embedded module Use Buildroot and the Yocto Project to create embedded Linux systems quickly and efficiently Upda...
View in text
Excerpt 2
-alone cross toolchain from source. Installing crosstool-NG Before you begin, you will need a working native toolchain and build tools on your host PC. To wo...
View in text
Excerpt 3
device. The memory location, 0x82000000, is chosen to be in an area of RAM that is not being used at this moment. If we intend to boot this kernel, we have t...
View in text
Excerpt 4
; if it is zero, it waits forever (this is the default); or if it is less than zero, it reboots without any delay. quiet Sets the console log level to , supp...
View in text
Excerpt 5
des statically with mknod is quite hard work and inflexible. There are other ways to create device nodes automatically on demand: devtmpfs: This is a pseudo...
View in text
Excerpt 6
area, or the spare area. SLC designs usually have 1 byte of OOB per 32 bytes of main storage, so for a 2 KiB page device, the OOB is 64 bytes per page, and f...
View in text
Excerpt 7
to the internet means those bugs can be exploited from afar. Consequentially, we have a common requirement to be able to update the software in the field. So...
View in text
Excerpt 8
ss, MKDEV(MAJOR_NUM, i)); } class_destroy(dummy_class); unregister_chrdev(MAJOR_NUM, DEVICE_NAME); printk("Dummy unloaded\n"); } module_init(dummy_init); mod...
View in text
Tags
AI categories
Programming LanguageOSLinux
ISBN: 1787283283
Publisher: Packt Publishing
Publish Year: 2017
Language: English
Pages: 478
File Format: PDF
File Size: 5.1 MB
Text Preview (First 20 pages)
Registered users can read the full content for free

Register as a Gaohf Library member to read the complete e-book online for free and enjoy a better reading experience.

Generating text preview…