Robot control system and robot
Patent Information
- Application Number
- CN202311726724.X
- Authority / Receiving Office
- CN · China
- Patent Type
- Patents(China)
- Current Assignee / Owner
- Filing Date
- 2023-12-14
- Publication Date
- 2026-08-21
- Estimated Expiration
- 2043-12-14
AI Technical Summary
[0003]然而,当前的机器人通常存在线路冗余较大的问题,并且在执行作业任务的过程中,机器人控制精度有限,在机器人出现伺服驱动故障的情况下,难以实现高效的故障排查,机器人系统在产线上的应用受限
[0016] The robot control system provided in this application embodiment uses a serial bus to connect the controller and the servo driver, allowing them to communicate and interact. This enables the controller and servo driver to be integrated onto the same circuit board, reducing the robot's circuit redundancy and size, and improving the stability and real-time performance of the robot control system. The controller can perform drive planning based on the task to be executed and issue drive tasks based on the results of the drive planning. The servo driver then performs servo control on the servo motors according to the received drive tasks. This allows the robot's servo control to be achieved collaboratively by the controller and the servo driver, which helps improve the accuracy of servo control and facilitates troubleshooting in the event of a drive failure, thus improving troubleshooting efficiency.
Smart Images

Figure CN117681229B_ABST
Abstract
Description
Technical Field
[0001] This application relates to the field of automatic control, and in particular to a robot control system and a robot. Background Technology
[0002] With the development of control technology, industrial robots are playing an increasingly important role in the manufacturing process. To ensure production efficiency and quality, the requirements for robot control algorithms are also becoming more stringent. To improve production line efficiency, a production line can typically be configured as a robot system, which includes at least one robot and at least two positioner systems. The robot performs different tasks by transferring control between the positioner systems through path planning and coordinated control.
[0003] However, current robots often suffer from excessive redundancy in their circuitry, and their control precision is limited during task execution. In the event of a servo drive failure, efficient troubleshooting is difficult, thus limiting the application of robot systems on production lines. Summary of the Invention
[0004] This application provides a robot control system and a robot, which at least helps to improve the robot's control accuracy and fault diagnosis efficiency, and increases the application prospects of the robot system on the production line.
[0005] According to some embodiments of this application, one aspect of this application provides a robot control system, including: a controller, the controller being used to perform drive planning and issue drive tasks according to the results of the drive planning; a servo driver, the servo driver being used to receive the drive tasks and perform servo control on the servo motors according to the drive tasks; and a serial bus, the serial bus being used to connect the controller and the servo driver, enabling the controller and the servo driver to communicate and interact through the serial bus.
[0006] In some embodiments, the servo driver includes a clock module; the output of the clock module is connected to the trigger port of the servo driver and to the hardware trigger pin of the controller, for generating and outputting a synchronous clock signal; the synchronous clock signal is used as a trigger signal for servo control of the servo driver, and is used by the controller to form a soft interrupt as a trigger signal for the controller drive planning.
[0007] In some embodiments, the controller is further configured to send configuration parameters of the servo driver. The serial bus includes a first serial bus and a second serial bus, wherein the transmission speed of the first serial bus is higher than that of the second serial bus. The first serial bus is used for the controller and the servo driver to perform periodic data interaction, including the drive task, according to the synchronization clock signal. The second serial bus is used for the controller to send the configuration parameters to the servo driver.
[0008] In some embodiments, the controller includes a driver layer and an application layer; the driver layer provides a communication interface to the application layer for the application layer to communicate through the communication interface; the application layer calls the communication interface provided by the driver layer to interact with the servo driver through the serial bus, and generates and sends the driver task.
[0009] In some embodiments, the application layer includes a main thread and several sub-threads, wherein the main thread and the sub-threads are respectively bound to different central processing units; the main thread is used to calculate the driving task for the next pulse cycle according to the triggering of the synchronization clock signal and send the driving task to the servo driver through the communication interface provided by the driving layer and the serial bus; the sub-threads are used to send the configuration parameters to the servo driver through the communication interface provided by the driving layer and the serial bus.
[0010] In some embodiments, the servo driver is further configured to perform servo planning for the next pulse cycle based on the driving tasks of the most recent several historical pulse cycles when the driving task for the next pulse cycle has not been received, and to perform servo control based on the servo planning result.
[0011] In some embodiments, the sub-thread is further configured to communicate and interact with external devices through the external interface provided by the driver layer, the external interface including: an industrial Ethernet port or a fieldbus interface.
[0012] In some embodiments, the servo controller is further configured to periodically report the servo control results of the servo motor via the serial bus according to the synchronization clock signal. The controller further includes a cache module; the cache module is configured to cache historical control data, which includes historical servo control results for several pulse cycles uploaded by the servo controller and several historical drive tasks issued by the controller. The historical control data is used for drive fault analysis in the event of a servo motor drive failure.
[0013] In some embodiments, the controller further includes an alarm module; the alarm module is used to compare whether the target servo control result of the drive task issued by the controller is consistent with the actual servo control result uploaded by the servo controller. If the target servo control result and the actual servo control result are inconsistent for multiple consecutive pulse cycles, the alarm module reports a drive error, so that the controller can stop the servo motor according to the drive error instruction.
[0014] According to some embodiments of this application, another aspect of this application provides a robot, including a module for performing the robot control method described in any of the foregoing embodiments.
[0015] The technical solution provided in this application has at least the following advantages:
[0016] The robot control system provided in this application embodiment uses a serial bus to connect the controller and the servo driver, allowing them to communicate and interact. This enables the controller and servo driver to be integrated onto the same circuit board, reducing the robot's circuit redundancy and size, and improving the stability and real-time performance of the robot control system. The controller can perform drive planning based on the task to be executed and issue drive tasks based on the results of the drive planning. The servo driver then performs servo control on the servo motors according to the received drive tasks. This allows the robot's servo control to be achieved collaboratively by the controller and the servo driver, which helps improve the accuracy of servo control and facilitates troubleshooting in the event of a drive failure, thus improving troubleshooting efficiency. Attached Figure Description
[0017] One or more embodiments are illustrated by way of example with reference to the accompanying drawings. These illustrations do not constitute a limitation on the embodiments, and unless otherwise stated, the figures in the drawings are not to be limited by scale.
[0018] Figure 1 This is a schematic diagram of the structure of a robot control system provided in one embodiment of this application;
[0019] Figure 2 This is a schematic diagram of another robot control system provided in an embodiment of this application;
[0020] Figure 3 A schematic diagram of the structure of yet another robot control system is provided as an embodiment of this application;
[0021] Figure 4 This is a schematic diagram of the structure of a controller provided in one embodiment of this application. Detailed Implementation
[0022] As can be seen from the background technology, current robots have a large amount of redundancy in their circuitry, and the efficiency of robot control precision and fault diagnosis needs to be improved.
[0023] This application provides a robot control system that uses a serial bus to connect a controller and a servo driver, allowing them to communicate and interact. This enables the controller and servo driver to be integrated onto the same circuit board, reducing the robot's circuitry redundancy and size, and improving the stability and real-time performance of the robot control system. The controller can perform drive planning based on the task to be executed and issue drive tasks based on the results of the drive planning. The servo driver then adjusts the servo motors according to the received drive tasks, so that the robot's servo control is achieved collaboratively by the controller and the servo driver. This improves the accuracy of servo control and facilitates troubleshooting in the event of a drive failure, thus increasing troubleshooting efficiency.
[0024] The embodiments of this application will now be described in detail with reference to the accompanying drawings. However, those skilled in the art will understand that many technical details have been provided in the embodiments of this application to facilitate a better understanding of the application. However, the technical solutions claimed in this application can be implemented even without these technical details and various variations and modifications based on the following embodiments.
[0025] refer to Figure 1 , Figure 1 This is a schematic diagram of the structure of a robot control system. One embodiment of this application provides a robot control system that can be applied to a robot or to a terminal device that can communicate with the robot. This embodiment of the application is described using an application to a robot as an example.
[0026] The robot control system includes: a controller 101, a servo driver 102, and a serial bus 103.
[0027] The controller 101 is used to perform drive planning for the robot and issue drive tasks based on the results of the drive planning.
[0028] The servo driver 102 is used to receive drive tasks and perform servo control on the servo motor according to the drive tasks.
[0029] The serial bus 103 is used to connect the controller 101 and the servo driver 102, enabling the controller 101 and the servo driver 102 to communicate and interact through the serial bus 103.
[0030] In the process of building a robot control system, the controller and servo driver can be integrated on the same circuit board, and then connected to the controller and servo driver using a serial bus. This allows the controller and servo driver to communicate and interact through the serial bus, eliminating the need for separate configurations of the controller and servo driver. This reduces the redundancy of the wiring caused by separate configurations of the controller and servo driver, thereby reducing uncertainties and external interference from external wiring, improving the stability of the robot control system, and significantly enhancing the real-time performance of the robot control system because the controller and servo driver communicate and interact through the serial bus.
[0031] After the robot receives the task to be executed, the controller can plan the robot's motion path according to the content of the task, and then plan the drive of the servo motors based on the motion path planning results. The servo motors are not included in the... Figure 1 The diagram illustrates a communication connection between the servo motor and the servo driver, allowing the servo motor to operate accurately according to the servo driver's control strategy. After completing the drive planning, the controller can send drive tasks to the servo driver via a serial bus based on the results. Upon receiving the drive task, the servo driver determines the control strategy for the servo motor based on its content and performs accurate servo control according to the determined strategy. The controller sends drive tasks, and the servo driver performs servo control on the servo motor according to the received task. This allows the control of the robot's servo motor to be achieved collaboratively by the controller and the servo driver, realizing integrated drive and control. This facilitates efficient troubleshooting of drive failures in the event of servo drive malfunctions and improves the accuracy of robot servo control.
[0032] refer to Figure 2 , Figure 2 This is a schematic diagram of a robot control system. In some embodiments, the servo driver 102 includes a clock module 121. The output terminal of the clock module 121 is connected to the trigger port of the servo driver 102 and to the hardware trigger pin of the controller 101, for generating and outputting a synchronous clock signal. The synchronous clock signal is used as a trigger signal for servo control of the servo driver 102 and is used by the controller 101 to form a soft interrupt as a trigger signal for drive planning of the controller 101.
[0033] In robot control systems, a crucial factor for improving servo control performance is the synchronization between the controller 101 and the servo driver 102. Poor synchronization between these two systems can lead to delayed servo control responses or incorrect servo motor control, ultimately causing robot malfunctions.
[0034] Therefore, during the construction of the robot control system, a clock module 121 can be set in the servo driver 102. The clock module 121 is used to output a synchronous clock signal, which enables the controller 101 and the servo driver 102 to be triggered synchronously, thereby constructing a drive and control system with high synchronization. Since the servo driver 102 can be triggered directly by the pulse input through the trigger port, while the controller 101 needs to be triggered by a software interrupt, the output of the clock module 121 can be connected to the trigger port of the servo driver 102 and the hardware trigger pin of the controller 101, respectively, to synchronously transmit the generated synchronous clock signal to the trigger port of the servo driver 102 and the hardware trigger pin of the controller 101.
[0035] The servo driver 102 is periodically triggered according to the synchronous clock signal received by the trigger port, receives the drive task and performs servo control on the servo motor according to the received drive task, while the controller 101 converts the received synchronous clock signal into an external event formed by software interrupt through the hardware trigger pin, and selectively triggers the generation and distribution of drive planning and drive tasks according to the synchronous clock signal.
[0036] By using the synchronous clock signal provided by the clock module 121 in the servo driver 102, the servo driver 102 and the controller 101 are triggered, so that the robot control system has good synchronization performance, thereby enabling the robot control system to perform servo control of the servo motor efficiently and accurately, thereby improving the robot's working efficiency.
[0037] Furthermore, this embodiment uses the example of the clock module 121 being located within the servo driver 102. In specific applications, the clock module 121 can also be set up independently or as part of the topology of the controller 101 within its circuit structure. Even when the clock module 121 is located in other positions, its output still needs to be connected to the trigger port of the servo driver 102 and the hardware trigger pin of the controller 101, respectively. The principle of achieving high synchronization between the controller 101 and the servo driver 102 remains the same, and therefore will not be elaborated further here.
[0038] In some embodiments, the controller 101 is also used to send configuration parameters of the servo driver 102. The serial bus 103 includes a first serial bus 131 and a second serial bus 132. The transmission speed of the first serial bus 131 is higher than that of the second serial bus 132. The first serial bus 131 is used for periodic data interaction between the controller 101 and the servo driver 102, including driving tasks, according to a synchronous clock signal. The second serial bus 132 is used for the controller 101 to send configuration parameters to the servo driver 102.
[0039] During the communication between the controller 101 and the servo driver 102 via the serial bus 103, the communication interaction between the controller 101 and the servo driver 102 includes the controller 101 sending configuration parameters to the servo driver 102, the controller 101 sending drive tasks, and the controller 101 uploading servo control results. In other words, the serial bus 103 needs to handle multiple communication tasks. Therefore, to avoid conflicts between communication tasks or resource consumption issues when multiple communication tasks are performed simultaneously, the serial bus 103 can be configured as a combination of a first serial bus 131 and a second serial bus 132.
[0040] The first serial bus 131 serves as a bus for periodic communication between the controller 101 and the servo driver 102 based on a synchronization clock signal. When the controller 101 and the servo driver 102 are triggered according to the synchronization clock signal, within the current pulse cycle of the synchronization clock signal, the first serial bus 131 can transmit the drive task issued by the controller 101 to the servo driver 102, and upload the servo drive result reported by the servo driver 102 from the previous pulse cycle to the controller. The servo drive result may include at least one of the following information: the current position or speed of the servo motor after servo control.
[0041] The second serial bus 132 serves as a bus for configuration parameter exchange between the controller 101 and the servo driver 102. The controller 101 can act as the master station, and the servo driver 102 as the slave station. The controller 101 sends configuration parameters to the servo driver 102 via the second serial bus 132, allowing the servo driver 102 to set accurate configuration parameters. The controller 101 can send configuration parameters before servo motor control, or it can update the servo driver 102's configuration parameters by sending new configuration parameters during control. During servo motor control, the servo driver 102 can also upload its own configuration parameters via the second serial bus 132 for the controller 101 to perform configuration parameter detection or planning.
[0042] Since the amount of data exchanged periodically between the controller 101 and the servo driver 102 is large, and the amount of data sent and updated by the servo driver 102 for configuration parameters is small, in order to reduce the cost of the robot control system, the transmission speed of the first serial bus 131 can be set to a larger value, and the transmission speed of the second serial bus 132 can be set to a smaller value. That is, the transmission speed of the first serial bus 131 is greater than the transmission speed of the second serial bus 132.
[0043] Furthermore, in specific applications, the transmission speed of the first serial bus 131 and the second serial bus 132 can be set to the same value, or the serial bus 103 can be configured as a three-way serial bus, with one serial bus responsible for issuing drive tasks to the controller 101, one serial bus responsible for reporting servo drive results to the servo driver 102, and another serial bus used by the controller 101 to issue configuration parameters to the servo driver 102. This application embodiment does not limit the specific structure and configuration parameters of the serial bus 103.
[0044] refer to Figure 3 , Figure 3 This is a schematic diagram of the structure of a robot control system. In some embodiments, the controller 101 includes a driver layer 111 and an application layer 112; the driver layer 111 is used to provide a communication interface to the application layer 112, so that the application layer 112 can communicate through the communication interface; the application layer 112 is used to call the communication interface provided by the driver layer 111, and interact with the servo driver 102 through the serial bus 103 to generate and send out driving tasks.
[0045] Based on the above analysis, the controller 101 cannot directly use the synchronous clock signal as a trigger signal. Therefore, the controller 101 can be configured to include a driver layer 111 and an application layer 112. The driver layer 111 provides various interfaces, including a communication interface, to the application layer 112, enabling the application layer 112 to effectively control the hardware. The application layer 112 then calls the communication interface provided by the driver layer 111 to interact with the servo driver 102 via the serial bus 103, performs motion planning based on the robot's task, and generates and sends the servo motor drive task. Taking the serial bus interface as an example, the serial bus 103 includes a first serial bus 131 and a second serial bus 132. The driver layer 111 provides the first and second serial bus interfaces to the application layer 112.
[0046] In addition, the driver layer 111 is also used to convert the synchronous clock signal into a soft interrupt, thereby forming an external event to trigger the application layer 112 to periodically perform drive planning and drive task issuance according to the synchronous clock signal, so that the controller 101 and the servo driver 102 can have good synchronization.
[0047] Reference Figure 3 and Figure 4 ,in, Figure 4This is a schematic diagram of the structure of a controller 101. In some embodiments, the application layer 112 includes a main thread 1121 and several sub-threads 1122. The main thread 1121 and the sub-threads 1122 are respectively bound to different central processing units. The main thread 1121 is used to calculate the driving task for the next pulse cycle based on the triggering of the synchronization clock signal, and to send the driving task to the servo driver 102 through the communication interface provided by the driver layer 111 and the serial bus 103. The sub-threads 1122 are used to send configuration parameters to the servo driver 102 through the communication interface provided by the driver layer 111 and the serial bus 103.
[0048] During the configuration of application layer 112, at least one main thread 1121 and at least one sub-thread 1122 can be configured in application layer 112 based on the type or importance of the processed business. For ease of understanding and description, this embodiment of the application uses an example where both the number of main thread 1121 and sub-thread 1122 is 1. In specific applications, the number of main threads 1121 can be 1, 2, or more, and the number of sub-threads 1122 can also be 1, 2, or more. After completing the configuration of main thread 1121 and sub-thread 1122, the main thread 1121 is associated with the interaction between the drive tasks and servo control results of controller 101 and servo driver 102, and the sub-thread 1122 is associated with the interaction between the configuration parameters of controller 101 and servo driver 102.
[0049] During the process of triggering the robot control system by the synchronous clock signal, the main thread 1121 obtains the soft interrupt corresponding to the synchronous clock signal through the interface provided by the driver layer 111. Taking the pulse period of the synchronous clock signal as the period, it periodically calculates the driving task in the next pulse period of the synchronous clock signal, and then sends the driving task to the servo driver through the communication interface provided by the driver layer 111 and the serial bus 103.
[0050] The sub-thread 1122 can establish a communication connection with the servo driver 102 through the communication interface provided by the driver layer 111. Then, before the servo motor is controlled by the servo driver 102, or before the robot performs the current task, the sub-thread 1122 sends configuration parameters to the servo driver 102 through the serial bus 103.
[0051] During the configuration of main thread 1121 and child thread 1122, they can be bound to different CPUs. This means the computing resources used by main thread 1121 and child thread 1122 are independent, minimizing the interference of child thread 1122's resource usage on the running efficiency of main thread 1121. By binding main thread 1121 and child thread 1122 to different CPUs, a core-sharing mechanism ensures that main thread 1121 can utilize sufficient computing resources, reducing the probability that main thread 1121 will fail to determine the driving task in a timely manner due to excessive resource consumption, thus improving the quality of robot servo control.
[0052] Furthermore, when there are multiple sub-threads 1122, these sub-threads 1122 can be bound to one or more different central processing units (CPUs) as needed. During the binding of sub-threads 1122 and the main thread 1121 to the CPU, the main thread 1121 and at least one sub-thread 1122 can also be bound to the same CPU. Then, the priority of the main thread 1121 can be set higher than that of the sub-threads 1122, allowing the main thread 1121 to preferentially access most or all of the CPU's resources. This reduces the number of CPUs required, thereby lowering the cost and size of the robot control system.
[0053] In some embodiments, sub-thread 1122 is also used to communicate and interact with external devices through the external interface provided by driver layer 111. The external interface includes an industrial Ethernet port or a fieldbus interface.
[0054] The driver layer 111 of the controller 101 can not only provide a communication structure for the application layer 112 to periodically communicate and interact with the servo driver 102 through the serial bus 103 according to the synchronous clock signal, but also provide an external interface for communication with external devices. The external interface can be an industrial Ethernet port such as EtherCat, ProfiNet, EtherNet IP or TCP / IP, or a fieldbus serial port such as Modbus, CAN or SPI.
[0055] Sub-thread 1122 can communicate and interact with external devices through an external interface, and can communicate and control external devices by sending control commands to them. This makes the robot control system highly compatible with scheduling in different scenarios and coordination with external devices, thereby improving the adaptability and compatibility of the robot control system with application scenarios.
[0056] In some embodiments, the servo driver 102 is further configured to perform servo planning for the next pulse cycle based on the drive tasks of the most recent several historical pulse cycles when no drive task for the next pulse cycle is received, and to perform servo control based on the servo planning result.
[0057] During the periodic triggering of drive planning by the soft interrupt generated by the controller 101 based on the synchronous clock signal, the controller 101 may encounter situations where the algorithm calculation task for drive planning or drive task generation cannot be completed within one pulse cycle of the synchronous clock signal due to excessive resource overhead or abnormal algorithm operation. That is, the main thread 1121 of the controller 101 cannot complete the drive task calculation task within one pulse cycle, which in turn causes the controller 101 to be unable to send the drive task to be executed in the next pulse cycle to the servo driver 102 through the serial bus 103 in the current pulse cycle.
[0058] Therefore, a preset program can be pre-programmed in the central processing unit of the servo driver 102 to dynamically store the drive tasks and servo motor control results received by the servo driver 102 in several historical pulse cycles closest to the current moment. If the servo driver 102 does not receive a drive task to be executed in the next pulse cycle, it automatically triggers servo control planning and predicts the servo motor control strategy based on the drive tasks or servo motor control structures received in several historical pulse cycles closest to the current moment. For example, based on the servo motor control results corresponding to each drive task in several historical pulse cycles, the position change of the servo motor between adjacent pulse cycles can be determined, or based on the actual position of the servo motor after control in several historical pulse cycles, the position change of the servo motor between adjacent cycles can be obtained. Then, the position changes are arranged in chronological order to calculate the trend of servo motor position changes or the variation law of the difference between adjacent positions. Here, position includes at least one of the servo motor's position, speed, or orientation during the servo control process of the robot control system.
[0059] Then, based on the trend of servo motor position changes or the variation pattern of the difference between positions after adjustment, the servo control of the servo motor in the next pulse cycle is predicted. Based on the prediction results, servo planning for the servo motor in the next pulse cycle is performed, and then the servo motor is controlled within the next pulse cycle based on the servo planning results. In other words, based on the changes in the servo motor position in the few historical pulse cycles closest to the current moment and the changes in the servo motor position between adjacent pulse cycles, the target position of the servo motor after the next pulse cycle is predicted, and servo control of the servo motor in the next pulse cycle is performed based on the prediction results.
[0060] The number of historical pulse cycles used can be 3, 5, or 7, etc. The servo driver 102 dynamically caches the driving tasks and / or servo control structures of the historical pulse cycles. When the cached records reach a preset value, the records of the current pulse cycle are used to overwrite the records of the pulse cycles with the largest time interval from the current moment, thereby reducing the amount of cached data and requirements.
[0061] In some embodiments, the controller 101 further includes an alarm module; the alarm module is used to compare whether the target servo control result of the drive task issued by the controller 101 is consistent with the actual servo control result uploaded by the servo controller 102. If the target servo control result and the actual servo control result are inconsistent for multiple consecutive pulse cycles, the alarm module reports a drive error, so that the controller can stop the servo motor according to the drive error instruction.
[0062] Referring to the above description, during the periodic triggering of drive planning by the controller 101 based on the soft interrupt generated by the synchronization clock signal, the algorithm calculation task for drive planning or drive task generation may not be completed within one pulse cycle of the synchronization clock signal. In the event of such a problem, the controller 101 will discard the calculation result of the current pulse cycle and will not issue the drive task. The servo driver 102 will predict the control of the servo motor based on the servo motor control results of its own cached historical pulse cycles, and perform servo control based on the prediction result.
[0063] After the current pulse cycle ends, the controller 101 will use the servo control results of the servo motor that it has cached as the basis for drive planning in the next pulse cycle. Since the controller 101 discards the drive task of one pulse cycle, the servo control results that it has cached are no longer synchronized with the actual servo control results of the servo controller 102. That is, the servo control results that the controller 101 uses for servo control planning are inconsistent with the actual servo control results of the servo controller 102.
[0064] If the controller 101 can complete the drive planning and drive task issuance within the next pulse cycle, the servo driver 102 will perform servo control according to the drive task issued by the controller 101, thereby resynchronizing the servo control results cached by the controller 101 with the actual servo control results of the servo driver 102.
[0065] If the controller 101 is still unable to complete the drive planning and drive task issuance within the next pulse cycle, the servo driver 102 will continue to predict the servo motor control based on the servo motor control results of its cached historical pulse cycles, and perform servo control according to the prediction results. This causes the error between the servo control results cached by the controller 101 and the actual servo control results of the servo driver 102 to increase. In this case, after a certain number of consecutive pulse cycles in which the controller 101 fails to issue a drive task, the servo control of the servo motor may deviate too much, leading to servo control failure or robot operation failure.
[0066] Therefore, the alarm module of controller 101 compares the target servo control result of the drive task issued by controller 101 with the actual servo control result uploaded by servo controller 102 to see if they are consistent. If controller 101 has not issued a drive task, it can directly determine that the two are inconsistent, or the target servo control result of the previously issued drive task can be used as the target servo control result for the pulse cycle without a drive task. If the target servo control result and the actual servo control result are inconsistent for multiple consecutive pulse cycles, it is determined that there is a significant deviation in servo control. The alarm module directly reports a servo motor drive error to controller 101, and controller 101 stops the servo motor drive by issuing a control command, thus stopping the servo motor.
[0067] By comparing the actual servo control results with the target servo control results, the synchronization of the servo control results cached by the controller 101 with the actual servo control results of the servo driver 102 is detected. If the two are out of sync for multiple consecutive pulse cycles, it is determined that there is a large deviation in the servo control, and the servo motor drive is stopped to avoid servo failure of the robot and damage to the robot, thereby improving safety.
[0068] When a significant deviation in servo control is determined, the number of consecutive pulse cycles can be 3, 5, or 7 pulse cycles, etc. This application does not limit the specific number of consecutive pulse cycles required and can be adjusted according to the application scenario. The consistency between the actual servo control result and the target servo control result means that the deviation between the two is less than or equal to 5%. Due to mechanical reasons, servo control may exhibit certain deviations. Therefore, if the deviation between the actual servo control result and the target servo control result is sufficiently small, they can be considered consistent.
[0069] In some embodiments, the servo controller 102 is further configured to periodically report the servo control results of the servo motor via the serial bus 103 according to the synchronous clock signal. The controller 101 also includes a cache module. The cache module is configured to cache historical control data, which includes historical servo control results of several pulse cycles uploaded by the servo controller 102 and several historical drive tasks issued by the controller 101. The historical control data is used for drive fault analysis in the event of a servo motor drive failure.
[0070] Because the communication data between servo controller 102 and controller 101 is transparent, a black-box mechanism cache module can be set in controller 101. After performing servo control on the servo motor according to the drive task, servo controller 102 periodically reports the servo control result of the current pulse cycle through serial bus 103 according to the synchronous clock signal for storage. When controller 101 issues a drive task, it also caches the issued drive task and, after receiving the servo control result fed back by servo controller 102, stores the two in a correlated manner as historical control data.
[0071] When the cache module caches historical control data, it can use dynamic caching to cache the drive tasks and servo control results of several historical pulse cycles with a time interval within a certain range from the current time. When there is enough cached data, the drive tasks and servo control results of the current pulse cycle can be used to cover the drive tasks and servo control results of the historical pulse cycle with the largest time interval from the current time, thereby reducing the amount of data and the required storage space of the cache module.
[0072] In the event of a drive failure, the data in the cache module can be read, and the drive failure can be analyzed based on the historical control data stored in the cache module, which helps to determine the cause of the servo motor drive failure.
[0073] It should be understood that, for ease of understanding, the above embodiments are detailed descriptions of one or more steps. Furthermore, the above embodiments can be implemented in combination with each other without technical conflict. The specific combination methods will not be elaborated here.
[0074] In summary, the robot control system provided in this application embodiment utilizes a serial bus to connect the controller and servo driver, allowing them to communicate and interact via the serial bus. This enables the controller and servo driver to be integrated onto the same circuit board, reducing the redundancy and size of the robot's wiring, thereby reducing external interference and improving the stability of the robot control system. Utilizing the serial bus for communication also improves the communication efficiency between the controller and servo driver, thus enhancing the real-time performance of the robot control system. The controller can perform drive planning based on the task to be executed and issue drive tasks based on the results of the drive planning. The servo driver then adjusts the servo motors according to the received drive tasks, enabling the robot's servo control to be achieved collaboratively by the controller and servo driver. This improves the accuracy of servo control and facilitates troubleshooting in the event of a drive failure, improving troubleshooting efficiency.
[0075] Accordingly, this application also provides a robot, including a robot control system for performing the robot control system mentioned in the above embodiments.
[0076] Those skilled in the art will understand that the above embodiments are specific examples of implementing this application, and in practical applications, various changes in form and detail can be made without departing from the spirit and scope of this application. Any person skilled in the art can make various alterations and modifications without departing from the spirit and scope of this application; therefore, the scope of protection of this application should be determined by the scope defined in the claims.
Claims
1. A robot control system, characterized in that, include: A controller, which performs drive planning and issues drive tasks based on the results of the drive planning; A servo driver, which receives the driving task and performs servo control on the servo motor according to the driving task; A serial bus, used to connect the controller and the servo driver, enabling the controller and the servo driver to communicate and interact via the serial bus; wherein... The servo driver includes a clock module; the output of the clock module is connected to the trigger port of the servo driver and to the hardware trigger pin of the controller, for generating and outputting a synchronous clock signal; the synchronous clock signal is used as a trigger signal for servo control of the servo driver, and is used by the controller to form a soft interrupt as a trigger signal for the controller's drive planning; the controller performs periodic data interaction, including the drive task, through the serial bus according to the synchronous clock signal. The servo driver is also used to perform servo planning for the next pulse cycle based on the driving tasks of the most recent historical pulse cycles when the driving task for the next pulse cycle has not been received, and to perform servo control based on the servo planning result.
2. The robot control system according to claim 1, characterized in that, The controller is also used to send configuration parameters of the servo driver. The serial bus includes a first serial bus and a second serial bus, and the transmission speed of the first serial bus is higher than that of the second serial bus. The first serial bus is used for the controller and the servo driver to perform periodic data interaction, including the driving task, according to the synchronization clock signal; The second serial bus is used for the controller to send the configuration parameters to the servo driver.
3. The robot control system according to claim 2, characterized in that, The controller includes a driver layer and an application layer; The driver layer is used to provide a communication interface for the application layer to communicate through the communication interface; The application layer is used to call the communication interface provided by the driver layer, interact with the servo driver through the serial bus, and generate and send out the driver task.
4. The robot control system according to claim 3, characterized in that, The application layer includes a main thread and several sub-threads, with the main thread and the sub-threads respectively bound to different central processing units; The main thread is used to calculate the driving task for the next pulse cycle based on the triggering of the synchronization clock signal, and send the driving task to the servo driver through the communication interface provided by the driver layer and the serial bus. The sub-thread is used to send the configuration parameters to the servo driver via the communication interface provided by the driver layer and the serial bus.
5. The robot control system according to claim 4, characterized in that, The sub-thread is also used to communicate and interact with external devices through the external interface provided by the driver layer. The external interface includes an industrial Ethernet port or a fieldbus interface.
6. The robot control system according to claim 1, characterized in that, The servo driver is also used to periodically report the servo control results of the servo motor through the serial bus according to the synchronous clock signal; the controller also includes a cache module. The caching module is used to cache historical control data, which includes historical servo control results for several pulse cycles uploaded by the servo driver and several historical drive tasks issued by the controller. The historical control data is used for drive fault analysis in the event of a servo motor drive failure.
7. The robot control system according to claim 6, characterized in that, The controller also includes an alarm module; The alarm module is used to compare the target servo control result of the drive task issued by the controller with the actual servo control result uploaded by the servo driver. If the target servo control result and the actual servo control result are inconsistent for multiple consecutive pulse cycles, a drive error is reported, and the controller stops the servo motor according to the drive error instruction.
8. A robot, characterized in that, Includes the robot control system as described in any one of claims 1 to 7.
Citation Information
Patent Citations
Driver Circuit for Driving Electromagnetic Actuators
CN104421022A
Serial communication system, communication control unit, and electronic device
US20160140077A1