Debugging method and device, control terminal and storage medium

By establishing communication between the controller of the building control system and the logical canvas, and automatically obtaining and synchronizing configuration parameters, the existing debugging process is solved and the problem of cumbersome and error-prone is easily solved, and an efficient and accurate debugging process is achieved.

CN119937505APending Publication Date: 2025-05-06GREE ELECTRIC APPLIANCE INC OF ZHUHAI
View PDF 0 Cites 0 Cited by

Patent Information

Application Number
CN202411925873.3
Authority / Receiving Office
CN · China
Patent Type
Applications(China)
Current Assignee / Owner
Filing Date
2024-12-25
Publication Date
2025-05-06

AI Technical Summary

Technical Problem

The debugging process of existing building control systems is cumbersome and error-prone, and requires manual acquisition and verification of parameters of the controller and display end, making it difficult to efficiently debug the controller's control logic in the future.

Method used

By establishing communication between the controller and the logical canvas, listening for configuration parameter updates of instantiated objects and logical components, obtaining and storing configuration parameters, and syncing to the logical canvas to complete the debugging process.

Benefits of technology

The automated debugging process is realized, the steps of manual operation are reduced, the efficiency and accuracy of debugging are improved, and the subsequent efficient debugging of the controller's control logic is facilitated.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN119937505A_ABST
    Figure CN119937505A_ABST
Patent Text Reader

Abstract

The invention relates to a debugging method and device, a control terminal and a storage medium, the method is applied to a controller, a logic canvas comprises an instantiated object and a logic component, the instantiated object corresponds to equipment parameters of access equipment of the controller, and the logic component corresponds to control logic of the controller. Comprising the following steps: acquiring respective configuration parameters of an instantiated object and a logic component under the condition of monitoring that the configuration parameters of the instantiated object and / or the logic component are updated; the configuration parameters are stored locally, and current configuration parameters of the instantiation object and the logic component stored locally are obtained; and synchronizing the current configuration parameter to the logic canvas, so that the logic canvas compares the consistency of the configuration parameter and the current configuration parameter, and the debugging process is completed. Therefore, the controller and the logic canvas are synchronously intercommunicated, the debugging process of the building control system can be automatically completed, manual acquisition for verification is not needed, and the control logic of the controller can be subsequently and efficiently debugged.
Need to check novelty before this filing date? Find Prior Art

Description

Technical Field

[0001] The present application relates to the field of building automation technology, and in particular to a debugging method, device, control terminal and storage medium. Background Art

[0002] In today's rapidly developing field of building automation, engineers are facing increasing technical challenges. With the expansion of the scale of building control systems and the diversification of control requirements, the control logic requirements of controllers are constantly increasing, making the debugging of on-site engineering particularly cumbersome and complex.

[0003] Generally, in order to meet the real-time monitoring of field data, engineers need to configure the parameters of the access device (such as the temperature collected by the temperature sensor) in the controller. In addition, the parameters of the host computer display terminal need to be associated with the parameters configured in the controller to complete the process of collecting the access device parameters and displaying the parameters on the display terminal.

[0004] In view of this, the current debugging process of the entire building control system requires manually obtaining the parameters of the access device configured in the controller, and then manually obtaining the parameters of the access device displayed on the display end, and verifying the two. This process is not only cumbersome and error-prone, but also difficult to efficiently debug the control logic of the controller afterwards. Summary of the invention

[0005] In order to solve the above-mentioned current debugging process of the entire building control system, it is necessary to manually obtain the points of the access devices configured in the controller, and then manually obtain the points of the access devices displayed on the display end, and verify the two. This process is not only cumbersome and error-prone, but also difficult to efficiently debug the control logic of the controller. The present application provides a debugging method, device, control terminal and storage medium. The specific technical solution is as follows:

[0006] In a first aspect, the present application provides a debugging method, which is applied to a controller, wherein the controller establishes communication with a logic canvas, wherein the logic canvas includes an instantiated object and a logic component, wherein the instantiated object and the logic component are connected, wherein the instantiated object corresponds to a device parameter of an access device of the controller, and the logic component corresponds to a control logic of the controller, wherein the method includes:

[0007] In case of monitoring the configuration parameter update of the instantiated object and / or the logical component, obtaining the configuration parameters of the instantiated object and the logical component respectively;

[0008] The configuration parameters are stored locally, and the current configuration parameters of the instantiated object and the logic component stored locally are obtained;

[0009] The current configuration parameters are synchronized to the logic canvas, so that the logic canvas compares the consistency between the configuration parameters and the current configuration parameters, thereby completing the debugging process.

[0010] In an optional implementation, storing the configuration parameters locally includes:

[0011] Generate a logic canvas verification code according to the configuration parameters, and obtain a historical logic canvas verification code stored locally;

[0012] Comparing the logic canvas verification code with the historical logic canvas verification code;

[0013] When the logic canvas verification code is inconsistent with the historical logic canvas verification code, the configuration parameters are stored locally.

[0014] In an optional implementation, storing the configuration parameters locally includes:

