CN107544299B - PC (personal computer) end APP (application) system for teaching control of six-degree-of-freedom mechanical arm - Google Patents

PC (personal computer) end APP (application) system for teaching control of six-degree-of-freedom mechanical arm Download PDF

Info

Publication number
CN107544299B
CN107544299B CN201710665060.9A CN201710665060A CN107544299B CN 107544299 B CN107544299 B CN 107544299B CN 201710665060 A CN201710665060 A CN 201710665060A CN 107544299 B CN107544299 B CN 107544299B
Authority
CN
China
Prior art keywords
teaching
mechanical arm
joint
module
track
Prior art date
Legal status (The legal status is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the status listed.)
Active
Application number
CN201710665060.9A
Other languages
Chinese (zh)
Other versions
CN107544299A (en
Inventor
禹鑫燚
陈志南
杨帆
欧林林
张强
Current Assignee (The listed assignees may be inaccurate. Google has not performed a legal analysis and makes no representation or warranty as to the accuracy of the list.)
Zhejiang University of Technology ZJUT
Original Assignee
Zhejiang University of Technology ZJUT
Priority date (The priority date is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the date listed.)
Filing date
Publication date
Application filed by Zhejiang University of Technology ZJUT filed Critical Zhejiang University of Technology ZJUT
Priority to CN201710665060.9A priority Critical patent/CN107544299B/en
Publication of CN107544299A publication Critical patent/CN107544299A/en
Application granted granted Critical
Publication of CN107544299B publication Critical patent/CN107544299B/en
Active legal-status Critical Current
Anticipated expiration legal-status Critical

Links

Images

Abstract

The system comprises a PC end APP system used for teaching control of the six-degree-of-freedom mechanical arm, wherein the PC end APP is installed on a Windows computer of a user; the PC terminal APP system comprises an interactive interface module, an APP main control module, a track optimization module and a control file generation module which are sequentially connected, the control file generation module downloads a control code file to the working mechanical arm through a File Transfer Protocol (FTP), and the working mechanical arm finishes optimized teaching work; the APP main control module is in WiFi communication connection with a data acquisition unit for detecting the motion parameters of the working mechanical arm. The method is used for operation control and parameter setting of the six-degree-of-freedom mechanical arm teaching system, and a user downloads and installs the PC end APP on a computer of a Windows system. The method comprises the steps that a PC terminal APP controls starting and stopping of teaching data acquisition, wirelessly receives angle information from a data acquisition unit, optimizes teaching tracks by combining a forward and reverse kinematics formula and a Cartesian track planning algorithm, and finally generates a control code file for controlling a working mechanical arm to finish optimized teaching operation.

Description

PC (personal computer) end APP (application) system for teaching control of six-degree-of-freedom mechanical arm
Technical Field
The invention relates to a robot arm teaching controller system, in particular to a PC (personal computer) end APP (application) system for teaching control of a six-degree-of-freedom robot arm.
Background
With the widespread use of industrial robots in various industries, it is expected that robots can perform more complex tasks, particularly in industries with complex trajectory planning such as spraying, welding, polishing and grinding, in a simpler manner in a minimum amount of time. At present, the use of industrial robots has a certain distance away from the realization of complete intellectualization, most tasks are completed mainly by means of teaching-reproduction, and how to realize teaching is still an important work before the robot executes processing tasks. Teaching-teaching in reproduction "teaching" is, as its name implies, meant to demonstrate teaching, i.e. that an operator demonstrates with some interaction the actions required when performing a processing task, and records the teaching process in a memory, before the robot performs normal processing. The "playback" is a process reproduction for teaching, and the robot performs a processing operation on a workpiece through a driver and a controller of the robot by using data in a memory and a predetermined conversion. Teaching-reproducing work generally includes teaching the position and posture of a track point, and the speed and acceleration in the motion process.
Most of the traditional industrial teaching systems adopt controller control and APP wired control. The controller is used for teaching the robot, an operator is required to have professional robot operation skills, the specifications of controllers manufactured by different manufacturers are different, the operation training period is long, and the controller is not easy to maintain after being damaged. The wired APP control needs complex wiring work, the length of the connecting wire also limits the space of teaching work, and data confidentiality is not achieved. In addition, a track optimization algorithm is not introduced into the existing controller and control APP, the teaching track executed by the final working mechanical arm is not smooth, the working speed change at the tail end of the mechanical arm is not uniform, and the expected working requirement cannot be met. Most teaching controller systems do not have good human-computer interaction performance, cannot feed back acquired data in real time, and are inconvenient to modify acquisition frequency and axis address, so that users cannot have good operation experience, and a good teaching effect cannot be achieved. Therefore, the whole teaching process needs to be wirelessly controlled by a PC (personal computer) end APP with good interactivity, and the final teaching track can be ensured to be smoother and more stable.
At present, the design aiming at the industrial mechanical arm teaching controller system mainly focuses on the aspects of controller and wired APP design and the like, and researches on the aspects of wireless communication control and teaching track optimization are less. The robot and the teaching communication system thereof are China 205620710[ P ] 2016-01-04, and realize data communication between a teaching collector and a controller, but the communication mode is wired, so that the robot has space limitation and lacks confidentiality; an industrial robot teaching system (Chenxi, Ninghou, Wang Lei, and the like) is provided, wherein the industrial robot teaching system comprises an industrial robot teaching system 104700705[ P ].2015-06-10, can finish teaching acquisition, data communication and teaching control, but does not optimize teaching tracks and cannot meet the requirement of high-precision industrial production; a robot teaching system and a control method thereof are provided (the charles, the Denghao, the little anemone, and the like. the robot teaching system and the control method thereof: China, 105058396[ P ].2015-11-18), the teaching process of the robot is described in detail, but no APP with good interaction performance is designed, and the operation of a user is complicated and inconvenient.
Disclosure of Invention
The invention aims to overcome the defects in the prior art, and provides a PC-end APP system for teaching control of a six-degree-of-freedom mechanical arm.
Firstly, the system has a humanized operation interface, so that different users can conveniently carry out various operations and settings of the teaching process, and various data and parameters are displayed for the users to visually track the whole teaching process; secondly, a Cartesian trajectory planning algorithm is introduced into the system, so that the final teaching trajectory is smoother, and the speed change of the end effector is more uniform; finally, the system can generate a code file for controlling the working mechanical arms to execute the teaching track, and multiple working mechanical arms can execute the teaching operation for unlimited times through once teaching.
The technical scheme adopted by the invention for solving the problems in the prior art is as follows:
a PC end APP system for six degrees of freedom arm teaching control, PC end APP installs on user's Windows computer. The PC side APP system comprises an interactive interface module, an APP main control module, a track optimization module and a control file generation module which are sequentially connected, the control file generation module downloads a control code file to one or more working mechanical arms through a File Transfer Protocol (FTP), and the working mechanical arms complete teaching work after optimization.
The APP main control module is in WiFi communication connection with a data acquisition unit for detecting the motion parameters of the working mechanical arm.
The specific structure of each module is as follows:
the interactive interface module is used for setting and operating the whole teaching system by a user and displaying various relevant parameters and data of the teaching system; through an interactive interface of the PC terminal APP, a user can set an IP address and a network port number of a WiFi hotspot to be connected, forward and reverse calibration of a coder in each joint of the teaching mechanical arm, acquisition frequency of angle data, shaft addresses of each shaft of the teaching mechanical arm, a used mechanical arm model, a download path of a control code file and the like, and the set parameters are transmitted to the APP main control module for processing; the user can also perform operations such as connection and disconnection of WiFi communication, starting and stopping of angle data acquisition, generation of a control code file, query of the ready state of a data acquisition unit, query of the angle data acquisition frequency and period, query of the shaft address of each shaft of the teaching mechanical arm and the like on an interactive interface of the PC terminal APP, and the operation instructions are transmitted to the APP main control module for processing; the interactive interface also displays all settable parameters and acquired angle data, and the parameters and the data are acquired from the APP main control module;
the APP main control module is a communication center and a control center of the APP at the PC end and is used for receiving, transmitting and processing various data, parameters and instructions. The APP main control module can control the PC end APP to establish communication connection with the data acquisition unit through WiFi communication. The parameter setting instruction and the operation instruction can be received from the interactive interface module, the control instruction of the corresponding communication protocol is generated after the processing, and the control instruction is sent to the data acquisition unit through WiFi communication and the simulation module is controlled through network communication. The angle data and the parameter information from the data acquisition unit can be received through WiFi communication, the real-time angle data and the parameter information are transmitted to an interactive interface for display, a motion angle data packet of each joint of the teaching mechanical arm is generated after the teaching is finished (namely after the data acquisition is stopped), and the angle data packet is transmitted to a track optimization module for optimization and is transmitted to a simulation module for simulation through network communication.
The track optimization module receives motion angle data packets of all joints of the teaching mechanical arm from the APP main control module, establishes a Cartesian coordinate system of each rod piece of the mechanical arm at each joint according to a D-H parameter modeling method by combining structural parameters of the currently used mechanical arm model, solves the position and the posture of the end effector relative to a fixed reference coordinate system by using a positive kinematic formula, and obtains a teaching track after solving a plurality of groups of solutions. And then, carrying out track optimization on the teaching track by using a Cartesian track planning algorithm. And finally, solving joint variables of each joint in the joint space of the optimized track by using an inverse kinematics formula and combining structural parameters of the currently used mechanical arm model, so as to obtain the optimized motion angle data packet at each acquisition moment. The angle data packet can be sent to a simulation module for simulation and sent to a control file generation module for control code file generation. The forward and inverse kinematics solution and Cartesian trajectory planning algorithm is as follows:
1) D-H parameters of six joints of the teaching mechanical arm (namely the length a of a connecting rod with the joint 1 being more than or equal to i being less than or equal to 6) are selectediLink corner αiOffset distance d of connecting rodiAnd joint angle thetai) Selecting joint angle theta of each joint of the work robot as input quantityiAs an output.
2) Firstly, a D-H parameter model of the teaching mechanical arm is constructed, and because each rod piece has two actions of rotation and translation relative to a reference coordinate system, a joint coordinate system is established for each rod piece along a joint axis, and the rod piece is described by the following four parameters:
(1) length of connecting rod ai: the length of a common perpendicular line between the joint axis i and the joint axis i + 1;
(2) link corner αi: making a plane perpendicular to the common perpendicular line between the two joint axes, projecting the joint axis i and the joint axis i +1 onto the plane, and winding a on the axis i according to the right hand rule in the planeiThe rotating angle of the steering shaft i +1 is the rotating angle of the connecting rod;
(3) offset distance d of connecting rodi: male vertical line ai-1From the point of intersection with the joint axis i to the common perpendicular aiA directed distance length from an intersection point with the joint axis i + 1;
(4) joint angle thetai:ai-1An extension line ofiThe included angle formed by the rotation around the joint axis i between the two teaching machines is acquiredThe angle of the arm joint.
The parameters of the D-H connecting rod for teaching six joints of the mechanical arm are obtained as shown in a table 1:
table 1 teaching mechanical arm D-H connecting rod parameter table
Joint i Length of connecting rod ai Link corner αi Offset distance d of connecting rodi Joint angle thetai
1 a1 α1 d1 θ1
2 a2 α2 d2 θ2
3 a3 α3 d3 θ3
4 a4 α4 d4 θ4
5 a5 α5 d5 θ5
6 a6 α6 d6 θ6
3) Using the base coordinate system as T0Coordinate system of
Figure BDA0001371508510000053
Representing the position and the posture of the i joint coordinate system relative to the i-1 joint coordinate system, then:
Figure BDA0001371508510000051
wherein, s θi=sinθi,cθi=cosθi,sαi=sinαi,cαi=cosαi
4) For the six-degree-of-freedom mechanical arm, a transformation matrix of the pose of the end effector of the mechanical arm relative to a fixed reference coordinate system (namely the transformation matrix of the coordinates of the position points at the tail end of the mechanical arm) is obtained.
Figure BDA0001371508510000052
5) And obtaining a discrete teaching track formed by the coordinate points of the end effector pose of the teaching arm at each acquisition moment relative to the fixed reference coordinate system after obtaining a transformation matrix of the end effector pose of the teaching arm at each acquisition moment relative to the fixed reference coordinate system.
6) For circular arc position interpolation, p in task space is taken1(x1,y1,z1)、p2(x2,y2,z2) And p3(x3,y3,z3) Three points, the plane equation formed by the three points is:
Ax+By+Cz=1
the values of the plane equation parameters A, B and C can be solved by:
Figure BDA0001371508510000061
7) finding p1p2And p2p3Midpoint p of two line segments12(x12,y12,z12),p23(x23,y23,z23) Let the coordinate of the center of a circle be po(xo,yo,zo) The following equation is satisfied by the center of circle obtained from the plane geometry:
Figure BDA0001371508510000062
and solving to obtain the coordinates of the circle center, wherein a spherical parameter equation with the circle center as the sphere center and r as the radius is as follows:
Figure BDA0001371508510000063
8) substituting the above formula into the plane equation Ax + By + Cz ═ 1 yields:
A(rcosφcosα+xo)+B(rcosφsinα+yo)+C(rsinα+zo)=1
because of the centre p of the circleo(xo,yo,zo) Also on a plane, so:
Arcosφcosα+Brcosφsinα+Crsinα=0
from the above formula, one can understand:
Figure BDA0001371508510000064
the parametric equation for obtaining the spatial circle is thus:
Figure BDA0001371508510000071
9) get vector
Figure BDA0001371508510000072
Is X1Axial vector, normal to the plane, Z1Axial vector, establishing T1Coordinate system, since the attitude transformation matrix is an orthonormal matrix of units, there is Y1=X1×Z1And further Y can be obtained1The axis vector, the attitude transformation matrix R and the translation vector T are as follows:
Figure BDA0001371508510000073
is provided with
Figure BDA0001371508510000074
Then there are:
Figure BDA0001371508510000075
the attitude transformation matrix R and the translation vector T may obtain a coordinate transformation matrix as:
Figure BDA0001371508510000076
10) taking the end locus at T1Position ofThe coordinate is p '(x', y ', z'), and the tail end track at T can be obtained through the attitude transformation matrix and the translation vector0Position p (x, y, z) in (1), i.e.:
[x y z 1]T=Q·[x' y' z' 1]T
at T1In the specification, the arc locus of the independent parameter α is:
Figure BDA0001371508510000081
wherein, α∈ (0, α)max),αmaxIs the arc angle value of the arc.
And (x, y, z) is obtained through transformation after the motion planning is carried out on alpha to obtain a track p '(x', y ', z'), and the track p '(x', y ', z') is the planned track of the circular interpolation.
11) Selecting a required point on the optimized track, and listing a transformation matrix of the pose of the end effector of the teaching arm at the moment relative to a fixed reference coordinate system of each interpolation point p (x, y, z):
Figure BDA0001371508510000082
12) solving for inverse kinematics for each optimized interpolation point p (x, y, z), where r isijTaking the value in the transformation matrix of the terminal coordinate point nearest to the interpolation point, the following can be obtained by solving in sequence:
Figure BDA0001371508510000083
Figure BDA0001371508510000084
Figure BDA0001371508510000085
θ23=A tan2[(-a3-a2c3)pz-(c1px+s1py)(d4-a2s3)
(a2s3-d4)pz-(a3+a2c3)(c1px+s1py)]
θ2=θ233
θ4=A tan2(-r13s1+r23c1,-r13c1c23-r23s1c23+r33s23)
s5=-[r13(c1c23c4+s1s4)+r23(s1c23c4-c1s4)-r33(s23c4)]
c5=r13(-c1s23)+r23(-s1s23)+r33(-c23)
θ5=A tan2(s5,c5)
s6=-r11(c1c23s4-s1c4)-r21(s1c23s4+c1c4)+r31(s23s4)
c6=r11[(c1c23c4+s1s4)c5-c1s23s5]+r21[(s1c23c4-c1s4)c5-s1s23s5]-r31(s23c4c5+c23s5)
θ6=A tan2(s6,c6)
wherein Atan2 is an arctangent function, si=sinθi,ci=cosθi
13) Because each joint angle is calculated by using an inverse trigonometric function, the periodic information of the function is lost, and therefore, after each joint angle is calculated, all possible values need to be found by adding or subtracting 360 degrees to the joint angle within the movable range of each joint, and then a unique reasonable value, namely the value closest to the angle value of the joint at the last moment, is selected from all the possible values by utilizing the continuity principle. And solving each joint angle corresponding to each optimized terminal pose, sorting the angle data packets, sending the angle data packets to a simulation module for simulation, and sending the angle data packets to a control file generation module for control code file generation.
And the simulation module simulates the execution condition of the working track of the working mechanical arm by using RoboDK simulation software. PC end APP can directly transmit the motion angle data packet of each joint of the teaching mechanical arm in the teaching process obtained through collection to the RoboDK through network communication, and the virtual working mechanical arm in the RoboDK software can execute a corresponding teaching motion track. After motion angle data packets of all joints of the teaching mechanical arm in the acquired teaching process are optimized in the track optimization module, the optimized motion angle data packets are transmitted to the RoboDK through network communication, and the virtual working mechanical arm in the RoboDK software can execute the corresponding optimized teaching motion track. And when the optimized teaching motion track executed in the RoboDK software is determined to meet the work requirement, the control file generation module generates a control code file required for controlling the actual working mechanical arm to complete the work.
And the control file generation module is used for generating a control code file required for controlling the actual working mechanical arm to complete the work. The input of the teaching robot is a motion angle data packet obtained by optimizing the motion angle data packet of each joint of the teaching mechanical arm in the acquired teaching process by a track optimization module. If the simulation module confirms the feasibility of the optimization scheme, the control file generation module converts the optimized motion angle data packet into a control code file capable of controlling the actual working mechanical arm to execute work after receiving the optimized motion angle data packet. And downloading the control code file to one or more working mechanical arms through an FTP (file transfer protocol), and finishing the optimized teaching work by the working mechanical arms.
The invention has the advantages and positive effects that:
according to the invention, the PC terminal APP is adopted to control the angle data collector, and compared with the traditional user terminal controller, the PC terminal APP can be installed on a computer of a user, so that the instrument manufacturing cost brought by the user terminal controller is saved; the user terminal controller does not need to worry about mechanical faults caused by the user terminal controller; excessive battery cost is not spent for the user terminal controller; the APP can be upgraded on line, so that a developer can repair problems and upgrade products conveniently; the controller appears in the form of APP, also conforms to the trend of intellectualization of the electric appliance nowadays, and is more easily accepted by users.
Compared with other types of mechanical arm teaching controller systems, the mechanical arm teaching controller system has the advantages of low cost, simple interface, convenience in installation and operation, and can meet the requirements of various different types of users. Compared with the traditional mechanical arm teaching system, the system is operated through a user terminal controller, the teaching track is optimized by using a PC (personal computer) terminal APP and combining a Cartesian track planning algorithm, the informationized interface display is adopted, the system is convenient and fast to operate wirelessly, the key control is simplified, the control code file can be generated by one key, and a user can obtain relatively-datalized parameter information and convenient and easy operation experience. A PC end APP system for teaching control of a six-degree-of-freedom mechanical arm is an excellent choice in the industry of teaching work of the mechanical arm, and is specialized, low in cost, convenient to install, easy to operate, high in universality and the like, so that convenience is brought to all manufacturers and operators.
Drawings
Fig. 1a is a diagram of a WiFi connection operation interface of a PC terminal APP of the present invention.
FIG. 1b is a diagram of a PC side APP arm model selection interface according to the present invention.
FIG. 1c is a diagram of the interface for positive and negative calibration of joint angle of PC end APP.
FIG. 1d is a diagram of a PC side APP axis address setting interface according to the present invention.
Fig. 1e is an interface diagram for setting acquisition frequency of the PC terminal APP of the present invention.
FIG. 1f is an interface diagram of the acquisition of the PC side APP and the generation of the control code of the present invention.
Fig. 1g is a file download setting interface diagram of the PC side APP of the present invention.
Fig. 2 is a control schematic block diagram of the present invention.
Detailed Description
The present invention will be described in further detail with reference to the accompanying drawings.
A PC-end APP system for teaching control of a six-degree-of-freedom mechanical arm is shown in figure 1 in interface composition and comprises a WiFi connection operation interface, a mechanical arm model selection interface, a joint angle positive and negative calibration interface, an axis address setting interface, a collection frequency setting interface, a collection and control code generation interface and a file downloading setting interface. Each interface is used for operation control and parameter setting of the teaching process, and can display corresponding data and parameters.
With reference to fig. 1 and 2, the embodiments of the present invention are as follows:
a user downloads and installs a PC terminal APP on a computer of a Windows system. After the installation is finished, the teaching operation of the six-degree-of-freedom mechanical arm can be carried out.
The PC terminal accesses a WiFi hotspot of the data acquisition unit by using a wireless network connection function; opening a WiFi connection operation interface of the PC side APP on an interactive interface of the PC side APP, setting a local IP address and a port number of the PC side APP, locking the IP address and the port number of the data collector, and clicking an opening button to establish data communication connection; opening a mechanical arm model selection interface of a PC (personal computer) end APP, selecting the currently used mechanical arm model, and acquiring related connecting rod parameters; opening a joint angle positive and negative calibration interface of a PC end APP, calibrating the positive and negative of the joint angle positive and negative calibration interface according to the position posture of an encoder installed in each joint of the mechanical arm, and ensuring that the angle positive change of each encoder is in the same direction; opening an axis address setting interface of a PC (personal computer) end APP, and after clicking a read address button, sending an encoder axis address reading instruction to a data acquisition unit by an APP main control module through WiFi (wireless fidelity) communication, so that the axis addresses of encoders in all joints can be read; the shaft address of the encoder of each joint can be set according to the sequence of each joint of the mechanical arm, so that the encoder angle data of the corresponding joint can be acquired in sequence; opening an acquisition frequency setting interface of the PC terminal APP, and setting acquisition frequency and period of the teaching; the current acquisition frequency and period can also be directly inquired; opening an acquisition and control code generation interface of the PC terminal APP, and sending an acquisition starting instruction to the data acquisition unit through WiFi communication by clicking the APP main control module after sampling is started; and clicking to stop sampling, sending a collection stopping instruction to the data collector by the APP main control module through WiFi communication, and transmitting the stored angle data packet to the track optimization module.
In the acquisition process, the acquired angle data can be directly and synchronously transmitted to the RoboDK simulation software through network communication, so that the virtual working mechanical arm in the RoboDK simulation software can synchronously execute the simulation of the teaching track along with an operator, and the virtual working mechanical arm of the RoboDK simulation software stops executing the teaching track when the acquisition is finished; after the track is optimized, clicking a RoboDK program button generated on a collection and control code generation interface, sending an angle data packet obtained by collection to RoboDK simulation software, simulating the process of the optimized teaching track executed by the working mechanical arm according to the received angle data packet by the RoboDK simulation software, visualizing the track in a curve form, and judging whether the optimized teaching track can be used for the production work of the actual working mechanical arm by a user through observing the condition of the track curve.
After receiving the teaching angle data packet, the track optimization module obtains a teaching track by combining the structural parameters of the currently used mechanical arm model, then performs track optimization on the teaching track by using a Cartesian track planning algorithm, and finally obtains a motion angle data packet optimized at each acquisition moment by combining the structural parameters of the currently used mechanical arm model by using an inverse kinematics formula, wherein the specific steps are as follows:
1) D-H parameters of six joints of the teaching mechanical arm (namely the length a of a connecting rod with the joint 1 being more than or equal to i being less than or equal to 6) are selectediLink corner αiOffset distance d of connecting rodiAnd joint angle thetai) Selecting joint angle theta of each joint of the work robot as input quantityiAs an output quantity;
TABLE 2D-H CONNECTING ROD PARAMETER METER FOR DEMONSTRATING MECHANICAL ARM
Joint i Length of connecting rod ai Link corner αi Offset distance d of connecting rodi Joint angle thetai
1 0 0 0 30°
2 -90° 0 0 -30°
3 0 3 6 -60°
4 -90° 4 8 -90°
5 90° 0 0 60°
6 -90° 0 0 90°
2) Firstly, a D-H parameter model of the teaching mechanical arm is constructed, for example, a PUMA560 robot is taken, and each rod piece has two actions of rotation and translation relative to a reference coordinate system, so that a joint coordinate system is established for each rod piece along a joint axis, and D-H connecting rod parameter tables 2 of six joints of the teaching mechanical arm at the nth acquisition moment are taken;
the position and the posture of the i joint coordinate system relative to the i-1 joint coordinate system
Figure BDA0001371508510000123
Expression (2)
Figure BDA0001371508510000121
And
Figure BDA0001371508510000122
where s θi=sinθi,cθi=cosθi,sαi=sinαi,cαi=cosαiAnd obtaining a transformation matrix of the pose of the teaching mechanical arm end effector at the nth acquisition moment relative to the fixed reference coordinate system as follows:
Figure BDA0001371508510000131
3) can obtain the end execution of the teaching mechanical armThe position coordinate of the device relative to the fixed reference coordinate system at the nth acquisition moment is pn(6.178,10.495,5.5);
After the position coordinates of the end effector of the teaching arm at each acquisition moment relative to the fixed reference coordinate system are obtained in the same manner, a discrete teaching track formed by the position and posture of the end effector of the teaching arm at each acquisition moment relative to the coordinate points of the fixed reference coordinate system can be obtained;
4) for circular arc position interpolation, p in task space is taken1(x1,y1,z1)、p2(x2,y2,z2) And p3(x3,y3,z3) Three points, let p1(2,0,0)、p2(2,2,0) and p3(0,2,0) according to the plane equation composed of three points
Figure BDA0001371508510000132
Obtaining:
A=0,B=0,C=4
from p1p2And p2p3Midpoint p of two line segments12(x12,y12,z12),p23(x23,y23,z23) Can obtain a plane
Internal simultaneous passage of p1、p2And p3Of the unique circle po(xo,yo,zo) And radius r:
Figure BDA0001371508510000133
5) establishing a new coordinate system O 'X' Y 'Z' (namely T) by taking the center of a circle as an origin and referring to the plane where the circle is positioned1): the origin of coordinates is the center p of the circular arco(xo,yo,zo) The normal of the plane is Z 'axis direction, O' p1Is the X 'axis direction, and the Y' axis direction is determined by the right hand rule. It can be seen that the homogeneous transformation matrix from the new coordinates to the base frame is:
Figure BDA0001371508510000141
wherein the content of the first and second substances,
Figure BDA0001371508510000142
6) in the new coordinate system O 'X' Y 'Z', the circular arc trajectory is:
Figure BDA0001371508510000143
wherein, α∈ (0, α)max),αmaxFor the arc angle value of the arc, after obtaining the trajectory p '(x', y ', z'), transform [ x yz 1]T=Q·[x' y' z' 1]TObtaining (x, y, z), namely the planning track after the circular arc optimization;
7) including the starting point and the ending point of the circular arc, four points are uniformly taken as new coordinates of the tail end of the mechanical arm, namely (2,0,0), (2.366,1.366,0), (1.366,2.366), (0,2,0), so that the motion track of the mechanical arm between the four points is smooth and uniform;
similarly, optimizing every three points in the coordinate points of the teaching track into a group, so as to obtain the optimized discrete coordinate points of the teaching track;
8) and performing inverse kinematics solution on each optimized coordinate point p (x, y, z), and listing a transformation matrix of the pose of the end effector of the teaching arm at the moment relative to a fixed reference coordinate system of each point p (x, y, z)
Figure BDA0001371508510000144
Wherein r isijTaking the value in the transformation matrix of the terminal coordinate point nearest to the interpolation point, taking PUMA560 robot as an example, combining the D-H parameters of the working mechanical arm and using the following formula to solve:
Figure BDA0001371508510000145
Figure BDA0001371508510000151
Figure BDA0001371508510000152
θ23=A tan2[(-a3-a2c3)pz-(c1px+s1py)(d4-a2s3)
(a2s3-d4)pz-(a3+a2c3)(c1px+s1py)]
θ2=θ233
θ4=A tan2(-r13s1+r23c1,-r13c1c23-r23s1c23+r33s23)
s5=-[r13(c1c23c4+s1s4)+r23(s1c23c4-c1s4)-r33(s23c4)]
c5=r13(-c1s23)+r23(-s1s23)+r33(-c23)
θ5=A tan2(s5,c5)
s6=-r11(c1c23s4-s1c4)-r21(s1c23s4+c1c4)+r31(s23s4)
c6=r11[(c1c23c4+s1s4)c5-c1s23s5]+r21[(s1c23c4-c1s4)c5-s1s23s5]-r31(s23c4c5+c23s5)
θ6=A tan2(s6,c6)
because each joint angle is calculated by an inverse trigonometric function and the periodic information of the function is lost, after each joint angle is obtained, all possible values are found by adding or subtracting 360 degrees to the joint angle in the movable range of each joint, a unique reasonable value is selected from all the possible values by using the continuity principle, namely the value closest to the angle value of the joint at the last moment, the coordinate of the interpolation point obtained by optimization is p (6.1782,10.4952,5.5), and the transformation matrix of the terminal coordinate point closest to the interpolation point is p (6.1782,10.4952,5.5)
Figure BDA0001371508510000153
And D-H parameters of the work robot are shown in Table 3, the optimum angle (radian system) of each joint of the work robot corresponding to the point p can be obtained as θ1=0.5236,θ2=-0.5236,θ3=-1.0472,θ4=-1.5708,θ5=1.0472,θ6=1.5708;
Table 3 working mechanical arm D-H connecting rod parameter table
Joint i Length of connecting rod ai Link corner αi Offset distance d of connecting rodi Joint angle thetai
1 0 0 0 θ1
2 -90° 0 0 θ2
3 0 3 6 θ3
4 -90° 4 8 θ4
5 90° 0 0 θ5
6 -90° 0 0 θ6
9) Solving each joint angle of the working arm corresponding to each optimized terminal coordinate and posture according to the same principle in the step 8), arranging an angle data packet, sending the angle data packet to a simulation module for simulation, and sending the angle data packet to a control file generation module for control code file generation;
after the user judges that the optimized teaching track can be used in the production work of the actual working mechanical arm, a robot program is generated by clicking on the acquisition and control code generation interface, and a control code file for controlling the working mechanical arm of the corresponding model can be automatically generated; and opening a file downloading setting interface of the PC terminal APP, setting a downloading path of a generated code file for controlling the working mechanical arm with the corresponding model, wherein the control code file is permanently stored in the path, and then a user can transmit the control code file to the mechanical arm with any corresponding model to finish the teaching work content.
Above is entire system's control condition, and PC end APP's interactive interface module lets user's operation become simple and convenient, and the orbit optimization mode lets the teaching orbit more level and smooth, and teaching movement speed changes more evenly, and control file generation module lets the application time of teaching orbit longer more, application object quantity is bigger.
It is emphasized that the examples described herein are illustrative and not restrictive and that this invention includes, without limitation, those examples described herein and other embodiments within the scope of the appended claims.

