Sign In Start Free Trial
Account

Add to playlist

Create a Playlist

Modal Close icon
You need to login to use this feature.
  • Book Overview & Buying Mastering Embedded Linux Development
  • Table Of Contents Toc
  • Feedback & Rating feedback
Mastering Embedded Linux Development

Mastering Embedded Linux Development

By : Frank Vasquez, Mr. Chris Simmonds
close
close
Mastering Embedded Linux Development

Mastering Embedded Linux Development

By: Frank Vasquez, Mr. Chris Simmonds

Overview of this book

Mastering Embedded Linux Development' is designed to be both a learning resource and a reference for your embedded Linux projects. The book starts by breaking down the fundamental elements that underpin all embedded Linux projects: the toolchain, the bootloader, the kernel, and the root filesystem. First, you will download and install a pre-built toolchain. After that, you will cross-compile each of the remaining three elements from scratch and learn to automate the process using Buildroot and the Yocto Project. The book progresses with coverage of over-the-air software updates and rapid prototyping with add-on boards. Two new chapters tackle modern development practices including Python packaging and deploying containerized applications. These are followed by a chapter on writing multithreaded code and another on techniques to manage memory in an efficient way. The final chapters demonstrate how to debug your code, whether it resides in user space or in the Linux kernel itself. In addition to GDB, the book also covers the different tracers and profilers that are available for Linux so that you can quickly pinpoint any performance bottlenecks in your system. By the end of this book, you will be able to create efficient and secure embedded devices with Linux that will delight your users.
Table of Contents (28 chapters)
close
close
1
Part 1: Elements of Embedded Linux
7
Part 2: Building Embedded Linux Images
11
Part 3: System Architecture and Design Decisions
18
Part 4: Developing Applications
23
Part 5: Debugging and Optimizing Performance

To get the most out of this book

The software used in this book is entirely open source. In almost all cases, I have used the latest stable versions available at the time of writing. While I have tried to describe the main features in a manner that is not version-specific, it is inevitable that some of the examples will need adaptation to work with later software. Here is the primary hardware and software used throughout the book:

  • QEMU (64-bit Arm)
  • Raspberry Pi 4
  • BeaglePlay
  • Yocto Project 5.0 Scarthgap
  • Buildroot 2024.02
  • Bootlin aarch64 glibc stable toolchain 2024.02-1
  • Arm GNU AArch32 bare-metal target (arm-none-eabi) toolchain 13.2.Rel1
  • U-Boot v2024.04
  • Linux kernel 6.6

Embedded development involves two systems: the host, which is used for developing the programs, and the target, which runs them. For the host system, I chose Ubuntu 24.04 LTS because of its widespread adoption and long-term maintenance guarantees. You may decide to run Linux on Docker, a virtual machine, or Windows Subsystem for Linux, but be aware that some tasks, such as building a distribution using The Yocto Project, are quite demanding and run better on a native installation of Linux.

For the targets, I chose the QEMU emulator, the Raspberry Pi 4, and the BeaglePlay. Using QEMU means that you can try out most of the examples without having to invest in any additional hardware. On the other hand, some things work better with real hardware. For that, I picked the Raspberry Pi 4 because it is inexpensive, widely available, and has very good community support. The BeaglePlay replaces the BeagleBone Black used in previous editions of the book. Of course, you are not limited to just these three targets. The idea behind the book is to provide you with general solutions to problems so that you can apply them to a wide range of target boards.

Download the example code files

The code bundle for the book is hosted on GitHub at https://github.com/PacktPublishing/Mastering-Embedded-Linux-Development. We also have other code bundles from our rich catalog of books and videos available at https://github.com/PacktPublishing. Check them out!

Download the color images

We also provide a PDF file that has color images of the screenshots/diagrams used in this book. You can download it here: https://packt.link/gbp/9781803232591.

Conventions used

There are a number of text conventions used throughout this book.

CodeInText: Indicates code words in text, database table names, folder names, filenames, file extensions, pathnames, dummy URLs, user input, and Twitter handles. For example: “Execute the make menuconfig command:”

A block of code is set as follows:

require recipes-core/images/core-image-minimal.bb
IMAGE_INSTALL:append = " helloworld strace"

Any command-line input or output is written as follows:

$ bitbake -c populate_sdk nova-image

Bold: Indicates a new term, an important word, or words that you see on the screen. For instance, words in menus or dialog boxes appear in the text like this. For example: “Back out of External toolchain and open the Toolchain submenu.”

Warnings or important notes appear like this.

Tips and tricks appear like this.

Unlock full access

Continue reading for free

A Packt free trial gives you instant online access to our library of over 7000 practical eBooks and videos, constantly updated with the latest in tech
bookmark search playlist download font-size

Change the font size

margin-width

Change margin width

day-mode

Change background colour

Close icon Search
Country selected

Close icon Your notes and bookmarks

Delete Bookmark

Modal Close icon
Are you sure you want to delete it?
Cancel
Yes, Delete

Confirmation

Modal Close icon
claim successful

Buy this book with your credits?

Modal Close icon
Are you sure you want to buy this book with one of your credits?
Close
YES, BUY