Transport aircraft flight simulation system
By using the full-envelope flight simulation module and the parent class CModel linked list structure in the transport aircraft flight simulation system, the problems of cumbersome and error-prone flight simulation systems in the existing technology are solved, achieving high coordination and accurate simulation effects, and simplifying Debugging process.
Patent Information
- Application Number
- CN202210128767.7
- Authority / Receiving Office
- CN · China
- Patent Type
- Patents(China)
- Current Assignee / Owner
- Filing Date
- 2022-03-03
- Publication Date
- 2024-09-06
- Estimated Expiration
- 2042-03-03
AI Technical Summary
The existing transport aircraft flight simulation system is cumbersome and error-prone during the construction and debugging process. Each sub-model has many operations, resulting in poor system coordination and difficulty in achieving high matching and accurate simulation effects.
A transport aircraft simulated flight system is designed, which uses a full-envelope flight simulation module, a graphical instrument system and a visual system to calculate the aircraft status information in real time through the main control system, and realizes inter-module communication through the linked list structure of the parent class CModel and derived subclasses. Data exchange and independent debugging, providing specific input and output interfaces to encapsulate model information.
It achieves high coordination and independent development and testing between each module, simplifies the model deletion and debugging process, improves the fidelity and control accuracy of the simulation software, and reduces the debugging complexity.
Smart Images

