CN115421940A - Multi-source heterogeneous model white box integration method based on shared memory technology - Google Patents

Multi-source heterogeneous model white box integration method based on shared memory technology Download PDF

Info

Publication number
CN115421940A
CN115421940A CN202211070517.9A CN202211070517A CN115421940A CN 115421940 A CN115421940 A CN 115421940A CN 202211070517 A CN202211070517 A CN 202211070517A CN 115421940 A CN115421940 A CN 115421940A
Authority
CN
China
Prior art keywords
model
simulation
shared memory
fmu
data
Prior art date
Legal status (The legal status is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the status listed.)
Pending
Application number
CN202211070517.9A
Other languages
Chinese (zh)
Inventor
付翔
郝康康
尚永权
王珺
Current Assignee (The listed assignees may be inaccurate. Google has not performed a legal analysis and makes no representation or warranty as to the accuracy of the list.)
Xi'an Zhongrui Chuanglian Technology Co ltd
Original Assignee
Xi'an Zhongrui Chuanglian Technology Co ltd
Priority date (The priority date is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the date listed.)
Filing date
Publication date
Application filed by Xi'an Zhongrui Chuanglian Technology Co ltd filed Critical Xi'an Zhongrui Chuanglian Technology Co ltd
Priority to CN202211070517.9A priority Critical patent/CN115421940A/en
Publication of CN115421940A publication Critical patent/CN115421940A/en
Pending legal-status Critical Current

Links

Images

Classifications

    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06FELECTRIC DIGITAL DATA PROCESSING
    • G06F9/00Arrangements for program control, e.g. control units
    • G06F9/06Arrangements for program control, e.g. control units using stored programs, i.e. using an internal store of processing equipment to receive or retain programs
    • G06F9/46Multiprogramming arrangements
    • G06F9/54Interprogram communication
    • G06F9/544Buffers; Shared memory; Pipes
    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06FELECTRIC DIGITAL DATA PROCESSING
    • G06F30/00Computer-aided design [CAD]
    • G06F30/20Design optimisation, verification or simulation
    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06FELECTRIC DIGITAL DATA PROCESSING
    • G06F8/00Arrangements for software engineering
    • G06F8/30Creation or generation of source code
    • G06F8/31Programming languages or programming paradigms
    • G06F8/315Object-oriented languages
    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06FELECTRIC DIGITAL DATA PROCESSING
    • G06F9/00Arrangements for program control, e.g. control units
    • G06F9/06Arrangements for program control, e.g. control units using stored programs, i.e. using an internal store of processing equipment to receive or retain programs
    • G06F9/44Arrangements for executing specific programs
    • G06F9/445Program loading or initiating
    • G06F9/44521Dynamic linking or loading; Link editing at or after load time, e.g. Java class loading
    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06FELECTRIC DIGITAL DATA PROCESSING
    • G06F9/00Arrangements for program control, e.g. control units
    • G06F9/06Arrangements for program control, e.g. control units using stored programs, i.e. using an internal store of processing equipment to receive or retain programs
    • G06F9/46Multiprogramming arrangements
    • G06F9/52Program synchronisation; Mutual exclusion, e.g. by means of semaphores
    • G06F9/526Mutual exclusion algorithms

Abstract

The invention discloses a multisource heterogeneous model white box integration method based on a shared memory technology, which is characterized in that a shared memory, a clock synchronization algorithm and a data interface protocol are packaged into a shared memory FMU through an FMI protocol, the communication FMU is led into each simulation tool, and each simulation tool realizes interactive data through the FMU, so that the joint simulation of a multisource heterogeneous model is realized. Compared with the method of integrating the model exported from the FMU, the method can adjust the parameters of the model in each piece of software at any time in the real-time simulation process and observe the output result of the model.

Description