[0015] Searching for updated configuration parameters from the configuration parameters, and storing the updated configuration parameters locally;

[0016] The obtaining the current configuration parameters of the instantiated object and the logic component stored locally includes:

[0017] Obtaining the current configuration parameters of the instantiated object and the logic component respectively stored locally, and searching the currently updated configuration parameters from the current configuration parameters;

[0018] The synchronizing the current configuration parameters to the logic canvas so that the logic canvas compares the consistency between the configuration parameters and the current configuration parameters includes:

[0019] The currently updated configuration parameters are synchronized to the logic canvas, so that the logic canvas compares the consistency between the updated configuration parameters and the currently updated configuration parameters.

[0020] In an optional implementation, searching for updated configuration parameters from the configuration parameters includes:

[0021] Obtain locally stored historical configuration parameters of the instantiated object and the logic component;

[0022] The configuration parameters are compared with the historical configuration parameters to obtain updated configuration parameters among the configuration parameters.

[0023] In an optional implementation, the controller is connected to a plurality of access devices, and in the controller, for each of the access devices, a corresponding device online status point is set to represent the offline status of the access device, and the method further includes:

[0024] For any of the access devices, sending a parameter request frame to the access device according to any device parameter of the access device;

[0025] within a preset time period, detecting whether a value of a device parameter sent by the access device in response to the parameter request frame is received;

[0026] If the value of the device parameter sent by the access device in response to the parameter request frame is not received, the point of the device online status corresponding to the access device is set.

[0027] In an optional embodiment, the method further comprises:

[0028] For any of the access devices, monitoring whether the point of the device online status corresponding to the access device is set;

[0029] If the point position of the device online status corresponding to the access device is monitored, determine the communication protocol with the access device;

[0030] Generate a device instance according to any device parameter of the access device and the communication protocol, wherein the device instance includes any device parameter of the access device;

[0031] Associating any device parameter of the access device contained in the device instance with a corresponding instantiated object in the logic canvas;

[0032] The association is used to achieve synchronization between a value of any device parameter of the access device contained in the device instance and a value of a corresponding instantiated object in the logic canvas.

[0033] In an optional embodiment, the method further comprises:

[0034] For any of the access devices, detecting whether the heartbeat information sent by the access device is received within a preset time period;

[0035] If the heartbeat information sent by the access device is not received, the point of the device online status corresponding to the access device is set.

[0036] In a second aspect, the present application provides a debugging device, which is applied to a controller, wherein the controller establishes communication with a logic canvas, wherein the logic canvas includes an instantiated object and a logic component, wherein the instantiated object is connected to the logic component, wherein the instantiated object corresponds to a device parameter of an access device of the controller, and the logic component corresponds to a control logic of the controller, wherein the device includes:

[0037] A parameter acquisition module, configured to acquire the configuration parameters of the instantiated object and the logical component respectively when monitoring the configuration parameter update of the instantiated object and / or the logical component;

[0038] A parameter storage module, used to store the configuration parameters locally and obtain the current configuration parameters of the instantiated object and the logic component stored locally;

[0039] The parameter synchronization module is used to synchronize the current configuration parameters to the logic canvas, so that the logic canvas compares the consistency between the configuration parameters and the current configuration parameters to complete the debugging process.

[0040] In a third aspect, a control terminal is provided, comprising a processor, a communication interface, a memory and a communication bus, wherein the processor, the communication interface and the memory communicate with each other via the communication bus;

[0041] Memory, used to store computer programs;

[0042] The processor is used to implement any debugging method described in the first aspect when executing the program stored in the memory.

[0043] In a fourth aspect, a storage medium is further provided, wherein instructions are stored in the storage medium, and when the storage medium is run on a computer, the computer executes any one of the debugging methods described in the first aspect.

[0044] In a fifth aspect, a computer program product comprising instructions is also provided, which, when executed on a computer, enables the computer to execute any of the above-mentioned debugging methods.

[0045] The above technical solution provided by the embodiment of the present application has the following advantages over the prior art: the debugging method provided by the embodiment of the present application is applied to a controller, the controller establishes communication with a logic canvas, the logic canvas contains instantiated objects and logic components, the instantiated objects and logic components are connected, the instantiated objects correspond to the device parameters of the access device of the controller, the logic components correspond to the control logic of the controller, and when the configuration parameter updates of the instantiated objects and / or logic components are monitored, the respective configuration parameters of the instantiated objects and logic components are obtained, the configuration parameters are stored locally, and the current configuration parameters of the locally stored instantiated objects and logic components are obtained, and the current configuration parameters are synchronized to the logic canvas, so that the logic canvas compares the configuration parameters with the current configuration parameters for consistency, and the debugging process is completed.

[0046] By monitoring whether the configuration parameters of the instantiated objects and / or logical components are updated, and in case of update, obtaining the respective configuration parameters of the instantiated objects and logical components, storing the configuration parameters locally, and obtaining the current configuration parameters of the locally stored instantiated objects and logical components, the current configuration parameters are synchronized to the logic canvas, so that the logic canvas compares the configuration parameters with the current configuration parameters for consistency, and completes the debugging process. In this way, the controller and the logic canvas are synchronized and communicated with each other, and the debugging process of the building control system can be automatically completed without manual acquisition and verification, and the control logic of the controller can be efficiently debugged later. BRIEF DESCRIPTION OF THE DRAWINGS