Figure CN114491818B
Abstract
Description
Technical Field
[0001] The invention relates to the technical field of spacecraft simulation system design, and in particular to a transport aircraft simulation flight system. Background Art
[0002] Flight simulation equipment refers to the general term for various equipment and systems that simulate aircraft flight and train pilots. It plays an important role in training pilots, reducing the risk of equipment loss, and cultivating aviation reserve forces. Flight simulation equipment began to appear in the 1930s. Since then, with the development of various technologies, the simulation of aircraft flight performance, avionics systems and weapon systems has made great progress, and the modeling and simulation of aircraft performance have become more perfect. Transport aircraft simulation flight software is developed to adapt to the characteristics of transport aircraft models. It can meet the requirements of beginners to experience flying, cultivate flying interests, and become familiar with flying knowledge.
[0003] Since a modern transport aircraft contains a large number of subsystems, and the simulator needs to simulate almost every system, the existing flight simulation system adopts the method of operating each sub-model class separately. The work of instantiating these hundreds of sub-models is already very cumbersome and error-prone, and the call to each object is even more cumbersome and difficult. Summary of the invention
[0004] In order to solve the deficiencies of the prior art, the present invention aims to provide a transport aircraft flight simulation system, including a main control system, an interface system, a graphic instrument system, and a visual system.
[0005] The main control system includes a full envelope flight simulation module, a mutual constraint relationship simulation module between aircrafts, a training environment simulation module, and provides a specific interface;
[0006] The graphic instrument system can simulate common transport aircraft instruments, electronic navigation systems, and provide specific instrument interfaces;
[0007] The visual database adopts a general airport and provides an interface for replacing the airport scenery database;
[0008] The interface system collects the pilot's control information and sends it to the main control system through the UDP network. The main control system simultaneously receives the operation information of the virtual system console, and calculates the aircraft's status information in real time through various model solutions, and then calculates the aircraft's position and attitude information in real time through the motion equation, and calculates the aircraft's speed, altitude and navigation information in real time. After completing a single operation cycle, the main control system sends the aircraft's status information to the graphic instrument system through the interface system to drive the cockpit equipment display, and at the same time sends the relevant information to the vision system through Ethernet.
[0009] Furthermore, the full envelope flight simulation module realizes the following functions:
[0010] Based on the aerodynamic data of transport aircraft, construct aerodynamic models and atmospheric models, establish aircraft motion equations and mathematical models of control systems, engines, landing gear, flaps, etc.;
[0011] The training mission setting data is read through the internal data interface to initialize the aircraft mathematical model; the pilot's lateral and longitudinal control signals of the aircraft and the operation instructions of the landing gear, speed brake, flaps, etc. are collected in real time to solve the aircraft mathematical model and control the aircraft movement;
[0012] Through the internal data interface, the aircraft position, attitude and other data are output to achieve data exchange with other modules; by modifying the module, the control rate with the highest possible matching degree and accurate throttle response can be achieved;
[0013] Each of the models is directly derived from the same parent class CModel. The parent class CModel provides an abstract interface for accessing each derived subclass. The interface is used to operate the derived object to initialize, receive data, run, output results and destruct itself. The operations exist as protected members in the base class and will be overloaded in each derived subclass to represent the different characteristics of each submodel. The parent class CModel has message processing capabilities to realize message processing and storage.
[0014] Furthermore, the training task setting data includes the initial position of the aircraft, the initial state of the engine, and the initial fuel volume;
[0015] Furthermore, solving the aircraft mathematical model includes establishing flight, target motion, emergency response, collision detection, and human motion mathematical models, and performing real-time solving.
[0016] Furthermore, the parent class CModel has two different constructors, and the derived subclasses have different levels. One represents a low-level model that only calculates a specific type of force, and the other represents a high-level model that integrates all external forces to calculate the flight status of the aircraft. Each of the high-level classes aggregates a series of the low-level classes and represents an independent functional sub-model in the full-envelope flight simulation system. The low-level classes can also aggregate other lower-level classes. The different constructors of the parent class CModel correspond to different levels of the derived subclasses.
[0017] Furthermore, the parent class CModel has a function PushIntoLinkedList that records the address of the derived child object. When a high-level class derived from the parent class CModel is instantiated, the constructor prepared for the high-level class in the parent class CModel is run first and pushes the pointer to this object into a linked list. When all the classes derived from the parent class CModel are instantiated, the linked list of the full-envelope flight simulation system model is formed. The formation of the linked list is a recursive process, and the linked list is used to control the full-envelope flight simulation system model to execute in sequence using recursion and loop methods.
[0018] Furthermore, the linked list of the full-envelope flight simulation system model strings together the various simulated systems. Systems that are not instantiated do not exist in the linked list and do not participate in the simulation. The entire simulation program does not need to be modified. Just comment out the line of code that instantiates the control load class and enable its alternative virtual input class and then recompile. When debugging the control load system, you only need to change the position of the comment symbol.
[0019] Furthermore, the aerodynamic model includes aerodynamic force, ground force and landing gear force models compounded therein.
[0020] Furthermore, the aerodynamic force, ground force and landing gear force model classes all contain a specific input and output interface cIn and cOut. Each high-level class representing an independent system is associated with a global input function. The global input function can only access the cIn and cOut to communicate with the aerodynamic force, ground force and landing gear force model classes, but cannot directly access other member variables of the class, thereby realizing module encapsulation.
[0021] Furthermore, the operation of the model class by the outside world is performed through the public member function Run (RunMode mode, double TimeStep), and the execution of the full-envelope flight simulation system class is controlled by changing the running mode "RunMode" of the enumeration type.
[0022] Compared with the prior art, the present invention has the following beneficial effects:
[0023] 1. Design a set of simulation software that is as complete and realistic as possible for a given aircraft model. The modules of the entire software should be well coordinated and independent of each other, so they can be developed and tested separately.
[0024] 2. Each component model of the flight simulation is directly derived from the same parent class CModel, which provides an abstract interface for accessing each derived subclass. CModel has two different constructors. Different constructors of the parent class CModel correspond to different levels of the derived subclasses.
[0025] 3. The linked list of simulation sub-models links up the various large systems of the simulation, making it easy to delete and debug the model independently. As long as a system is not instantiated, it does not exist in the linked list and does not participate in the simulation, and the entire simulation program does not need to be modified. This greatly facilitates debugging.
[0026] 4. Each model class contains a specific input and output interface, cIn and cOut. The global input function can generally only access cIn and cOut to communicate with each sub-simulation system, but cannot directly access other member variables of the class. This protects the information in the class, realizes the encapsulation of the module, and is conducive to separate development and separate debugging. BRIEF DESCRIPTION OF THE DRAWINGS
[0027] In order to more clearly illustrate the technical solutions of the embodiments of the present invention, the following briefly introduces the drawings required for use in the embodiments of the present invention. Obviously, the drawings described below are only some embodiments of the present invention, and for ordinary technicians in this field, other drawings can be obtained based on these drawings without creative work.
[0028] Figure 1 is an overall structural diagram of a transport aircraft flight simulation system in an embodiment of the present invention;
[0029] Figure 2 This is a schematic diagram of the structure of a full envelope flight simulation module according to an embodiment of the present invention;
[0030] Figure 3 It is a structural diagram of the parent class CModel in an embodiment of the present invention;
[0031] Figure 4 is the relationship between the model classes of the flight simulation module of the embodiment of the present invention;
[0032] Figure 5 It is a linked list structure diagram formed by objects instantiated from a high-level class in an embodiment of the present invention;
[0033] Figure 6 It is the process of pushing an object pointer into a linked list in the embodiment of the present invention;
[0034] Figure 7 It is the sequential operation process of the embodiment of the present invention on the high-level model class;
[0035] Figure 8 is an initialization routine of the flight simulation module of an embodiment of the present invention;
[0036] Fig. 9 This is a main function flow chart of the main control system of an embodiment of the present invention;
[0037] Fig.10 It is a class structure diagram of the flight dynamics model of an embodiment of the present invention and the aerodynamic force, ground force and landing gear force compounded therein. DETAILED DESCRIPTION
[0038] The technical solution of the present invention is further described below with reference to the accompanying drawings and through specific implementation methods.
[0039] Reference Figure 1 A transport aircraft simulation flight system shown includes a main control system, an interface system, a graphic instrument system, and a visual system. After the transport aircraft simulation flight system is normally started, the interface system collects the pilot's control information (control stick, throttle lever, pedals and circuit breaker, control box signal), and sends it to the main control system through the UDP network; the main control system simultaneously receives the operation information of the virtual system console, and calculates the aircraft's engine, hydraulic, fuel, power supply and other status information in real time through various model solutions, and then calculates the aircraft's position and attitude information in real time through the motion equation, and calculates the aircraft's speed, altitude and navigation information in real time; after a single operation cycle is completed, the main control system sends the aircraft's status information to the graphic instrument system through the interface system to drive the cockpit equipment display, and at the same time sends the relevant information to the visual system through Ethernet, providing a realistic training environment for the pilot.
[0040] The main control system includes a full envelope flight simulation module, a mutual constraint relationship simulation module between aircrafts, a training environment simulation module, and provides a specific interface;
[0041] The graphic instrument system can simulate common transport aircraft instruments, electronic navigation systems, and provide specific instrument interfaces;
[0042] The visual database adopts a general airport and provides an interface for replacing the airport scenery database;
[0043] Reference Figure 2 The main functions of the full flight envelope flight simulation module include:
[0044] Based on the aerodynamic data of transport aircraft such as the Xianzhou-60, Yun-7, and An-24, the aerodynamic model and atmosphere model are constructed, and the aircraft motion equations and mathematical models of the control system, engine, landing gear, flaps, etc. are established;
[0045] Read the training mission setting data through the internal data interface, including the initial position of the aircraft, the initial state of the engine, the initial fuel volume, etc., to initialize the aircraft mathematical model;
[0046] Collect the pilot's lateral and longitudinal control signals of the aircraft and the operation instructions of the landing gear, speed brake, flaps, etc. in real time, solve the aircraft mathematical model, and control the movement of the aircraft;
[0047] Output aircraft position, attitude and other data through internal data interface to achieve data exchange with other modules;
[0048] The module is modified to achieve the highest possible control rate and precise throttle response.
[0049] The workflow of the flight simulation module for the full flight envelope is divided into the following steps:
[0050] Model initialization: Initialize various mathematical models according to the initial task settings. A certain transport aircraft flight simulation system uses XML files to configure dimensional structure information.
[0051] Signal collection: Collect the pilot's control information through the input interface;
[0052] Model solving: Establish mathematical models of flight, target motion, emergency response, collision detection, and human motion, and solve them in real time.
[0053] The overall framework design of the main control system adopts the object-oriented programming concept. It is to design a set of simulation software that is as complete and realistic as possible for a given model. The coordination between the modules of the entire software is good, and each module is independent of each other and can be developed and tested separately. The following will discuss the four aspects of class inheritance, scheduling method, model definition and data management.
[0054] Reference Figure 3 As shown in the figure, each component model of the flight simulation module is directly derived from the same parent class CModel, which provides an abstract interface for accessing each derived subclass. For example, its public virtual function Run (RunMode mode, doubleTimeStep) can be used to operate the derived object to initialize, receive data, run, output results and destruct itself. These five operations exist as protected members in the base class and will be overloaded in each derived subclass to represent the different characteristics of each submodel. Similarly, CModel also has message processing capabilities, realizing message processing and storage.
[0055] Reference Figure 4Since all flight simulation module sub-models are directly derived from the parent class CModel, in order to distinguish the hierarchical relationship of each sub-model, CModel has two different constructors. Because of the polymorphism of CModel, the derived classes can have different levels. One represents low-level models, such as CGearForce and CAeroForce, which only calculate a specific type of force; the other represents high-level models, such as CFlight, which integrates all external forces to calculate the flight status of the aircraft, so it needs to collect CGroundForce and CAeroForce, etc. Each high-level class aggregates a series of low-level classes and represents an independent functional sub-model in the flight simulator. Low-level classes can also aggregate other low-level classes, for example, CGearForce and CCrashForce are aggregated in CGroundForce to represent two different ground contact forces, landing gear force and collision force between the body and the ground.
[0056] In order to facilitate the management and calling of each flight simulation module sub-model, a function PushIntoLinkedList() is added in CModel to record the address of the derived sub-object. When the high-level class derived from CModel is instantiated, the constructor prepared for the high-level class in CModel is first run and the pointer to this object ('this') is pushed into a linked list. Figure 5 and Figure 6 The static member pointers m_pRoot, m_pTail and m_pNext in CModel form a linked list. When all classes derived from CModel are instantiated, the linked list is formed, so that the simulation model can be controlled to execute in sequence using recursion and looping methods.
[0057] The formation of this linked list is a recursive process. Among them, m_pRoot, m_pTail and m_pNext are all static pointer variables. In the steps represented by the color box in the figure, first, the pointer m_pNext at the end of the original linked list is made to point to the current object, and then the current object is used as the end of the linked list.
[0058] The linked list indicating all flight simulation module simulation sub-models not only serves as a clue in the entire simulation, but also makes the simulation process more organized. Since the linked list strings together the various large systems of the simulation, it is convenient to delete and debug the model independently. As long as a system is not instantiated, it does not exist in the linked list, and does not participate in the simulation, and the entire simulation program does not need to be modified. This greatly facilitates debugging. For example, if you now want to shield the influence of the control load (when the system function is missing or imperfect) and use virtual signals (inputting the pilot's operation amount on the computer screen) to verify the flight dynamics model, you only need to simply comment out the line of code that instantiates the control load class and enable its alternative virtual input class and then recompile. When debugging the control load system, you only need to change the position of the comment symbol. In this way, the impact on the system program can be minimized.
[0059] The class structure of the flight dynamics model and the aerodynamic force, ground force and landing gear force compounded therein is shown in FIG10 .
[0060] Since CFlight is defined as a high-level class, the pointer of its derived object needs to be pushed into the linked list, so the constructor of CFlight should be combined with the constructor in CModel that serves the high-level class instantiation: CFlight(char*name,void(*InputFunction)()):CModel(name,InputFunction)
[0061] The name identifies the name of the object, so that it can be tracked in the linked list and used by some macro commands. The pointer InputFunction indicates the address of the global function that provides input for the CFlight class. This function is responsible for collecting output information from other systems and inputting it to CFlight. Each high-level class representing an independent system is associated with a global input function.
[0062] Each model class contains a specific input and output interface, cIn and cOut. The global input function can generally only access cIn and cOut to communicate with each sub-simulation system, but cannot directly access other member variables of the class. This protects the information in the class, realizes the encapsulation of the module, and is conducive to separate development and separate debugging.
[0063] The operation of the model class by the outside world is mainly carried out through the public member function Run (RunMode mode, doubleTimeStep). The simulation class execution is controlled by changing the run mode "RunMode" of the enumeration type. For example, an object in the linked list can be run in the initialization mode.
[0064] pModel->Run(_INIT,timestep);
[0065] One of the advantages of using C++ is that it facilitates code reuse. For example, most aircraft are equipped with multiple landing gears, and the force calculation equations for each landing gear to contact the ground are similar, so you only need to design a landing gear class to derive different landing gear objects according to different aircraft configurations. The enumeration member Type in the landing gear class represents the type of landing gear. Assigning a value to Type in the instantiated object can make the object represent a specific landing gear system. Fig.10 The middle landing gear class instantiates three objects in CGroundForce, namely the front landing gear (cNoseGear), the main left landing gear (cLeftGear) and the main right landing gear (cRightGear). These three objects are aggregated in the ground force calculation class CGroundForce, which is responsible for outputting the force between the landing gear and the ground. Also aggregated in CGroundForce are the objects derived from the class CCrashForce for calculating collision effects. Due to improper operation, the protruding parts of the aircraft may collide with the ground, so each possible collision point needs to instantiate a collision force calculation object, such as the nose, tail, engine compartment and wing tip.
[0066] The CEarth class and CAtomsphere class in CFlight are also two very important classes. The CEarth class represents the geographic model of the ellipsoidal earth. It can be used to convert between rectangular coordinates and polar coordinates, and to calculate the distance between two reference points along the ellipsoid surface. CAtomshpere is a standard atmospheric model that can calculate atmospheric pressure, temperature, Mach number, true airspeed, corrected airspeed, dynamic pressure, pressure altitude, impact pressure, and other atmospheric-related calculations.
[0067] After instantiation, the high-level simulation model class can form a linked list. When performing simulation iterative calculations, this linked list is needed to operate the simulation steps.
[0068] Figure 7 It shows the operation process of the high-level model class using the linked list. The intermediate pointer variable *pCur of type CModel traverses each node in the linked list and makes the node run in the desired mode until the last node in the linked list is operated, completing an iteration.
[0069] After all the components are constructed, the simulation system starts with the main function to construct the CSim object. A function in the object calls the static function Iterate(RunModemode, double TimeStep) of CModel and runs it in _INIT mode. Iterate(…) contains a Figure 8 The traversal process will complete the initialization of all high-level classes. The process of initializing low-level classes is completed by their high-level classes directly calling their Run (RunModemode, double TimeStep).
[0070] After initialization is completed, Iterate(RunMode mode, double TimeStep) will run in _RUN mode. The information exchange between subsystems is completed by calling the global pointer function, such as Figure 7 In pCur->m_pInputFnc().
[0071] like Fig. 9 As shown in the figure, the main function is the entry function of the system and manages the system process. In the main function, the object cSim is first constructed, and then three processes begin: initialization, operation, and termination. Since flight simulation is a real-time simulation, the time of each frame needs to be precisely controlled, and the time to complete all simulation calculations in a frame is uncertain, so it is necessary to first measure the time to complete an iteration, and then delay and supplement the interpolation with the step size.
[0072] After the transport aircraft simulation flight system is started, the system automatically runs in real-time mode. At this time, the simulated aircraft is automatically trimmed to a default runway and the aircraft is in automatic start-up state. In the initial state, the red throttle lever is set to zero position and the aircraft is in braking state. First, the pilot trims the aircraft through the blue trim lever, and then pushes the red throttle lever to accelerate the aircraft. During the aircraft taxiing process, the aircraft direction can be controlled by the rudder pedals, and the aircraft taxiing direction can also be changed by the joystick. After waiting for the aircraft to take off, the aircraft pitch and roll angles can be controlled by the joystick, and the relevant parts of the aircraft can be controlled by the flap button and the landing gear button.
[0073] It should be noted that the above specific implementations are only preferred embodiments of the present invention and the technical principles used. Those skilled in the art should understand that various modifications, equivalent substitutions, changes, etc. can be made to the present invention. However, as long as these changes do not deviate from the spirit of the present invention, they should be within the scope of protection of the present invention. In addition, some terms used in the specification and claims of this application are not restrictive, but are only for the convenience of description.
Claims
1. A transport aircraft flight simulation system, comprising a main control system, an interface system, a graphic instrument system, and a visual system, characterized in that: The main control system includes a full envelope flight simulation module, a mutual constraint relationship simulation module between aircrafts, a training environment simulation module, and provides a specific interface; The graphic instrument system can simulate common transport aircraft instruments, electronic navigation systems, and provide specific instrument interfaces; The visual database adopts a general airport and provides an interface for replacing the airport scenery database; The interface system collects the pilot's control information and sends it to the main control system through the UDP network. The main control system simultaneously receives the operation information of the virtual system console, and calculates the aircraft's state information in real time through various model solutions, and then calculates the aircraft's position and attitude information in real time through the motion equation, and calculates the aircraft's speed, altitude and navigation information in real time; After a single operation cycle is completed, the main control system sends the aircraft status information to the graphic instrument system through the interface system to drive the cockpit equipment display, and sends the relevant information to the visual system through Ethernet; Based on the aerodynamic data of transport aircraft, construct aerodynamic model and atmosphere model, establish aircraft motion equations and mathematical models of control system, engine, landing gear and flaps; The training mission setting data is read through the internal data interface to initialize the aircraft mathematical model; the pilot's lateral and longitudinal control signals of the aircraft and the operation instructions of the landing gear, speed brake, and flaps are collected in real time, the aircraft mathematical model is solved, and the aircraft movement is controlled; Output aircraft position and attitude data through the internal data interface to achieve data exchange with other modules; Modify the module to achieve the highest possible control rate and precise throttle response; Each of the models is directly derived from the same parent class CModel. The parent class CModel provides an abstract interface for accessing each derived subclass. The interface is used to operate the derived object to initialize, receive data, run, output results and destruct itself. The operations exist as protected members in the base class and will be overloaded in each derived subclass to represent the different characteristics of each submodel. The parent class CModel has message processing capabilities to realize message processing and storage.
2. The transport aircraft flight simulation system according to claim 1, characterized in that: The training mission setting data includes the initial position of the aircraft, the initial state of the engine, and the initial fuel volume.
3. The transport aircraft flight simulation system according to claim 1, characterized in that: The solving of the aircraft mathematical model includes establishing the mathematical models of flight, target movement, emergency response, collision detection, and human movement, and performing real-time solving.
4. The transport aircraft flight simulation system according to claim 1, characterized in that: The parent class CModel has two different constructors, and the derived subclasses have different levels. One represents a low-level model that only calculates a specific type of force, and the other represents a high-level model that integrates all external forces to calculate the flight status of the aircraft. Each of the high-level classes aggregates a series of the low-level classes and represents an independent functional sub-model in the full-envelope flight simulation system. The low-level classes can also aggregate other lower-level classes. The different constructors of the parent class CModel correspond to different levels of the derived subclasses.
5. The transport aircraft flight simulation system according to claim 4, characterized in that: The parent class CModel has a function PushIntoLinkedList that records the address of the derived child object. When the high-level class derived from the parent class CModel is instantiated, the constructor prepared for the high-level class in the parent class CModel is run first and pushes the pointer to this object into a linked list. When all the classes derived from the parent class CModel are instantiated, the linked list of the full-envelope flight simulation system model is formed. The formation of the linked list is a recursive process. The linked list uses recursion and looping methods to control the sequential execution of the full-envelope flight simulation system model.
6. The transport aircraft flight simulation system according to any one of claims 4 to 5, characterized in that: The linked list of the full-envelope flight simulation system model strings together the various simulated systems. Systems that are not instantiated do not exist in the linked list and do not participate in the simulation. The entire simulation program does not need to be modified. Just comment out the line of code that instantiates the control load class, enable its alternative virtual input class, and then recompile. When debugging the control load system, you only need to change the position of the comment symbol.
7. The transport aircraft flight simulation system according to claim 1, characterized in that: The aerodynamic model includes aerodynamic force, ground force and landing gear force models compounded therein.
8. The transport aircraft flight simulation system according to claim 7, characterized in that: The aerodynamic force, ground force and landing gear force model classes all contain a specific input and output interface cIn and cOut. Each high-level class representing an independent system is associated with a global input function. The global input function can only access the cIn and cOut to communicate with the aerodynamic force, ground force and landing gear force model classes, but cannot directly access other member variables of the class, thereby realizing module encapsulation.
9. The transport aircraft flight simulation system according to claim 1, characterized in that: The operation of the model class by the outside world is performed through the public member function Run (RunMode mode, double TimeStep), and the execution of the full envelope flight simulation system class is controlled by changing the running mode "RunMode" of the enumeration type.