Multi-source heterogeneous model white box integration method based on shared memory technology
Technical Field
The invention belongs to the technical field of simulation, and relates to a multi-source heterogeneous model white box integration method based on a shared memory technology.
Background
With the wide application of computer simulation technology, model-based system engineering is increasingly applied to the research and development process of products, and digital modeling simulation can comprehensively verify and optimize the design scheme of the products, thereby obviously shortening the research and development period and reducing the cost. Due to the difference of simulation technologies in various fields, respective special commercial simulation software is gradually developed, is accepted by the industry and is widely adopted. At present, because the directions of the commercial simulation software of each subject are different, when the whole system needs to be simulated, one piece of software cannot be competent, and therefore, different subject simulation tools are needed for joint simulation.
The european development information plan (ITEA 2) in 2010 proposes the FMI standard, and FMI defines a general interface specification for joint simulation, based on which joint simulation of models built by different simulation tools can be implemented. The specification defines two modes of joint Simulation, one mode is Model Exchange (ME) and the other mode is Co-Simulation (CS), and the two modes are different in that the FMU in the first mode does not contain a Model solver, and the FMU in the second mode contains the Model solver. All simulation processes are standardized by the standard, models of all modeling and simulation software can be exported into FMU (Functional Module-up Unit) files according to the standard, and other software can analyze and call the files based on the FMI standard, so that the joint simulation of multidisciplinary simulation software is realized. The standard was upgraded to FMI2.0 in 2014 with variable parameter functionality during simulation runs, enhanced initialization behavior, and implementation environment integration and processing simulators, etc., improving usability and compatibility. The standard is adopted by more than 110 commercial simulation software, including common simulation software AMESim, simulink and the like, and gradually develops into a widely accepted unified standard.
The nature of the joint simulation of the multi-source heterogeneous model is to allow different simulation tools to interact with data. In computer systems, this problem is expressed as process communication. The process communication is divided into low-level communication (only transmitting state and integer value) and high-level communication (improving the efficiency of signal communication, transmitting a large amount of data, and reducing the complexity of programming) according to the amount of information exchanged and the efficiency. Advanced process communication is divided into three modes: a shared memory mode, a message passing mode, and a shared file mode.
Foreign institutions generally adopt simulation software (commercial or open source) of a specific version related to integrated simulation for secondary development when processing multi-source heterogeneous model integrated simulation, and compile controls matched with data services defined by the software, so as to complete integrated simulation of the multi-source heterogeneous model.
In order to get rid of the limitation of foreign Simulation software companies, the mainstream solution is to export a Simulation Model built in a business tool into an FMU file (particularly in a Co-Simulation format, because only the FMU file in the format is provided with a solver, and the FMU in a Model-Exchange format is not suitable for the method), and then load all the FMU files on a Simulation platform for integrated Simulation, such as the Mworks software of the samson soft control company in suzhou and the GCair software of the seiko science and technology company in beijing.
The research of China on distributed integrated simulation starts in the 20 th and 90 th years, the military in China has made great progress through years of effort, DIS and related technologies are overcome, a multi-weapon comprehensive simulation demonstration system based on a DIS and HLA mixed system structure is built, and the system has obvious gap with America and Europe.
At present, the domestic research aiming at the field mainly has the following defects with the U.S. and Europe:
first, foreign technology development starts early, and military investment is large, and the commercialization stage is already completed at present. While the country is always in follow-up research and still is limited to follow the standard specifications proposed by the U.S. military, and does not belong to our autonomous specifications and actual systems, let alone commercialization. The purchase of foreign tools is expensive, independent intellectual property rights are not mastered, and the development trend of supporting autonomy of the current country is not met;
secondly, the drawbacks of the method as described above are evident. The biggest defects of the method adopted by foreign institutions are as follows: when the version of the simulation software is upgraded, the existing integrated simulation client control may fail, needs to be re-developed, has a large workload, and brings troubles to the use, maintenance and after-sale of the integrated simulation software. Meanwhile, the purchase of foreign tools is expensive, independent intellectual property rights are not mastered, and the development trend of supporting autonomy of the current country is not met. As for the method adopted by the domestic institution, the maximum limitations are: the Simulation tool must support the export of the FMU in the Co-Simulation format to integrate the models built in the FMU, and the FMI official website query shows that the Simulation tools capable of supporting the export of the FMU in the Co-Simulation format are very few, and many mainstream Simulation tools prefer to import the FMU models of other tools for the commercial interest and intellectual property, but not export the models of the current Simulation tools to other tools. And secondly, the derived model is a black box model, and the intermediate variable of the model cannot be checked in the process of loading the model on a target simulation platform for simulation, and the model is extremely inconvenient in the debugging process. The model needs to be frequently imported and exported. Finally, differences between simulation tools can result in some models not being correctly computed by the FMU when they are imported into other simulation tools.
Disclosure of Invention
The invention aims to provide a multi-source heterogeneous model white box integration method based on a shared memory technology, and solves the problems of multidisciplinary and cross-platform model integration and joint simulation.
The invention is realized by the following technical scheme:
a multi-source heterogeneous model white box integration method based on a shared memory technology comprises the following operations:
1) Packaging a shared memory FMU through an FMI protocol, wherein the shared memory FMU comprises an FMI description file and an executable file, and a shared memory, a clock synchronization protocol and a data interface protocol to be followed by software participating in simulation are given;
the shared memory is in an inter-process communication mode, and the address space of the same physical memory is mapped into the address spaces of different processes, so that the communication among the different processes can be realized by directly modifying the memory in the address spaces;
the clock synchronization sets the synchronous communication step length of each simulation software of the joint simulation;
the data interface relation protocol establishes a unified interface protocol for each simulation tool, and comprises the steps of adding _ in to the name of an input signal and adding _ out to the name of an output signal in each subsystem, separating the signals by using English commas (,), separating the total input signal and the output signal by using English semicolons (;), and allowing no repetition of the name of each signal; the information forms interface information of each subsystem in a character string mode, and provides support for FMU processing interface relation;
the shared memory FMU reserves a setting port of a communication step length of interface protocol and model interaction for a user;
2) Then the shared memory FMU is led into each simulation tool participating in simulation, each simulation tool realizes interactive data through the shared memory FMU,
after the simulation software is imported into the FMU, the parameters are defined as the parameters of the model variables, and the parameters can be displayed and modified on a parameter setting interface of the FMU;
3) According to the FMI simulation process, after FMU parameter information is set, simulation software calls an FMI interface function to transmit the information to an executable file in the FMU in the initialization process of the FMU;
the interface parameters set by the executable file analysis are created or read according to the input and output parameters in the interface information; writing the output data of the model into a shared memory at a specific communication step length moment according to an interface protocol; meanwhile, other models are waited to write the input data required by the model into the shared memory and then read the input data; and then entering the next communication step length, and circulating until all the simulations are finished.
The FMI description file describes the FMU model attribute information in detail and comprises the structure and the content of a model frame; the simulation tool reads the model configuration information by analyzing the model configuration information;
the executable file specifies interfaces of all required functions in the joint simulation and is used for simulating basic configuration before execution;
by compiling a model description file of the FMU, interface information of a subsystem and a communication step length of model interaction are reserved for a user to set;
ModelVariables in the model description file can be used to define model variables; writing XML of the model description file, and defining interface information, communication step length, input and output numbers and the like as model variables.
The clock synchronization is realized by using a data mutual exclusion lock and simulation time synchronization:
firstly, the total simulation duration requirements of all models of combined simulation are consistent;
secondly, input data of a certain model are output from other models, at the time T, the model A writes the output data and the self simulation time T into the shared memory named by the data name, after the model B reaches the time T, whether the shared memory of the data name exists is firstly searched, and if not, interface information is set to be wrong;
and then reading the moment of the current shared memory, if the moment of the current shared memory is consistent, directly reading the data, and if the moment of the current shared memory is T-1, reading the data of the last communication step length, wherein the moment and the data need to be circularly waited for by the simulation software A to refresh.
Compared with the prior art, the invention has the following beneficial technical effects:
the invention leads the multi-source heterogeneous model integration not paying attention to the import and export of the model through an FMI (very knowledge interchange) interface, packages a shared memory, a clock synchronization algorithm and a data interface protocol into a unified FMU through an FMI protocol, leads the FMU into each simulation tool, and leads each simulation tool to realize interactive data through the FMU, thereby realizing the joint simulation of the multi-source heterogeneous model; compared with the defect that the models are led out of the FMU for integration, the models in the invention are operated in the respective matched simulation software, the internal parameters of the models can be modified in each simulation software, the models can be simulated again immediately after being modified, the output results of the models are observed in each simulation software, and iteration is carried out; the heterogeneous model integration method can adjust the parameters of the model at any time in the simulation process and observe the output result of the model, is white box integrated simulation, and can obviously improve the simulation efficiency.
The invention realizes white box integration of various heterogeneous and multi-source system simulation models, provides a brand-new solution, and simultaneously makes simple and convenient integration of heterogeneous models possible:
the invention adopts heterogeneous model integration: according to the FMI protocol, the shared memory and related protocols can be compiled into a universal FMU through C + + programming, simulation software needing combined simulation is introduced, and white box integration of the multi-source heterogeneous model is achieved.
The invention adopts a data interface protocol: establishing a uniform interface protocol according to the interactive data relationship among the simulation tools; the interface protocol forms interface information of each subsystem in a character string mode, and the interface information is transmitted to a dynamic library in the FMU through simulation software, and the dynamic library takes interactive signal names as attributes to search values corresponding to the names; and finishing the corresponding relation and processing of the input data and the output data of a plurality of simulation software.
The invention adopts the synchronization under the shared memory: in the process of joint simulation, the rigidity and complexity of each model are different, and meanwhile, the solving efficiency of each simulation software is different, so that the simulation progress is inconsistent, and therefore, a synchronization algorithm needs to be defined in an FMU, and synchronous calculation of each software of the joint simulation is ensured by using a data mutual exclusion lock and simulation time synchronization.
Drawings
FIG. 1 is a schematic flow diagram of the present invention;
FIG. 2 is an interaction;
FIG. 3 is a PID control model;
FIG. 4 is a hydraulic source model;
FIG. 5 is a hydraulic actuator model;
FIG. 6 is a diagram of Amesim simulation results;
FIG. 7 is a plot of PID expected and actual values.
Detailed Description
The present invention will now be described in further detail with reference to the following examples, which are intended to be illustrative, but not limiting, of the invention.
Referring to fig. 1,1, a multi-source heterogeneous model white box integration method based on a shared memory technology is characterized by comprising the following operations:
1) Packaging a shared memory FMU through an FMI protocol, wherein the shared memory FMU comprises an FMI description file and an executable file, and a shared memory, a clock synchronization protocol and a data interface protocol to be followed by software participating in simulation are provided;
the shared memory is in an inter-process communication mode, and the address space of the same physical memory is mapped into the address spaces of different processes, so that the communication between the different processes can be realized by directly modifying the memory in the address spaces;
the clock synchronization sets the synchronous communication step length of each simulation software of the joint simulation;
the data interface relation protocol establishes a unified interface protocol for each simulation tool, and comprises the steps of adding _ in to the name of an input signal and adding _ out to the name of an output signal in each subsystem, separating the signals by using English commas (,), separating the total input signal and the output signal by using English semicolons (;), and allowing no repetition of the name of each signal; the information forms interface information of each subsystem in a character string mode, and provides support for FMU processing interface relation;
the shared memory FMU reserves a setting port of a communication step length of interface protocol and model interaction for a user;
2) Then, the shared memory FMU is led into each simulation tool participating in simulation, each simulation tool realizes interactive data through the shared memory FMU,
after the simulation software is imported into the FMU, the parameters are defined as the parameters of the model variables, and the parameters can be displayed and modified on a parameter setting interface of the FMU;
3) According to the FMI simulation process, after FMU parameter information is set, simulation software calls an FMI interface function to transmit the information to an executable file in the FMU in the initialization process of the FMU;
the interface parameters set by the executable file analysis are created or read according to the input and output parameters in the interface information; writing the output data of the model into a shared memory at a specific communication step length moment according to an interface protocol; meanwhile, other models are waited to write the input data required by the model into the shared memory and then read the input data; and then entering the next communication step length, and circulating until all the simulations are finished.
The following describes each part in detail.
The FMU under FMI protocol is a ZIP compressed package taking FMU as suffix, mainly comprises two files, one is FMI Description File (Description File) based on XML format, and defines the structure and content of model frame; the two are executable files, such as Dynamic Link Library (DLL) files in Windows platforms, that specify the interface of all the required functions in the co-simulation.
The FMI model description file is an important component of an FMI standard and is used for simulating basic configuration work before execution; the XML file describes the FMU model attribute information in detail, and the simulation software analyzes the XML file and reads the model configuration information.
The executable file contains core codes required by the compiled simulation model to execute simulation, and external interface function names specified in FMI standard are presented externally. The model provider needs to implement all functions according to the interface definition, and the simulation software can run by calling the functions;
specifically, the DLL file that the FMU can generate in the Co-Simulation mode is accompanied by a solver used in the original modeling tool, that is, another model solver is not used in the Simulation of the FMU model.
Among the FMI standard of Co-Simulation and the FMI standard of Model Exchange, the data interface information contained in the DLL file is not very same; simulation software simulates the FMU model by circularly calling and using the algorithm logic contained in the interface function, and the function execution condition needs to be known through state information at each step of calling.
1. Making a shared memory FMU
And manufacturing the FMU according to the process of executing the FMU by the simulation software.
Firstly, in the joint simulation process of the heterogeneous model, the subsystem models are in different simulation software, and data interaction among the subsystems can form a certain interface relation. Through the interface relationship, each subsystem can obtain the data required by itself. For example, the pressure (Ps) in the Amesim model needs to be passed to the model in Simulinex, while the model in Simulinex needs to pass the flow (Q) to the model in Amesim.
The interface relation protocol of the invention specifies that the name of an input signal plus 'in', the name of an output signal plus 'out' in each subsystem, the signals are separated by an English comma (,) and the total input signal and the output signal are separated by an English semicolon (;), and the name of each signal is not allowed to be repeated. The information forms interface information of each subsystem in a character string mode, and provides support for FMU processing interface relation. As in the above example. For the Amesim model, the interface information is as follows: "Q _ in; ps _ out "; for the SimulationX model, the interface information is: "Ps _ in; q _ out ".
Secondly, the FMU needs to set the communication step length of the interface information and the model interaction for the user. The requirement can be realized by writing model description of FMU, modelvariables in the model description file can be used for defining model variables, writing XML of the model description file, and defining interface information, communication step length, input and output numbers and the like as the model variables.
2. Joint simulation
After the simulation software or the simulation tool is imported into the FMU, the parameters are defined as the parameters of the model variables, and the parameters can be displayed and modified on a parameter setting interface of the FMU. Namely, the FMU can be generated at one time and modified and used at any time.
The whole process can be divided into four stages when the simulation task is carried out: instantiation, initialization, simulation operation and simulation termination; according to the FMI simulation process, after a user sets parameter information, simulation software calls an FMI interface function to transmit the information to an executable file in an FMU in the initialization process of the FMU.
The executable file (dll) analyzes the set interface parameters, and creates or reads the shared memory according to the input and output parameters in the interface information; at a specific communication step time, writing the output data of the model into a shared memory according to a software interface protocol; and meanwhile, other models are waited to write the input data required by the model into the shared memory and then read the input data. And then entering the next communication step length, and circulating until all the simulations are finished.
3. Data synchronization
In the joint simulation process, the key point after the integration of the multi-source heterogeneous model is data synchronization. The data synchronization can ensure that the calculation result of the model is correct. The invention realizes data synchronization by using data mutual exclusion lock and simulation time synchronization. Firstly, the total simulation duration requirements of all models of the combined simulation are consistent. Secondly, the input data of a certain model is from the output of other models, at the time T, the model A writes the output data and the simulation time T of the model A into the shared memory named by the data name, after the model B reaches the time T, whether the shared memory of the data name exists is firstly searched, and if not, the interface information is set to be wrong. And then reading the moment of the current shared memory, if the moment of the current shared memory is consistent with the moment of the current shared memory, directly reading the data, and if the moment of the current shared memory is T-1, reading the data with the last communication step length, wherein the moment and the data need to be circularly waited for the refreshing of the simulation software A.
Specific examples are given below: example of multi-source heterogeneous model white-box integration.
The hydraulic servo control system is a complex system with multidisciplinary intersection and high technical density, mainly comprises subsystems such as machinery, hydraulic pressure and control, and the subsystems have coupling relation of interaction and mutual influence. The design of the hydraulic servo control system has obvious 'multidisciplinary' characteristics and belongs to a typical multidisciplinary design problem. Therefore, how to comprehensively coordinate each subsystem for multidisciplinary design has become a key problem of the design of the mechatronic-hydraulic integrated system.
Whether the optimization of the hydraulic servo control system can be solved or not is mainly determined by whether a reasonable optimization model can be established or not and selecting an effective optimization algorithm suitable for the optimization model. Therefore, multidisciplinary modeling and joint simulation of complex system design and optimization of the hydraulic servo control system are required.
The hydraulic servo control system is a servo control system of a hydraulic cylinder position closed loop, models shown in the following are established, and the interactive relation among the models and the interface information combed according to the self-defined interface protocol are shown in figure 2. PID control is a model built with Open Modelica simulation software, as shown in FIG. 3. The hydraulic source is a model built by using simulation X simulation software, and is shown in FIG. 4; the hydraulic control and execution mechanism is a model built by AMESim simulation software, and is shown in figure 5. Compared with the method of integrating the model exported from the FMU, the method can adjust the parameters of the model in each piece of software at any time in the real-time simulation process and observe the output result of the model.
Specifically, the input target value in the PID control model is a sinusoidal signal with an amplitude of 0.02 and a frequency of 0.02 HZ. And after PID calculation, the output value is transmitted to an Amesim hydraulic actuator model through a shared memory FMU. Meanwhile, a hydraulic source model in Simulingx transmits a pressure signal to a hydraulic actuating mechanism of Amesim through a shared memory FMU, the hydraulic actuating mechanism of Amesim transmits an output displacement signal to a control system through the shared memory FMU, and output displacement of the hydraulic actuating mechanism is output according to a sine signal of the control system through negative feedback and PID control.
Through simulation, the displacement curve of the hydraulic actuator model in AMESim is shown in FIG. 6, and the PID expected value and the actual action value in Open Modelica are shown in FIG. 7.
The embodiments given above are preferable examples for implementing the present invention, and the present invention is not limited to the above-described embodiments. Any non-essential addition and replacement made by the technical characteristics of the technical scheme of the invention by a person skilled in the art belong to the protection scope of the invention.

