A kind of implementation method of the open bottom position instruction interface of robot controller
Technical field
The invention belongs to industrial robot control technology fields, specifically relate to a kind of open bottom position of robot controller and refer to
Enable the implementation method of interface.
Background technique
Industrial robot is the jewel on manufacturing industry imperial crown, will be played an important role in the industrial revolution of new generation.For
It gains the initiative in the industrial revolution of new generation, China proposes power's strategy of " intelligence manufacture 2025 ", copes with industrial structure tune
The problems such as whole, high-quality manufacture and aging of population, is to manufacturing industry bring challenge.Especially in Guangdong Province, the Zhejiang Province etc. in China
Manufacturing industry developed regions are proposed " machine substitute human labor " plan one after another, realize manufacturing replacement upgrading, push manufacturing hair
Exhibition.Industrial Robot Technology faces unprecedented policy advantage and the market demand.However, China's Industrial Robot Market quilt
Several big giant's monopolizations such as KUKA, ABB, FANUC, cause the development of native country Robot industry to be had difficulty in taking a step.Also, robot building
Enterprise extremely closes for protection technique and market interest, industrial robot control system, not only increases enterprise development and answers
With cost, the development of Industrial Robot Technology is also limited.
For the open bottom position instruction interface of robot controller to special movement needs are realized, fusion third party is offline certainly
Dynamic programming technique carries out kinematics, trajectory planning algorithm performance comparison is of great significance.However, the machine being commercialized at present
People's control system is all made of the nonshared control unit of enclosed construction, is generally made using special purpose computer as upper layer main control computer
It uses special purpose robot's language as off-line programing tool, is solidificated in EEPROM using special microprocessor, and by control algolithm.
This dedicated system it is difficult to ensure that third-party platform provide position command support.The Rapid Control Prototype Development of Dual such as DSPACE
System, although providing general hardware platform, software still needs to set up from bottom, and time cost cost is high.So
A kind of open robot controller is needed to be capable of providing the support to bottom position instruction.
Summary of the invention
In order to overcome the problems, such as the bottom position instruction interface closing of robot nonshared control unit, the invention proposes one kind
The implementation method of the open bottom position instruction interface of robot controller.Third party's position command can divide from transmission mode
To be online and offline, the instruction of task space pose and joint space position command can be divided into from instruction meaning.It is open
The bottom position instruction interface of robot controller should all support these transmission modes and instruction meaning.
In order to achieve the above objectives, the implementation method of the open bottom position instruction interface of robot controller of the present invention
It mainly comprises the steps that
Third party's task space trajectory plans pose sequence node transmitting data file.
In the pose sequence node write-in memory module RAM/ROM that third-party platform plans task space trajectory, FPGA
In memory interface module the task space pose sequence node in RAM/ROM is read under the action of control bus A
In cache module Block RAM.Control parameter is arranged in host CPU, will be stored in Block RAM by FPGA internal bus A
In pose sequence node read in host CPU inverse kinematics device and carry out inverse kinematics, pose sequence node is turned
Change joint rotation angle sequence into, joint rotation angle sequence is converted into driving joint by the joint space trajectory planning of trajectory planning module
The joint position sequence of rotation, and send the motion control that position control module realizes each joint to.Host CPU passes through FPGA simultaneously
Internal bus A by joint position sequence be written joint position control instruction module, auxiliary CPU can by internal bus B from joint position
It sets and reads current joint position control instruction in control instruction module.
Third party's joint space trajectory planning joint position sequence node transmitting data file.
The discrete joint position sequence of joint space trajectory planning is written in memory module RAM/ROM third-party platform,
Control parameter, the discrete joint position sequence that will be stored in RAM/ROM by the memory interface module in FPGA is arranged in host CPU
Column are read in cache module Block RAM, and host CPU is read in cache module BlockRAM by internal bus A
Discrete joint position sequence, and send the motion control that position control module realizes each joint to.Host CPU passes through FPGA simultaneously
Internal bus A by joint position sequence be written joint position control instruction module, auxiliary CPU can by internal bus B from joint position
It sets and reads current joint position control instruction in control instruction module.
Third party's task space trajectory plans pose sequence node on-line normalization.
Pose sequence node that task space trajectory is planned is entered the cache of FPGA by third-party platform by auxiliary CPU write
In module Block RAM, control parameter is arranged in host CPU, will be stored in the pose in Block RAM by FPGA internal bus A
Sequence node reads in host CPU inverse kinematics device and carries out inverse kinematics, and pose sequence node is converted into joint
Corner sequence, joint rotation angle sequence are converted into the pass of driving articulation by the joint space trajectory planning of trajectory planning module
Position sequence is saved, and sends the motion control that position control module realizes each joint to.Host CPU passes through FPGA internal bus simultaneously
Joint position control instruction module is written in joint position sequence by A, and auxiliary CPU can be referred to by internal bus B from joint position control
It enables and reads current joint position control instruction in module.
Third party's joint space trajectory planning joint position sequence node on-line normalization.
The joint position sequence node of joint space trajectory planning is entered the high speed of FPGA by third-party platform by auxiliary CPU write
In cache module Block RAM, host CPU reads the joint position section in cache module Block RAM by internal bus A
Point sequence, and send the motion control that position control module realizes each joint to.Host CPU will by FPGA internal bus A simultaneously
Joint position control instruction module is written in joint position sequence, and auxiliary CPU can be by internal bus B from joint position control instruction mould
Current joint position control instruction is read in block.
The invention has the following advantages:
Third party's task space trajectory plans pose sequence node transmitting data file and third party's joint space track rule
It draws joint position sequence node transmitting data file and uses file, transfer data to control system memory,
Advantage is that its control process can be defined as to a kind of specific operation functional module, is arbitrarily called by host CPU, opens for product
Hair realizes peculair motion demand;Third party's task space trajectory plans that pose sequence node on-line normalization mode and third party are closed
Section space tracking planning joint position sequence node on-line normalization mode contacts receiving locus data using auxiliary CPU to realize machine
The motion control of people, is mainly used for research work, and different motion model, the comparative study for moving derivation algorithm may be implemented,
It is convenient and efficient.
Detailed description of the invention
Fig. 1 is that bottom position instructs open interface control principle drawing.
Specific embodiment
The invention will be described in further detail with reference to the accompanying drawing:
The open implementation method of robot controller bottom position instruction interface of the present invention mainly includes following step
It is rapid:
Third party's task space trajectory plans pose sequence node transmitting data file.
This mode is mainly used in the transmission of third party's task space trajectory planning off-line data, and third-party platform will
In the pose sequence node write-in memory module RAM/ROM of task space trajectory planning, the memory interface module in FPGA exists
The task space pose sequence node in RAM/ROM is read into cache module Block RAM under the action of control bus A
In.Control parameter is arranged in host CPU, is read the pose sequence node being stored in Block RAM by FPGA internal bus A
Inverse kinematics are carried out in host CPU inverse kinematics device, pose sequence node are converted into joint rotation angle sequence, joint turns
Angle sequence is converted into the joint position sequence of driving articulation by the joint space trajectory planning of trajectory planning module, and passes
Give the motion control that position control module realizes each joint.Host CPU passes through FPGA internal bus A for joint position sequence simultaneously
Joint position control instruction module is written, auxiliary CPU can be read from joint position control instruction module by internal bus B to be worked as
Preceding joint position control instruction.
Third party's joint space trajectory planning joint position sequence node transmitting data file.
This mode is mainly used in the transmission of third party's joint space trajectory planning off-line data.Third-party platform will
In the discrete joint position sequence write-in memory module RAM/ROM of joint space trajectory planning, control parameter is arranged in host CPU, leads to
The memory interface module crossed in FPGA is by the discrete joint position sequence read being stored in RAM/ROM to cache module
In Block RAM, host CPU reads the discrete joint position sequence in cache module Block RAM by internal bus A,
And send the motion control that position control module realizes each joint to.Host CPU passes through FPGA internal bus A for joint position simultaneously
Joint position control instruction module is written in sequence, and auxiliary CPU can be read from joint position control instruction module by internal bus B
To current joint position control instruction.
Third party's task space trajectory plans pose sequence node on-line normalization.
This mode is mainly used in the transmission of third party's task space trajectory planning online data.Third-party platform will
The pose sequence node of task space trajectory planning is entered in the cache module Block RAM of FPGA by auxiliary CPU write, main
Control parameter is arranged in CPU, and the pose sequence node being stored in Block RAM is read host CPU by FPGA internal bus A
Inverse kinematics are carried out in inverse kinematics device, and pose sequence node is converted into joint rotation angle sequence, joint rotation angle sequence
Column are converted into the joint position sequence of driving articulation by the joint space trajectory planning of trajectory planning module, and send to
Position control module realizes the motion control in each joint.Joint position sequence is written by FPGA internal bus A for host CPU simultaneously
Joint position control instruction module, auxiliary CPU can be read from joint position control instruction module current by internal bus B
Joint position control instruction.
Third party's joint space trajectory planning joint position sequence node on-line normalization.
This mode is mainly used in the transmission of third party's joint space trajectory planning online data.Third-party platform will
The joint position sequence node of joint space trajectory planning is entered in the cache module Block RAM of FPGA by auxiliary CPU write,
Host CPU reads the joint position sequence node in cache module Block RAM by internal bus A, and sends position to
Control module realizes the motion control in each joint.By FPGA internal bus A joint is written in joint position sequence by host CPU simultaneously
Position control instruction module, auxiliary CPU can read current joint from joint position control instruction module by internal bus B
Position control instruction.
Embodiment one
With reference to Fig. 1, it is illustrated so that third party's task space trajectory plans pose sequence node transmitting data file as an example.
After carrying out task space trajectory planning in third-party platform, pose sequence node data file is saved as to the text of .bin format
Part is specified track data file download in memory paragraph to the track data in RAM/ROM block by network interface.Host CPU is by setting
The register corresponding positions for setting dma controller are 1, keep dma controller enabled.Dma controller is specified from being stored in RAM/ROM block
Pose sequence node data are read at storage location into cache Block RAM, host CPU passes through internal bus controller A
The pose sequence node in cache Block RAM is read, and is sent to host CPU Inverse Kinematics Solution module, by each of solution
Joint rotation angle sequence is sent to position control module, and position control module realizes that joint trajectories track by PD control.It is main simultaneously
By FPGA internal bus A joint position control instruction module is written in joint position sequence by CPU, and auxiliary CPU can be by internal total
Line B reads current joint position control instruction from joint position control instruction module.
Embodiment two
With reference to Fig. 1, carried out in third party's joint space trajectory planning joint position sequence node on-line normalization mode as an example
Explanation.Third-party platform by the joint position sequence node of joint space trajectory planning by Ethernet interface and udp protocol with
Hexadecimal format is sent to auxiliary CPU, communication speed 1kHz online.Auxiliary CPU receives a frame data and is just written into height
In fast cache module Block RAM, initial address 0x0000.Host CPU reads cache module by internal bus A
Joint position sequence node in Block RAM, and send position control module to, position control module is realized by PD control
Joint trajectories tracking.By FPGA internal bus A joint position control instruction mould is written in joint position sequence by host CPU simultaneously
Block, auxiliary CPU can read current joint position control instruction by internal bus B from joint position control instruction module.