[0047] The accompanying drawings, which are incorporated in and constitute a part of this specification, illustrate embodiments consistent with the present application and, together with the description, serve to explain the principles of the present application.

[0048] In order to more clearly illustrate the embodiments of the present application or the technical solutions in the prior art, the drawings required for use in the embodiments or the description of the prior art will be briefly introduced below. Obviously, for ordinary technicians in this field, other drawings can be obtained based on these drawings without paying any creative labor.

[0049] One or more embodiments are exemplarily described by pictures in the corresponding drawings, and these exemplified descriptions do not constitute limitations on the embodiments. Elements with the same reference numerals in the drawings represent similar elements, and unless otherwise stated, the figures in the drawings do not constitute proportional limitations.

[0050] Figure 1 A topological diagram of a traditional automatic control system provided in an embodiment of the present application;

[0051] Figure 2 A schematic diagram of a logic canvas visualization interface provided in an embodiment of the present application;

[0052] Figure 3 A schematic diagram of an implementation flow of a debugging method provided in an embodiment of the present application;

[0053] Figure 4 A schematic diagram of an implementation flow of another debugging method provided in an embodiment of the present application;

[0054] Figure 5 A schematic diagram of an implementation flow of another debugging method provided in an embodiment of the present application;

[0055] Figure 6 A schematic diagram of the association between device parameters and instantiated objects of a device instance provided in an embodiment of the present application;

[0056] Figure 7 A schematic diagram of an implementation flow of another debugging method provided in an embodiment of the present application;

[0057] Figure 8 A schematic diagram of the structure of a debugging device provided in an embodiment of the present application;

[0058] Fig. 9 A schematic diagram of the structure of a control terminal provided in an embodiment of the present application. DETAILED DESCRIPTION

[0059] In order to make the purpose, technical solution and advantages of the embodiments of the present application clearer, the technical solution in the embodiments of the present application will be clearly and completely described below in conjunction with the drawings in the embodiments of the present application. Obviously, the described embodiments are part of the embodiments of the present application, not all of the embodiments. Based on the embodiments in the present application, all other embodiments obtained by ordinary technicians in this field without making creative work are within the scope of protection of this application.

[0060] The disclosure below provides many different embodiments or examples to realize the different structures of the present application. In order to simplify the disclosure of the present application, the parts and settings of specific examples are described below. Of course, they are only examples, and the purpose is not to limit the present application. In addition, the present application can repeat reference numbers and / or letters in different examples. This repetition is for the purpose of simplification and clarity, and does not itself indicate the relationship between the various embodiments and / or settings discussed.

[0061] like Figure 1The figure shows the topology diagram of the traditional automatic control system, which is mainly composed of a management platform, a controller, and terminal devices. The management platform mainly refers to the host computer, the monitoring and control platform system, and the server, etc. Its main function is to accurately reflect the real-time data collected by the terminal devices and realize the visual configuration programming of the control logic in the controller; the controller is generally responsible for reading and writing device data and executing control logic; the terminal devices include sensors, HVAC, air supply and exhaust, water supply and drainage, etc., which are responsible for monitoring certain parameters of the external environment, such as temperature, concentration, light intensity, voltage, etc., and at the same time accept control instructions from the controller to realize the coordinated operation of multiple devices and achieve the purpose of logic design.

[0062] For the debugging process of the entire building control system, in order to avoid manually obtaining the parameters of the access device configured in the controller, and then manually obtaining the parameters of the access device displayed on the display end, and verifying the two, the embodiment of the present application realizes adaptive synchronization of data between the logic canvas and the controller, and the data changes in the controller can be intuitively observed from the logic canvas interface, so as to facilitate the real-time monitoring and debugging of the data by the on-site debugging personnel. Among them, the so-called logic canvas is a concrete expression of the control logic in a controller, which is mainly composed of logic components and instantiated objects, and the instantiated objects are connected to the logic components. The instantiated objects correspond to the device parameters of the access device of the controller (that is, the above-mentioned terminal device), and the logic components correspond to the control logic of the controller, such as Figure 2 shown.

[0063] Based on the above invention concept, Figure 3 FIG. 1 is a schematic diagram of an implementation flow of a debugging method provided in an embodiment of the present application. The method is applied to a controller and may specifically include the following steps:

[0064] S301 , when monitoring the configuration parameter update of the instantiated object and / or the logical component, obtain the configuration parameters of the instantiated object and the logical component respectively.

[0065] In an embodiment of the present application, for the logic canvas, whether the configuration parameters of the instantiated objects and / or logic components in the logic canvas are updated is monitored. When the configuration parameters of the instantiated objects and / or logic components in the logic canvas are updated, the configuration parameters of the instantiated objects and logic components are obtained.

