A method and system for generating a simulation operating environment based on a super device object model

Through the simulated operation environment generation method based on the super equipment object model, the problem of inefficiency in the equipment development and testing process is solved, efficient testing and debugging is achieved, project delivery cycle is shortened, and customer satisfaction is improved.

CN119740366APending Publication Date: 2025-04-01深圳开鸿数字产业发展有限公司
View PDF 0 Cites 2 Cited by

Patent Information

Application Number
CN202411790841.7
Authority / Receiving Office
CN · China
Patent Type
Applications(China)
Current Assignee / Owner
Filing Date
2024-12-06
Publication Date
2025-04-01

AI Technical Summary

Technical Problem

The prior art is inefficient in equipment development and testing, and is limited by equipment availability, site restrictions and safety risks, resulting in long delivery cycles and low customer satisfaction.

Method used

The simulation operation environment generation method based on the super equipment object model is adopted. By receiving and analyzing the model data, the topology information and capability pool information of the super equipment are obtained, the simulated device operation environment is generated, and the chaos theory is used to generate automatic operation simulation data and business scenario simulation data.

Benefits of technology

It improves development efficiency, reduces inconvenience and delay caused by equipment availability, site restrictions and security risks, shortens project delivery cycle, improves customer satisfaction, and promotes the rapid innovation and development of intelligent applications in IoT.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN119740366A_ABST
    Figure CN119740366A_ABST
Patent Text Reader

Abstract

The present invention discloses a method and system for generating a simulated operating environment based on a super device physical model, the method comprising: receiving physical model data sent by a super device physical model, parsing the physical model data, obtaining topological information and capability pool information of the super device; and generating a simulated device operating environment based on the topological information and the capability pool information. The present invention receives physical model data sent by a super device physical model, parses the physical model data, obtains topological information and capability pool information of the super device, and then constructs a simulated operating environment of multiple devices based on the topological information and the capability pool information, which not only avoids the tedious process of logging in to devices one by one to trigger messages in the traditional method, reduces the time cost and energy investment of development and testing, but also breaks through the constraints of device availability, site restrictions and security risks, and improves the efficiency and quality of application development and verification.
Need to check novelty before this filing date? Find Prior Art

Description

Technical Field

[0001] The present invention relates to the technical field of Internet of Things, and in particular to a method and system for generating a simulated operating environment based on a super device object model. Background Art

[0002] In the field of device development and testing, developers usually need to perform a lot of operations on real devices when conducting testing and debugging. Although this method can ensure the actual operation of the system, the process is not only time-consuming and labor-intensive, but also affected by many factors such as device availability, site restrictions, and security risks. Traditional simulation devices require developers to log in to each device one by one and trigger messages, which is extremely inefficient. For example, in actual projects, whether it is the debugging of the automation system of a smart factory or the integration testing of smart home devices, they all face problems such as long delivery cycles and low customer satisfaction, making it difficult to fully meet the market's demand for efficient and high-quality device development.

[0003] Therefore, the prior art still needs to be improved and enhanced. Summary of the invention

[0004] The technical problem to be solved by the present invention is that, in view of the above-mentioned defects of the prior art, a method and system for generating a simulated operating environment based on a super device physical model is provided, aiming to solve the multiple problems faced by developers in the process of testing and debugging equipment, such as low efficiency, limited equipment availability, site restrictions and safety risks.

[0005] In order to solve the above technical problems, the technical solution adopted by the present invention is as follows:

[0006] In a first aspect, the present invention provides a method for generating a simulation operation environment based on a super device object model, wherein the method comprises:

[0007] Receiving the object model data sent by the super device object model, and parsing the object model data to obtain the topology information and capability pool information of the super device;

[0008] A simulated device operating environment is generated based on the topology information and the capability pool information.

[0009] In one implementation, the topology information includes the connection relationship between each device in the super device, the communication mechanism and the capability code of each device, and the capability pool information includes the attributes, methods and events of each capability.

[0010] In one implementation, the generating a simulated device operating environment based on the topology information and the capability pool information includes:

[0011] Based on the topology information, create a device tree structure;

[0012] Based on the capability pool information, assign corresponding capability attributes, methods and events to each device node in the device tree structure to obtain a device instance;

[0013] A simulated device operating environment is generated based on the device tree structure and the device instance.

[0014] In one implementation, the method further includes:

[0015] Based on chaos theory, automatic operation simulation data of the equipment and / or business scenario simulation data are generated to obtain simulation operation data;

[0016] Based on the simulated device operating environment and the simulated operating data, the operating state of the real device is simulated.

[0017] In one implementation, the step of generating automatic operation simulation data of the device based on chaos theory includes:

[0018] Based on the attributes of the device, get the data type of the device;

[0019] Based on chaos theory and the data type, select a corresponding chaos model;

[0020] Based on the chaos model, automatic operation simulation data of the equipment is generated.

[0021] In one implementation, generating business scenario simulation data of a device based on chaos theory includes:

[0022] Based on the business scenario of the device, obtain predefined rules of the business scenario;

[0023] Based on the predefined rules, a device to be started is obtained to obtain a target device;

[0024] Based on the attribute of the target device, obtain the data type of the target device;

[0025] Based on chaos theory and the data type, select a corresponding chaos model;

[0026] Based on the chaos model, business scenario simulation data of the device is generated.

[0027] In one implementation, the step of obtaining the simulation operation data further includes:

[0028] The simulation operation data is reported according to the preset interval.

[0029] In a second aspect, an embodiment of the present invention further provides a system for generating a simulated operating environment based on a super device object model, wherein the system comprises:

