
Hands-On RTOS with Microcontrollers
Building real-time embedded systems using FreeRTOS, STM32 MCUs, and SEGGER debug tools
- 496 pages
- English
- ePUB (mobile friendly)
- Available on iOS & Android
Hands-On RTOS with Microcontrollers
Building real-time embedded systems using FreeRTOS, STM32 MCUs, and SEGGER debug tools
About this book
Build a strong foundation in designing and implementing real-time systems with the help of practical examples
Key Features
- Get up and running with the fundamentals of RTOS and apply them on STM32
- Enhance your programming skills to design and build real-world embedded systems
- Get to grips with advanced techniques for implementing embedded systems
Book Description
A real-time operating system (RTOS) is used to develop systems that respond to events within strict timelines. Real-time embedded systems have applications in various industries, from automotive and aerospace through to laboratory test equipment and consumer electronics. These systems provide consistent and reliable timing and are designed to run without intervention for years.This microcontrollers book starts by introducing you to the concept of RTOS and compares some other alternative methods for achieving real-time performance. Once you've understood the fundamentals, such as tasks, queues, mutexes, and semaphores, you'll learn what to look for when selecting a microcontroller and development environment. By working through examples that use an STM32F7 Nucleo board, the STM32CubeIDE, and SEGGER debug tools, including SEGGER J-Link, Ozone, and SystemView, you'll gain an understanding of preemptive scheduling policies and task communication. The book will then help you develop highly efficient low-level drivers and analyze their real-time performance and CPU utilization. Finally, you'll cover tips for troubleshooting and be able to take your new-found skills to the next level.By the end of this book, you'll have built on your embedded system skills and will be able to create real-time systems using microcontrollers and FreeRTOS.
What you will learn
- Understand when to use an RTOS for a project
- Explore RTOS concepts such as tasks, mutexes, semaphores, and queues
- Discover different microcontroller units (MCUs) and choose the best one for your project
- Evaluate and select the best IDE and middleware stack for your project
- Use professional-grade tools for analyzing and debugging your application
- Get FreeRTOS-based applications up and running on an STM32 board
Who this book is for
This book is for embedded engineers, students, or anyone interested in learning the complete RTOS feature set with embedded devices. A basic understanding of the C programming language and embedded systems or microcontrollers will be helpful.
]]>
Frequently asked questions
- Essential is ideal for learners and professionals who enjoy exploring a wide range of subjects. Access the Essential Library with 800,000+ trusted titles and best-sellers across business, personal growth, and the humanities. Includes unlimited reading time and Standard Read Aloud voice.
- Complete: Perfect for advanced learners and researchers needing full, unrestricted access. Unlock 1.4M+ books across hundreds of subjects, including academic and specialized titles. The Complete Plan also includes advanced features like Premium Read Aloud and Research Assistant.
Please note we cannot support devices running on iOS 13 and Android 7 or earlier. Learn more about using the app.
Information
Section 1: Introduction and RTOS Concepts
- Chapter 1, Introducing Real-Time Systems
- Chapter 2, Understanding RTOS Tasks
- Chapter 3, Task Signaling and Communication Mechanisms
Introducing Real-Time Systems
- What is "real-time" anyway?
- Defining RTOS
- Deciding when to use an RTOS
Technical requirements
What is real-time anyway?
The ranges of timing requirements
- Taking readings from a temperature sensor via the ADC
- Running a closed-loop control algorithm (to maintain a constant temperature at the soldering iron tip)
- Adjusting the output of the heater as needed



The ways of guaranteeing real-time behavior
Types of real-time systems
Hardware
- The inflexibility of non-programmable devices.
- The expertise required is generally less commonly available than software/firmware developers.
- The cost of full-featured programmable devices (for example, large FPGAs).
- The high cost of developing a custom ASIC.
Bare-metal firmware
Table of contents
- Title Page
- Copyright and Credits
- About Packt
- Contributors
- Preface
- Section 1: Introduction and RTOS Concepts
- Introducing Real-Time Systems
- Understanding RTOS Tasks
- Task Signaling and Communication Mechanisms
- Section 2: Toolchain Setup
- Selecting the Right MCU
- Selecting an IDE
- Debugging Tools for Real-Time Systems
- Section 3: RTOS Application Examples
- The FreeRTOS Scheduler
- Protecting Data and Synchronizing Tasks
- Intertask Communication
- Section 4: Advanced RTOS Techniques
- Drivers and ISRs
- Sharing Hardware Peripherals across Tasks
- Tips for Creating a Well-Abstracted Architecture
- Creating Loose Coupling with Queues
- Choosing an RTOS API
- FreeRTOS Memory Management
- Multi-Processor and Multi-Core Systems
- Troubleshooting Tips and Next Steps
- Assessments
- Other Books You May Enjoy