An embedded evaluation system based on rule engine and virtual simulation

Through the embedded evaluation system based on rule engine and virtual simulation, the problems of high cost and poor flexibility of traditional evaluation are solved, and efficient and flexible embedded system evaluation is achieved, supporting complex environment simulation and rapid configuration.

CN119690033BActive Publication Date: 2025-09-30SHENZHEN ACAD OF AEROSPACE TECH
View PDF 0 Cites 0 Cited by

Patent Information

Application Number
CN202411715127.1
Authority / Receiving Office
CN · China
Patent Type
Patents(China)
Current Assignee / Owner
Filing Date
2024-11-27
Publication Date
2025-09-30
Estimated Expiration
2044-11-27

AI Technical Summary

Technical Problem

Traditional embedded system evaluation methods are costly and time-consuming, making it difficult to cover all operating scenarios. In addition, the evaluation function points have poor flexibility and are unable to meet the needs of complex embedded systems.

Method used

An embedded evaluation system based on rule engine and virtual simulation is adopted. The simulation model module simulates hardware conditions and fault conditions. The rule engine module monitors and judges the circuit status in real time. The user front-end configures the evaluation rules and displays the results. The modular design of the system supports flexible configuration and rapid adjustment.

Benefits of technology

Reduce evaluation costs, improve evaluation efficiency and comprehensiveness, support complex environment simulation, discover potential problems, and achieve flexible evaluation process configuration and system performance improvement.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN119690033B_ABST
    Figure CN119690033B_ABST
Patent Text Reader

Abstract

The present invention provides an embedded system evaluation system based on a rule engine and virtual simulation, comprising a simulation model module for simulating the behavior of an embedded device and its circuit system and providing a virtual test environment to simulate different hardware conditions, input signals, and fault conditions; a rule engine module for triggering actions or making intelligent decisions based on preset rules; wherein the rule engine module monitors data during the simulation process in real time and determines whether the circuit system is in a normal working state based on the rules; a user front-end module for configuring the simulation model, defining evaluation rules, displaying simulation phenomena, and outputting evaluation results; and before the simulation begins, the simulation model module sends all basic rules for the microcontroller and electronic modules involved in the simulation to the rule engine module to form a rule library. The present invention can solve the problems of high cost, long cycle time, and poor flexibility in the existing embedded system evaluation technology.
Need to check novelty before this filing date? Find Prior Art

Description

Technical Field

[0001] The present invention relates to the technical field of virtual simulation systems, and in particular to an embedded evaluation system based on a rule engine and virtual simulation. Background Art

[0002] With the widespread application of embedded systems in various industries, such as industrial automation, automotive electronics, and medical equipment, the performance and reliability requirements are increasing. Traditional embedded system evaluation methods often rely on physical hardware construction and actual operational testing. This approach is not only costly and time-consuming, but also difficult to cover all possible operational scenarios and boundary conditions. In addition, traditional embedded simulation evaluation tools have simple or single evaluation content, and the evaluation function points cannot be flexibly configured to meet user needs. When the embedded system becomes complex or requires the evaluation of functional points with certain logical connections, traditional embedded evaluation tools are difficult to meet the requirements, and evaluators need to spend a lot of time and effort to compile the evaluation results.

[0003] Therefore, it is of great significance to develop an embedded evaluation system based on rule engine and virtual simulation. Summary of the Invention

[0004] In order to solve the problems existing in the prior art, the purpose of the present invention is to provide an embedded system evaluation system based on rule engine and virtual simulation to solve the problems of high cost, long cycle and poor flexibility of embedded system evaluation in the prior art.

[0005] The present invention achieves the above-mentioned purpose through the following technical solutions:

[0006] An embedded evaluation system based on rule engine and virtual simulation, comprising:

[0007] Simulation model module, used to simulate the behavior of embedded devices and their circuit systems, and provide a virtual test environment to simulate different hardware conditions, input signals and fault conditions;

[0008] A rule engine module is used to trigger actions or make intelligent decisions based on preset rules. The rule engine module monitors the data during the simulation in real time and determines whether the circuit system is in normal working condition based on the rules.

