Graphical interactive programming method and software system suitable for electromechanical system

Through graphical interactive programming methods and simulation technology, problems such as high hardware dependence, resource limitation, real-time and multi-task processing capabilities in embedded software development are solved, and more efficient and reliable electromechanical system development is achieved, reducing the development of the mechanical and electrical system. The development cost and debugging difficulty are improved, and the system security is improved.

CN119292584APending Publication Date: 2025-01-10SUZHOU TRENDSHENG TECHNOLOGY CO LTD
View PDF 0 Cites 0 Cited by

Patent Information

Application Number
CN202411414281.5
Authority / Receiving Office
CN · China
Patent Type
Applications(China)
Current Assignee / Owner
Filing Date
2024-10-11
Publication Date
2025-01-10

AI Technical Summary

Technical Problem

Traditional embedded software development faces problems such as high hardware dependence, resource limitations, high real-time requirements, high multi-task processing capabilities, difficulty in debugging and maintenance, and high security requirements, resulting in high development difficulty and high cost.

Method used

Using graphical interactive programming methods, by establishing a database of the device components, performing visual editing of motion timing and encrypting encoding, executable encrypted action files, simplifying hardware function editing, improving development efficiency and reliability, and optimizing operation logic through simulation simulation and troubleshoot.

Benefits of technology

It reduces hardware dependence, improves development efficiency and reliability, simplifies debugging and maintenance processes, improves the system's security and multi-tasking capabilities, and solves resource limitations and real-time requirements.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN119292584A_ABST
    Figure CN119292584A_ABST
Patent Text Reader

Abstract

The invention discloses a graphical interactive programming method and software system suitable for an electromechanical system.The method comprises the following steps that S1, a device component database is established, specifically, basic information of constituent device components of the electromechanical system is input, parameter editing is conducted on the device components, and the device component database special for the electromechanical system is established; s2, performing electromechanical system motion time sequence visual editing: performing motion editing, motion time sequence editing, motion time sequence simulation and encryption coding on a device component to generate an executable encryption motion file; and S3, importing the action file of the electromechanical system: importing the generated encrypted action file into the electromechanical system. By means of the programming method, function editing of hardware in the electromechanical system can be achieved more simply, the function requirements of the electromechanical system can be achieved conveniently and reliably, and therefore the difficulty point in embedded software development is solved.
Need to check novelty before this filing date? Find Prior Art

Description

Technical Field

[0001] The present invention relates to the technical field of electromechanical system automatic control, and in particular to a graphical interactive programming method and software system suitable for electromechanical systems. Background Art

[0002] Electromechanical systems are widely used in various industrial fields, such as automobile manufacturing, engineering machinery, metallurgy, chemical industry, medical treatment, etc. In these fields, electromechanical systems can achieve highly automated and intelligent production, improve production efficiency and product quality, and reduce production costs and labor costs. Common electromechanical systems include IVD equipment, scientific research equipment, robotic equipment, etc.

[0003] In the functional realization of electromechanical systems, the development of hardware and software is mainly involved. In terms of hardware, it is necessary to design hardware circuits such as embedded processors, memories, sensors, and drivers that are suitable for the operation of the equipment. In terms of software, it is necessary to write embedded software programs such as operating systems, control algorithms, and communication protocols.

[0004] Through embedded development, the control, monitoring, protection and other functions of the electromechanical system can be integrated to realize the intelligent and automatic control of the equipment. At the same time, the functions and performance of the equipment can be increased and the adaptability and flexibility of the equipment can be improved through software upgrades and expansions.

[0005] The application of embedded software can improve the intelligence, automation and multifunctionality of electromechanical systems, improve the production efficiency and product quality of equipment, and reduce production costs and labor costs. At the same time, through software upgrades and expansions, the functions and performance of equipment can be increased, the adaptability and flexibility of equipment can be improved, and strong support can be provided for the sustainable development of enterprises. However, the difficulties in the development of embedded software for electromechanical systems are mainly reflected in the following aspects:

[0006] 1. High hardware dependence: Embedded software needs to be closely integrated with a specific hardware platform, and the development process requires an in-depth understanding of the characteristics and performance of the hardware. This high dependence on hardware makes embedded software less portable and requires customized development for different hardware platforms.

[0007] 2. Resource limitations: The resources of embedded systems are usually limited, including storage space, memory, and processor speed. When developing software under limited resources, it is necessary to fully consider factors such as software efficiency, memory usage, and response time, which brings great challenges to development.