[0066] For example, Figure 2 As shown, for the logic components 1 to 3 and instantiated objects 1 to 6 in the logic canvas, there are corresponding configuration parameters. Whether these configuration parameters are updated is monitored. When it is monitored that these configuration parameters are updated, the configuration parameters of the logic components 1 to 3 and instantiated objects 1 to 6 are obtained.

[0067] S302, storing the configuration parameters locally, and obtaining the current configuration parameters of each of the locally stored instantiated objects and logical components.

[0068] In the embodiment of the present application, for the configuration parameters of the instantiated object and the logic component respectively, the configuration parameters can be stored locally. In addition, the current configuration parameters of the instantiated object and the logic component respectively stored locally are obtained.

[0069] It should be noted that the configuration parameters of the instantiated object and the logical component, as well as the current configuration parameters of the instantiated object and the logical component stored locally, may be the same or different, and their consistency needs to be verified subsequently, which is not limited in this embodiment of the present application.

[0070] S303, synchronizing the current configuration parameters to the logic canvas, so that the logic canvas compares the configuration parameters with the current configuration parameters to complete the debugging process.

[0071] In an embodiment of the present application, for a controller, current configuration parameters of instantiated objects and logic components stored locally can be synchronized to a logic canvas, so that the logic canvas receives current configuration parameters of instantiated objects and logic components stored locally in the controller.

[0072] For the logic canvas, the current configuration parameters of the instantiated objects and logic components stored locally in the controller and the consistency of the configuration parameters of the instantiated objects and logic components local to the logic canvas can be compared to complete the debugging process.

[0073] Among them, if the current configuration parameters of the instantiated objects and logical components stored locally in the controller are consistent with the configuration parameters of the instantiated objects and logical components locally in the logic canvas, it means that the data adaptive synchronization between the logic canvas and the controller is successful and the debugging is successful, otherwise it is considered that the debugging failed.

[0074] Through the above description of the technical solution provided by the embodiment of the present application, by monitoring whether the configuration parameters of the instantiated objects and / or logical components are updated, and in the case of update, obtaining the respective configuration parameters of the instantiated objects and logical components, storing the configuration parameters locally, and obtaining the current configuration parameters of the locally stored instantiated objects and logical components, synchronizing the current configuration parameters to the logic canvas, so that the logic canvas compares the configuration parameters with the current configuration parameters for consistency, and completes the debugging process. In this way, the controller and the logic canvas are synchronized and communicated with each other, and the debugging process of the building control system can be automatically completed without manual acquisition for verification, and the control logic of the controller can be efficiently debugged later.

[0075] In addition, in the embodiment of the present application, the configuration parameters of the instantiated objects and logical components obtained need to be verified, and then according to the verification results, it can be known whether the configuration parameters of the instantiated objects and logical components have been updated, so as to decide whether to store them locally. Figure 4 FIG. 1 is a schematic diagram of an implementation flow of another debugging method provided in an embodiment of the present application. The method is applied to a controller and may specifically include the following steps:

[0076] S401 , when monitoring the configuration parameter update of the instantiated object and / or the logical component, obtain the configuration parameters of the instantiated object and the logical component respectively.

[0077] In the embodiment of the present application, this step is similar to the above-mentioned step S301, and the embodiment of the present application will not be described one by one here.

[0078] S402, generating a logic canvas verification code according to the configuration parameters, and obtaining a historical logic canvas verification code stored locally.

[0079] In the embodiment of the present application, for the configuration parameters of the instantiated objects and logic components respectively, a logic canvas verification code can be generated according to the configuration parameters. In addition, it is also necessary to obtain the historical logic canvas verification code stored locally, and the historical logic canvas verification code is generated according to the historical configuration parameters of the instantiated objects and logic components respectively.

[0080] S403, comparing the logic canvas verification code with the historical logic canvas verification code.

[0081] S404: When the logic canvas verification code is inconsistent with the historical logic canvas verification code, the configuration parameters are stored locally, and the current configuration parameters of the locally stored instantiated objects and logic components are obtained.

[0082] In an embodiment of the present application, for the logic canvas verification code and the historical logic canvas verification code, the logic canvas verification code can be compared with the historical logic canvas verification code. When the logic canvas verification code is consistent with the historical logic canvas verification code, it means that the respective configuration parameters of the instantiated object and the logic component have not been updated, and therefore there is no need to update the respective configuration parameters of the instantiated object and the logic component in the controller.

[0083] If the logic canvas verification code is inconsistent with the historical logic canvas verification code, it means that the configuration parameters of the instantiated object and the logic component have been updated. At this time, the configuration parameters of the instantiated object and the logic component need to be updated in the controller, so the configuration parameters of the instantiated object and the logic component are stored locally in the controller. In addition, the current configuration parameters of the instantiated object and the logic component stored locally need to be obtained.

[0084] S405, synchronizing the current configuration parameters to the logic canvas, so that the logic canvas compares the configuration parameters with the current configuration parameters to complete the debugging process.

[0085] In the embodiment of the present application, this step is similar to the above step S303, and the embodiment of the present application will not be described one by one here.

