Jump to content

FreeRTOS

From Wikipedia, the free encyclopedia

This is an old revision of this page, as edited by Mrchapp (talk | contribs) at 17:51, 26 July 2012 (remove bogus pic). The present address (URL) is a permanent link to this revision, which may differ significantly from the current revision.

FreeRTOS
DeveloperReal Time Engineers ltd.
OS familyReal-time operating systems
Working stateCurrent
Source modelFree Software/Open Source
Latest release7.1.1 / May, 2012
Repository
Marketing targetEmbedded devices
PlatformsARM (ARM7, ARM9, Cortex-M3), Atmel AVR, AVR32, HCS12, MicroBlaze, MSP430, PIC, Renesas H8/S, SuperH, RX, x86, 8052, Coldfire, V850, 78K0R, Fujitsu MB91460 series, Fujitsu MB96340 series, Nios II
Kernel typeMicrokernel
LicenseModified GPL to allow commercial use
Official websitehttp://www.freertos.org/

FreeRTOS is a popular[1] real-time operating system for embedded devices, being ported to 31 microcontrollers. It is distributed under the GPL with an optional exception. The exception permits users' proprietary code to remain closed source while maintaining the kernel itself as open source, thereby facilitating the use of FreeRTOS in proprietary applications.[2]

Implementation

FreeRTOS is designed to be small and simple. The kernel itself consists of only three or four C files. To make the code readable, easy to port, and maintainable, it is written mostly in C, but there are a few assembly functions included where needed (mostly in architecture specific scheduler routines).

FreeRTOS provides methods for multiple threads or tasks, and semaphores. Thread priorities are supported. In addition there are three schemes of memory allocation provided, allocate only, allocate and free with a very simple, fast, algorithm, and a more complex allocate and free algorithm. There are none of the more advanced features typical found in operating systems like Linux or Microsoft Windows, such as device drivers, advanced memory management, user accounts, and networking. The emphasis is on compactness and speed of execution. FreeRTOS can be thought of as a 'thread library' rather than an 'operating system', although command line interface and POSIX like IO abstraction add-ons are available.

FreeRTOS implements multiple threads by having the host program call a thread tick method at regular short intervals. The thread tick method switches tasks depending on priority and a round-robin scheduling scheme. The usual interval is 1/1000 of a second to 1/100 of a second, via. an interrupt from a hardware timer, but this interval is often changed to suit a particular application.

The download contains prepared configurations and demonstrations for every port and compiler, allowing rapid application design. The FreeRTOS.org site also contains RTOS tutorials, details of the RTOS design and performance comparison results for various microcontrollers.

Key features

  • Very small memory footprint, low overhead, and very fast execution.
  • Very good for hobbyists who are new to OSes.
  • Scheduler can be configured for both preemptive or cooperative operation.
  • Coroutine support (Coroutine in FreeRTOS is a very simple and lightweight task that has very limited use of stack)
  • Trace support through generic trace macros. Tools such as FreeRTOS+Trace (provided by the FreeRTOS partner Percepio) can thereby record and visualize the runtime behavior of FreeRTOS-based systems. This includes task scheduling and kernel calls for semaphore and queue operations.

Supported architectures

SAFERTOS was constructed as a complementary offering to FreeRTOS, with common functionality but with a uniquely designed safety critical implementation. The FreeRTOS functional model was subjected to a full HAZOP, weakness within the functional model and API where identified and resolved. The resulting requirements set was put through a full IEC 61508 SIL 3 development life cycle, the highest possible for a software only component.


Another related project is OPENRTOS which has an identical code base to FreeRTOS but with different licensing. The OPENRTOS license removes all reference to the GPL and its implications. For example, one of the conditions of using FreeRTOS in a commercial product is that the user is made aware of the use of FreeRTOS and the source code must be provided upon request. As it is a commercial product available for purchase, OPENRTOS doesn't have this licensing requirement. OPENRTOS users also have access to full techical support.

See also

References