[0008] 3. High real-time requirements: Embedded software often needs to handle tasks with high real-time requirements, such as sensor data acquisition, control instruction execution, etc. This requires the software to complete the corresponding operations within the specified time, otherwise it may cause system crashes or performance degradation. Therefore, developers need to ensure the real-time and stability of the software.

[0009] 4. High multi-tasking capability requirements: Embedded systems usually need to handle multiple tasks at the same time, which requires the software to have strong multi-tasking capabilities. Developers need to design reasonable task scheduling strategies and synchronization mechanisms to ensure the normal operation of each task and system stability.

[0010] 5. Difficulty in debugging and maintenance: Due to the complex hardware and software environments of embedded systems, debugging and maintenance are often difficult once errors or exceptions occur in the software. In addition, due to the closed nature of embedded systems, it is sometimes difficult to obtain sufficient debugging information and tool support.

[0011] 6. High security requirements: For embedded systems in some key areas, such as aerospace, medical equipment, etc., the software security requirements are very high. Developers need to ensure the reliability and security of the software to prevent security issues such as system crashes or data leaks caused by software failures.

[0012] In summary, traditional embedded software development faces many difficulties and challenges, requiring developers to have a solid programming foundation, in-depth system knowledge and rich practical experience. At the same time, as the application areas of embedded systems continue to expand and their functions continue to increase, higher requirements are also placed on the development of embedded software. Summary of the invention

[0013] In view of these problems of traditional embedded software development in the electromechanical system development described in the technical background, the present invention proposes a graphical interactive programming method and software system suitable for the electromechanical system. Through this programming method, the function editing and implementation of the hardware in the electromechanical system can be more simply carried out, and the functional requirements of the electromechanical system can be conveniently and reliably realized, thereby solving the difficulties in the embedded software development involved in the above-mentioned background technology.

[0014] In order to achieve the above-mentioned purpose, the technical solution of the present invention provides a graphical interactive programming method suitable for electromechanical systems, characterized in that it includes the following steps: S1 establishment of a component database: entering the basic information of the components constituting the electromechanical system, and editing the parameters of the components to establish a component database dedicated to the electromechanical system; S2 visual editing of the motion timing of the electromechanical system: performing action editing and action timing editing, motion timing simulation and encryption encoding on the components to generate an executable encrypted action file; S3 importing the electromechanical system action file: importing the generated encrypted action file into the electromechanical system.

[0015] Further, in step S2, action editing and action timing editing of the device component specifically include: S21: selecting the device component for which action editing is desired in the device component database, and graphically dragging it to the timing operation box; S22: listing all minimum action timing blocks of the corresponding device component; S23: arranging the minimum action timing blocks in sequence / system priority according to time sequence / trigger conditions, and finally forming an action operation timing diagram; S24: determining whether there are other device components in the action flow, if not, completing the action editing and action timing editing, otherwise jumping to step S21 to continue execution.

[0016] Furthermore, in step S2, when performing motion timing simulation, the recorded components are connected by analogy with the connection relationship of the actual mechanical structure using wiring to build a simulation operation platform that is the same as the actual electromechanical system, so as to optimize the operation logic of the electromechanical system and troubleshoot faults through simulation.

[0017] Furthermore, in step S2, encryption encoding specifically includes: S25: converting the device component driver into a driver package of machine language recognizable by hardware according to the parameters saved in the device component database; S26: packaging the minimum action timing block of the device component into a single functional instruction of machine language recognizable by the electromechanical system hardware; S27: combining the single functional instructions according to the action timing diagram to generate an instruction package; S28: encrypting the instruction package and the driver package through an encryption algorithm to generate a final action execution file.

[0018] Furthermore, in step S27, by splitting the time sequence parameters and logic condition judgment parameters between each minimum action timing block in the action timing diagram, adding time parameters, logic judgment parameters and system priorities between single machine language instructions, a machine language instruction package is synthesized.

[0019] Furthermore, in step S28, the SHA256 encryption algorithm is used to encrypt the machine language instruction package and the driver package to ultimately form an action execution file.

[0020] The present invention also provides a graphical interactive programming software system suitable for electromechanical systems, which includes the following modules: a component database establishment module, which is used to enter the basic information of the components that constitute the electromechanical system, and edit the parameters of the components to establish a component database dedicated to the electromechanical system; an electromechanical system motion timing visualization editing module, which is used to perform action editing and action timing editing, motion timing simulation and encryption encoding on the components to generate executable encrypted action files; an electromechanical system action file importing module, which is used to import the encrypted action file generated by the electromechanical system motion timing visualization editing module into the electromechanical system. BRIEF DESCRIPTION OF THE DRAWINGS