[0009] User front-end module, through which the simulation model is configured, evaluation rules are defined, simulation phenomena are displayed, and evaluation results are output;

[0010] Before the simulation starts, the simulation model module sends all basic rules of the microcontroller and electronic modules involved in the simulation to the rule engine module to form a rule base;

[0011] When the simulation starts, the simulation model module starts simulating the circuit system according to the user configuration. The rule engine module monitors the data in the simulation process in real time, matches it with the rules in the rule library, and determines whether the circuit system is working normally.

[0012] According to an embedded evaluation system based on a rule engine and virtual simulation provided by the present invention, the simulation model module realizes the simulation operation of a microcontroller, a sensor, an actuator, and an electronic circuit through virtualization software.

[0013] According to an embedded evaluation system based on a rule engine and virtual simulation provided by the present invention, the simulation model is configured as a device for adding a logical interface to the code fragment of key behaviors, and the logical interface is configured to send data to the user front-end module and the rule engine module; wherein, the data sent through the logical interface obtains real-time display of simulation phenomena and real-time tracking results of simulation events, and the operating status of the simulation system is monitored and analyzed.

[0014] According to an embedded evaluation system based on a rule engine and virtual simulation provided by the present invention, the rule engine module includes:

[0015] Rule base module, used to store all business rules;

[0016] The rule execution module is used to define logical conditions and corresponding actions;

[0017] The fact acquisition module is used to obtain data input into the rule engine in real time;

[0018] The reasoning module is used to match rules and execute corresponding actions based on the rule set and facts in the working memory.

[0019] According to an embedded evaluation system based on a rule engine and virtual simulation provided by the present invention, the user front-end module includes:

[0020] Simulation building module, used to support users to build circuits and write codes;

[0021] The rule definition module provides a graphical rule definition interface to support user-defined evaluation rules;

[0022] Simulation display module, used to display simulation phenomena;

[0023] The evaluation result display module is used to output the evaluation results.

[0024] According to an embedded evaluation system based on a rule engine and virtual simulation provided by the present invention, the simulation construction module is configured to allow the construction of the required circuit diagram before the evaluation process begins. The circuit diagram includes at least one microcontroller and various electronic modules and components connected to it; wherein the completed circuit information is automatically sent to the simulation model so that the simulation model can start and configure the corresponding components for simulation operation based on this information.

[0025] According to the embedded evaluation system based on rule engine and virtual simulation provided by the present invention, before the evaluation begins, the embedded code is written or uploaded through a specified interface. The system has a built-in GCC compiler for compiling the user-provided embedded code into an executable program; when the simulation is officially started, the system's integrated GDB interface is responsible for loading the compiled executable program into a virtual microcontroller to simulate the program execution process in a real environment.

[0026] According to an embedded evaluation system based on a rule engine and virtual simulation provided by the present invention, the rule definition module specifically includes:

[0027] Nodes and connecting lines. Nodes are used to represent the basic units of rules, conditions, or actions, and connecting lines are used to represent the logical relationships between nodes.

[0028] Allows you to select rules from the preset rule library and add corresponding nodes in the rule definition module according to the selected rules;

[0029] Provides a user interface to specify conditions for added nodes and define actions to be performed when the conditions are met. These conditions and actions are set in the form of node attributes;

[0030] Allows users to flexibly use connection lines in the graphical interface to connect various nodes according to logical relationships through drag-and-drop and connection operations to form a complete evaluation rule process;

[0031] Provide editing function to modify the properties of each node directly in the graphical interface;

[0032] After completing the addition, connection and property setting of nodes, the corresponding evaluation rules are automatically generated and saved. The evaluation rules can be executed based on the graphically defined structure and logic.

[0033] According to an embedded evaluation system based on a rule engine and virtual simulation provided by the present invention, data interaction is performed between the simulation model module, the rule engine module and the user front-end module via a network protocol to achieve communication and collaboration between the modules.

[0034] According to an embedded evaluation system based on a rule engine and virtual simulation provided by the present invention, the network protocol supports the simulation model module to send real-time data generated during the simulation process to the rule engine module for rule matching and intelligent decision-making. It also supports the rule engine module to feed back decision results or triggered action instructions to the simulation model module to adjust the simulation behavior;

