Embedded Systems Design Europe - November 2007 - (Page 22) RTOS • Generate output signals that affect the plant, as shown in Figure 1. To separate high-speed control systems from all other control applications, consider that high-speed control systems need to operate at loop rates of 1 ms or less, or perform the aforementioned three actions deterministically at a rate of at least 1 kHz. Moreover, these systems must achieve the control-loop rate to avoid mission-critical system failure. High-speed control systems, therefore, require a hard real-time solution. While performance is absolutely important, high-speed control systems have other requirements. To find the right RTOS for your control applications, you must consider the following factors: • • • • • • • Performance Software development tools Debugging Control algorithm integration Hardware and I/O support Code footprint Communication quickly and predictably to events such as a new input signal. The terms for gauging this performance are maximum interrupt service routine (ISR) latency and maximum interrupt service thread (IST) latency. High-speed control applications, such as hardware-in-the-loop simulations and motion control systems, typically require ISR and IST times to be less than 10 µs. Most true RTOSs, such as Wind River’s VxWorks, QNX’s Neutrino, and Green Hills’ Integrity, can meet these requirements. In addition, various amalgamations of Linux and real-time schedulers, such as RTLinux and RTAI, can solve high-speed control application challenges. On the other hand, operating systems that weren’t designed for real time from the ground up, such as Windows XP Embedded and general distributions of Linux, don’t meet the interrupt latency requirements. SOFTWARE DEVELOPMENT TOOLS Next, consider the software development environment you need to program a particular RTOS. Just as performance is similar to the horsepower of an RTOS, the development environment is similar to the suspension and “ride” that make it comfortable to use. While the RTOS may have all the right specifications, the development environment has an enormous impact on the quality and speed of development as well as the project’s overall success. These features can be as simple as syntax highlighting and function completion or as powerful as codegeneration wizards and source-code control compatibility. Effective codegeneration tools for common functions can save days of development time for new and experienced developers. Another factor to consider is the availability of add-on tools for development environments. Eclipse-based environments such as Wind River Workbench and QNX Momentics offer a wide array of third-party plug-ins. DEBUGGING It’s one thing to know a system is capable of high-speed control, but it’s another to achieve it consistently. The debugging capabilities of your realtime software development tools can mean the difference between creating a successful control system and spiraling into an endless search for elusive bugs. Standard features such as singlestepping, printf(), and syslog() methods are necessary, but optimizing a real-time application is difficult without advanced debugging tools. These include application profiling, memory analysis, and execution tracing tools. Application and memory profilers offer insight into the processor and memory usage of each task running on the system. By identifying which tasks are using the most CPU and memory resources, you can quickly find areas that need optimization. Keep in mind that the level of technical support an RTOS vendor provides can be critical in the development and debugging stages. PERFORMANCE The most important consideration when choosing an RTOS is reliable performance. The operating system must meet basic horsepower requirements to enable the control software to do its task. One of the most important requirements is low interrupt latency, which is shown in Figure 2. The system must be able to respond 22 NOVEMBER – DECEMBER 2007 | embedded systems design europe | www.embedded.com/europe 020-022-024-025_ESDE.indd 22 6/11/07 16:42:45 http://www.embedded.com/europe
For optimal viewing of this digital publication, please enable JavaScript and then refresh the page. If you would like to try to load the digital publication without using Flash Player detection, please click here.