[0030] An information acquisition module is used to receive the physical model data sent by the super device physical model, and parse the physical model data to obtain the topology information and capability pool information of the super device;

[0031] The device operating environment generating module is used to generate a simulated device operating environment based on the topology information and the capability pool information.

[0032] In the third aspect, an embodiment of the present invention further provides a terminal, wherein the terminal includes a memory, a processor, and a simulation operating environment generation program based on a super device object model stored in the memory and executable on the processor, and when the processor executes the simulation operating environment generation program based on the super device object model, the steps of the simulation operating environment generation method based on the super device object model of any one of the above-mentioned schemes are implemented.

[0033] In a fourth aspect, an embodiment of the present invention further provides a computer-readable storage medium, wherein a simulation operating environment generation program based on a super-device object model is stored on the computer-readable storage medium, and when the simulation operating environment generation program based on the super-device object model is executed by a processor, the steps of the simulation operating environment generation method based on the super-device object model described in any one of the above-mentioned schemes are implemented.

[0034] Beneficial effects: The present invention provides a method for generating a simulated operating environment based on a super-device physical model. Compared with the prior art, the present invention first receives the physical model data sent by the super-device physical model, and parses the physical model data to obtain the topological information and capability pool information of the super-device, thereby achieving a comprehensive understanding of the device structure and function, and providing the necessary data basis for subsequent steps. Then, based on the topological information and the capability pool information, a simulated device operating environment is generated, so that developers can perform efficient testing and debugging without relying on real physical devices. The method proposed in the present invention not only improves development efficiency by constructing a highly simulated simulated operating environment, but also reduces the inconvenience and delay caused by factors such as equipment availability, site restrictions and security risks. At the same time, the method proposed in the present invention reduces the operational complexity of traditional simulation devices logging in to trigger messages one by one, thereby shortening the project delivery cycle, improving customer satisfaction, and promoting the rapid innovation and development of IoT smart applications. BRIEF DESCRIPTION OF THE DRAWINGS

[0035] Figure 1 A flowchart of a specific implementation of a method for generating a simulated operating environment based on a super device object model provided in an embodiment of the present invention.

[0036] Figure 2 A diagram of the implementation architecture of a method for generating a simulated operating environment based on a super device object model provided in an embodiment of the present invention.

[0037] Figure 3 An interactive flow chart of sending physical model data from a super device management cloud platform to a super device simulator in a method for generating a simulation operating environment based on a super device physical model provided in an embodiment of the present invention.

[0038] Figure 4 It is a principle block diagram of a simulation operation environment generation system based on a super device object model provided by an embodiment of the present invention.

[0039] Figure 5 This is a block diagram of the internal structure principle of a terminal provided by an embodiment of the present invention. DETAILED DESCRIPTION

[0040] In order to make the purpose, technical solution and effect of the present invention clearer and more specific, the present invention is further described in detail with reference to the accompanying drawings and examples. It should be understood that the specific embodiments described herein are only used to explain the present invention and are not used to limit the present invention.

[0041] In the field of device development and testing, developers usually need to perform a lot of operations on real devices when conducting testing and debugging. Although this method can ensure the actual operation of the system, the process is not only time-consuming and labor-intensive, but also affected by many factors such as device availability, site restrictions, and security risks. Traditional simulation devices require developers to log in to each device one by one and trigger messages, which is extremely inefficient. For example, in actual projects, whether it is the debugging of the automation system of a smart factory or the integration testing of smart home devices, they all face problems such as long delivery cycles and low customer satisfaction, making it difficult to fully meet the market's demand for efficient and high-quality device development.

[0042] In order to solve the above problems, this embodiment provides a method for generating a simulated operating environment based on a super device physical model. When implemented, this embodiment first receives the physical model data sent by the super device physical model, and parses the physical model data to obtain the topological information and capability pool information of the super device, thereby achieving a comprehensive understanding of the device structure and function, and providing the necessary data basis for subsequent steps. Then, based on the topological information and the capability pool information, a simulated device operating environment is generated, so that developers can perform efficient testing and debugging without relying on real physical devices. The method proposed in the present invention not only improves development efficiency by constructing a highly simulated simulated operating environment, but also reduces the inconvenience and delay caused by factors such as device availability, site restrictions and security risks. At the same time, the method proposed in the present invention reduces the operational complexity of traditional simulation devices logging in to trigger messages one by one, thereby shortening the project delivery cycle, improving customer satisfaction, and promoting the rapid innovation and development of smart applications in the Internet of Things.

[0043] For example, suppose a technology company is carrying out intelligent transformation of an old office building. They hope to test and debug the new intelligent building management system without disturbing the existing office environment. At this time, the company can adopt the method proposed by the present invention. First, by receiving the physical model data sent by the super device physical model and parsing these data, the topological information and capability pool information of all intelligent devices in the office building are obtained. This step not only realizes a comprehensive understanding of the internal structure and equipment functions of the office building, but also provides the necessary data basis for the subsequent simulation work. For example, engineers can understand the specific layout and functional characteristics of the air conditioning system, lighting system and security monitoring system on each floor. Next, based on the obtained topological information and capability pool information, a highly simulated simulation operation environment is generated. In this environment, efficient testing and debugging work can be carried out without relying on real physical equipment. For example, the temperature setting values ​​of different floors can be adjusted in the simulation environment, the response speed of the intelligent lighting system can be checked, or the alarm mechanism of the security monitoring system can be tested. This process significantly improves the development efficiency and reduces the inconvenience and delay caused by factors such as the unavailability of actual equipment, site restrictions and potential safety risks. In addition, this method also reduces the operational complexity of traditional simulation equipment to log in to trigger messages one by one, allowing engineers to configure and test system responses in various scenarios more quickly, thereby shortening the project delivery cycle and improving customer satisfaction. At the same time, since possible problems can be discovered and solved in advance in a virtual environment, the system ultimately deployed in a real environment is more stable and reliable, promoting the rapid innovation and development of IoT smart applications. In short, through the simulation operating environment construction method provided by the present invention, the company can not only optimize the implementation process of the smart building renovation project, but also ensure the efficiency and reliability of the new system, thereby improving project quality and customer satisfaction.