[0035] The network protocol also ensures that the user front-end module can communicate bidirectionally with the simulation model module and the rule engine module. On the one hand, it receives and displays the simulation phenomena and status information sent by the simulation model module. On the other hand, it allows the user to configure simulation parameters, define or modify evaluation rules through the front-end interface, and send these configurations and rules to the corresponding modules through the network protocol for execution.

[0036] It can be seen that compared with the prior art, the system provided by the present invention has the following beneficial effects:

[0037] 1. The present invention uses virtual simulation technology to conduct comprehensive evaluation of embedded systems without purchasing actual hardware, greatly reducing evaluation costs.

[0038] 2. The virtual simulation environment provided by the present invention can be quickly built and modified, and the evaluation scene and parameters can be quickly adjusted to improve evaluation efficiency.

[0039] 3. The evaluation system based on the rule engine of the present invention can dynamically adjust the evaluation rules and processes according to different evaluation requirements, thereby realizing flexible configuration of the evaluation process.

[0040] 4. The virtual simulation technology of the present invention can simulate extreme and complex operating environments, helping evaluators to discover potential problems and defects, and improving the comprehensiveness and accuracy of the evaluation.

[0041] 5. This invention separates the simulation model, rule engine, and user front-end into functional components, enabling them to interact and collaborate over a network. This modular design improves system performance, flexibility, scalability, and fault tolerance. When users need to upgrade a function or add an extension, they don't need to redevelop the entire system.

[0042] The present invention will be further described in detail below with reference to the accompanying drawings and specific embodiments. BRIEF DESCRIPTION OF THE DRAWINGS

[0043] Figure 1 This is a schematic diagram of an embodiment of an embedded evaluation system based on a rule engine and virtual simulation according to the present invention. DETAILED DESCRIPTION

[0044] To make the objectives, technical solutions, and advantages of the present invention more clear, the technical solutions of the present invention will be clearly and completely described below in conjunction with the accompanying drawings. Obviously, the embodiments described are only some of the embodiments of the present invention, not all of them. Based on the embodiments of the present invention, all other embodiments obtained by ordinary technicians in this field without making creative efforts shall fall within the scope of protection of the present invention.

[0045] References herein to "embodiments" mean that a particular feature, structure, or characteristic described in connection with the embodiments may be included in at least one embodiment of the present application. The appearance of this phrase in various places in the specification does not necessarily refer to the same embodiment, nor does it constitute an independent or alternative embodiment that is mutually exclusive of other embodiments. It is understood, both explicitly and implicitly, by those skilled in the art that the embodiments described herein may be combined with other embodiments.

[0046] See also Figure 1 The present invention provides an embedded evaluation system based on a rule engine and virtual simulation, comprising:

[0047] The simulation model module is used to simulate the behavior of embedded devices and their circuit systems, and provide a virtual test environment to simulate different hardware conditions, input signals and fault conditions, so that the system can be functionally verified and performance evaluated without the need for real embedded hardware.

[0048] The rule engine module is used to trigger actions or make intelligent decisions based on preset rules. It monitors data during the simulation in real time and uses these rules to determine whether the circuit system is functioning properly. The rule engine module is the decision-making core of the entire system. It tracks data and events in the simulation environment and triggers actions or makes intelligent decisions based on preset rules.

[0049] User front-end module, through which the simulation model is configured, evaluation rules are defined, simulation phenomena are displayed, and evaluation results are output.

[0050] Before the simulation starts, the simulation model module sends all the basic rules of the microcontroller and electronic modules involved in the simulation to the rule engine module to form a rule base;

[0051] When the simulation starts, the simulation model module starts simulating the circuit system according to the user configuration. The rule engine module monitors the data in the simulation process in real time, matches it with the rules in the rule library, and determines whether the circuit system is working normally.

[0052] In this embodiment, the simulation model module realizes the simulation operation of the microcontroller, sensor, actuator, and electronic circuit through virtualization software.

