The present disclosure generally relates to robots, and particularly to a robot control method, robot, and a computer-readable storage medium.
Robots have been widely applied in many fields, and the tasks they face no longer require only position control. When performing robot grinding, assembly operations, human body massage, and rehabilitation services, force control and position control of robot are required. The above-mentioned operations often suffer from the problem of unknown working environment. On the one hand, the position information of the surface of the working object relative to the robot is unknown, and the mechanical properties of the working object are unknown, resulting in the inability to achieve effective adjustment of contact force. On the other hand, due to the unknown environment pose in task trajectory planning, it may cause a large contact force error when the planned trajectory cannot adapt to the environment pose.
Many aspects of the present embodiments can be better understood with reference to the following drawings. The components in the drawings are not necessarily drawn to scale, the emphasis instead being placed upon clearly illustrating the principles of the present embodiments. Moreover, in the drawings, all the views are schematic, and like reference numerals designate corresponding parts throughout the several views.
The disclosure is illustrated by way of example and not by way of limitation in the figures of the accompanying drawings, in which like reference numerals indicate similar elements. It should be noted that references to “an” or “one” embodiment in this disclosure are not necessarily to the same embodiment, and such references can mean “at least one” embodiment.
The processor 101 may be an integrated circuit chip with signal processing capability. The processor 101 may be a central processing unit (CPU), a general-purpose processor, a digital signal processor (DSP), an application specific integrated circuit (ASIC), a field-programmable gate array (FPGA), a programmable logic device, a discrete gate, a transistor logic device, or a discrete hardware component. The general-purpose processor may be a microprocessor or any conventional processor or the like. The processor 101 can implement or execute the methods, steps, and logical blocks disclosed in the embodiments of the present disclosure.
The storage 102 may be, but not limited to, a random-access memory (RAM), a read only memory (ROM), a programmable read only memory (PROM), an erasable programmable read-only memory (EPROM), and an electrical erasable programmable read-only memory (EEPROM). The storage 102 may be an internal storage unit of the robot, such as a hard disk or a memory. The storage 102 may also be an external storage device of the robot, such as a plug-in hard disk, a smart memory card (SMC), and a secure digital (SD) card, or any suitable flash cards. Furthermore, the storage 102 may also include both an internal storage unit and an external storage device. The storage 102 is used to store computer programs, other programs, and data required by the robot. The storage 102 can also be used to temporarily store data that have been output or is about to be output.
Exemplarily, the one or more computer programs 103 may be divided into one or more modules/units, and the one or more modules/units are stored in the storage 102 and executable by the processor 101. The one or more modules/units may be a series of computer program instruction segments capable of performing specific functions, and the instruction segments are used to describe the execution process of the one or more computer programs 103 in the robot. For example, the one or more computer programs 103 may be divided into a steady-state establishing module 501, a contact torque acquisition module 502, a rotation control module 503, and a tangential motion control module 504 as shown in
In one embodiment, the robot further includes an end effector 104 and a sensor 105 that are electrically connected to the processor 101.
It should be noted that the block diagram shown in
Referring to
Step S101: Establish a steady state between the end effector and a working surface through a preset impedance control mechanism, and adjusting a contact force between the end effector and the working surface according to a preset desired force.
Referring to FGI. 3, in one embodiment, the estimation of the environment poses and the control of the contact force is implemented on the basis of a position-based impedance control mechanism shown in
Specifically, a reference position of the end effector (denoted as Xr) can be obtained first, and the contact force (denoted as F) between the end effector and the surface of the working environment (hereinafter referred to as “working surface”) is measured by the sensor 105 of the robot. The reference position may be the current actual position of the end effector.
Then, by inputting the contact force into a preset impedance control equation, the position compensation amount of the end effector (denoted as ΔX) can be calculated. The command position (denoted as Xc) of the end effector can be calculated according to the position compensation amount and the reference position, namely: Xc−X, +ΔX.
Then, the command position is input into a preset position servo controller to control the movement of the end effector.
It should be noted that the establishment of a steady state between the end effector and the working surface can be a process of continuous iterative updating, and the above-mentioned steps are only one cycle. The step of obtaining the reference position of the end effector and its subsequent steps may need to be repeatedly executed until the preset steady-state condition is met. The steady-state condition is that the contact force is equal to the desired force (denoted as Fd), that is, F=Fd. The desired force is the adjustment expectation for the contact force, which can be set according to actual needs.
The specific impedance control equation to be used may be set according to actual needs, which is not specifically limited. In one embodiment, the following adaptive impedance control equation can be used: Md({umlaut over (X)}c−{umlaut over (X)}r)+Bd({dot over (X)}c−{dot over (X)}r)=F−Fd, where Md is a preset inertia matrix, Bd is a preset damping matrix, and Fd is the desired force. In this impedance control equation, the stiffness term (denoted as Kd) is set to zero.
Through the above-mentioned impedance control mechanism, the steady state between the end effector and the working surface can be established in the face of any varying environmental stiffness without obtaining an accurate initial position of the working surface.
Step S102: Obtain a contact torque generated by the contact force.
As shown in
Step S103: Control the end effector to rotate according to the contact torque until a pose of the end effector is consistent with a pose of the working surface.
During this process, the end effector can be controlled to rotate to gradually reduce the contact torque. When the contact torque is 0, it can be determined that the pose of the end effector is consistent with the pose of the working surface, as shown in
In one embodiment, the impedance control mechanism can be used to adjust the contact torque, and the contact torque is adjusted according to a preset desired torque. The desired torque is the adjustment expectation for the contact torque, which is set to 0 here. When performing impedance control, it needs to replace the contact force in the impedance control equation with the contact torque, and replace the desired force with the desired torque. When M=0, it can be determined that the pose of the end effector is consistent with the pose of the working surface, thereby completing the estimation of the environment pose.
Step S104: Control the end effector to move tangentially along the working surface.
Specifically, the first coordinates of the trajectory point of the end effector at the next moment may be determined first, and the first coordinates are coordinates in an end coordinate system.
Then, the first coordinates are transformed according to the pose of the end effector to obtain the second coordinates of the trajectory point of the end effector at the next moment, and the second coordinates are coordinates in a base coordinate system. In one embodiment, the second coordinates can be calculated according to the following equation:
where endX
Finally, the end effector can be controlled to move along the tangential direction of the working surface according to the second coordinates. The second coordinates are input into the position servo controller to control the end effector to move tangentially along the working surface, so as to avoid contact force errors caused by the movement direction not conforming to the environment pose.
In summary, according to the method of the above-mentioned embodiments, the following operations are performed: establishing a steady state between the end effector and a working surface through a preset impedance control mechanism, and adjusting a contact force between the end effector and the working surface according to a preset desired force; obtaining a contact torque generated by the contact force; controlling the end effector to rotate according to the contact torque until a pose of the end effector is consistent with a pose of the working surface; and controlling the end effector to move tangentially along the working surface. With the method above, even in the face of an unknown working environment, the contact force can be effectively adjusted, and a task trajectory planning that adapts to the environment pose can be performed, thereby effectively reducing the error of the contact force.
It should be understood that sequence numbers of the foregoing processes do not mean an execution sequence in this embodiment of this disclosure. The execution sequence of the processes should be determined according to functions and internal logic of the processes, and should not be construed as any limitation on the implementation processes of this embodiment of this disclosure.
Corresponding to the robot control method described in the embodiments above,
In one embodiment, the steady-state establishing module 501 may include a contact force measuring unit, a position compensation calculation unit, a command position calculation unit, and a command position input unit. The contact force measuring unit is to obtain a reference position of the end effector, and measure the contact force between the end effector and the working surface through a sensor of the robot. The position compensation calculation unit is to input the contact force into a preset impedance control equation to calculate a position compensation amount for the end effector. The command position calculation unit is to calculate a command position of the end effector according to the position compensation amount and the reference position. The command position input unit is to input the command position into a preset position servo controller to control the movement of the end effector.
In one embodiment, the rotation control module 503 may include a rotation control unit and a pose determination unit. The rotation control unit is to control the end effector to rotate to gradually reduce the contact torque. The pose determination unit is to, in response to the contact torque being equal to 0, determine that the pose of the end effector is consistent with the pose of the working surface.
In one embodiment, the tangential motion control module 504 may include a first coordinate determination unit, a coordinate converting unit, and a tangential motion control unit. The first coordinate determination unit is to determine first coordinates of a trajectory point of the end effector at a next moment. The first coordinates are coordinates in an end coordinate system. The coordinate converting unit is to convert the first coordinates according to the pose of the end effector to obtain second coordinates of the trajectory point of the end effector at the next moment. The second coordinates are coordinates in a base coordinate system. The tangential motion control unit is to control the end effector to move tangentially along the working surface according to the second coordinates.
The coordinate converting unit is to calculate the second coordinates according to the following equation:
where
where endX
In one embodiment, an impedance control equation used in the impedance control mechanism is as follows: Md({umlaut over (X)}c−{umlaut over (X)}r)+Bd({dot over (X)}c−{dot over (X)}r)=F−Fd, where Md is a preset inertia matrix, Bd is a preset damping matrix, Xr is a reference position of the end effector, Xc is a commend position of the end effector, F is the contact force, and Fd is the desired force.
It should be noted that the basic principles and technical effects of the robot control device are the same as the aforementioned method. For a brief description, for parts not mentioned in this device embodiment, reference can be made to corresponding description in the method embodiments.
It should be noted that content such as information exchange between the modules/units and the execution processes thereof is based on the same idea as the method embodiments of the present disclosure, and produces the same technical effects as the method embodiments of the present disclosure. For the specific content, refer to the foregoing description in the method embodiments of the present disclosure. Details are not described herein again.
Another aspect of the present disclosure is directed to a non-transitory computer-readable medium storing instructions which, when executed, cause one or more processors to perform the methods, as discussed above. The computer-readable medium may include volatile or non-volatile, magnetic, semiconductor, tape, optical, removable, non-removable, or other types of computer-readable medium or computer-readable storage devices. For example, the computer-readable medium may be the storage device or the memory module having the computer instructions stored thereon, as disclosed. In some embodiments, the computer-readable medium may be a disc or a flash drive having the computer instructions stored thereon.
It should be understood that the disclosed device and method can also be implemented in other manners. The device embodiments described above are merely illustrative. For example, the flowcharts and block diagrams in the accompanying drawings illustrate the architecture, functionality and operation of possible implementations of the device, method and computer program product according to embodiments of the present disclosure. In this regard, each block in the flowchart or block diagrams may represent a module, segment, or portion of code, which comprises one or more executable instructions for implementing the specified logical function(s). It should also be noted that, in some alternative implementations, the functions noted in the block may occur out of the order noted in the figures. For example, two blocks shown in succession may, in fact, be executed substantially concurrently, or the blocks may sometimes be executed in the reverse order, depending upon the functionality involved. It will also be noted that each block of the block diagrams and/or flowchart illustration, and combinations of blocks in the block diagrams and/or flowchart illustration, can be implemented by special purpose hardware-based systems that perform the specified functions or acts, or combinations of special purpose hardware and computer instructions.
In addition, functional modules in the embodiments of the present disclosure may be integrated into one independent part, or each of the modules may be independent, or two or more modules may be integrated into one independent part. in addition, functional modules in the embodiments of the present disclosure may be integrated into one independent part, or each of the modules may exist alone, or two or more modules may be integrated into one independent part. When the functions are implemented in the form of a software functional unit and sold or used as an independent product, the functions may be stored in a computer-readable storage medium. Based on such an understanding, the technical solutions in the present disclosure essentially, or the part contributing to the prior art, or some of the technical solutions may be implemented in a form of a software product. The computer software product is stored in a storage medium and includes several instructions for instructing a computer device (which may be a personal computer, a server, a network device, or the like) to perform all or some of the steps of the methods described in the embodiments of the present disclosure. The foregoing storage medium includes: any medium that can store program code, such as a USB flash drive, a removable hard disk, a read-only memory (ROM), a random access memory (RAM), a magnetic disk, or an optical disc.
A person skilled in the art can clearly understand that for the purpose of convenient and brief description, for specific working processes of the device, modules and units described above, reference may be made to corresponding processes in the embodiments of the foregoing method, which are not repeated herein.
In the embodiments above, the description of each embodiment has its own emphasis. For parts that are not detailed or described in one embodiment, reference may be made to related descriptions of other embodiments.
A person having ordinary skill in the art may clearly understand that, for the convenience and simplicity of description, the division of the above-mentioned functional units and modules is merely an example for illustration. In actual applications, the above-mentioned functions may be allocated to be performed by different functional units according to requirements, that is, the internal structure of the device may be divided into different functional units or modules to complete all or part of the above-mentioned functions. The functional units and modules in the embodiments may be integrated in one processing unit, or each unit may exist alone physically, or two or more units may be integrated in one unit. The above-mentioned integrated unit may be implemented in the form of hardware or in the form of software functional unit. In addition, the specific name of each functional unit and module is merely for the convenience of distinguishing each other and are not intended to limit the scope of protection of the present disclosure. For the specific operation process of the units and modules in the above-mentioned system, reference may be made to the corresponding processes in the above-mentioned method embodiments, and are not described herein.
A person having ordinary skill in the art may clearly understand that, the exemplificative units and steps described in the embodiments disclosed herein may be implemented through electronic hardware or a combination of computer software and electronic hardware. Whether these functions are implemented through hardware or software depends on the specific application and design constraints of the technical schemes. Those ordinary skilled in the art may implement the described functions in different manners for each particular application, while such implementation should not be considered as beyond the scope of the present disclosure.
In the embodiments provided by the present disclosure, it should be understood that the disclosed apparatus (device)/terminal device and method may be implemented in other manners. For example, the above-mentioned apparatus (device)/terminal device embodiment is merely exemplary. For example, the division of modules or units is merely a logical functional division, and other division manner may be used in actual implementations, that is, multiple units or components may be combined or be integrated into another system, or some of the features may be ignored or not performed. In addition, the shown or discussed mutual coupling may be direct coupling or communication connection, and may also be indirect coupling or communication connection through some interfaces, devices or units, and may also be electrical, mechanical or other forms.
The units described as separate parts may or may not be physically separate, and parts displayed as units may or may not be physical units, may be located in one position, or may be distributed on a plurality of network units. Some or all of the modules may be selected according to actual requirements to achieve the objectives of the solutions of the embodiments.
The functional units and modules in the embodiments may be integrated in one processing unit, or each unit may exist alone physically, or two or more units may be integrated in one unit. The above-mentioned integrated unit may be implemented in the form of hardware or in the form of software functional unit.
When the integrated module/unit is implemented in the form of a software functional unit and is sold or used as an independent product, the integrated module / unit may be stored in a non-transitory computer-readable storage medium. Based on this understanding, all or part of the processes in the method for implementing the above-mentioned embodiments of the present disclosure may also be implemented by instructing relevant hardware through a computer program. The computer program may be stored in a non-transitory computer-readable storage medium, which may implement the steps of each of the above-mentioned method embodiments when executed by a processor. In which, the computer program includes computer program codes which may be the form of source codes, object codes, executable files, certain intermediate, and the like. The computer-readable medium may include any primitive or device capable of carrying the computer program codes, a recording medium, a USB flash drive, a portable hard disk, a magnetic disk, an optical disk, a computer memory, a read-only memory (ROM), a random-access memory (RAM), electric carrier signals, telecommunication signals and software distribution media. It should be noted that the content contained in the computer readable medium may be appropriately increased or decreased according to the requirements of legislation and patent practice in the jurisdiction. For example, in some jurisdictions, according to the legislation and patent practice, a computer readable medium does not include electric carrier signals and telecommunication signals.
The embodiments above are only illustrative for the technical solutions of the present disclosure, rather than limiting the present disclosure. Although the present disclosure is described in detail with reference to the above embodiments, those of ordinary skill in the art should understand that they still can modify the technical solutions described in the foregoing various embodiments, or make equivalent substitutions on partial technical features; however, these modifications or substitutions do not make the nature of the corresponding technical solution depart from the spirit and scope of technical solutions of various embodiments of the present disclosure, and all should be included within the protection scope of the present disclosure.
Number | Date | Country | Kind |
---|---|---|---|
202011416299.0 | Dec 2020 | CN | national |
The present application is a continuation-application of International Application PCT/CN2020/139890, with an international filing date of Dec. 28, 2020, which claims foreign priority of Chinese Patent Application No. 202011416299.0, filed on Dec. 7, 2020 in the China National Intellectual Property Administration, the contents of all of which are hereby incorporated by reference.
Number | Date | Country | |
---|---|---|---|
Parent | PCT/CN2020/139890 | Dec 2020 | US |
Child | 18089614 | US |