Claims (4)

1. A multi-source heterogeneous model white box integration method based on a shared memory technology is characterized by comprising the following operations:
1) Packaging a shared memory FMU through an FMI protocol, wherein the shared memory FMU comprises an FMI description file and an executable file, and a shared memory, a clock synchronization protocol and a data interface protocol to be followed by software participating in simulation are given;
the shared memory is in an inter-process communication mode, and the address space of the same physical memory is mapped into the address spaces of different processes, so that the communication between the different processes can be realized by directly modifying the memory in the address spaces;
the clock synchronization sets the synchronous communication step length of each simulation software of the joint simulation;
the data interface relation protocol establishes a unified interface protocol for each simulation tool, and comprises the steps of adding _ in to the name of an input signal and adding _ out to the name of an output signal in each subsystem, separating the signals by using English commas (,), separating the total input signal and the output signal by using English semicolons (;), and allowing no repetition of the name of each signal; the information forms interface information of each subsystem in a character string form, and provides support for FMU processing interface relation;
the shared memory FMU reserves a setting port of a communication step length of interface protocol and model interaction for a user;
2) Then, the shared memory FMU is led into each simulation tool participating in simulation, each simulation tool realizes interactive data through the shared memory FMU,
after the simulation software is imported into the FMU, the parameters are defined as the parameters of the model variables, and the parameters can be displayed and modified on a parameter setting interface of the FMU;
3) According to the FMI simulation process, after FMU parameter information is set, simulation software calls an FMI interface function to transmit the information to an executable file in the FMU in the initialization process of the FMU;
the interface parameters set by the executable file analysis are created or read according to the input and output parameters in the interface information; writing the output data of the model into a shared memory at a specific communication step length moment according to an interface protocol; meanwhile, other models are waited to write the input data required by the model into the shared memory and then read the input data; and then entering the next communication step length, and circulating until all the simulations are finished.
2. The multi-source heterogeneous model white box integration method based on the shared memory technology, as claimed in claim 1, wherein the FMI description file describes FMU model attribute information in detail, including structure and content of model framework; the simulation tool reads the model configuration information by analyzing the model configuration information;
the executable file specifies the interface to all required functions in the co-simulation for simulating the basic configuration before execution.
3. The multi-source heterogeneous model white box integration method based on the shared memory technology as claimed in claim 1 or 2, characterized in that interface information of a subsystem and communication step length of model interaction are left to a user for setting by writing a model description file of an FMU;
ModelVariables in the model description file can be used to define model variables; writing XML of the model description file, and defining interface information, communication step length, input and output numbers and the like as model variables.
4. The shared-memory-technology-based multi-source heterogeneous model white-box integration method according to claim 1, wherein the clock synchronization is data synchronization achieved by using a data exclusive lock and simulation time synchronization:
firstly, the total simulation duration requirements of all models of combined simulation are consistent;
secondly, input data of a certain model are output from other models, at the time T, the model A writes the output data and the self simulation time T into the shared memory named by the data name, after the model B reaches the time T, whether the shared memory of the data name exists is firstly searched, and if not, interface information is set to be wrong;
and then reading the moment of the current shared memory, if the moment of the current shared memory is consistent, directly reading the data, and if the moment of the current shared memory is T-1, reading the data of the last communication step length, wherein the moment and the data need to be circularly waited for by the simulation software A to refresh.
CN202211070517.9A 2022-09-02 2022-09-02 Multi-source heterogeneous model white box integration method based on shared memory technology Pending CN115421940A (en)