[0053] In this embodiment, the simulation model is configured as a device for adding a logical interface to the code fragment of the key behavior, and the logical interface is configured to send data to the user front-end module and the rule engine module; wherein, the data sent through the logical interface obtains the real-time display of the simulation phenomenon and the real-time tracking results of the simulation event, and the operating status of the simulation system is monitored and analyzed.

[0054] Specifically, an embedded device is a device that integrates a dedicated circuit system and software. Its hardware part usually includes a microcontroller, sensors, actuators and other electronic circuits, and its software part is usually an executable program running on the microcontroller.

[0055] To simulate embedded devices, simulation models use various virtualization software to simulate microcontrollers, sensors, actuators, and electronic circuits. For example, QEMU can be used to simulate a microcontroller, and embedded code can be compiled into an executable program using GCC. The executable program on the microcontroller can then be loaded into QEMU using the GDB interface. Programming tools such as SystemC, SystemC-AMS, SPICE, and C++ can be used to simulate sensors, actuators, and basic electronic circuits (resistors, capacitors, diodes, transistors, power supplies, switches, etc.).

[0056] Because the simulation model simulates all controller behaviors and electronic signals, users can add logical interfaces to key behavioral code snippets. These interfaces can send data to the user front end and the rule engine, enabling real-time display of simulation phenomena and tracking of simulation events. Before the simulation begins, the simulation model sends all the basic rules for the microcontroller and electronic modules involved in the simulation to the rule engine, forming a rule library.

[0057] In order to meet the needs of user operations, the simulation model must also have other interfaces for interacting with the user front end, so as to realize functions such as running simulation, stopping simulation, configuring circuits, modifying codes, and compiling codes.

[0058] In this embodiment, the rule engine module is a system that can execute business rules. It automatically makes decisions based on input data by parsing predefined rule sets. The rule engine can separate business logic (evaluation content) from application (simulation software) code, so that business rules (evaluation targets) can be flexibly defined, modified, and executed. There are many common rule engines that can implement these functions, such as Drools, Jess, Easy Rules, etc. In order to realize the evaluation of embedded simulation models, the rule engine module needs to have the following core modules:

[0059] The rule base module stores all business rules. After the user configures the simulation model's circuit information, the simulation model will inform the rule engine of the basic rules that can be loaded for this evaluation. For example, if the user adds Button 1 to the circuit, the simulation model will inform the rule engine that the basic rules that can be added include "Button 1 Pressed" and "Button 1 Released." The rule engine will then save these basic rules in the rule base.

[0060] The rule execution module defines logical conditions and corresponding actions. Rules are typically conditional expressions consisting of "if-then" statements. For example, "If button 1 is pressed, then LED 1 turns on" can be used to evaluate the proper functionality of button 1 and LED 1. Before starting the evaluation, users can use the rule definition module provided by the front-end. Using the graphical interface, users can select a number of basic rules from the rule library based on their specific needs and then combine them into a rule set (evaluation target).

[0061] The fact acquisition module is used to obtain data (simulation model data and user interaction data) input into the rule engine in real time. The rule engine evaluates rules based on this data. For example, whether button 1 is pressed or released, whether LED 1 is on or off, etc.

[0062] The inference module is used to match rules and execute corresponding actions based on the rule set and facts in the working memory. The inference engine uses the inference process to determine which rules need to be triggered. Finally, the rule engine sends the triggering information to the user front end for display.

[0063] In this embodiment, the user front-end primarily provides a user-friendly interactive interface, enabling users to conveniently configure simulation content, define evaluation rules, observe the simulation scene, and analyze evaluation results. Many development tools can implement these functions, such as using C++ or C# to develop Windows-based applications and JavaScript to develop browser-based web applications. Specifically, the user front-end needs to include the following functional modules:

[0064] The simulation building module is used to support users to build circuits and write codes on the front-end interface according to their needs.

[0065] The rule definition module provides a graphical rule definition interface that supports user-defined evaluation rules, making it easier for embedded developers and university teachers to use. After the rule definition is completed, the defined information is sent to the rule engine. When the evaluation is started, the rule engine's reasoning module compares this information with the facts.

