Good RTOSs are scalable to meet different sets of requirements for different applications.
In contrast to real-time operating systems, the most popular operating systems for personal computer use such as Windows are called general-purpose operating systems. Preemption defines the capability to identify the task that needs a resource the most and allocates it the control to obtain the resource.
Once again, hard real-time operating systems can guarantee that control system input data is processed in a consistent amount of time with a fixed worst-case maximum.
RTOSs offer non-fragmenting memory allocation techniques instead of heaps. And yet others rely on message passing for positive synchronization as well as data passing duties.
It is these memory, speed and timing constraints that dictate the use of real-time operating systems in embedded software. While more in-depth technical information on how real-time operating systems differ from general-purpose operating systems is given in a section below, it is important to remember that there are advantages and disadvantages to both types of OS.
This ensures some amount of run-time for each task, but means that the designer's wishes are not always followed. However, these operating systems are designed for different use cases than real-time operating systems, and are not the ideal platform for running applications that require precise timing or extended up-time.
It is constant, independent of any load factor such as the number of tasks in a software system. The sections below outline basic concepts and terminology related to real-time operating systems.
In a firm real-time system, time constraints have to be met in a majority of cases. For more complex embedded systems, an RTOS can be a combination of various modules, including the kernel, networking protocol stacks, and other components.
The Task Scheduler controls the execution of application software tasks, and can make them run in a very timely and responsive fashion. When the high-priority task has finished its current work, the mid-priority task would be allowed to continue. Neither alternative is acceptable for embedded systems that need to provide service continually for long periods of time.
Then if the need for a task switch arises anywhere within a 10-millisecond timeframe, the actual task switch would occur only at the end of the current 10-millisecond period. Task Switching Timing. If messages can be sent more quickly than they can be handled, the RTOS will provide message queues for holding the messages until they can be processed.