Priority Applications (1)

Application Number Priority Date Filing Date Title
CN202211070517.9A CN115421940A (en) 2022-09-02 2022-09-02 Multi-source heterogeneous model white box integration method based on shared memory technology

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
CN202211070517.9A CN115421940A (en) 2022-09-02 2022-09-02 Multi-source heterogeneous model white box integration method based on shared memory technology

Publications (1)

Publication Number Publication Date
CN115421940A true CN115421940A (en) 2022-12-02

Family

ID=84202831

Family Applications (1)

Application Number Title Priority Date Filing Date
CN202211070517.9A Pending CN115421940A (en) 2022-09-02 2022-09-02 Multi-source heterogeneous model white box integration method based on shared memory technology

Country Status (1)

Country Link
CN (1) CN115421940A (en)

Cited By (1)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN116541131A (en) * 2023-06-29 2023-08-04 西安羚控电子科技有限公司 Multi-model operation method and system based on VxWorks real-time system

Cited By (2)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN116541131A (en) * 2023-06-29 2023-08-04 西安羚控电子科技有限公司 Multi-model operation method and system based on VxWorks real-time system
CN116541131B (en) * 2023-06-29 2023-09-22 西安羚控电子科技有限公司 Multi-model operation method and system based on VxWorks real-time system