Claims (2)

1. A PC end APP system for six degrees of freedom arm demonstration control, its characterized in that: the PC end APP is installed on a Windows computer of a user; the PC end APP comprises an interactive interface module, an APP main control module, a track optimization module and a control file generation module which are sequentially connected, the control file generation module downloads a control code file to one or more teaching mechanical arms through a File Transfer Protocol (FTP), and the teaching mechanical arms finish optimized teaching work;
the APP main control module is in communication connection with a data acquisition unit for detecting motion parameter information of the teaching mechanical arm through WiFi;
the specific structure of each module is as follows:
the interactive interface module is used for setting and operating the whole teaching system by a user and displaying various relevant motion parameter information and data of the teaching system; through an interactive interface of a PC (personal computer) end APP, a user can set an IP (Internet protocol) address and a network port number of a WiFi hotspot to be connected, forward and reverse calibration of a coder in each joint of the teaching mechanical arm, acquisition frequency of real-time angle data, shaft addresses of each shaft of the teaching mechanical arm, a model of the used teaching mechanical arm and a download path of a control code file, and the set motion parameter information is transmitted to the APP main control module for processing; the user can also perform WiFi communication connection and disconnection, real-time angle data acquisition starting and stopping, control code file generation, data acquisition unit ready state query, real-time angle data acquisition frequency and period query and teaching mechanical arm axis address query on the interactive interface of the PC side APP, and the operation instructions are transmitted to the APP main control module for processing; the interactive interface also displays all settable motion parameter information and acquired real-time angle data, and the motion parameter information and the data are acquired from the APP main control module;
the APP main control module is a communication center and a control center of the APP at the PC end and is used for receiving, transmitting and processing various data, motion parameter information and instructions; the APP main control module can control the PC end APP to establish communication connection with the data collector through WiFi communication; the motion parameter information setting instruction and the operation instruction can be received from the interactive interface module, the control instruction of the corresponding communication protocol is generated after the motion parameter information setting instruction and the operation instruction are processed, and the control instruction is sent to the data acquisition unit through WiFi communication and the simulation module is controlled through network communication; motion parameter information including real-time angle data from a data acquisition unit can be received through WiFi communication, the motion parameter information including the real-time angle data is transmitted to an interactive interface for display, after teaching is finished, data acquisition is stopped, motion angle data packets of all joints of a teaching mechanical arm are generated, the motion angle data packets are transmitted to a track optimization module for optimization, and the data packets are transmitted to a simulation module through network communication for simulation;
the track optimization module is used for receiving motion angle data packets of all joints of the teaching mechanical arm from the APP main control module, establishing a Cartesian coordinate system of each rod piece of the teaching mechanical arm at each joint according to a D-H parameter modeling method by combining structural parameters of the currently used model of the teaching mechanical arm, solving the position and the posture of the end effector relative to a fixed reference coordinate system by using a positive kinematic formula, and obtaining a teaching track after solving multiple groups of solutions; then, optimizing the teaching track by using a Cartesian track planning algorithm; finally, solving joint variables of all joints in the optimized track by using an inverse kinematics formula in combination with structural parameters of the currently used model of the teaching mechanical arm, so as to obtain a motion angle data packet optimized at each acquisition moment; the motion angle data packet can be sent to a simulation module for simulation and a control code file generation module for control code file generation;
the simulation module simulates the execution condition of the working track of the teaching mechanical arm by using RoboDK simulation software; the PC terminal APP can directly transmit the collected motion angle data packets of each joint of the teaching mechanical arm in the teaching process to the RoboDK through network communication, and a virtual teaching mechanical arm in RoboDK software can execute a corresponding teaching motion track; after motion angle data packets of all joints of the teaching mechanical arm in the acquired teaching process are optimized in the track optimization module, the optimized motion angle data packets are transmitted to the RoboDK through network communication, and the virtual teaching mechanical arm in the RoboDK software can execute the corresponding optimized teaching motion track; when the optimized teaching motion track executed in the RoboDK software is determined to meet the work requirement, a control code file required for controlling the actual teaching mechanical arm to complete the work is generated by a control file generation module;
the control file generation module is used for generating a control code file required for controlling the actual teaching mechanical arm to complete work; the input of the teaching robot is a motion angle data packet obtained by optimizing a motion angle data packet of each joint of the teaching mechanical arm in the acquired teaching process by a track optimization module; if the simulation module confirms the feasibility of the optimization scheme, the control file generation module converts the optimized motion angle data packet into a control code file capable of controlling the actual teaching mechanical arm to execute work after receiving the optimized motion angle data packet; and downloading the control code file to one or more teaching mechanical arms through an FTP (file transfer protocol), and finishing the optimized teaching work by the teaching mechanical arms.
2. The PC-side APP system for six-DOF robot teaching control of claim 1, wherein: after receiving the motion angle data packet from the PC side APP main control module, the track optimization module optimizes a teaching track by combining forward and inverse kinematics solution and a Cartesian track planning algorithm, sends the optimized motion angle data packet to the simulation module for simulation, and sends the optimized motion angle data packet to the control file generation module for control code file generation, wherein the forward and inverse kinematics solution and the Cartesian track planning algorithm are as follows:
2.1) selecting D-H motion parameter information of six joints of the teaching mechanical arm, namely the length a of a connecting rod with the joint 1 more than or equal to i less than or equal to 6iLink corner αiOffset distance d of connecting rodiAnd joint angle thetaiSelecting joint angle theta of each joint of the teaching mechanical arm after track optimization as input quantityiAs an output quantity;
2.2) firstly, constructing a D-H parameter model of the teaching mechanical arm, and establishing a joint coordinate system for each rod piece along a joint axis because each rod piece has two actions of rotation and translation relative to a reference coordinate system, so as to describe the rod piece by using the following four pieces of motion parameter information:
(1) length of connecting rod ai: common perpendicular n between the axis of joint i and the axis of joint i +1iLength of (d);
(2) link corner αi: making a plane perpendicular to the common perpendicular between the axes of the two joints, projecting the axis of joint i and the axis of joint i +1 onto this plane, on the planeThe shaft of the joint i in the plane is turned to the shaft of the joint i +1 around the connecting rod according to the right-hand rule, and the corner of the shaft is the connecting rod corner;
(3) offset distance d of connecting rodi: public vertical line ni-1From the point of intersection with the axis of joint i to the common perpendicular niA directed distance length from an intersection point with the axis of the joint i + 1;
(4) joint angle thetai:ai-1An extension line ofiThe included angle formed by the rotation around the axis of the joint i;
2.3) base coordinate system as T0Coordinate system of
Figure FDA0002581550910000031
Representing the position and the posture of the i joint coordinate system relative to the i-1 joint coordinate system, then:
Figure FDA0002581550910000032
wherein, s θi=sinθi,cθi=cosθi,sαi=sinαi,cαi=cosαi
2.4) for the six-degree-of-freedom mechanical arm, obtaining a transformation matrix for teaching the pose of the end effector of the mechanical arm relative to a fixed reference coordinate system, namely the transformation matrix for teaching the coordinates of the position points at the tail end of the mechanical arm:
Figure FDA0002581550910000033
2.5) obtaining a transformation matrix of the pose of the end effector of the teaching arm at each acquisition moment relative to the fixed reference coordinate system, thus obtaining a discrete teaching track consisting of coordinate points of the pose of the end effector of the teaching arm at each acquisition moment relative to the fixed reference coordinate system;
2.6) using Cartesian arc interpolation method, first taking p in the teaching track1(x1,y1,z1)、p2(x2,y2,z2) And p3(x3,y3,z3) If the three points form a plane equation of Ax + By + Cz equal to 1, the values of the plane equation parameters A, B and C can be solved By the following formula:
Figure FDA0002581550910000041
2.7) finding p1p2And p2p3Midpoint p of two line segments12(x12,y12,z12),p23(x23,y23,z23) Let the coordinate of the center of a circle be po(xo,yo,zo) And solving to obtain the coordinates of the circle center, wherein a spherical parameter equation with the circle center as the sphere center and r as the radius is as follows:
Figure FDA0002581550910000042
2.8) the above formula is substituted into the plane equation Ax + By + Cz ═ 1 to obtain:
A(rcosφcosα+xo)+B(rcosφsinα+yo)+C(rsinα+zo)=1
the parametric equation for obtaining the spatial circle is:
Figure FDA0002581550910000043
2.9) taking the vector
Figure FDA0002581550910000044
Is X1Axial vector, normal to the plane, Z1Axial vector, establishing T1Coordinate system, since the attitude transformation matrix is an orthonormal matrix of units, there is Y1=X1×Z1And further Y can be obtained1The axis vector, the attitude transformation matrix R and the translation vector T are as follows:
Figure FDA0002581550910000051
is provided with
Figure FDA0002581550910000052
Then there are:
Figure FDA0002581550910000053
the attitude transformation matrix R and the translation vector T may obtain a coordinate transformation matrix as:
Figure FDA0002581550910000054
2.10) taking the end trajectory at T1Is p '(x', y ', z'), and the terminal track at T can be obtained by the attitude transformation matrix and the translation vector0The position p (x, y, z) in (1) is a planning track of circular interpolation;
2.11) selecting a needed interpolation point on the optimized track, and listing a transformation matrix of the pose of the end effector of the teaching arm relative to a fixed reference coordinate system at each point p (x, y, z) at the moment:
Figure FDA0002581550910000055
2.12) solving for the inverse kinematics for each optimized interpolation point p (x, y, z), where rijTaking the value in the transformation matrix of the terminal coordinate point nearest to the interpolation point, the following can be obtained by solving in sequence:
Figure FDA0002581550910000056
Figure FDA0002581550910000057
Figure FDA0002581550910000061
θ23=A tan 2[(-a3-a2c3)pz-(c1px+s1py)(d4-a2s3)
(a2s3-d4)pz-(a3+a2c3)(c1px+s1py)]
θ2=θ233
θ4=A tan 2(-r13s1+r23c1,-r13c1c23-r23s1c23+r33s23)
s5=-[r13(c1c23c4+s1s4)+r23(s1c23c4-c1s4)-r33(s23c4)]
c5=r13(-c1s23)+r23(-s1s23)+r33(-c23)
θ5=A tan 2(s5,c5)
s6=-r11(c1c23s4-s1c4)-r21(s1c23s4+c1c4)+r31(s23s4)
c6=r11[(c1c23c4+s1s4)c5-c1s23s5]+r21[(s1c23c4-c1s4)c5-s1s23s5]-r31(s23c4c5+c23s5)
θ6=A tan 2(s6,c6)
wherein A tan2 is an arc tangent function, si=sinθi,ci=cosθi
2.13) after the angle of each joint is solved, then all possible values are found out by adding or subtracting 360 degrees to the angle of the joint in the movable range of each joint, and then a unique reasonable value is selected from all the possible values by utilizing the continuity principle, namely the value closest to the angle value of the joint at the last moment; and solving each joint angle corresponding to each optimized terminal pose, arranging the joint angles into a motion angle data packet, sending the motion angle data packet to the simulation module for simulation, and sending the motion angle data packet to the control file generation module for control code file generation.
CN201710665060.9A 2017-08-07 2017-08-07 PC (personal computer) end APP (application) system for teaching control of six-degree-of-freedom mechanical arm Active CN107544299B (en)