[0086] In this way, the configuration parameters of the instantiated objects and logical components obtained need to be verified. Then, based on the verification results, it can be known whether the configuration parameters of the instantiated objects and logical components have been updated, so as to decide whether to store them locally. Then, the current configuration parameters of the instantiated objects and logical components stored locally are obtained, and the current configuration parameters are synchronized to the logic canvas, so that the logic canvas compares the configuration parameters with the current configuration parameters for consistency, and completes the debugging process. In this way, the controller and the logic canvas are synchronized and communicated with each other, and the debugging process of the building control system can be automatically completed. There is no need to manually obtain and verify, and the control logic of the controller can be efficiently debugged later.

[0087] In addition, in the embodiment of the present application, the configuration parameters of the instantiated objects and logical components obtained need to be verified, and then according to the verification results, it can be known whether the configuration parameters of the instantiated objects and logical components have been updated. If they have been updated, the updated configuration parameters can be found and then updated to the local controller. Subsequently, the currently updated configuration parameters in the current configuration parameters of the instantiated objects and logical components stored locally in the controller can be searched, and then synchronized to the logic canvas to compare the consistency to complete the debugging. Based on this, if Figure 5 FIG. 1 is a schematic diagram of an implementation flow of another debugging method provided in an embodiment of the present application. The method is applied to a controller and may specifically include the following steps:

[0088] S501 , when monitoring the configuration parameter update of the instantiated object and / or the logical component, obtain the configuration parameters of the instantiated object and the logical component respectively.

[0089] In the embodiment of the present application, this step is similar to the above-mentioned step S301, and the embodiment of the present application will not be described one by one here.

[0090] S502, generating a logic canvas verification code according to the configuration parameters, and obtaining a historical logic canvas verification code stored locally.

[0091] In the embodiment of the present application, this step is similar to the above-mentioned step S402, and the embodiment of the present application will not be described one by one here.

[0092] S503, comparing the logic canvas verification code with the historical logic canvas verification code.

[0093] In the embodiment of the present application, this step is similar to the above-mentioned step S403, and the embodiment of the present application will not be described one by one here.

[0094] S504: When the logic canvas verification code is inconsistent with the historical logic canvas verification code, search for updated configuration parameters from the configuration parameters, and store the updated configuration parameters locally.

[0095] In an embodiment of the present application, for the logic canvas verification code and the historical logic canvas verification code, the logic canvas verification code can be compared with the historical logic canvas verification code. When the logic canvas verification code is inconsistent with the historical logic canvas verification code, it means that the configuration parameters of the instantiated object and the logic component have been updated. At this time, the updated configuration parameters can be found from the configuration parameters of the instantiated object and the logic component, and the updated configuration parameters can be stored locally.

[0096] Among them, for searching for updated configuration parameters in the respective configuration parameters of the instantiated objects and logical components, specifically, the historical configuration parameters of the instantiated objects and logical components stored locally can be obtained, and the configuration parameters of the instantiated objects and logical components can be compared with the historical configuration parameters of the instantiated objects and logical components stored locally to obtain the updated configuration parameters in the configuration parameters of the instantiated objects and logical components.

[0097] S505, obtaining current configuration parameters of each of the locally stored instantiated object and the logic component, and searching for currently updated configuration parameters from the current configuration parameters.

[0098] In the embodiment of the present application, the current configuration parameters of each of the locally stored instantiated object and the logic component are obtained, and the currently updated configuration parameters are searched from the current configuration parameters. The principle of searching the currently updated configuration parameters from the current configuration parameters is similar to the above, and the embodiment of the present application will not be repeated here one by one.

[0099] S506: Synchronize the currently updated configuration parameters to the logic canvas, so that the logic canvas compares the updated configuration parameters with the currently updated configuration parameters for consistency, thereby completing the debugging process.

[0100] In the embodiment of the present application, the currently updated configuration parameters in the current configuration parameters of the locally stored instantiated objects and logic components can be synchronized to the logic canvas, so that the logic canvas can receive the currently updated configuration parameters.

[0101] For the logic canvas, the updated configuration parameters can be found from the configuration parameters of the instantiated objects and logic components, and then compared with the currently updated configuration parameters for consistency to complete the debugging process.

[0102] Among them, if the currently updated configuration parameters in the current configuration parameters of the instantiated objects and logical components stored locally in the controller are consistent with the updated configuration parameters in the configuration parameters of the instantiated objects and logical components locally in the logic canvas, it means that the data adaptive synchronization between the logic canvas and the controller is successful and the debugging is successful, otherwise it is deemed that the debugging failed.

[0103] In this way, the configuration parameters of the instantiated objects and logical components obtained need to be verified. Then, based on the verification results, it can be known whether the configuration parameters of the instantiated objects and logical components have been updated. If they have been updated, the updated configuration parameters can be found and then updated to the local controller. Subsequently, the currently updated configuration parameters in the current configuration parameters of the instantiated objects and logical components stored locally in the controller can be found, and then synchronized to the logic canvas to compare the consistency to complete the debugging. In this way, the controller and the logic canvas are synchronized and communicated with each other, and the debugging process of the building control system can be automatically completed, without the need for manual acquisition and verification, and the control logic of the controller can be debugged efficiently later.

