The content of the invention
It is a primary object of the present invention to provide a kind of robot and its teaching machine communication system and method, to solve controlThe problem of communication efficiency is low between device and teaching machine.
To achieve these goals, according to an aspect of the invention, there is provided a kind of robot demonstrator communication system,The system includes:Teaching machine, for by the instructing combination received into packet send, wherein, instruct for for pairThe instruction that robot is controlled;And controller, it is connected with teaching machine, the packet for receiving teaching machine transmission,The operation of instruction control machine people in packet, wherein, controller includes resolver, and resolver is used to parsePacket, obtains the instruction in packet.
Further, controller also includes:First overtime alert mechanism, is connected with resolver, for controller toTeaching machine starts timing when sending status information, and state is believed if being not received by teaching machine in the first preset timeThe return information of breath, then send overtime prompting, wherein, status information is the status information that robot is run.
Further, teaching machine communication system also includes:Aperiodicity communication agency, is connected with controller and teaching machine,Sent for sending a command to controller by aperiodic traffic thread and receiving controller by aperiodic traffic threadAcyclic status information.
Further, teaching machine communication system also includes:Periodical communication mechanism, is connected with controller and teaching machine,For sending a command to controller by periodic communication thread and receiving the week that controller is sent by periodic communication threadThe status information of phase property.
Further, teaching machine includes:Display screen, the status information sent for display controller to teaching machine.
Further, controller also includes:Server, is connected with resolver, for the data obtained according to resolverThe instruction type of instruction in bag sends instructions to instruction processor structure corresponding with instruction type.
Further, instruction processor structure includes:Configuration-direct processing mechanism, is connected with server, for according to clothesThe configuration-direct that business device is sent performs control;Wherein, configuration-direct is the instruction for being configured to robot system;Command instruction processing mechanism, is connected with server, and the command instruction for being sent according to server performs control, wherein,Command instruction is the instruction being configured for the action to robot.
Further, teaching machine includes:Client, is instructed for being received by user-machine interface, and by instruction groupGenerated data bag is sent to controller.
Further, teaching machine also includes:Second overtime alert mechanism, is connected with client, for teaching machine toController starts timing when sending instruction, if being not received by reply of the controller to instruction in the second preset timeInformation, then send overtime prompting.
To achieve these goals, according to another aspect of the present invention, a kind of robot is additionally provided, the robot bagInclude the robot demonstrator communication system that the present invention is provided.
To achieve these goals, according to another aspect of the present invention, additionally provide a kind of logical for robot demonstratorThe communication means of letter system, this method includes:Received data packet, wherein, packet be instructing combination into packet,Instruct as the instruction being controlled to robot;And the packet received is solved in real time by resolverAnalysis, obtains the instruction in packet.
Further, after the instruction in obtaining packet, this method also includes:Instruction in packetInstruction type sends instructions to instruction processor structure corresponding with instruction type, wherein, instruction type refers to including configurationOrder and command instruction, configuration-direct are the instruction for being configured to robot system, and command instruction is for machineThe instruction that the action of device people is configured.
The present invention is by teaching machine, for the instructing combination received to be sent into packet, wherein, instruct for forThe instruction being controlled to robot;And controller, it is connected with teaching machine, the data for receiving teaching machine transmissionBag, the operation of the instruction control machine people in packet, wherein, controller includes resolver, and resolver is used forPacket is parsed, the instruction in packet is obtained, solves the problem of communication efficiency is low between controller and teaching machine,And then reached the effect for improving communication efficiency between controller and teaching machine.
Embodiment
It should be noted that in the case where not conflicting, the feature in embodiment and embodiment in the application can phaseMutually combination.Describe the present invention in detail below with reference to the accompanying drawings and in conjunction with the embodiments.
In order that those skilled in the art more fully understand application scheme, below in conjunction with the embodiment of the present applicationAccompanying drawing, the technical scheme in the embodiment of the present application is clearly and completely described, it is clear that described embodimentThe only embodiment of the application part, rather than whole embodiments.Based on the embodiment in the application, abilityThe every other embodiment that domain those of ordinary skill is obtained under the premise of creative work is not made, should all belong toThe scope of the application protection.
It should be noted that term " first ", " second " in the description and claims of this application and above-mentioned accompanying drawingEtc. being for distinguishing similar object, without for describing specific order or precedence.It should be appreciated that so makingData can be exchanged in the appropriate case, so as to embodiments herein described herein.In addition, term " comprising "A series of " having " and their any deformation, it is intended that covering is non-exclusive to be included, for example, containing stepsProcess, method, system, product or the equipment of rapid or unit are not necessarily limited to those steps clearly listed or unit,But may include not list clearly or for the intrinsic other steps of these processes, method, product or equipment orUnit.
The embodiments of the invention provide a kind of robot demonstrator communication system.
Fig. 1 is the schematic diagram of robot demonstrator communication system according to a first embodiment of the present invention, as shown in figure 1,The system includes:
Teaching machine 10, for the instructing combination received to be sent into packet.
Teaching machine 10 is robot demonstrator 10, and robot can be industrial robot, wherein, the instruction receivedFor for the instruction being controlled to robot.Instruction can be user by input equipments such as control panels to teaching machine10 be manually entered or inputted to teaching machine 10 by wireless communication interface etc., teaching machine 10 will be receivedThe instructing combination arrived is into packet, and teaching machine 10 can be by way of packing by the instruction group generated data receivedBag, the efficiency of transmission of data can be improved by the way that instructing combination is sent into packet, reduce the data in transmitting procedureLose.Teaching machine 10 sends the instructing combination received to controller 20 into packet.
Controller 20, is connected with teaching machine 10, the packet for receiving the transmission of teaching machine 10, according in packetInstruction control machine people operation.
Controller 20 receives the packet that teaching machine 10 is sent, wherein, controller 20 includes resolver, and resolver is usedIn parsing packet, the instruction in packet is obtained.Resolver is parsed to the packet received, obtains dataCommand information in bag.In the prior art, resolver is operated in teaching machine 10, and teaching machine 10 is time-sharing system,Data processing speed is slow, for example, data processing cycle is usually hundreds of milliseconds;And controller 20 is real-time system,Wherein, real-time system refers to the request of system energy timing respective external event, is completed within the defined time to the eventProcessing, and the system for controlling the harmonious operation of all real-time tasks, in the prior art, the communication system of robotIn system, resolver is operated in the time-sharing system of teaching machine 10, and communication speed is slow.Data in controller 20 updateWith processing faster, for example, the data processing cycle in controller 20 is 2 milliseconds, data processing of data and bottom etc.The contact of mechanism is closer, therefore resolver is operated in controller 20, it is possible to increase the processing speed of data, carriesThe speed sent and received of high data, therefore improve the communication efficiency between controller 20 and teaching machine 10.
Alternatively, controller 20 also includes:Server, is connected with resolver, for the data obtained according to resolverThe instruction type of instruction in bag sends instructions to instruction processor structure corresponding with instruction type.
Controller 20 includes server, and resolver obtains the instruction letter in packet by the resolve packet receivedAfter breath, command information is sent to server, server is analyzed and judged to the command information received, rootAccording to the instruction type in command information, instruction processor structure corresponding with instruction type is sent instructions to, by correspondingInstruction processor structure process instruction.Wherein, instruction type can be divided into two classes, configuration-direct and command instruction.
Alternatively, instruction processor structure includes:Configuration-direct processing mechanism and command instruction processing mechanism, configuration-directProcessing mechanism is connected with server, and the configuration-direct for being sent according to server performs control;Wherein, configuration-directFor for the instruction configured to robot system;Command instruction processing mechanism is connected with server, for according to clothesThe command instruction that business device is sent performs control, wherein, command instruction is the finger being configured for the action to robotOrder.For example, configuration-direct can be the instruction configured to the system of robot, for example, setting robot zero pointPosition, spacing, the instruction of the type such as system error message.Command instruction can be that the action that robot is run is carried outThe instruction of setting, for example, advancing, is retreated, the instruction of the type such as lift hand.The processing configuration of configuration-direct processing mechanism refers toOrder, command instruction processing mechanism processing command instruction, wherein, configuration-direct, which is often set, to be once saved in system,Until before configuration-direct is to the configuration change next time, using always.For example, being set for the dead-center position of robotPostpone, all reset position can be used as using the dead-center position after each robot is out of service.And command instruction often onlyPerform once, do not preserved after execution, for example, sending lift hand command instruction to robot, robot performs lift and made manuallyAfterwards, order terminates, and does not preserve typically.Robot terminates after operation, and command instruction will not be produced to operation next timeInfluence.Instruction handled by configuration-direct processing mechanism and command instruction processing mechanism can also need to carry out according to userAdjustment and set, Fig. 2 is the schematic diagram of command instruction according to embodiments of the present invention and configuration-direct, as shown in Fig. 2For example, the manageable instruction of configuration-direct processing mechanism has robot to configure (Robot Config) instruction, motion controlSystem configuration (CNC Config) instruction and axle configuration (Axis Congifg_01-06) instruction.Command instruction processing mechanismManageable instruction has input/output commands (I/O), system command (pSYS), motion control commands (pCNC)With axle order (pAxis).Server sends instructions to instruction processor structure corresponding with instruction type, by correspondingInstruction processor structure process instruction, it is possible to increase the efficiency of instruction identification and processing, by configuration-direct and command instruction pointOpen, by corresponding instruction processor structure process instruction, robot can be controlled within the shorter time according to instruction operationOr set, improve the efficiency of data processing.
Alternatively, controller 20 also includes:First overtime alert mechanism, is connected with resolver, in controller20 start timing when sending status information to teaching machine 10, if being not received by teaching machine in the first preset timeThe return information of 10 pairs of status informations, then send overtime prompting, wherein, status information is the state letter that robot is runBreath.
In robot running, controller 20 can obtain the running state information of robot, and status information is anti-Teaching machine 10 is fed to, controller 20 sends status information to teaching machine 10.Sent in controller 20 to teaching machine 10During status information, the first overtime alert mechanism starts timing, because teaching machine 10 is when receiving status information, can send outGo out the return information to the status information, therefore, if being not received by returning for teaching machine 10 in the first preset timeComplex information, then send overtime prompting, wherein, it can be polytype prompting that time-out, which is reminded, for example, time-out is remindedIt can be that the mode that sound prompting or signal lamp flash is reminded, can also be display alarm on the display screenThe mode of signal is pointed out.The information being not received by by the first overtime alert mechanism to time-out is reminded, can be rightCommunication failure in transmitting procedure makes prompting in time, facilitates user to be overhauled in time to communication failure, improves workEfficiency.
Alternatively, teaching machine 10 includes:Client, is instructed for being received by user-machine interface, and by instruction groupGenerated data bag is sent to controller 20.
Teaching machine 10 includes client, and client can receive instruction, and instruction then is packaged into packet sends to controlDevice 20 processed, client can be received by user-machine interface and instructed, and user-machine interface can be TIP,Can other kinds of can carry out the input interface of man-machine interaction.
Alternatively, teaching machine 10 includes:Display screen, the state sent for display controller 20 to teaching machine 10Information.For example, the display screen of teaching machine 10 can be the display screen of the client of teaching machine 10, clientThe status information that display screen can send for display controller 20 to teaching machine 10, for example, robot is heldThe status informations such as row forward motion or specially set display robot status information display screen onDisplay.By the status information of the display screen display robot in teaching machine 10 user can be facilitated to understand robotRunning status.
Alternatively, teaching machine 10 also includes:Second overtime alert mechanism, is connected with client, in teaching machine10 start timing when sending and instruct to controller 20, if being not received by 20 pairs of controller in the second preset timeThe return information of instruction, then send overtime prompting.
Teaching machine 10 sends to controller 20 and instructed, and can be the instruction sent in the form of packet, in controllerAfter 20 receive instruction, it can send and reply message to teaching machine 10, the second overtime alert mechanism, in teaching machine 10Start timing when sending and instruct to controller 20, if being not received by 20 pairs of fingers of controller in the second preset timeReplying message for order, then send overtime prompting, the time-out that the second overtime alert mechanism is sent is reminded can be with the first time-outIt is identical that alert mechanism is sent, can also be different, by sending prompting to communication overtime, user can be facilitated right in timeCommunication failure is overhauled, and then improves operating efficiency.
Alternatively, teaching machine communication system also includes:Aperiodicity communication agency, with controller 20 and teaching machine 10Connection, is controlled for sending a command to controller 20 by aperiodic traffic thread and being received by aperiodic traffic threadThe acyclic status information that device 20 processed is sent.
Alternatively, teaching machine communication system also includes:Periodical communication mechanism, connects with controller 20 and teaching machine 10Connect, for sending a command to controller 20 by periodic communication thread and receiving controller by periodic communication threadThe 20 periodic status informations sent.
The aperiodicity communication agency and periodical communication mechanism of teaching machine communication system are separated, and are respectively used to send non-weekPhase property is instructed and periodically instruction, and receives acyclic status information and periodic status information respectively.ItsIn, command instruction is typically cycles per instruction, for example, command instruction is advances, then teaching machine 10 passes through advancement commandsPeriodical communication mechanism is sent to controller, and controller periodically sends advancement commands to robot, for example, oftenAn advancement commands were sent to robot every 0.5 second, so that robot performs forward motion always.Configuration-direct is usualIt is non-cycles per instruction, configuration-direct is sent to controller by aperiodicity communication agency.
In embodiments of the present invention, aperiodicity communication agency and periodical communication mechanism all pass through transmission control protocol(Transmission Control Protocol, referred to as TCP) communicates, and instead of the number of users used in the prior artCommunicated according to datagram protocol (User Datagram Protocol, referred to as UDP), solve controller 20 and teaching machineLoss of data and communication blockage problem when being communicated between 10, it is ensured that the accuracy and security of data transfer.
It can be connected between the teaching machine 10 and controller 20 of robot by netting twine, wireless WIFI can also be passed throughConnection, is realized by Transmission Control Protocol between teaching machine 10 and controller 20 and communicated, resolver operates in controller 20Real-time system in.Transmission Control Protocol not only can by application program to its data be divided into suitable group one by one (namely numberAccording to bag) lower floor is given, and it can confirm the packet that receives, can be by setting timeout clock (namely the first time-outAlert mechanism and the second overtime alert mechanism) confirm whether the data sent are received, therefore Transmission Control Protocol can be withIt is supplied to the data communication of two main frame high reliability of communication.
The embodiment using teaching machine 10 by the instructing combination received into packet send, wherein, instruct for for pairThe instruction that robot is controlled, controller 20 is connected with teaching machine 10, the number for receiving the transmission of teaching machine 10According to bag, the operation for instructing control machine people in packet, wherein, controller 20 includes resolver, resolverFor parsing packet, the instruction in packet is obtained, is communicated so as to solve between controller 20 and teaching machine 10The problem of efficiency is low, and then reached the effect for improving communication efficiency between controller 20 and teaching machine 10.
Fig. 3 is the schematic diagram of robot demonstrator communication system according to a second embodiment of the present invention, and the embodiment can be withAs the preferred embodiment of above-mentioned first embodiment, as shown in figure 3, the system includes:Teaching machine 10 and controller20。
Teaching machine 10 includes client 101 and input interface 102.
Controller 20 includes resolver 201, server 202, configuration-direct processing mechanism 203 and command instruction processingMechanism 204.
In an optional application scenarios, received and instructed by the input interface 102 in teaching machine 10, clientThe instructing combination received is packaged into packet (DataPack) by 101 sends the resolver 201 into controller 20,Resolver 201 is parsed the packet received, obtains the command information in packet, then by command informationBe sent to server 202, server 202 analyze and judge the type instructed in the command information be configuration-direct orCommand instruction, after result is judged, sends command information to corresponding configuration-direct according to the type of instructionMechanism 203 or command instruction processing mechanism 204 are managed, by configuration-direct processing mechanism 203 or command instruction processing mechanism204 pairs of command informations are further processed, and obtaining can be by the command information of machine recognition, and then control machine peopleOperation.By the way that resolver 201 is operated in controller 20, it is possible to increase resolver receives the frequency of instruction, shortenThe cycle of processing data, and then improve the communication efficiency between teaching machine 10 and controller 20.
Preferably, controller 20 is capable of any running state information of read machine people, by status information according to reverse flowJourney feeds back to server 202, and status information is packaged into data by the identification state information of server 202 by resolverBag, then feeds back to teaching machine 10 by packet, and the client of teaching machine 10 will include in client after processing data packetsOn the display screen at end 101, operating personnel are facilitated to grasp the running status of robot.
The embodiment of the present invention additionally provides a kind of communication means for robot demonstrator communication system.
Fig. 4 is the flow chart of the communication means for robot demonstrator communication system according to embodiments of the present invention.Such asShown in Fig. 4, this method comprises the following steps:
Step S102, received data packet.
Packet can be the packet that instruction is combined into, and instruct as the instruction being controlled to robot.InstructionCan user inputted by the panel interface of teaching machine or sent by network interface.Can be by controllingDevice received data packet processed, for example, the resolver received data packet of controller.
Step S104, carries out real time parsing to the packet received by resolver, obtains the instruction in packet.
Resolver carries out real time parsing to the packet received, wherein, real time parsing can be that analytic frequency exceedes in advanceIf the parsing of frequency, for example, the parsing cycle is 2ms, can by the cycle for 2ms parsing as real time parsing, itsIn, resolver is run in the controller, and the data processing in controller faster, contacts closer with bottom, therefore solutionParser can be parsed to the packet received in real time, obtained the instruction in packet, passed through the real-time of resolverParsing, it is possible to increase the efficiency of data processing, and then improve the communication efficiency between teaching machine and controller.
Alternatively, after the instruction in obtaining packet, the instruction type of the instruction in packet, which will be instructed, to be sent outInstruction processor structure corresponding with instruction type is delivered to, wherein, instruction type includes configuration-direct and command instruction, matches somebody with somebodyIt is the instruction for being configured to robot system to put instruction, and command instruction is to be set for the action to robotThe instruction put.
After the instruction in obtaining packet, corresponding instruction processor structure is sent instructions to according to instruction type,It can be that server analysis decision instruction obtains instruction type, then send instructions to corresponding instruction processor structure and enterRow processing.Instruction type can include configuration-direct and command instruction, and configuration-direct can be that the system of robot is enteredThe instruction of row configuration, command instruction can be the instruction that the specific behavior such as action to robot is configured, configurationInstruction includes:Robot configuration (Robot Config) instruction, motion control configuration (CNC Config) instruction (That is CNC configuration-directs) and axle configuration (Axis Congifg_01-06) instruction.Command instruction includes:Input/outputOrder (I/O), system command (pSYS), motion control commands (pCNC, namely CNC orders) and axle order (pAxis).For example, configuration-direct can be the instruction configured to the system of robot, for example, robot dead-center position is set,It is spacing, the instruction of the type such as system error message.Command instruction can be configured to the action that robot is runInstruction, for example, advancing, is retreated, the instruction of the type such as lift hand.Configuration-direct processing mechanism handles configuration-direct, lifeInstruction processor structure is made to handle command instruction, wherein, configuration-direct, which is often set, to be once saved in system, untilBefore configuration-direct is to the configuration change next time, use always, for example, after being set for the dead-center position of robot,All reset position can be used as using the dead-center position after each robot is out of service.And command instruction often only carries out oneIt is secondary, do not preserved after execution, for example, sending lift hand command instruction to robot, robot is performed after the manual work of lift,Order terminates, and does not preserve typically.Robot terminates after operation, and command instruction will not produce influence to operation next time.Server sends configuration-direct to configuration-direct processing mechanism, and command instruction is sent to command instruction processing mechanism.Configuration-direct and command instruction can be adjusted according to actual conditions, for example, can be adjusted and set by softwarePut.
Preferably, timing is started when controller sends status information to teaching machine, if do not had in the first preset timeThere is the return information for receiving teaching machine to status information, then send overtime prompting.Send and refer to controller in teaching machineAfter order, also the return information of instruction is monitored, timing is started when teaching machine sends and instructed to controller, ifReturn information of the controller to instruction is not received by second preset time, overtime prompting is also sent.It is super by settingWhen remind, can occur in communication abnormal or find communication abnormality in time after interrupting, to facilitate operating personnel to tie up in timeRepair, improve the communication efficiency between teaching machine and controller.
In robot running, controller can obtain the running state information of robot, by status information feedbackTo teaching machine, controller sends status information to teaching machine.When controller sends status information to teaching machine, firstOvertime alert mechanism starts timing, because teaching machine is when receiving status information, can send and the status information is returnedComplex information, therefore, if being not received by the return information of teaching machine in the first preset time, sends time-out and carriesWake up, wherein, it can be polytype prompting that time-out, which is reminded, for example, it can be sound prompting that time-out, which is reminded, also may be usedReminded in the way of being signal lamp flicker, can also be that the mode of display alarm signal on the display screen is pointed out.Pass throughThe information that first overtime alert mechanism is not received by time-out is reminded, can be to the communication failure in transmitting procedurePrompting is made in time, facilitates user to be overhauled in time to communication failure, operating efficiency is improved.
Alternatively, after status information of the controller to teaching machine distribution of machine people, status information is shown in display screenOn, can be for display controller to teaching for example, display screen can be the display screen of the client of teaching machineThe status information that device is sent, for example, display robot is carrying out the status informations such as forward motion.By in teaching machineDisplay screen display robot status information can facilitate user understand robot running status.
Alternatively, send a command to controller by aperiodic traffic thread and received by aperiodic traffic thread and controlThe acyclic status information that device processed is sent.Controller is sent a command to and by the cycle by periodic communication threadCommunication thread receives the periodic status information that controller is sent.
By the way that the aperiodicity communication agency and periodical communication mechanism of teaching machine communication system are separated, send non-respectivelyPeriodically instruction and periodically instruction, and acyclic status information and periodic status information are received respectively.Wherein, command instruction is typically cycles per instruction, for example, command instruction is advances, then teaching machine passes through advancement commandsPeriodical communication mechanism is sent to controller, and controller periodically sends advancement commands to robot, for example, oftenAn advancement commands were sent to robot every 0.5 second, so that robot performs forward motion always.Configuration-direct is usualIt is non-cycles per instruction, configuration-direct is sent to controller by aperiodicity communication agency.
The embodiment uses received data packet, then carries out real time parsing to the packet received by resolver, obtainsInstruction into packet, so as to solve the problem of communication efficiency is low between controller and teaching machine, and then reachesImprove the effect of communication efficiency between controller and teaching machine.
It should be noted that can be in such as one group computer executable instructions the step of the flow of accompanying drawing is illustratedPerformed in computer system, and, although logical order is shown in flow charts, but in some cases, canWith with different from the shown or described step of order execution herein.
The embodiment of the present invention additionally provides a kind of robot, and the robot includes the robot demonstrator of the embodiment of the present inventionCommunication system.
Obviously, those skilled in the art should be understood that above-mentioned each module of the invention or each step can be with generalComputing device realize that they can be concentrated on single computing device, or be distributed in multiple computing device institutesOn the network of composition, alternatively, they can be realized with the executable program code of computing device, it is thus possible toIt is stored in storage device by computing device to perform, or they is fabricated to each integrated circuit die respectivelyBlock, or the multiple modules or step in them are fabricated to single integrated circuit module to realize.So, it is of the inventionAny specific hardware and software is not restricted to combine.
The preferred embodiments of the present invention are the foregoing is only, are not intended to limit the invention, for the skill of this areaFor art personnel, the present invention can have various modifications and variations.Within the spirit and principles of the invention, madeAny modification, equivalent substitution and improvements etc., should be included in the scope of the protection.