Priority Applications (1)

Application Number Priority Date Filing Date Title
CN201710665060.9A CN107544299B (en) 2017-08-07 2017-08-07 PC (personal computer) end APP (application) system for teaching control of six-degree-of-freedom mechanical arm

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
CN201710665060.9A CN107544299B (en) 2017-08-07 2017-08-07 PC (personal computer) end APP (application) system for teaching control of six-degree-of-freedom mechanical arm

Publications (2)

Publication Number Publication Date
CN107544299A CN107544299A (en) 2018-01-05
CN107544299B true CN107544299B (en) 2020-10-09

Family

ID=60970650

Family Applications (1)

Application Number Title Priority Date Filing Date
CN201710665060.9A Active CN107544299B (en) 2017-08-07 2017-08-07 PC (personal computer) end APP (application) system for teaching control of six-degree-of-freedom mechanical arm

Country Status (1)

Country Link
CN (1) CN107544299B (en)

Families Citing this family (7)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN108340352A (en) * 2018-02-09 2018-07-31 巨轮中德机器人智能制造有限公司 The long-range real-time control method of industrial robot based on teaching joint arm
CN108453707B (en) * 2018-04-12 2021-11-19 珞石(山东)智能科技有限公司 Robot dragging teaching track generation method
CN109048894A (en) * 2018-08-07 2018-12-21 中铁工程机械研究设计院有限公司 A kind of 3D analogue system of the excavation robot remotely operated
CN109773756A (en) * 2019-02-20 2019-05-21 苏州科技大学 A kind of Multi-freedom-degreemanipulator manipulator and control method
CN112045664A (en) * 2019-06-06 2020-12-08 南京理工大学 General mechanical arm controller based on ROS system
CN110293539B (en) * 2019-06-24 2022-09-30 佛山智异科技开发有限公司 Method and device for realizing software architecture of industrial robot demonstrator and demonstrator
CN111474866B (en) * 2020-04-07 2023-11-10 杭州迅蚁网络科技有限公司 Unmanned warehouse station motion control simulation method and system based on ROS