[0104] In addition, in an embodiment of the present application, a detection mechanism for an access device in an offline state is also provided. This mechanism is used to detect whether the access device is online or offline, and to simulate the offline access device to achieve the effect of device access, so as to complete the debugging of the control logic of the controller.

[0105] Based on this, in an embodiment of the present application, the controller is connected to multiple access devices (the access devices here are the above-mentioned terminal devices). In the controller, for each access device, a corresponding device online status point is set to represent the online and offline status of the access device.

[0106] For any access device, according to any device parameter of the access device, a parameter request frame is sent to the access device. Within a preset time period, it is detected whether the value of the device parameter sent by the access device in response to the parameter request frame is received. If the value of the device parameter sent by the access device in response to the parameter request frame is not received, the point of the device online status corresponding to the access device is set, and the setting indicates that the access device is offline.

[0107] For any access device, monitor whether the point of the device online status corresponding to the access device is set. If the point of the device online status corresponding to the access device is monitored to be set, determine the communication protocol with the access device, and generate a device instance according to any device parameter of the access device and the communication protocol. The device instance includes any device parameter of the access device. Associate any device parameter of the access device contained in the device instance with the corresponding instantiated object in the logic canvas. The association is used to synchronize the value of any device parameter of the access device contained in the device instance with the value of the corresponding instantiated object in the logic canvas, such as Figure 6 shown.

[0108] In addition, in the embodiment of the present application, a detection mechanism for the offline state of the access device is also provided, which can be specifically detected through heartbeat information. Based on this, for any access device, within a preset time period, it is detected whether the heartbeat information sent by the access device is received; if the heartbeat information sent by the access device is not received, the point of the device online state corresponding to the access device is set.

[0109] The debugging method provided by the embodiment of the present application is described below in conjunction with specific embodiments. Figure 7 As shown, when new configuration parameters are updated in the logic canvas, the controller obtains the new logic canvas configuration parameters through its canvas listening port unit, transmits the new logic canvas configuration parameters to the central processing unit, generates a new logic canvas verification code, and then compares the new logic canvas verification code with the logic canvas verification code inside the controller. The logic canvas synchronization unit obtains a new verification signal, updates the logic canvas configuration parameters according to the new verification signal, and saves it to the data storage unit inside the controller. The logic control unit then obtains the new configuration parameters from the data storage unit to complete the update of the logic canvas configuration parameters. The above process is the data synchronization between the logic canvas sending configuration parameters to the controller. Conversely, the data synchronization from the controller to the logic canvas is that the logic control unit obtains the new configuration parameters from the data storage unit, sends the new configuration parameters to the central processing unit, and the central processing unit sends the new configuration parameters to the canvas listening port unit. The canvas listening port unit transmits the new configuration parameters to the logic canvas to complete the update of the controller configuration parameters.

[0110] In addition, in the embodiment of the present application, a mechanism for detecting the offline state of the access device is also provided. The controller determines whether the access device is in an offline state by detecting whether the device parameters of the access device are normally transmitted in numerical value. If the online state changes, it will be synchronized with the data display terminal immediately. For offline access devices in the project, this mechanism will also be used to simulate the access of the offline access device. The specific implementation method is that the controller will generate a device instance according to the device parameters, and associate the device instance with the instantiated object in the logic canvas through the device instance. The main thing is that the value of the device parameter in the device instance is processed by linear conversion and other methods to be the value displayed in the instantiated object in the upper computer. In this way, the device instance is associated with the instantiated object, so as to achieve the purpose of replacing the device parameters of the offline access device with the device instance, and realize the completeness of the device parameters during the debugging project, so as to complete the logic debugging of the field controller.

[0111] Its main implementation methods are as follows Figure 6 As shown in the figure, it mainly provides an interactive data transmission channel in the real-time interactive function of the logic canvas. After the instantiated object is associated with the device parameters, a transmission message channel can be constructed to achieve the synchronous update of the values ​​of the instantiated object in the data display terminal and the device parameters in the controller. Figure 6 As shown, when the control system is not connected to the terminal device, the controller generates a device instance according to the device parameters of the terminal device and the communication protocol. The device instance is a data source that stores the device parameters of the terminal device. The device instance replaces the access of the terminal device. In the logic canvas of the host computer, when the value of the instantiated object is updated, the device parameter associated with it in the device instance synchronizes the value, realizing an integrated real-time interactive development environment.

[0112] The so-called instantiated object is a collection of associated parameters such as device parameters and control parameters that exist in the logic canvas visualization interface. Device parameters are parameters of the terminal device, and control parameters are parameters that only exist in the controller to achieve a certain control purpose. The values ​​of the associated instantiated objects will be synchronized to the device parameters and control parameters. Logic components are collections with control logic, with input, output, enable and other pins, such as Figure 2 As shown, after the value of instantiated object 4 (temperature) is changed, logic component 1 (which can be configured as an integrated control unit that controls the start and stop of equipment based on temperature detection) monitors the input signal, executes the control logic, and outputs a control instruction to the output end. The instantiated object 1 (motor enable) at the output end updates its own value to control the start and stop of the motor equipment. The logic canvas that is interactively configured in the host computer is realized to display the control logic between each instantiated object in a graphically visualized way.