[0021] In order to more clearly illustrate the technical solutions of the embodiments of the present invention, the drawings required for use in the embodiments are briefly introduced below. It should be understood that the following drawings only show certain embodiments of the present invention and therefore should not be regarded as limiting the scope. For ordinary technicians in this field, other related drawings can be obtained based on these drawings without creative work.

[0022] Figure 1 is a flow chart of a graphical interactive programming method applicable to electromechanical systems of the present invention;

[0023] Figure 2 It is a flow chart of the process of converting the electromechanical system motion sequence visualization into an action execution file of the present invention;

[0024] Figure 3 is a block diagram of a graphical interactive programming software system applicable to electromechanical systems of the present invention;

[0025] Figure 4 is a schematic diagram of a timing block of the present invention;

[0026] Figure 5 is a schematic diagram of a timing diagram of the present invention;

[0027] Figure 6 is a schematic diagram of a parameter editing framework of the present invention;

[0028] Figure 7 Schematic diagram of the script editor framework of the present invention. DETAILED DESCRIPTION

[0029] The following will be combined with the drawings in the embodiments of the present invention to clearly and completely describe the technical solutions in the embodiments of the present invention. Obviously, the described embodiments are only part of the embodiments of the present invention, not all of the embodiments. Based on the embodiments of the present invention, all other embodiments obtained by ordinary technicians in this field without creative work are within the scope of protection of the present invention.

[0030] In an embodiment of the present invention, a graphical interactive programming method suitable for an electromechanical system is provided, which is characterized in that it includes the following steps: S1 establishment of a component database: inputting basic information of the components constituting the electromechanical system, and performing parameter editing on the components to establish a component database dedicated to the electromechanical system; S2 visual editing of the motion timing of the electromechanical system: performing action editing and action timing editing, motion timing simulation, and encryption encoding on the components to generate an executable encrypted action file; S3 importing an electromechanical system action file: importing the generated encrypted action file into the electromechanical system.

[0031] Further, in step S2, action editing and action timing editing of the device component specifically include: S21: selecting the device component for which action editing is desired in the device component database, and graphically dragging it to the timing operation box; S22: listing all minimum action timing blocks of the corresponding device component; S23: arranging the minimum action timing blocks in sequence / system priority according to time sequence / trigger conditions, and finally forming an action operation timing diagram; S24: determining whether there are other device components in the action flow, if not, completing the action editing and action timing editing, otherwise jumping to step S21 to continue execution.

[0032] Furthermore, in step S2, when performing motion timing simulation, the recorded components are connected by analogy with the connection relationship of the actual mechanical structure using wiring to build a simulation operation platform that is the same as the actual electromechanical system, so as to optimize the operation logic of the electromechanical system and troubleshoot faults through simulation.

[0033] Furthermore, in step S2, encryption encoding specifically includes: S25: converting the device component driver into a driver package of machine language recognizable by hardware according to the parameters saved in the device component database; S26: packaging the minimum action timing block of the device component into a single functional instruction of machine language recognizable by the electromechanical system hardware; S27: combining the single functional instructions according to the action timing diagram to generate an instruction package; S28: encrypting the instruction package and the driver package through an encryption algorithm to generate a final action execution file.

[0034] Furthermore, in step S27, by splitting the time sequence parameters and logic condition judgment parameters between each minimum action timing block in the action timing diagram, adding time parameters, logic judgment parameters and system priorities between single machine language instructions, a machine language instruction package is synthesized.

[0035] Furthermore, in step S28, the SHA256 encryption algorithm is used to encrypt the machine language instruction package and the driver package to ultimately form an action execution file.

[0036] In another embodiment of the present invention, a graphical interactive programming software system suitable for electromechanical systems is also provided, which can be used to execute the method described above, and the system includes the following modules: a component database establishment module, which is used to enter the basic information of the components that constitute the electromechanical system, and edit the parameters of the components to establish a component database dedicated to the electromechanical system; an electromechanical system motion timing visualization editing module, which is used to perform action editing and action timing editing, motion timing simulation and encryption encoding on the components to generate executable encrypted action files; an electromechanical system action file importing module, which is used to import the encrypted action file generated by the electromechanical system motion timing visualization editing module into the electromechanical system. Specific embodiments

[0038] like Figure 1 As shown, the graphical interactive programming method applicable to electromechanical systems of the present invention mainly includes:

[0039] (1) Input basic information of components of the electromechanical system: List the components that need to be controlled according to the composition of the designed electromechanical complete system, such as stepper motor 1, stepper motor 2, input sensor, analog sensor 1, etc. You can also customize the name according to the function of the electromechanical system, such as X-axis motion motor, cooling fan motor, equipment start button, injection pressure sensor, etc. Establish a database dedicated to this electromechanical system. The flexible selection of components solves the problem of high hardware dependence in embedded software development. It is no longer necessary to use professional programming software to redevelop according to the different types and quantities of components used on different hardware platforms. You only need to reselect and cut the components.

[0040] (2) Component specification editing: According to the design requirements of the electromechanical system, set the parameters of the components of the electromechanical system to ensure that the performance and specifications of all components are correct before the actual action programming. This is similar to establishing a dedicated database for the electromechanical system itself. This solves the problems of high hardware dependence and difficult debugging and maintenance in embedded software development. It is no longer necessary to repeatedly use professional programming software for debugging, optimization and development due to component changes and product optimization and debugging.

[0041] (3) Visual editing of electromechanical system motion timing: You can define the action of each component and graphically drag it to the timing operation box for real-time operation. Debugging and maintenance can effectively shorten the implementation cycle and avoid bugs that are prone to occur during the development process through rapid editing and importing. The modular packaging program can weaken the requirements of traditional embedded software development, such as solid programming foundation, in-depth system knowledge and rich practical experience, and reduce the actual development cost and cycle of embedded software.

[0042] like Figure 2 As shown, in the process of generating the action execution file code, the device component driver package is first generated according to the device component selected in the device component database, a single functional instruction is generated according to the minimum action timing block, and the single functional instructions are combined according to the action timing diagram to generate an instruction package. Finally, the instruction package and the driver package are encrypted by the SHA256 encryption algorithm to generate the final action instruction file.

[0043] (4) Simulation of the motion sequence of the electromechanical system: The recorded components are connected by analogy with the actual mechanical structure connection relationship, so as to build a simulation operation platform that is the same as the physical electromechanical system. When the electromechanical system is developed remotely or does not have a physical object, and cannot be debugged under the actual mechanical structure, simulation can be used instead of actual debugging. Simulation can also be used to optimize the operation logic and troubleshoot the electromechanical system before actual debugging. Building a simulation operation platform that is analogous to the physical object can quickly verify the resource requirements and multi-task processing capability requirements of the electromechanical system.

[0044] (5) Action file generation and output: Automatically encode and encrypt to generate executable files for the actual electromechanical system and save them in the storage medium. Through the built-in encoding module, the generated action file comes with the multi-task system task allocation priority (FreeRTOS system) to ensure resource requirements and multi-task real-time requirements. The final action file export is encrypted to effectively ensure security.

[0045] (6) Import file into electromechanical system: Import the generated and saved action file into the actual motor system.

[0046] like Figure 3 As shown, the graphical interactive programming software system applicable to electromechanical systems of the present invention includes:

[0047] The basic information entry module of the device component is used to create a new device component or import a device component;

[0048] The device component parameter editing module is used to add device components and delete, modify, etc.

[0049] The electromechanical system motion timing editing module is used to edit the motion of the device components, edit the motion timing, simulate the motion, and generate executable motion files through encryption coding;

[0050] The electromechanical system action file import module is used to import the encrypted action file through the electromechanical system communication interface and store it in the electromechanical system.

[0051] In a specific embodiment, when editing the device component parameters in the device component database, the driver components involved in the editing are shown in Table 1:

[0052] Table 1

[0053]

[0054]

[0055] The electrical specification attribute programming configuration rules, the structure for editing the above driver components is as follows: (The following Table 2 only describes the language structure, and the content of D0-Dn does not represent the actual invention, but is just an example)

[0056] Table 2

[0057]

[0058] When the motion file is generated, the programming uses the timing diagram as a bridge between natural language and machine language. Therefore, the motion logic structure will consist of three parts: natural language (timing block, such as Figure 4 As shown), timing diagram (as shown Figure 5 As shown, the timing diagram of the combination of two motors + one solenoid valve), machine language.

[0059] The machine language structure is similar to the parameter editing part, but the structure will have a time sequence or trigger conditions. The specific structure is as follows; the motion logic has an absolute 0 point time to start the motion, which is recorded as 0S.

[0060] Table 3. Action instruction framework

[0061]

[0062] Table 4. Trigger time instruction framework

[0063]