Citations (7)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN102825604A (en) * 2012-09-18 2012-12-19 广西玉林正方机械有限公司 Motion control programming system of six-DOF (degree of freedom) robot
CN103576614A (en) * 2013-11-13 2014-02-12 东华大学 Multi-axis motion control system
CN103926847A (en) * 2014-05-04 2014-07-16 威海正棋机电技术有限公司 Robot simulation system
CN105922257A (en) * 2016-04-28 2016-09-07 纳博特南京科技有限公司 Robot teaching system based on mobile electronic equipment
CN105955206A (en) * 2016-05-26 2016-09-21 东华大学 Multi-shaft motion control method based on data driving and parameter mixing optimization
CN106346484A (en) * 2015-07-17 2017-01-25 发那科株式会社 Teaching operation supporting apparatus for robot motion, and teaching operation supporting method
CN106483885A (en) * 2016-11-24 2017-03-08 南京熊猫电子股份有限公司 A kind of PC tool system based on robot

Family Cites Families (1)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
US20160274787A1 (en) * 2015-03-19 2016-09-22 Denso Wave Incorporated Apparatus for operating robots

Patent Citations (7)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN102825604A (en) * 2012-09-18 2012-12-19 广西玉林正方机械有限公司 Motion control programming system of six-DOF (degree of freedom) robot
CN103576614A (en) * 2013-11-13 2014-02-12 东华大学 Multi-axis motion control system
CN103926847A (en) * 2014-05-04 2014-07-16 威海正棋机电技术有限公司 Robot simulation system
CN106346484A (en) * 2015-07-17 2017-01-25 发那科株式会社 Teaching operation supporting apparatus for robot motion, and teaching operation supporting method
CN105922257A (en) * 2016-04-28 2016-09-07 纳博特南京科技有限公司 Robot teaching system based on mobile electronic equipment
CN105955206A (en) * 2016-05-26 2016-09-21 东华大学 Multi-shaft motion control method based on data driving and parameter mixing optimization
CN106483885A (en) * 2016-11-24 2017-03-08 南京熊猫电子股份有限公司 A kind of PC tool system based on robot

