Research and Implementation of Integrative Real-Time & Hardware-in-the-loop Simulation Platform Based on Simulink
- Author
- XuLin
- Advisor
- YaoYiPing
- School
- National University of Defense Science and Technology
- Major
- Computer Science and Technology
- Classification
- TP391.9 Computer simulation
- Degree
- Master's thesis
- Year
- 2008
- Downloads
- 942
- Citations
- 16
- SIMULINK
- Real-Time eXtension (RTX)
- Real-Time Simulation
- hardware-in-the-loop simulation
- Graphics modeling
Abstract
Real-time and hardware-in-the-loop simulation is an important branch in the area of computer simulation. And it’s of the highest confidence level in a variety of simulation systems. At present, most of the real-time and hardware-in-the-loop simulation platforms that are used widely have difficulties in all-purpose use, modeling, or interactive simulation. Simulink is a very popular tool internationally on the dynamic system modeling and simulation. It can be used in many areas engineering and mathematics involved, and its powerful graphics modeling feature greatly enhances the efficiency of the development of simulation applications. However, Simulink itself does not support real-time simulation, and does not provide the necessary external physical interface for hardware-in-the-loop simulation as well. Therefore, in order to take full advantages of Simulink simulation productions and its powerful graphics modeling feature, research and development of integrative real-time and hardware-in-the-loop simulation platform based on Simulink is of great significance.Aiming at the actuality that Simulink dynamic systems modeling and simulation lacks real-time control and graphics modeling lacks physical interface module, the key technologies of implementation of intergrative real-time and hardware-in-the-loop simulation platform based on Simulink are discussed thoroughly in the paper. The main works and innovations are as the followings.1. Hardware is an important part of hardware-in-the-loop simulation system, so to provide access to external physical interface to support the hardware-in-the-loop simulation is necessary. Because of that Simulink itself does not provide external physical interface module, on the basis of characteristics of Simulink graphical modeling, this thesis presents a solution which uses S-function modules integrating hardware driving to provide external physical interface. So that physical interface is added to Simulink graphics modeling, it is easier for the development of hardware-in-the-loop simulation application and the efficiency of the development improved too.2. Real-time control is the core of real-time simulation platform and directly bears on the real-time performance that the real-time simulation system can achieve. Aiming at the actuality that model C code generated by Real-Time Workshop lacks real-time control, this thesis presents a way based on template files with real-time control to convert model C code automatically and designs the template files. The model C code can be added real-time control automatically by the method, so the real-time control simulation is carried out.3. Real-time simulation data display and storage is an important aspect of real-time and hardware-in-the-loop simulation, its realization base is data exchange between real-time process and non real-time process. For creating large shared memory between real-time process and non real-time process may affect the performance and stability of the simulation system, this thesis presents a high-performance data exchange algorithm based on optimized data buffer queue. The algorithm is not only a good way to achieve a large number of inter-process high-speed data exchange and to ensure the system’s performance and stability. 4. Interaction in simulation is an important way to improve the efficiency of the simulation, and remodifying and resetting of the simulation parameters is the important part of interaction. Aiming at the problem that model code of Simulink does not provide interactive features, this thesis presents the method of interactive simulation based on the parameters configuration file and file format is optimized. The method implements interaction functions and improves the efficiency of real-time simulation.On the basis of those research results, the intergrative real-time and hardware-in-the-loop simulation platform with functions such as graphics modeling, physical interface, real-time simulation operation and control, interactive simulation, real-time data display, results analysis and so on is designed and implemented. The platform can effectively support the development and execution of real-time and hardware-in-the-loop simulation application. It has been successfully applied in some actual projects and achieves excellent real-time performance.
Table of contents
Abstract 10-11
ABSTRACT 11-13
first chapter 13-21
1.1 topics background 13-17 < br /> 1.1.1 topic sources 13-14
1.1.2 research status 14-16
1.1.3 research faces major technical problems 16-17
1.2 research significance and objectives 17-18
1.3 the main work and innovation 18-19
1.4 paper structure 19-21
the second chapter is based on general-purpose operating systems Simulink modeling and simulation technology overview 21-32
2.1 Simulink Overview 21-24
2.1.1 MATLAB Overview 21-22
2.1.2 dynamic system modeling and simulation tool Simulink 22-23
2.1.3 operating system based on real- time simulation platform extension Simulink performance 23-24
2.2 real-time operating system overview 24-26
2.3 Windows system real-time performance overview 26-28
2.3.1 Windows system real-time performance 26
2.3.2 Windows systems to improve real-time performance of the method 26-28
2.4 build based on RTX real-time Windows system platforms 28-31
2.4 .1 RTX real-time system overview 29
2.4.2 RTX architecture 29-30
2.4.3 Windows system based on RTX real-time performance overview 30-31
2.5 Chapter Summary 31-32
Chapter Simulink-based real-time semi-physical simulation platform key technology research 32-51
3.1 Simulink based hardware interface technology research 32-40
3.1.1 S- function works 32-35
3.1.2 C MEX S- function written 35-38 <br / > 3.1.3 custom module provides a semi -physical simulation external physical interfaces 38-40
3.2 real-time code generation technology research 40-45
3.2.1 model code generation 40-41
3.2.2 model code real-time transformation 41-43
3.2.3 real-time works automatically generated 43-45
3.3 efficient IPC algorithm 45-49
3.3.1 RTX and Windows systems communicate 45-46
3.3.2 simulation data real-time display and storage 46-48
3.3.3 buffer queue -based algorithm to achieve efficient data dump IPC 48-49
3.4 interactive simulation technology Research 49-50
3.5 Summary 50-51
Chapter integrated real-time semi-physical simulation platform for the design and implementation of 51-68
4.1 features real-time semi-physical simulation and process 51-53
4.1.1 real-time semi-physical simulation Features 51-52
4.1.2 real-time semi-physical simulation process 52-53
4.2 system architecture design 53-55
4.3 shared memory architecture design 55-57
4.4 system design and implementation of the main functions of 57-67
4.4.1 main frame design and Implementation 57-60
4.4.2 real-time generation of engineering design and implementation 60-61
4.4.3 simulation run control design and implementation 61-63
4.4.4 data dump and real-time display function design and implementation 63
4.4.5 simulation interactive features of the design and implementation of 63-64 <br / > 4.4.6 simulation results of data analysis functions after the design and implementation 64-67
4.5 Chapter Summary 67-68
Chapter integrated real-time semi-physical simulation platform test and application 68-77
5.1 system functional test 68-70
5.1.1 simulation project to create functional test 68-69
5.1 .2 simulation run functional tests 69
5.1.3 simulation data analysis function test 69-70
5.2 system Performance Testing 70-75
5.2 .1 General Construction based on RTX real-time operating system platform real-time characteristic test 70-71
5.2.2 semi-physical simulation platform for real-time integration of real-time performance test 71-75
5.3 the practical application of the system 75-77
Chapter VI Conclusion 77-79
6.1 thesis work summarizes 77-78
6.2 further work 78-79
Thanks 79-80
References 80-83
master's papers published during 83-84 <br / > master's participation during the research work 84-85
Appendix A: real-time simulation works DSP project file template 85-88
Appendix B: sample workspace file 88
Related dissertations
- Research of Flight Control System Hardware-In-The-Loop Simulation for UAV Based on dSPACE
- Design of Hardware-In-The-Loop Simulation Platform for Aircraft Braking System Based on LabVIEW
- Simulink-based diesel engine and its control system modeling and simulation
- Research on the Real-time Simulation Platform RT-LAB and Its Application in the Aircraft Design
- Research on the Modeling and Simulation of the Pneumatic System Based on Amesim
- Applied Research on HIL Simulation of Fused Quartz Furnace Control System
- Optimization Control Method and Hardware-in-the-loop Simulation Platform of the Raw Slurry Blending Process
- Motion Object Detection Based on Dm642
- Research and Implementation of a Real-time Algorithm for Ship Wave Simulation
- Simulation Research on Modulation Technology for THz Communication System
- Study of Lead-acid Battery Bank Applied in Long Pulse Magnet Power Supply System
- Power Hardware In the Loop Simulation Technology of Microgrid
- The Study of HVDC Transmission System Using Modular Multilever Converter Based on Real-time Simulation of RT-LAB
- The Research of Improved Dual-Windowed Interpolation Harmonic Detection and Hybrid Active Power Filter Simulation
- The Research of Photovoltaic Grid-connected System Islanding
- The Control Strategy of Wind Power System Based on Direct-drive Type of PMSG
- Research on the Real-Time Simulation Technology of Grid-Connected Converter
- Research on the Control Strategy of the Single-phase Photovoltaic Grid-connected Inverter with LCL Filter
- Study for Cascade Brushless Doubly-fed Machine and Its Speed Control System Application
- The Hardware-in-the-loop Real-time Simulation Research of PMSM with RT-LAB