[0113] Corresponding to the above method embodiment, the embodiment of the present application also provides a debugging device, which is applied to a controller, wherein the controller establishes communication with a logic canvas, wherein the logic canvas includes an instantiated object and a logic component, wherein the instantiated object is connected to the logic component, wherein the instantiated object corresponds to a device parameter of an access device of the controller, and the logic component corresponds to a control logic of the controller, such as Figure 8 As shown, the device may include:

[0114] The parameter acquisition module 810 is used to acquire the configuration parameters of the instantiated object and the logical component respectively when monitoring the configuration parameter update of the instantiated object and / or the logical component;

[0115] A parameter storage module 820 is used to store the configuration parameters locally and obtain the current configuration parameters of the instantiated object and the logic component stored locally;

[0116] The parameter synchronization module 830 is used to synchronize the current configuration parameters to the logic canvas, so that the logic canvas compares the consistency between the configuration parameters and the current configuration parameters to complete the debugging process.

[0117] The present application also provides a control terminal, such as Fig. 9 As shown, it includes a processor 91, a communication interface 92, a memory 93 and a communication bus 94, wherein the processor 91, the communication interface 92, and the memory 93 communicate with each other through the communication bus 94.

[0118] Memory 93, used for storing computer programs;

[0119] The processor 91 is used to execute the program stored in the memory 93 to implement the following steps:

[0120] In case of monitoring the configuration parameter update of the instantiated object and / or the logical component, the respective configuration parameters of the instantiated object and the logical component are obtained; the configuration parameters are stored locally, and the current configuration parameters of the instantiated object and the logical component stored locally are obtained; the current configuration parameters are synchronized to the logical canvas, so that the logical canvas compares the configuration parameters with the current configuration parameters for consistency, and the debugging process is completed.

[0121] The communication bus mentioned in the control terminal can be a Peripheral Component Interconnect (PCI) bus or an Extended Industry Standard Architecture (EISA) bus, etc. The communication bus can be divided into an address bus, a data bus, a control bus, etc. For ease of representation, only one thick line is used in the figure, but it does not mean that there is only one bus or one type of bus.

[0122] The communication interface is used for communication between the above control terminal and other devices.

[0123] The memory may include a random access memory (RAM) or a non-volatile memory, such as at least one disk memory. Optionally, the memory may also be at least one storage device located away from the aforementioned processor.

[0124] The above-mentioned processor can be a general-purpose processor, including a central processing unit (CPU), a network processor (NP), etc.; it can also be a digital signal processor (DSP), an application specific integrated circuit (ASIC), a field programmable gate array (FPGA) or other programmable logic devices, discrete gate or transistor logic devices, discrete hardware components.

[0125] In another embodiment provided in the present application, a storage medium is further provided, in which instructions are stored. When the storage medium is run on a computer, the computer executes the debugging method described in any one of the above embodiments.

[0126] In another embodiment provided by the present application, a computer program product including instructions is also provided, which, when executed on a computer, enables the computer to execute any of the debugging methods described in the above embodiments.

[0127] In the above embodiments, it can be implemented in whole or in part by software, hardware, firmware or any combination thereof. When implemented using software, it can be implemented in whole or in part in the form of a computer program product. The computer program product includes one or more computer instructions. When the computer program instructions are loaded and executed on a computer, the process or function described in the embodiment of the present application is generated in whole or in part. The computer may be a general-purpose computer, a special-purpose computer, a computer network, or other programmable device. The computer instructions may be stored in a storage medium, or transmitted from one storage medium to another storage medium, for example, the computer instructions may be transmitted from a website site, a computer, a server or a data center by wired (e.g., coaxial cable, optical fiber, digital subscriber line (DSL)) or wireless (e.g., infrared, wireless, microwave, etc.) mode to another website site, computer, server or data center. The storage medium may be any available medium that a computer can access or a data storage device such as a server or a data center that includes one or more available media integrations. The available medium may be a magnetic medium, (e.g., a floppy disk, a hard disk, a tape), an optical medium (e.g., a DVD), or a semiconductor medium (e.g., a solid-state drive Solid State Disk (SSD)), etc.

[0128] It should be noted that, in this article, relational terms such as first and second, etc. are only used to distinguish one entity or operation from another entity or operation, and do not necessarily require or imply any such actual relationship or order between these entities or operations. Moreover, the terms "include", "comprise" or any other variants thereof are intended to cover non-exclusive inclusion, so that a process, method, article or device including a series of elements includes not only those elements, but also other elements not explicitly listed, or also includes elements inherent to such process, method, article or device. In the absence of further restrictions, the elements defined by the sentence "comprise a ..." do not exclude the existence of other identical elements in the process, method, article or device including the elements.