Also Published As

Publication number Publication date
CN107544299A (en) 2018-01-05

Similar Documents

Publication Publication Date Title
CN107544299B (en) PC (personal computer) end APP (application) system for teaching control of six-degree-of-freedom mechanical arm
CN107363812B (en) Wireless control six-degree-of-freedom mechanical arm demonstration system
CN107932504B (en) PyQt-based mechanical arm operation control system
CN107901039B (en) Python-based desktop-level robot offline programming simulation system
US9311608B2 (en) Teaching system and teaching method
CN106502095B (en) A kind of cooperative control method of more industrial robots
CN111381815B (en) Offline programming post code conversion method and dual-robot cooperative intelligent manufacturing system and method based on same
CN104552300B (en) A kind of off-line programing teaching apparatus based on teaching robot and method
JP7439206B2 (en) Information processing methods, information processing devices, programs, recording media, production systems, robot systems, article manufacturing methods
CN107838922B (en) Robot repetition-free teaching method
CN107309884B (en) Robot calibration system and method
CN109531577B (en) Mechanical arm calibration method, device, system, medium, controller and mechanical arm
CN112873204B (en) Robot calibration method, device, equipment and computer readable storage medium
KR101876845B1 (en) Robot control apparatus
CN108568816B (en) Method for controlling an automated work unit
CN111797521A (en) Three-dimensional simulation debugging and monitoring method for automatic production line
CN111775145A (en) Control system of series-parallel robot
JP2021045797A (en) Simulation device, simulation program, and simulation method
JP2018051647A (en) Robot control device, robot and robot system
Diachenko et al. Industrial collaborative robot Digital Twin integration and control using Robot Operating System
CN106881717B (en) A kind of surface of robot spacing follows method for paint spraying
Arnarson et al. The application of virtual reality in programming of a manufacturing cell
CN109664273B (en) Industrial robot cursor dragging teaching method and system
Kuts et al. Digital Twin: Universal User Interface for Online Management of the Manufacturing System
CN112720502A (en) Control method of single-multi-axis manipulator

Legal Events

Date Code Title Description
PB01 Publication
PB01 Publication
SE01 Entry into force of request for substantive examination
SE01 Entry into force of request for substantive examination
GR01 Patent grant
GR01 Patent grant