[0066] The simulation display module is used to display simulation phenomena. After running a simulation or starting an evaluation, the simulation front-end will activate the simulation display module. The simulation model continuously sends simulation phenomena, such as "LED 1 lights up," to the user front-end. The simulation front-end needs to display these phenomena in the simulation display module in real time. Furthermore, the simulation display module provides an interface that supports user interaction, allowing users to inject events into the simulation model. For example, a user may want to send events such as "Button 1 pressed and released" to the simulation model.

[0067] The evaluation results display module is used to output evaluation results. After the evaluation begins, the simulation model continuously sends simulation behavior information to the rule engine, which compares this information in real time. When the rule engine finds that the simulation facts meet the user-defined rules, it sends the inference results to the user front-end. This information can be displayed in the evaluation results display module during or after the evaluation.

[0068] In this embodiment, the simulation construction module is configured to allow the construction of the required circuit diagram before the evaluation process begins, which circuit diagram includes at least one microcontroller and various electronic modules and components connected to it; wherein the completed circuit information is automatically sent to the simulation model so that the simulation model can start and configure the corresponding components for simulation operation based on this information.

[0069] In this embodiment, before the evaluation begins, the embedded code is written or uploaded through the specified interface. The system has a built-in GCC compiler for compiling the embedded code provided by the user into an executable program. When the simulation is officially started, the system-integrated GDB interface is responsible for loading the compiled executable program into the virtual microcontroller to simulate the program execution process in a real environment.

[0070] As can be seen, users need to build the required circuit diagram before the evaluation begins, including the microcontroller and various electronic modules and components. The completed circuit information is sent to the simulation model, which activates the relevant components based on the specific information. Users also need to write or upload embedded code before the evaluation begins, and then use the system's GCC to compile the embedded code into an executable program. After the simulation starts, the GDB interface loads the executable program into the virtual microcontroller for execution.

[0071] In this embodiment, the rule definition module specifically includes:

[0072] Nodes and connecting lines. Nodes are used to represent the basic units of rules, conditions or actions, and connecting lines are used to represent the logical relationships between nodes.

[0073] Allows you to select rules from a preset rule library and add corresponding nodes in the rule definition module based on the selected rules.

[0074] Provides a user interface to specify conditions for added nodes and define actions to be performed when the conditions are met. These conditions and actions are set in the form of node attributes.

[0075] It allows users to flexibly use connection lines in the graphical interface to connect various nodes according to logical relationships through drag-and-drop and connection operations to form a complete evaluation rule process.

[0076] Provides editing function to modify the properties of each node directly in the graphical interface.

[0077] After completing the addition, connection and property setting of nodes, the corresponding evaluation rules are automatically generated and saved. The evaluation rules can be executed based on the graphically defined structure and logic.

[0078] As you can see, the main graphical elements displayed in the graphical rule definition module are nodes and connecting lines. Each node represents the basic unit of a rule, condition, or action, and each connecting line represents the logical relationship between nodes. Users can obtain rules from the previous rule library, add conditions and actions, and then add nodes to the rule definition module, and then connect these nodes with connecting lines. Users can also modify the properties of each node (such as condition judgment, action parameters, etc.) to ultimately form evaluation rules.

[0079] In this embodiment, the simulation model module, the rule engine module and the user front-end module exchange data via a network protocol to achieve communication and collaboration between the modules.

[0080] The network protocol enables the simulation model module to send real-time data generated during the simulation process to the rule engine module for rule matching and intelligent decision-making. It also enables the rule engine module to feed back decision results or triggered action instructions to the simulation model module to adjust simulation behavior. The network protocol also ensures that the user front-end module can communicate bidirectionally with the simulation model module and the rule engine module. On the one hand, it receives and displays simulation phenomena and status information sent by the simulation model module. On the other hand, it allows users to configure simulation parameters, define or modify evaluation rules through the front-end interface, and send these configurations and rules to the corresponding modules via the network protocol for execution. For example, data exchange between the simulation model module, the rule engine module, and the user front-end module can use protocols such as TCP, HTTP, MQTT, and WebSocket.

[0081] In practical applications, this embodiment further provides an application method of an embedded evaluation system based on a rule engine and virtual simulation, including:

[0082] 1. Build the circuit: Use the user front end to build the circuit of the embedded device, including the embedded microcontroller, various peripheral electronic modules and components, and then save it.

[0083] 2. Write code: Use the user front end to write embedded code, and then compile the program to ensure that the program can run normally.

[0084] 3. Simulation: Use the simulation function provided by the system to run the embedded simulation system to observe whether the embedded system's execution effect meets the evaluation requirements. If not, you can modify the circuit and code until it meets the requirements.

[0085] 4. Define rules: Open the rule definition module on the user front end and define evaluation rules. Rules are usually defined based on conditions such as device status, communication data, and user input, and trigger conditions and subsequent actions can be set.

[0086] 5. Start the evaluation: Run the evaluation and observe the simulation phenomena. The evaluation system will automatically execute the simulation and rule engine according to the evaluation rules set by the user, and record the evaluation results. When the simulation model module generates new events or data, the rule engine automatically evaluates this information, determines whether the trigger conditions of certain rules are met, and performs corresponding actions (such as controlling devices, sending notifications, generating reports, etc.). The system supports dynamic loading and modification of rules at runtime, facilitating debugging and optimization during the simulation process.

[0087] 6. Observation results: The system ends the evaluation (timed stop, automatic stop due to meeting the rules, manual stop), and displays the evaluation results in the evaluation result display module on the user front end.

[0088] In summary, most simulation tools currently on the market suffer from severe scripting issues and limited simulation functionality. For example, they only support a small number of microcontrollers or lack user-friendly programming or the ability to freely build circuits. This invention utilizes the open-source, general-purpose computer simulation and virtualization tool QEMU, as well as industrial-grade electronic circuit simulation frameworks such as SystemC, System-AMS, and SPICE. These powerful tools can simulate complex and large embedded systems, unrestricting connections between electronic modules and supporting simulation at the controller instruction level and electronic signal timing level.

[0089] Furthermore, traditional electronic circuit simulation models do not have automatic evaluation functions, have few evaluation functions, or the evaluation tasks do not support users to modify at will. For large embedded systems with complex evaluation targets, the burden on evaluators is still very large. The present invention combines rule engine technology to achieve the separation of business logic (evaluation content) and application (simulation software) code, so that business rules (evaluation targets) can be flexibly defined, modified and executed, which is more suitable for the automated evaluation of large and complex embedded systems. After the embedded simulation circuit is built, the evaluation engine automatically obtains the basic rules of all simulation modules, and the user freely matches the required evaluation functions in the rule base. The user's operation will not affect the simulation model, and the evaluator does not need to care about the technical implementation of the embedded system and the simulation system.

[0090] Furthermore, in traditional embedded evaluation systems, the evaluation function points must be implemented by simulation model developers because these evaluation function codes are coupled with the simulation model code, making it impossible for other developers to intervene. This makes the simulation model code more complex, bloated, and difficult to maintain. The present invention separates the business logic (evaluation content) from the application program (simulation software) code. The two do not affect each other and can be developed and maintained in parallel. When the function of one side needs to be upgraded, it will not affect the other side. The developer responsible for the rule engine does not need to care about the implementation method of the simulation model, which greatly reduces the development threshold and development time of the system.

[0091] Furthermore, whereas traditional computer software integrates the simulation model, rule engine, and user front-end, this invention separates these three components by function, enabling them to interact and collaborate over a network. This modular design improves the system's performance, flexibility, scalability, and fault tolerance. Users no longer need to redevelop the entire system when they need to upgrade a feature or add an extension.

[0092] The technical features of the above embodiments can be combined arbitrarily. To make the description concise, not all possible combinations of the technical features in the above embodiments are described. However, as long as there is no contradiction in the combination of these technical features, they should be considered to be within the scope of this specification.

[0093] The above embodiments are only preferred embodiments of the present invention and cannot be used to limit the scope of protection of the present invention. Any non-substantial changes and replacements made by technicians in this field on the basis of the present invention fall within the scope of protection required by the present invention.

Claims

