Hard and Soft Real-Time System

Source: Internet
Author: User

A system is said to be real-time if the total correctness of an operation depends not only upon its logical correctness, but also upon the time in which it is already med. the classical conception is that in a hard or immediate
Real-Time System, the completion of an operation after its deadline is considered useless-ultimately, this may lead to a critical failure of the complete system. A soft real-time system on the other hand will
Tolerate such lateness, and may respond with decreased service quality (e.g., dropping frames while displaying a video ).

Hard Real-Time SystemsAre typically found interacting at a low level with physical hardware, in embedded
Systems. For example, a car engine control
System is a hard real-time system because a delayed signal may cause engine failure or damage. Other examples of hard real-time embedded systems include medical systems such as heart pacemakers and
Industrial Process controllers.

Hard real-time systems are used when it is imperative that an event is reacted to within a strict deadline. usually such strong guarantees are required of systems for which not reacting in a certain window of time wocould cause great loss in some manner, especially
Physically damaging the surroundings or threatening human lives (although the strict definition is simply that missing the deadline constitutes failure of the system ). systems that always have hard real-time constraints (due to the potentially severe outcome
Of missing a deadline) include nuclear power stations and car airbags. In the context of multitasking systems the scheduling policy
Is normally priority driven pre-emptive schedulers.
Other scheduling algorithms include Earliest Deadline First, Which, ignoring the overhead
Of context switching, is sufficient for system loads of less than 100%.[Citation
Needed
]


New overlay scheduling systems, such as an adaptive partition scheduler assist in managing large systems
With a mixture of hard real-time and non real-time applications.

Soft Real-Time SystemsAre typically those used where there is some issue of concurrent access and the need to keep a number of connected systems up to date with changing situations. Example: the software that
Maintains and updates the flight plans for each cial airliners. These can operate to a latency of seconds. Live audio-video systems are also
Usually soft real-time; violation of constraints results in degraded quality, but the system can continue to operate.

It is important to note that hard versus soft real-time does not necessarily relate to the length of time available. A machine may overheat if a processor does not turn on cooling within 15 minutes (hard real-time ). on the other hand, a network
Interface Card may lose buffered data if it is not read within a fraction of a second, but the data can be resent over the network (Soft Real-Time), without major adverse consequences.

Hardware real-time, as its name implies, is controlled in real time by hardware, that is, the hardware on the computer motherboard-integrated circuits, such as CPU and bios. That is to say, the CPU computing cycle (CPU cycle) follows the preset standards, such as average allocation (so-called time slice), or allocation based on certain hardware priorities, to prevent a hardware from taking the response time of the entire system, so that various external components, especially the input and output devices, can receive timely feedback from the system. That is to say, how long can an external component receive system feedback and obtain the CPU computing time,
This is the so-called deterministic real time. In fact, real-time systems not only require hardware support, but also special real-time operating systems. Therefore, these systems are generally specialized devices, such as industrial automation control and military electronic equipment. Their operating systems are dedicated.

Soft Real-Time refers to changes made to non-real-time operating systems, such as desktop computer operating systems, such as Windows, to achieve near real-time results, but strictly speaking, it is not real-time, but close to real-time. It uses a dedicated software component to replace the control functions in the desktop computer operating system, such as process control and kernel, in order to achieve a response speed close to the ability to get system feedback on time and complete computing. I know that a few small companies have successfully developed
The real-time software attachment on XP embedded (xpe) allows developers to use xpe to achieve near-soft effect. In the European and American markets, this method has been developed for commercial use to develop and manufacture "soft" gambling game machines, medical devices, automated control devices, and so on.

#######################

Real Time OS (real time operating system)


Real-time Operating System

Once a Real-Time Word is entered, there is a strict requirement on the response time. The real-time operating system must be real-time, and certain operations must be completed within the specified time. It is mainly used in industrial control. Generally, the number of tasks in Real-time Operating Systems is fixed, and there are hard real-time and soft real-time points. Hard Real-time requires that operations must be completed within the specified time, this is guaranteed during the operating system design; soft real-time is not so strict, As long as according to the task priority, the operation can be completed as quickly as possible. The operating system we usually use can be changed to a real-time operating system after certain changes.

A real-time operating system is an operating system that ensures that specific functions are completed within a certain period of time. For example, an operating system can be designed to ensure that robots on the production line can obtain an object. In the "hard" real-time operating system, if the calculation of reachable objects cannot be completed within the allowed time, the operating system will end with an error. In the "soft" real-time operating system, the production line can continue to work, but the output of the product slows down because the product cannot arrive within the allowed time, this gives robots a short period of absence from production. Some real-time operating systems are designed for specific applications, while others are common. Some general-purpose operating systems call themselves real-time operating systems. However, to some extent, most general-purpose operating systems, such as Microsoft's Windows
NT or ibm OS/390 have real-time system features. This means that even if an operating system is not a strict real-time system, it can solve some real-time application problems.

Generally, real-time operating systems must have the following features:

1) multi-task;

2) thread priority

3) Multiple interrupt levels

Small embedded operating systems often require real-time operating systems. The kernel must meet the requirements of real-time operating systems. However, other components, such as device drivers, are also required. Therefore, a real-time operating system is usually larger than the kernel.


[B] Soft Real-Time System and hard real-time system [/B]

Real-time systems have strict requirements on logic and timing. deviations between logic and time series may cause serious consequences. There are two types of real-time systems: Soft Real-Time Systems and hard real-time systems.
A soft real-time system only requires that the event response be real-time, and does not require that a task be completed within a certain period of time. In a hard real-time system, not only does the task response need to be real-time, in addition, the event processing must be completed within the specified time. Generally, most real-time systems combine the two.

In fact, no absolute number can indicate what is hard real-time and soft real-time. The boundaries between them are very vague. This is related to the CPU, clock speed, memory, and other parameters selected [1]. In addition, application scenarios have different requirements for real-time system performance. Therefore, on the existing fixed software and hardware platform, how can we test and find out the key parameters that determine the real-time performance of the system, and provide optimization measures and test data, it has become a topic of universal significance and worthy of in-depth discussion. This article is based on this purpose.

Because the significance of using a real-time operating system is to be able to handle various emergencies in a timely manner, that is, to handle various interruptions, therefore, the most important and representative performance indicator parameter for measuring the embedded real-time operating system should undoubtedly be the interrupt response time. The interrupt response time is usually defined:

Interrupt response time = Interrupt Delay Time + time for saving CPU status + execution time of the ISR entry function of the kernel [2].

Interruption delay time = max (maximum time of Guanzhong disconnection, maximum Command time) + time for starting to execute the first command of Isr [2].

Contact Us

The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion; products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the content of the page makes you feel confusing, please write us an email, we will handle the problem within 5 days after receiving your email.

If you find any instances of plagiarism from the community, please send an email to: info-contact@alibabacloud.com and provide relevant evidence. A staff member will contact you within 5 working days.

A Free Trial That Lets You Build Big!

Start building with 50+ products and up to 12 months usage for Elastic Compute Service

  • Sales Support

    1 on 1 presale consultation

  • After-Sales Support

    24/7 Technical Support 6 Free Tickets per Quarter Faster Response

  • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.