[0044] The method for generating a simulated operating environment based on a super device object model provided in this embodiment can be applied to smart terminals, such as Figure 1 As shown in , the specific steps include:

[0045] Step S100: receiving object model data sent by a super device object model, and parsing the object model data to obtain topology information and capability pool information of the super device.

[0046] In this embodiment, first, the super device simulator uses the MQTT data transmission protocol and interface to receive the object model data sent by the super device object model, wherein the super device object model is sent to the super device simulator by the super device management cloud platform, such as Figure 2As shown in the figure, when the super device simulator is started and successfully connected to the super device management cloud platform, the super device management cloud platform actively sends the latest super device object model to ensure configuration synchronization. Subsequently, during operation, the super device simulator can actively pull any latest super device object model from the super device management cloud platform as needed to maintain the timeliness and accuracy of the super device object model. The MQTT protocol is known for its lightweight, low bandwidth consumption, and support for high-latency or unreliable networks. This ensures that even under poor network conditions, object model data can be received in a timely and stable manner, thus providing a solid foundation for subsequent data processing. Then, as Figure 2 As shown, it includes object model data parsing and processing, parsing the object model data. This process not only extracts the original topology information and capability pool information, but also prepares for the next data processing stage by understanding the structure and meaning of this information. The parsed data is easier to understand and operate. In addition, according to the characteristics and application requirements of the super device object model data, data conversion, filtering and integration operations can be further performed to finally obtain the topology information and capability pool information of the super device. This processing method allows only data directly related to the target application to be retained, redundant information to be removed, and the data format to be unified to meet the needs of different application scenarios. This not only improves the quality of the data, but also enhances flexibility and adaptability. Among them, the topology information includes the connection relationship between each device in the super device, the communication mechanism and the capability coding of each device, and the capability pool information includes the attributes, methods and events of each capability.

[0047] In addition, if Figure 3As shown, in order to ensure the accuracy and synchronization of the data, the super device management cloud platform will explicitly send the physical model data, including the capability pool information and the topology information, to the super device simulator. First, the super device management cloud platform sends the capability pool information to the super device simulator. After receiving the specific capability pool information, the super device simulator updates its internal capability pool data and replies a confirmation message to the super device management cloud platform to ensure synchronization between the two. Once the super device management cloud platform receives the confirmation callback of the completion of the capability pool reception, it will trigger the issuance of detailed topology information. At this point, the super device management cloud platform uses the MQTT protocol again to send the specific topology information of the super device to the super device simulator. After receiving this information, the super device simulator updates its internal topology information data and replies a confirmation message to the management platform again, indicating that the detailed topology information has been successfully received and processed. Therefore, this embodiment adopts a hybrid method of "super device simulator parsing as the main method, combined with super device management cloud platform issuance", which can give full play to the advantages of both, ensuring that both a high degree of authenticity and deep parsing are maintained in a multi-device simulation environment, and achieving data consistency and synchronization accuracy. Through the super device simulator's in-depth analysis of the physical model data, topology information and capability pool information can be extracted and processed, providing a high-quality, easy-to-operate data foundation for application development; and the super device management cloud platform's distribution mechanism ensures the timely update and consistency verification of key configuration information (such as capability pools and detailed topology structures).

[0048] Finally, the topology information and capability pool information of the super device are saved in the MySQL database table to obtain the information required for the operation of a super device. Since the entire process is to simulate the device data of all device nodes under it through a super device, the effect of multi-device connection debugging can be achieved through only one MQTT connection. This centralized management method greatly simplifies the complexity of debugging and maintenance, reduces costs, and also improves efficiency because there is no need to establish an independent connection for each individual device. In summary, this embodiment provides an efficient and reliable method to simulate the operating status of a device, which greatly facilitates development and testing.

[0049] Step S200: Generate a simulated device operating environment based on the topology information and the capability pool information.

[0050] In this embodiment, a simulated device operating environment is generated based on the topology information and the capability pool information. Figure 2As shown, it includes the generation of a simulated operating environment and also includes a front-end user display interface. Users can operate and set through the front-end user display interface, view the status information and debugging results of the simulated environment, and the front-end user display interface synchronizes the device status in real time through WebSocket technology, so that users can view the operating environment and status updates of the simulated device, providing a dynamic and interactive user experience. This process not only involves the accurate simulation of the super device and all the node devices under it, but also includes the accurate mapping of the complex connection relationship, communication mechanism and capability encoding of each device. By utilizing the detailed data stored in the MySQL database, a highly realistic virtual environment is constructed, which faithfully reproduces the architecture and functional characteristics of the actual super device. The advantage of this step is that it provides developers and test engineers with a platform for experimentation and verification without relying on physical devices. This greatly improves development efficiency because the simulated environment can be quickly created or modified at any point in time without waiting for the hardware to be ready or dealing with complex wiring issues. This approach also enhances security and controllability. Testing in a simulated environment can avoid potential risks to the real environment, such as service interruptions that may be caused by network attacks or configuration errors. Since the effect of multi-device connection debugging can be simulated through only one MQTT connection, the demand for a large number of physical devices is reduced, thereby reducing the cost of purchasing, maintaining and updating these devices. In summary, generating a simulated device operating environment based on topology information and capability pool information provides great convenience and support for development, testing and maintenance, significantly improves work efficiency and project success rate, and also achieves effective cost control and security assurance.

