From Bare Metal to Real-Time Operating Systems (RTOS): When to Make the Switch?

From Bare Metal to Real-Time Operating Systems (RTOS): When to Make the Switch?

Kunvar Chokshi is an embedded development engineer with over ten years of embedded experience. The Edian team provided the translation. Embedded developers typically start their projects in the bare metal domain—without an operating system, no multitasking, just raw code running directly on the hardware. This approach is all about direct register manipulation and peripheral control … Read more

Task Scheduling in FreeRTOS – Startup

Task Scheduling in FreeRTOS - Startup

One of the core tasks of an operating system is task scheduling. Tasks have different names in different operating systems, such as task, thread, or process, with processes typically associated with independent address spaces. The goals of scheduling are to ensure fairness, real-time performance (for real-time systems), maximize CPU utilization, and meet task priority requirements. … Read more

Chapter 18 of FreeRTOS: Multi-Core Scheduling (SMP Extension)

Chapter 18 of FreeRTOS: Multi-Core Scheduling (SMP Extension)

Table of Contents 1. Overview of SMP Architecture 1.1 Basic Concepts 1.2 FreeRTOS-SMP Features 2. Inter-Core Task Migration Experiment 2.1 Experiment Objectives 2.2 Experiment Steps 2.3 Experiment Result Analysis 3. Protection of Shared Resources in Multi-Core Systems 3.1 Common Issues 3.2 Comparison of Solutions 3.3 Example Code 4. Key API Analysis 4.1 SMP Extension APIs … Read more

Chapter 25 of ‘Getting Started with FreeRTOS’: Practical Memory Leak Detection

Chapter 25 of 'Getting Started with FreeRTOS': Practical Memory Leak Detection

Table of Contents Course Objectives 1. Custom malloc/free Hook Functions 1.1 Basics of FreeRTOS Memory Management 1.2 Principles of Hook Function Implementation 1.3 Practical: Implementation of Memory Tracking Hook 2. Memory Fragmentation Monitoring Solutions 2.1 Causes of Memory Fragmentation 2.2 Fragmentation Detection Methods 2.3 Comparison Table of Optimization Strategies Practical Project: Memory Monitoring System 3.1 … Read more

FreeRTOS Learning: System Porting

FreeRTOS Learning: System Porting

Scan to FollowLearn Embedded Together, learn and grow together This series of articles on FreeRTOS aims to help beginners quickly get started and master the basic principles and usage methods of FreeRTOS while organizing knowledge for themselves. FreeRTOS Quick Start – Initial Exploration of the System FreeRTOS Official Chinese Website is Now Live FreeRTOS Coding … Read more

From Task Scheduling to Interrupt Management: The ESP32-FreeRTOS Example Library to Kickstart Your IoT Development

From Task Scheduling to Interrupt Management: The ESP32-FreeRTOS Example Library to Kickstart Your IoT Development

When you are still struggling with the “while(1)” loop in microcontroller programming, the absence of a Real-Time Operating System (RTOS) has become the biggest obstacle to advancing your project. The ESP32-freeRTOS open-source project provides over 20 practical examples, allowing you to easily implement task scheduling, resource synchronization, and interrupt management in C, completely bidding farewell … Read more

ESP32-S3 Practical Project – Project Requirements

ESP32-S3 Practical Project - Project Requirements

Sharing is a positive attitude towards life! Project Requirements ESP32-S3 is an MCU chip that integrates 2.4 GHz Wi-Fi and Bluetooth 5 (LE), supporting Long Range mode. The ESP32-S3 is equipped with a Xtensa® 32-bit LX7 dual-core processor, with a maximum frequency of 240 MHz, 512 KB of built-in SRAM (TCM), 45 programmable GPIO pins, … Read more

Task Analysis in FreeRTOS

Task Analysis in FreeRTOS

1.1 Task StatesApplications can contain multiple tasks, but generally, a microcontroller (MCU) in an application has only one core, meaning that at any given time, only one task is actually executed. This means a task can have one of two states, namelyRunning StateandNon-Running State. However, the non-running state can be further divided into several sub-states. … Read more

Chapter 16 of FreeRTOS: Stream Buffer

Chapter 16 of FreeRTOS: Stream Buffer

Table of Contents 1. Core Concepts of Stream Buffer 1.1 Design Purpose 1.2 Key Features 2. Practical Implementation of Efficient Data Stream Transmission 2.1 Serial Data Transmission and Reception Example 2.2 Performance Optimization Techniques 3. In-depth Comparison with Queues 4. Quick Reference for Key APIs 5. Best Practice Recommendations 1. Core Concepts of Stream Buffer … Read more

Simulink Multi-Task Code Generation and Real-Time Scheduling

Simulink Multi-Task Code Generation and Real-Time Scheduling

In the model-based design (MBD) process, multi-task code generation and real-time scheduling serve as a critical bridge connecting model design to hardware implementation. As the functionality of industrial control systems becomes increasingly complex, issues such as multi-rate sampling, real-time task priority management, and resource conflict avoidance have become significant development challenges. Simulink provides comprehensive support … Read more