[0064] Engineers combine the control process according to the timing blocks, display the timing diagram in real time, and finally generate executable statements.

[0065] Figure 6 and Figure 7 The parameter editing framework and the script editing framework of the present invention are shown respectively

[0066] The graphical interactive programming method and software system applicable to electromechanical systems of the present invention can effectively solve the difficulties brought about by traditional embedded software development of electromechanical systems:

[0067] (1) Build a dedicated database for each electromechanical system by entering the device components, which effectively solves the problem of high hardware dependence due to different hardware platforms and the need to redevelop embedded software.

[0068] (2) Graphical sequential action editing integrates the professional underlying development and real-time system in embedded software development, reduces the requirements for developers, shortens the development cycle, and improves development reliability. It effectively solves the problems of resource limitations, high real-time requirements, and high multi-tasking processing capabilities.

[0069] (3) Graphical sequential action simulation can simulate the generated action file in the sequential process according to the actual constraints, pay attention to the status of each component of the electromechanical system in the process, check whether there are problems with the operation logic, and reasonably allocate the working sequence of the components according to the operation status to optimize the action process time. It can solve the problem of difficult debugging and maintenance, and provide assistance for multi-tasking and real-time requirements.

[0070] (4) Generate and export encrypted action files to replace the file generation process of embedded software, eliminating the need for professional programming software to intervene in the development process, reducing development costs. Improve the safety of electromechanical systems and solve the problem of high safety requirements.

[0071] The above description is only a preferred specific implementation manner of the present invention, but the protection scope of the present invention is not limited thereto. Any technician familiar with the technical field can make equivalent replacements or changes according to the technical scheme and inventive concept of the present invention within the technical scope disclosed by the present invention, which should be covered by the protection scope of the present invention.

Claims

1. A graphical interactive programming method suitable for electromechanical systems, characterized in that: The steps include: S1 Establishment of component database: input basic information of components constituting the electromechanical system, and edit the parameters of the components to establish a component database dedicated to the electromechanical system; S2 electromechanical system motion timing visual editing: perform motion editing and motion timing editing, motion timing simulation and encryption coding on device components to generate executable encrypted motion files; S3 mechatronic system action file import: import the generated encrypted action file into the mechatronic system.

2. The method according to claim 1, characterized in that In step S2, editing the actions and timing of the device components specifically includes: S21: Select the component whose action you want to edit in the component database, and graphically drag it to the timing operation box; S22: List all minimum action timing blocks of the corresponding device components; S23: Arrange the minimum action timing blocks in order of precedence / system priority according to the time sequence / trigger condition, and finally form an action operation timing diagram; S24: Determine whether there are other components in the action flow. If not, complete the action editing and action timing editing. Otherwise, jump to step S21 to continue execution.

3. The method according to claim 2, characterized in that In step S2, when performing motion timing simulation, the recorded components are connected by analogy with the connection relationship of the actual mechanical structure using wiring to build a simulation operation platform that is the same as the actual electromechanical system, so as to optimize the operation logic of the electromechanical system and troubleshoot faults through simulation.

4. The method according to claim 3, characterized in that In step S2, the encryption encoding specifically includes: S25: converting the device component driver into a driver package in a machine language recognizable by the hardware according to the parameters saved in the device component database; S26: Packing the minimum action timing block of the device component into a single machine language function instruction recognizable by the electromechanical system hardware; S27: Combining the functional single instructions to generate an instruction packet according to the action timing diagram; S28: Encrypt the instruction package and the driver package through an encryption algorithm to generate a final action execution file.

5. The method according to claim 4, characterized in that In step S27, by splitting the time sequence parameters and logic condition judgment parameters between each minimum action timing block in the action timing diagram, adding time parameters, logic judgment parameters and system priorities between single machine language instructions, a machine language instruction package is synthesized.

6. The method according to claim 5, characterized in that In step S28, the SHA256 encryption algorithm is used to encrypt the machine language instruction package and the driver package to ultimately form an action execution file.

7. A graphical interactive programming software system suitable for electromechanical systems, characterized in that: Includes the following modules: The component database establishment module is used to input the basic information of the components constituting the electromechanical system and edit the parameters of the components to establish a component database dedicated to the electromechanical system; The electromechanical system motion timing visual editing module is used to edit the motion and motion timing of the device components, simulate the motion timing, and perform encryption coding to generate executable encrypted motion files; The electromechanical system action file import module is used to import the encrypted action file generated by the electromechanical system motion timing visualization editing module into the electromechanical system.