[0051] Specifically, the step S200 includes the following steps:

[0052] Step S201: Create a device tree structure based on the topology information;

[0053] Step S202: Based on the capability pool information, corresponding capability attributes, methods and events are assigned to each device node in the device tree structure to obtain a device instance;

[0054] Step S203: Generate a simulated device operating environment based on the device tree structure and the device instance.

[0055] In one implementation, first, based on the topology information, a device tree structure is created. This process involves accurately mapping the complex connection relationship and communication mechanism between the super device and all the node devices under it, and constructing a virtual representation that reflects the actual physical architecture. In this way, the hierarchical structure and interdependence within the super device can be accurately reproduced, laying a solid foundation for subsequent simulation work. Then, based on the capability pool information, the corresponding capability attributes, methods and events are assigned to each device node in the device tree structure to obtain a device instance. This step ensures that each virtual device not only has the correct physical connection location, but also has its due functional characteristics. By combining the capability pool information with the device tree structure, the behavior mode of each device can be defined in detail, including the operations (methods) it can perform, the characteristics (attributes) it has, and the dynamic changes (events) it may trigger. Such processing makes the device behavior in the simulation environment as close to the real situation as possible, enhancing the authenticity and reliability of the simulation. Then, based on the device tree structure and the device instance, a simulated device operating environment is generated, which faithfully reproduces the physical and functional characteristics of the super device, allowing developers and test engineers to conduct various experiments and verification activities. Since all operations are performed in a controlled virtual environment, the impact on the real physical environment is avoided, reducing potential risks, providing great convenience for development, testing and maintenance, and significantly improving work efficiency and the overall success rate of the project.

[0056] In one implementation, the method further includes: first, based on chaos theory, generating automatic operation simulation data of the device and / or business scenario simulation data to obtain simulation operation data, such as Figure 2As shown, including simulation operation data generation. Then, based on the simulated device operation environment and the simulated operation data, the operation state of the real device is simulated. Because the device operation and business process in the actual scene show some complexity and uncertainty, for example: power consumption, light switch state, environmental parameters and equipment failure phenomena do not exist in isolation, but are affected by various unpredictable factors such as voltage fluctuations, equipment aging, user behavior patterns, seasonal demand changes, atmospheric pressure, topography, local thermal convection, etc. These phenomena show a certain degree of chaotic characteristics. Small changes in initial conditions may cause huge differences in system states, making it difficult for traditional linear models to accurately describe or predict their behavior. Therefore, the present invention introduces chaos theory to generate more realistic and reliable automatic operation simulation data and business scenario simulation data. By adopting a method based on chaos theory, the essential characteristics of these nonlinear dynamic systems can be captured, and the simulated data can not only reflect the complex interactions within the system, but also reflect the influence of external random factors, thereby providing more realistic analysis tools and decision support for equipment maintenance, energy management, environmental monitoring and other fields. This method helps to improve simulation accuracy, enhance understanding of complex systems, and promote development and innovation in related fields.

[0057] In one implementation, the step of generating automatic operation simulation data of the device based on chaos theory includes:

[0058] First, based on the properties of the device, the data type of the device is obtained. This step is crucial because it provides the basis for the subsequent selection of an appropriate chaotic model. The properties of a device refer to the specific characteristics or parameters exhibited by the device during its operation. They describe the function, behavior, and output of the device. The properties of the device include but are not limited to functional characteristics (such as the switch function of the lighting control system, the measurement range of the temperature sensor), physical connections (such as the type of communication interface, the position in the network topology), output signals (such as voltage level, current intensity, digital signal form), working modes (such as timer control, manual control, automatic sensing), and environmental dependence (such as sensitivity to surrounding environmental factors). By fully understanding these properties, the behavior pattern of the device and the data characteristics it generates can be more accurately judged. For example, for an intelligent lighting control system, by checking its working mode and output signal, it can be clearly seen that it is a switch-type device, because its main function is to switch between "on" and "off", so it can be classified as switch-type data, and the intelligent lighting control system can also adjust the brightness of the light, so the intelligent lighting control system can also be regarded as continuous data. Therefore, when the intelligent lighting control system is only used to control the on and off of the light, it belongs to switch-type data. When the intelligent lighting control system adjusts the brightness, it involves continuously changing values, which belongs to continuous data; for a smart home meter, it can be classified as cumulative data, because it records the electricity consumption that continues to grow over time; those devices that are greatly affected by environmental factors, such as wind vanes, thermometers, hygrometers, etc., which change according to factors such as weather conditions and indoor personnel activities, can be classified as environmental perception data; the fault alarm signal or other status indication of the equipment, which usually manifests itself in two states of normal / fault, can be classified as state feedback data. This classification helps to select the most appropriate chaos model for simulation in the future, ensuring that the simulation results are as close to the real situation as possible.