1. An embedded evaluation system based on rule engine and virtual simulation, characterized in that: include: Simulation model module, used to simulate the behavior of embedded devices and their circuit systems, and provide a virtual test environment to simulate different hardware conditions, input signals and fault conditions; A rule engine module is used to trigger actions or make intelligent decisions based on preset rules. The rule engine module monitors the data during the simulation in real time and determines whether the circuit system is in normal working condition based on the rules. User front-end module, through which the simulation model is configured, evaluation rules are defined, simulation phenomena are displayed, and evaluation results are output; Before the simulation starts, the simulation model module sends all basic rules of the microcontroller and electronic modules involved in the simulation to the rule engine module to form a rule base; When the simulation starts, the simulation model module starts simulating the circuit system according to the user configuration. The rule engine module monitors the data in the simulation process in real time, matches it with the rules in the rule library, and determines whether the circuit system is working normally.

2. The system according to claim 1, wherein: The simulation model module realizes the simulation operation of microcontrollers, sensors, actuators and electronic circuits through virtualization software.

3. The system according to claim 1, wherein: The simulation model is configured as a device for adding a logical interface to the code fragment of key behaviors, and the logical interface is configured to send data to the user front-end module and the rule engine module; wherein, the data sent through the logical interface obtains real-time display of simulation phenomena and real-time tracking results of simulation events, and monitors and analyzes the operating status of the simulation system.

4. The system according to claim 1, wherein: The rule engine module includes: Rule base module, used to store all business rules; The rule execution module is used to define logical conditions and corresponding actions; The fact acquisition module is used to obtain data input into the rule engine in real time; The reasoning module is used to match rules and execute corresponding actions based on the rule set and facts in the working memory.

5. The system according to claim 1, wherein: The user front-end module includes: Simulation building module, used to support users to build circuits and write codes; The rule definition module provides a graphical rule definition interface to support user-defined evaluation rules; Simulation display module, used to display simulation phenomena; The evaluation result display module is used to output the evaluation results.

6. The system according to claim 5, characterized in that: The simulation construction module is configured to allow the construction of the required circuit diagram before the evaluation process begins, which includes at least one microcontroller and various electronic modules and components connected to it; wherein the completed circuit information is automatically sent to the simulation model so that the simulation model can start and configure the corresponding components for simulation operation based on this information.

7. The system according to claim 5, characterized in that: Before the evaluation begins, the embedded code is written or uploaded through the specified interface. The system has a built-in GCC compiler, which is used to compile the user-provided embedded code into an executable program. When the simulation is officially started, the system's integrated GDB interface is responsible for loading the compiled executable program into the virtual microcontroller to simulate the program execution process in a real environment.

8. The system according to claim 5, characterized in that: The rule definition module specifically includes: Nodes and connecting lines. Nodes are used to represent the basic units of rules, conditions, or actions, and connecting lines are used to represent the logical relationships between nodes. Allows you to select rules from the preset rule library and add corresponding nodes in the rule definition module according to the selected rules; Provides a user interface to specify conditions for added nodes and define actions to be performed when the conditions are met. These conditions and actions are set in the form of node attributes; Allows users to flexibly use connection lines in the graphical interface to connect various nodes according to logical relationships through drag-and-drop and connection operations to form a complete evaluation rule process; Provide editing function to modify the properties of each node directly in the graphical interface; After completing the addition, connection and property setting of nodes, the corresponding evaluation rules are automatically generated and saved. The evaluation rules can be executed based on the graphically defined structure and logic.

9. The system according to any one of claims 1 to 8, characterized in that: The simulation model module, rule engine module and user front-end module perform data interaction through network protocols to achieve communication and collaboration between modules.

10. The system according to claim 9, characterized in that: The network protocol supports the simulation model module to send real-time data generated during the simulation process to the rule engine module for rule matching and intelligent decision-making. It also supports the rule engine module to feed back decision results or triggered action instructions to the simulation model module to adjust the simulation behavior; The network protocol also ensures that the user front-end module can communicate bidirectionally with the simulation model module and the rule engine module. On the one hand, it receives and displays the simulation phenomena and status information sent by the simulation model module. On the other hand, it allows the user to configure simulation parameters, define or modify evaluation rules through the front-end interface, and send these configurations and rules to the corresponding modules through the network protocol for execution.