Similar Documents

Publication Publication Date Title
CN111507020B (en) Graphical display method for distributed simulation results of electromechanical systems of multi-electric aircraft
US8352906B2 (en) Method, system, and computer program product for implementing external domain independent modeling framework in a system design
CN107341294A (en) Spacecraft Information System Modeling emulation mode based on Modelica language
Pakonen et al. A toolset for model checking of PLC software
CN110221815B (en) Automatic generation method of control software model based on ontology
JP2009524138A (en) Modeling and simulation methods
CN102289593A (en) Multidisciplinary virtual experiment interactive simulation solution system
CN107346249A (en) A kind of computer software development approach based on model
CN111650847A (en) Method for integrating actuator model in aeroengine hardware on loop platform
CN103942092B (en) A kind of HLA synergy emulation methods for supporting LabView graphic programmings
CN115098218B (en) Description and simulation method from FMU model to functional block model in configuration software
CN109918820A (en) Complicated satellite simulation support platform
CN115421940A (en) Multi-source heterogeneous model white box integration method based on shared memory technology
Đukić et al. Model execution: An approach based on extending domain-specific modeling with action reports
CN102750177B (en) Script realization method using compiler
CN104657136B (en) The integrated system of Simulink components
CN104063231A (en) Test resource rapid access method based on HIT-TENA
Pohl et al. vMAGIC—automatic code generation for VHDL
Wang et al. Component-based formal modeling of PLC systems
CN110955411A (en) Software integration interactive design method
CN103810335A (en) Complex system parallel simulation oriented assembly type description method
Tolvanen et al. Metamodeling for medical devices: Code generation, model-debugging and run-time synchronization
Herber A Framework for Automated HW/SW Co-Verification of SystemC Designs using Timed Automata
Zheng et al. Design and implementation of a dynamic system simulation framework for plasma control system verification platform
Yang et al. Executing Strategy and Visualization Design for Instruction of Soft PLC System.

Legal Events

Date Code Title Description
PB01 Publication
PB01 Publication
SE01 Entry into force of request for substantive examination
SE01 Entry into force of request for substantive examination