[STM32] Introduction to FreeRTOS

00. Table of Contents

01. What is FreeRTOS

The name of FreeRTOS is divided into two parts: Free and RTOS. Free means free, free and unconstrained. The full name of RTOS is Real Time Operating System, and the Chinese name is Real Time Operating System. FreeRTOS is a free RTOS system. RTOS does not refer to a certain system, but refers to a type of system, such as UCOS, FreeRTOS, RTX, RT-Thread, etc. are all RTOS operating systems.

The operating system allows multiple tasks to run at the same time. This is called multitasking. In fact, a processor core can only run one task at a time. The responsibility of the task scheduler in the operating system is to decide which task to run at a certain moment, and task scheduling switches between tasks very quickly. This gives people the illusion that there are multiple tasks running at the same time.

The classification method of the operating system can be determined by the working method of the task scheduler. For example, some operating systems assign the same running time to each task, and when the time is up, it is the next task's turn. Unix operating system is like this. The task scheduler of RTOS is designed to be predictable, which is exactly what the embedded real-time operating system needs. In the real-time environment, the operating system must respond to a certain event in real time. Therefore, the system task is assigned a task priority. The scheduler can then decide which task should be run at the next moment based on this priority.

FreeRTOS is a kind of RTOS system. FreeRTOS is very small and can run in a microcontroller with limited resources. In terms of the number of files, FreeRTOS is much smaller than UCOSII and UCOSSIII.

02. Why choose FreeRTOS

There are many RTOS systems, but why choose FreeRTOS? And FreeRTOS has few materials, and most of them are in English. The specific reasons are as follows:

  1. FreeRTOS is free. This is very important. UCOS is charged. UCOS is the first choice if you learn RTOS system, but you must consider the cost if you are making a product. Obviously, FreeRTOS is a good choice, of course, you can also choose other free RTOS systems.

  2. Many semiconductor manufacturers' SDK packages use FreeRTOS as their operating system, especially chips or modules with protocol stacks such as WIFI and Bluetooth.

  3. Many software manufacturers use FreeRTOS as the operating system of their company's software. It is not as good as the famous TouchGFX, and all its routines are based on FreeRTOS. All ST's routines that use the RTOS system also use FreeRTOS.

  4. Simple, the number of files in FreeRTOS is very small, much less compared with UCOS system.

  5. The documentation is relatively complete. You can find the required documentation and source code on the FreeRTOS official website, but all the documentation is in English.

  6. FreeRTOS has been ported to many different microprocessors. It is not as good as the STM32F1, F2, F3, F4 and the latest F7 that we use. This greatly facilitates our study and use.

  7. The social occupancy is high. FreeRTOS has jumped to the first place in the RTOS system occupancy in recent years as calculated by EEtimes.

2010 and 2011 RTOS Use List
Insert picture description here

2012 and 2013 RTOS Use List
Insert picture description here

2013 and 2014 RTOS use list
Insert picture description here

2014 and 2015 RTOS use list
Insert picture description here

2017 RTOS Use List
Insert picture description here

2019 RTOS Use List
Insert picture description here

03. FreeRTOS features

Insert picture description here

04. FreeRTOS commercial license

FreeRTOS has derived two other systems: OpenRTOS and SafeRTOS. The FreeRTOS open source license agreement allows the FreeRTOS system to be used in commercial applications without the need to disclose your private code. You can use OpenRTOS if you have the following requirements:

  • You cannot accept the conditions of the FreeRTOS open source license agreement
  • You need technical support
  • Want to get development help
  • Need legal protection or other protection

The use of OpenRTOS requires compliance with commercial agreements. The difference between the open source license of FreeRTOS and the commercial license of OpenRTOS is as follows:

Insert picture description here

05. Reserved

06. Appendix

6.1 [STM32] STM32 series tutorial summary

Website: [STM32] STM32 series tutorial summary

07. Reference

《FreeRTOS Reference Manual》

《Using the FreeRTOS Real Time Kernel -A Practical Guide》

《The Definitive Guide to ARM Cortex-M3 and Cortex-M4 Processors,3rd Edition》

Guess you like

Origin blog.csdn.net/dengjin20104042056/article/details/109400155