[0129] Each embodiment in this specification is described in a related manner, and the same or similar parts between the embodiments can be referred to each other, and each embodiment focuses on the differences from other embodiments. In particular, for the system embodiment, since it is basically similar to the method embodiment, the description is relatively simple, and the relevant parts can be referred to the partial description of the method embodiment.

[0130] The above description is only a preferred embodiment of the present application and is not intended to limit the protection scope of the present application. Any modification, equivalent replacement, improvement, etc. made within the spirit and principle of the present application are included in the protection scope of the present application.

Claims

1. A debugging method, characterized in that: Applied to a controller, the controller establishes communication with a logic canvas, the logic canvas includes an instantiated object and a logic component, the instantiated object and the logic component are connected, the instantiated object corresponds to a device parameter of an access device of the controller, the logic component corresponds to a control logic of the controller, and the method includes: In case of monitoring the configuration parameter update of the instantiated object and / or the logical component, obtaining the configuration parameters of the instantiated object and the logical component respectively; The configuration parameters are stored locally, and the current configuration parameters of the instantiated object and the logic component stored locally are obtained; The current configuration parameters are synchronized to the logic canvas, so that the logic canvas compares the consistency between the configuration parameters and the current configuration parameters, thereby completing the debugging process.

2. The method according to claim 1, characterized in that The storing the configuration parameters locally includes: Generate a logic canvas verification code according to the configuration parameters, and obtain a historical logic canvas verification code stored locally; Comparing the logic canvas verification code with the historical logic canvas verification code; When the logic canvas verification code is inconsistent with the historical logic canvas verification code, the configuration parameters are stored locally.

3. The method according to claim 2, characterized in that The storing the configuration parameters locally includes: Searching for updated configuration parameters from the configuration parameters, and storing the updated configuration parameters locally; The obtaining the current configuration parameters of the instantiated object and the logic component stored locally includes: Obtaining the current configuration parameters of the instantiated object and the logic component respectively stored locally, and searching the currently updated configuration parameters from the current configuration parameters; The synchronizing the current configuration parameters to the logic canvas so that the logic canvas compares the consistency between the configuration parameters and the current configuration parameters includes: The currently updated configuration parameters are synchronized to the logic canvas, so that the logic canvas compares the consistency between the updated configuration parameters and the currently updated configuration parameters.

4. The method according to claim 3, characterized in that The searching for updated configuration parameters from the configuration parameters includes: Obtain locally stored historical configuration parameters of the instantiated object and the logic component; The configuration parameters are compared with the historical configuration parameters to obtain updated configuration parameters among the configuration parameters.

5. The method according to claim 1, characterized in that The controller is connected to a plurality of access devices. In the controller, for each of the access devices, a corresponding device online status point is set to represent the offline status of the access device. The method further includes: For any of the access devices, sending a parameter request frame to the access device according to any device parameter of the access device; within a preset time period, detecting whether a value of a device parameter sent by the access device in response to the parameter request frame is received; If the value of the device parameter sent by the access device in response to the parameter request frame is not received, the point of the device online status corresponding to the access device is set.

6. The method according to claim 5, characterized in that The method further comprises: For any of the access devices, monitoring whether the point of the device online status corresponding to the access device is set; If the point position of the device online status corresponding to the access device is monitored, determine the communication protocol with the access device; Generate a device instance according to any device parameter of the access device and the communication protocol, wherein the device instance includes any device parameter of the access device; Associating any device parameter of the access device contained in the device instance with a corresponding instantiated object in the logic canvas; The association is used to achieve synchronization between a value of any device parameter of the access device contained in the device instance and a value of a corresponding instantiated object in the logic canvas.

7. The method according to claim 5, characterized in that The method further comprises: For any of the access devices, detecting whether the heartbeat information sent by the access device is received within a preset time period; If the heartbeat information sent by the access device is not received, the point of the device online status corresponding to the access device is set.

8. A debugging device, characterized in that: Applied to a controller, the controller establishes communication with a logic canvas, the logic canvas includes an instantiated object and a logic component, the instantiated object and the logic component are connected, the instantiated object corresponds to a device parameter of an access device of the controller, the logic component corresponds to a control logic of the controller, and the device includes: A parameter acquisition module, configured to acquire the configuration parameters of the instantiated object and the logical component respectively when monitoring the configuration parameter update of the instantiated object and / or the logical component; A parameter storage module, used to store the configuration parameters locally and obtain the current configuration parameters of the instantiated object and the logic component stored locally; The parameter synchronization module is used to synchronize the current configuration parameters to the logic canvas, so that the logic canvas compares the consistency between the configuration parameters and the current configuration parameters to complete the debugging process.

9. A control terminal, characterized in that: It includes a processor, a communication interface, a memory and a communication bus, wherein the processor, the communication interface and the memory communicate with each other through the communication bus; Memory, used to store computer programs; A processor, for implementing any of the methods described in claims 1-7 when executing a program stored in a memory.

10. A storage medium having a computer program stored thereon, characterized in that: When the program is executed by a processor, the method according to any one of claims 1 to 7 is implemented.