[0059] Next, based on chaos theory and the data type, the corresponding chaos model is selected. This process involves an in-depth understanding of different chaotic maps or systems and an evaluation of their applicability. First, the characteristics of the data type must be understood. Each data type has its own unique dynamic characteristics, which determine which chaos models are best suited to simulate them. For example, switch data is usually expressed as a binary state (such as on / off), cumulative data gradually increases or decreases over time, environmental perception data fluctuates with changes in external conditions, and state feedback data reflects changes in the internal or external state of the device.Next, after understanding the characteristics of the data type, based on chaos theory and the data type, select the corresponding chaos model. For example, for switch data, such as the switch or door lock controller of the intelligent lighting control system, you can choose the Logistic mapping (logistic mapping) chaos model. Logistic mapping is a simple nonlinear iterative formula that can generate a sequence with similar random characteristics. It is very suitable for simulating the transition between switch states. By setting a threshold and comparing the result of each iteration with the threshold, you can decide whether the state of the device is "on" or "off". This model can capture a wide range of state changes caused by small differences in initial conditions, reflecting the uncertainty in the real world; for continuous data, such as the light brightness adjustment of the intelligent lighting control system, you can also choose the Logistic mapping (logistic mapping) chaos model, and use Logistic mapping to generate a brightness change sequence. Logistic mapping is a simple mathematical model used to describe the The growth process of a population under limited resource conditions, but it is also suitable for simulating the changes of continuous data with saturation characteristics. By setting appropriate parameters, the Logistic map can generate a series of smooth transition values ​​from the initial brightness to the target brightness, ensuring that the change in light brightness is both natural and efficient. At the same time, it can also be dynamically adjusted according to factors such as ambient light intensity to provide a more humane lighting experience; for cumulative data, such as meter readings or water meter records, the chaotic autoregressive model (CAR) is a more appropriate choice. The CAR model combines chaos theory with traditional time series analysis methods to better capture the nonlinear and dynamic characteristics of the data. By analyzing the chaotic characteristics of historical electricity or water consumption data, the model parameters are determined, and then the model is used to generate future trend forecasts. This method not only takes into account past behavior patterns, but also predicts future changes. It is particularly suitable for data affected by multiple complex factors; for environmental perception data, such as temperature sensors, hygrometers, or wind vanes, the Lorenz system (Lorenz The three variables of the Lorentz system can describe complex fluid motion, similar to the air flow in the atmosphere. By analyzing meteorological data and sensor measurement data, the parameters in the Lorentz equation are adjusted to make the simulation results as close to the actual situation as possible. The new state value obtained after each iteration represents the predicted value at the next time point. At the same time, a moderate amount of noise can be introduced into the generated data to simulate measurement errors and other unforeseen factors. For state feedback data, such as equipment fault alarm signals or other status indications, other chaotic models such as Henon mapping may be a better choice. Henon mapping is also a nonlinear iterative formula, but its two-dimensional characteristics make it more suitable for capturing state changes caused by the interaction of multiple factors. This type of model can help simulate changes in equipment health, including the transition between normal operating states and possible fault states.

[0060] Then, based on the chaotic model, the automatic operation simulation data of the equipment is generated. This stage is the core of the whole process. It uses the mathematical formula of the selected chaotic model for iterative calculation to generate a series of numerical values ​​that meet the expected characteristics. First, initialize the model parameters. According to the actual working conditions and historical data of the equipment, adjust the key parameters in the chaotic model. For example, for the simulation of the wind vane using the Lorenz system, it is necessary to adjust the parameters in the equation according to the local meteorological data. Initialization also includes setting the initial conditions for the iterative calculation, which is usually based on the current time point or the most recent real measurement value. Then, iterative calculation is performed. Once the model parameters and initial conditions are set, iterative calculation can be started. Each iteration will generate a new state value, representing the predicted data at the next time point. For example, when using the Lorenz system to simulate wind direction changes, by substituting the current wind direction as the initial condition, the new state value obtained after iterative calculation represents the predicted wind direction at a certain moment in the future. In addition, in order to make the simulated data closer to the actual situation, an appropriate amount of noise can be added to the generated data to simulate measurement errors and other unforeseen factors. For example, for environmental perception data, such as temperature sensors or hygrometers, small measurement errors or local thermal convection may cause numerical fluctuations. By introducing noise, the realism of the simulation can be increased.

[0061] In summary, by automatically running simulation data of generated equipment based on chaos theory, we can not only create a highly realistic virtual environment, but also effectively deal with various uncertainties and complexities in the actual environment. The advantage of this method is that it can capture the nonlinear dynamic characteristics that are difficult to reflect with traditional statistical methods, and provide a more accurate and rich simulation experience.

[0062] In one implementation, generating business scenario simulation data of a device based on chaos theory includes:

[0063] First, based on the business scenario of the device, the predefined rules of the business scenario are obtained. The business scenario refers to a collection of interrelated tasks or activities under specific conditions. It describes how users interact with devices and how devices work together to achieve certain goals. For example, in an office environment, when an employee enters the room, the lights are automatically turned on and the brightness of the lights is adjusted. This is a specific business scenario. The predefined rules are a set of operation guidelines or logical conditions pre-set for the above business scenarios, which are used to guide what actions should be taken when encountering specific situations. The predefined rules contain two main parts: trigger conditions and execution actions: Trigger conditions: This is a prerequisite for starting the rule, such as a human body sensor detecting that someone enters the room. Execution action: Once the trigger condition is met, the action to be executed, such as turning on the light and adjusting the brightness of the light. The business scenario of the device and its corresponding predefined rules are pre-set. Users can select the corresponding business scenario according to actual needs. Once a business scenario is selected, the corresponding predefined rules will be automatically obtained based on the scenario. The predefined rules guide the system on how to respond to specific conditions or events based on specific business needs and expected behaviors. In order to efficiently manage and execute these complex predefined rules, professional rule engine software (such as Drools, OpenRules, etc.) can be used. By loading predefined business rules into the rule engine, not only can the business logic be abstracted into a series of independent rules, but also dynamic addition, modification and deletion of rules can be supported, which significantly improves the flexibility and maintainability of the system. In addition, the rule engine not only manages static rules, but also handles the contextual information and state management required by the business scenario, including global variables, event triggers, and the state of the current environment (such as time, weather conditions, etc.) to ensure that the rules can respond appropriately according to the real-time situation. The powerful reasoning ability and efficient query mechanism provided by the rule engine enable the system to respond quickly to environmental changes and make appropriate decisions. Developers can easily define complex conditional logic through the rule engine and ensure that the execution of rules meets business requirements. Although the business scenario itself is not directly loaded into the rule engine as an entity, it is reflected through a set of related business rules. Each business scenario corresponds to a set of rule sets. These rules are activated and managed in the rule engine to jointly achieve the goals of the business scenario. This approach not only ensures that the system can meet the initial requirements, but also has sufficient flexibility to adapt to possible changes in the future. Therefore, through the application of the rule engine, the intelligent system can flexibly respond to the needs of various business scenarios while maintaining a high degree of automation.

[0064] After obtaining the predefined rules of the business scenario based on the business scenario of the device, it is possible to determine which devices need to be run based on the predefined rules, that is, based on the predefined rules, obtain the devices to be started and executed, and obtain the target device. After knowing the device to be run, that is, the target device, the data type of the target device is obtained based on the properties of the target device. Then, based on chaos theory and the data type, a corresponding chaos model is selected. The method of obtaining the data type of the target device based on the properties of the target device and selecting the corresponding chaos model based on chaos theory and the data type is the same as the method of "obtaining the data type of the device based on the properties of the device; selecting the corresponding chaos model based on chaos theory and the data type", which has been discussed above and will not be repeated here. Finally, based on the chaos model, the business scenario simulation data of the device is generated. Specifically, first, based on the predefined rules, the device that needs to be started is determined, and then the business scenario simulation data of the device is generated based on the chaos model corresponding to the device, so as to adjust the operation of the device. For example, the user selects a business scenario as: in an office environment, when an employee enters the room, the light is automatically turned on and the light brightness is adjusted. According to this business scenario, the predefined rule of the business scenario is: when the human body sensor detects that someone enters the room, the light is turned on and the light brightness is adjusted. Then, according to the predefined rule, it can be determined that the device that needs to be started is the intelligent light control system. Then, based on the properties of the intelligent light control system, the data types of the intelligent light control system are switch data and continuous data. In order to simulate more realistic and dynamic environmental changes, a chaotic model (Logistic mapping chaotic model) corresponding to the data type (switch data and continuous data) of the intelligent light control system is further introduced to generate the business scenario simulation data of the device. Logistic mapping is a simple nonlinear iterative formula that can generate a sequence with similar random characteristics. It is very suitable for simulating the transition between switch states. By setting a threshold and comparing the result of each iteration with the threshold, it can be determined whether the state of the device is "on" or "off". In this method, the human body sensor can also trigger the switch operation of the light. In addition, through the Logistic mapping chaos model, a data sequence that seems random but actually follows a specific pattern can be generated for adjusting the light brightness. When using the Logistic mapping light brightness change, the current brightness value is used as the initial condition and substituted into the Logistic mapping for iterative calculation. The result of each iteration can be used as the brightness prediction value for the next time point, and the generated data can be appropriately scaled and offset according to the actual situation to make it conform to the measurement range of the brightness sensor.The series of values ​​generated by the logistic map represent small adjustments to different levels of light brightness. Within a few minutes after a person enters the room, the light is gradually adjusted based on the data generated by the chaotic model, simulating natural and orderly but unpredictable changes, making each experience slightly different and closer to the uncertainty in real life.

[0065] In one implementation, after obtaining the simulation operation data, that is, obtaining the automatic operation simulation data and / or the business scenario simulation data, the following includes: reporting the simulation operation data to the super device management cloud platform according to a preset interval, and sending the latest simulation data to the super device management cloud platform regularly (for example, every 5 seconds), so as to continuously reflect the latest status and behavior pattern of the device, which helps to capture and respond to any anomalies or changes in a timely manner. In addition, the regular reporting mechanism ensures the timeliness and integrity of the data, making the simulation results closer to the dynamic changes in the real world, thereby enhancing the practicality and accuracy of the simulation system.

[0066] In one implementation, based on the simulated device operating environment and the simulated operating data, the operating state of the real device can be simulated. Specifically, after receiving the simulated operating data, the super device management cloud platform can send function calls and attribute write instructions to the super device simulator according to the simulated operating data to simulate the behavior and response of the real device. For function calls, the front-end page of the super device simulator provides an interface for setting function call responses, allowing users to configure specific function response logic. When receiving a function call request (such as "turn on the light" or "turn off the air conditioner") issued by the super device management cloud platform, the super device simulator will first verify whether the request meets the predefined business rules and security conditions. Then, if the request meets the predefined business rules and security conditions, the super device simulator performs the corresponding operation, updates the record in the MySQL database to reflect the latest device status, and replies a function call confirmation message to the super device management cloud platform through the MQTT protocol, indicating that the operation has been completed and its results. This mechanism not only enhances the interactivity and practicality of the simulation environment, but also enables the super device simulator to respond to external commands in real time and keep in sync with the super device management cloud platform system. For property writing, when the super device simulator receives a property write message sent by the super device management cloud platform, the super device simulator will modify the relevant data in the internal MySQL table according to the content of the message, such as updating the brightness value of the light bulb, the reading of the temperature sensor, etc. After the update is completed, the super device simulator sends a property write reply message to the super device management cloud platform through the MQTT protocol to confirm the status of the property update and provide any necessary feedback information, such as the reason for the success or failure of the operation. This process ensures that the device status is consistent with the actual device, allowing users to accurately observe the various property changes of the device in a virtual environment. After simulating the operating status of the real device based on the simulated device operating environment and the simulated operating data, this embodiment can display the interface through the front-end user so that users can accurately observe and test the various behaviors and property changes of the device in a virtual environment. Users can operate and set through the front-end user display interface, and view the status information and debugging results of the simulated environment, such as Figure 2 As shown, the front-end user display interface uses WebSocket technology to achieve real-time synchronization, ensuring that the update of the device status can be reflected to the user immediately, providing a dynamic and interactive testing and observation environment. In summary, this embodiment can effectively support the development, testing and optimization of the Internet of Things system by simulating the operating status and response of real devices, which not only improves the development efficiency, but also reduces the risk before actual deployment, and provides a solid foundation for the successful implementation of the Internet of Things system.

[0067] In summary, this embodiment first receives the physical model data sent by the super device physical model, and parses the physical model data to obtain the topological information and capability pool information of the super device, thereby achieving a comprehensive understanding of the device structure and function, and providing the necessary data basis for subsequent steps. Then, based on the topological information and the capability pool information, a simulated device operating environment is generated, so that developers can perform efficient testing and debugging without relying on real physical devices. The method proposed in the present invention not only improves development efficiency by constructing a highly simulated simulation operating environment, but also reduces the inconvenience and delay caused by factors such as device availability, site restrictions and security risks. At the same time, the method proposed in the present invention reduces the operational complexity of traditional simulation devices logging in to trigger messages one by one, thereby shortening the project delivery cycle, improving customer satisfaction, and promoting the rapid innovation and development of IoT smart applications.

[0068] like Figure 4 As shown in, this embodiment also provides a simulation operation environment generation system based on a super device physical model, the system comprising: an information acquisition module 10 and a simulation device operation environment generation module 20. Specifically, the information acquisition module 10 is used to receive physical model data sent by the super device physical model, and parse the physical model data to obtain the topology information and capability pool information of the super device. The simulation device operation environment generation module 20 is used to generate a simulated device operation environment based on the topology information and the capability pool information.

[0069] In one implementation, the topology information includes the connection relationship between each device in the super device, the communication mechanism and the capability code of each device, and the capability pool information includes the attributes, methods and events of each capability.

[0070] In one implementation, the simulated device operating environment generation module 20 includes:

[0071] A device tree structure creation unit, used to create a device tree structure based on the topology information;

[0072] A device instance acquisition unit, configured to assign corresponding capability attributes, methods and events to each device node in the device tree structure based on the capability pool information to obtain a device instance;

[0073] The simulated device operating environment generating unit is used to generate a simulated device operating environment based on the device tree structure and the device instance.

[0074] In one implementation, the system further includes a simulation operation data acquisition module and a device operation status simulation module. Specifically, the simulation operation data acquisition module is used to generate automatic operation simulation data and / or business scenario simulation data of the device based on chaos theory to obtain simulated operation data. The standby operation status simulation module is used to simulate the operation status of the real device based on the simulated device operation environment and the simulated operation data.

[0075] In one implementation, the simulation operation data acquisition module includes:

[0076] An automatic operation simulation data acquisition unit, used for generating automatic operation simulation data of the equipment based on chaos theory;

[0077] The business scenario simulation data acquisition unit is used to generate business scenario simulation data of the device based on chaos theory.

[0078] In one implementation, the automatic operation simulation data acquisition unit includes:

[0079] A data type acquisition first subunit is used to obtain the data type of the device based on the attributes of the device;

[0080] A chaos model acquisition first subunit is used to select a corresponding chaos model based on chaos theory and the data type;

[0081] The automatic operation simulation data acquisition subunit is used to generate automatic operation simulation data of the device based on the chaos model.

[0082] In one implementation, the business scenario simulation data acquisition unit includes:

[0083] A predefined rule acquisition subunit, used to acquire predefined rules of a business scenario based on a business scenario of a device;

[0084] A target device acquisition subunit is used to acquire a device to be started and executed based on the predefined rule to obtain a target device;

[0085] A data type acquisition second subunit is used to obtain the data type of the target device based on the attribute of the target device;

[0086] A chaos model acquisition second subunit is used to select a corresponding chaos model based on chaos theory and the data type;

[0087] The business scenario simulation data acquisition subunit is used to generate business scenario simulation data of the device based on the chaotic model.

[0088] In one implementation, the step of obtaining the simulation operation data further includes:

[0089] The data reporting unit is used to report the simulation operation data according to a preset interval.

[0090] The working principles of each module in the screen projection display system of this embodiment are the same as the principles of each step in the above method embodiment, and will not be repeated here.

[0091] Based on the above embodiment, the present invention further provides a terminal, the principle block diagram of the terminal can be as follows: Figure 5 The terminal may include one or more processors 100 ( Figure 5 Only one is shown), a memory 101 and a computer program 102 stored in the memory 101 and executable on one or more processors 100, for example, a screen projection display program. When one or more processors 100 execute the computer program 102, the various steps in the screen projection display method embodiment can be implemented. Alternatively, when one or more processors 100 execute the computer program 102, the functions of the various modules / units in the screen projection display method embodiment can be implemented, which is not limited here.

[0092] In one embodiment, the processor 100 may be a central processing unit (CPU), or other general-purpose processors, digital signal processors (DSP), application-specific integrated circuits (ASIC), field-programmable gate arrays (FPGA) or other programmable logic devices, discrete gate or transistor logic devices, discrete hardware components, etc. A general-purpose processor may be a microprocessor or any conventional processor, etc.

[0093] In one embodiment, the memory 101 may be an internal storage unit of an electronic device, such as a hard disk or memory of the electronic device. The memory 101 may also be an external storage device of the electronic device, such as a plug-in hard disk, a smart media card (SMC), a secure digital (SD) card, a flash card, etc. equipped on the electronic device. Further, the memory 101 may also include both an internal storage unit of the electronic device and an external storage device. The memory 101 is used to store computer programs and other programs and data required by the terminal. The memory 101 may also be used to temporarily store data that has been output or is to be output.

[0094] Those skilled in the art will understand that Figure 5 The principle block diagram shown in the figure is only a block diagram of a partial structure related to the scheme of the present invention, and does not constitute a limitation on the terminal to which the scheme of the present invention is applied. The specific terminal may include more or fewer components than those shown in the figure, or combine certain components, or have a different arrangement of components.

[0095] Those of ordinary skill in the art can understand that all or part of the processes in the above-mentioned embodiment methods can be completed by instructing the relevant hardware through a computer program, and the computer program can be stored in a non-volatile computer-readable storage medium. When the computer program is executed, it can include the processes of the embodiments of the above-mentioned methods. Among them, any reference to memory, storage, operating database or other media used in the embodiments provided by the present invention may include non-volatile and / or volatile memory. Non-volatile memory may include read-only memory (ROM), programmable ROM (PROM), electrically programmable ROM (EPROM), electrically erasable programmable ROM (EEPROM) or flash memory. Volatile memory may include random access memory (RAM) or external cache memory. By way of illustration and not limitation, RAM is available in many forms, such as static RAM (SRAM), dynamic RAM (DRAM), synchronous DRAM (SDRAM), double operational data rate SDRAM (DDRSDRAM), enhanced SDRAM (ESDRAM), synchronous link (Synchlink) DRAM (SLDRAM), memory bus (Rambus) direct RAM (RDRAM), direct memory bus dynamic RAM (DRDRAM), and memory bus dynamic RAM (RDRAM), etc.

[0096] Finally, it should be noted that the above embodiments are only used to illustrate the technical solutions of the present invention, rather than to limit it. Although the present invention has been described in detail with reference to the aforementioned embodiments, those skilled in the art should understand that they can still modify the technical solutions described in the aforementioned embodiments, or make equivalent replacements for some of the technical features therein. However, these modifications or replacements do not deviate the essence of the corresponding technical solutions from the spirit and scope of the technical solutions of the embodiments of the present invention.

Claims

1. A method for generating a simulation operating environment based on a super device object model, characterized in that: The method comprises: Receiving the object model data sent by the super device object model, and parsing the object model data to obtain the topology information and capability pool information of the super device; A simulated device operating environment is generated based on the topology information and the capability pool information.

2. The method for generating a simulation operation environment based on a super device object model according to claim 1, characterized in that: The topology information includes the connection relationship between each device in the super device, the communication mechanism and the capability code of each device, and the capability pool information includes the attributes, methods and events of each capability.

3. The method for generating a simulation operation environment based on a super device object model according to claim 2, characterized in that: The generating a simulated device operating environment based on the topology information and the capability pool information includes: Based on the topology information, create a device tree structure; Based on the capability pool information, assign corresponding capability attributes, methods and events to each device node in the device tree structure to obtain a device instance; A simulated device operating environment is generated based on the device tree structure and the device instance.

4. The method for generating a simulation operation environment based on a super device object model according to claim 3, characterized in that: The method further comprises: Based on chaos theory, automatic operation simulation data of the equipment and / or business scenario simulation data are generated to obtain simulation operation data; Based on the simulated device operating environment and the simulated operating data, the operating state of the real device is simulated.

5. The method for generating a simulation operation environment based on a super device object model according to claim 4, characterized in that: The automatic operation simulation data of the equipment is generated based on chaos theory, including: Based on the attributes of the device, get the data type of the device; Based on chaos theory and the data type, select a corresponding chaos model; Based on the chaos model, automatic operation simulation data of the equipment is generated.

6. The method for generating a simulation operation environment based on a super device object model according to claim 4, characterized in that: The business scenario simulation data of the device is generated based on chaos theory, including: Based on the business scenario of the device, obtain predefined rules of the business scenario; Based on the predefined rules, a device to be started is obtained to obtain a target device; Based on the attribute of the target device, obtain the data type of the target device; Based on chaos theory and the data type, select a corresponding chaos model; Based on the chaos model, business scenario simulation data of the device is generated.

7. The method for generating a simulated operating environment based on a super device object model according to claim 5 or 6, characterized in that: The obtaining of simulation operation data then includes: The simulation operation data is reported according to the preset interval.

8. A simulation operation environment generation system based on a super device object model, characterized in that: The system comprises: An information acquisition module is used to receive the physical model data sent by the super device physical model, and parse the physical model data to obtain the topology information and capability pool information of the super device; The simulated device operating environment generation module is used to generate a simulated device operating environment based on the topology information and the capability pool information.

9. A terminal, characterized in that: The terminal includes a memory, a processor, and a simulation operating environment generation program based on a super device object model stored in the memory and executable on the processor. When the processor executes the simulation operating environment generation program based on the super device object model, the steps of the simulated device operating environment generation method as described in any one of claims 1 to 7 are implemented.

10. A computer-readable storage medium, characterized in that: The computer-readable storage medium stores a simulation operating environment generation program based on a super device object model. When the simulation operating environment generation program based on a super device object model is executed by a processor, the steps of the simulation operating environment generation method based on a super device object model as described in any one of claims 1 to 7 are implemented.

Citation Information

Cited By

  • Method, system, equipment and medium for constructing standard system of internet of things of swan Mongolia

    CN121486411A

  • A method, system, device and medium for constructing a standard system of the horizen internet of things

    CN121486411B