Disclosure of Invention
In view of the above, it is necessary to provide a vision measuring and positioning system, a vision measuring and positioning method, and a storage device capable of accurately positioning an assembly or machining position of an obliquely placed workpiece to solve the above problems.
A vision measuring and positioning system for use with a vision measuring and positioning device, the vision measuring and positioning device comprising:
the material loading jig is used for fixing the workpiece and adjusting the position and the inclination angle of the workpiece;
a manipulator;
the camera is arranged on the manipulator;
a processor adapted to implement instructions;
the storage device is suitable for storing a plurality of instructions, the length of each pixel point of the picture shot by the camera is lambda, and the instructions are suitable for being loaded and executed by the processor:
controlling the loading jig to rotate the workpiece placed at the inclined preset angle alpha around a central shaft K so as to enable the workpiece to be placed horizontally;
controlling the manipulator to drive the camera to move to a position where a central shaft of a workpiece has a preset distance H, wherein the central shaft K is perpendicular to an optical center of the camera and a plane where a machining or assembling position point of the workpiece is located;
controlling the camera to take pictures of the horizontally placed workpieces and transmitting the pictures to the processor and the storage equipment;
and calculating the space coordinate of the processing or assembling position point of the obliquely placed workpiece relative to the optical center of the camera according to the shot picture and the preset angle alpha.
A vision measurement positioning method, comprising:
controlling a material loading jig to rotate a workpiece placed at an inclined preset angle alpha around a central shaft K so as to enable the workpiece to be placed horizontally;
controlling a manipulator to drive a camera to move to a position with a preset distance H from a central shaft of a workpiece, wherein the central shaft is perpendicular to an optical center of the camera and a plane where a machining or assembling position point of the workpiece is located;
controlling the camera to take pictures of the horizontally placed workpieces and transmitting the pictures to the processor and the storage equipment;
and calculating the space coordinate of the processing or assembling position point of the obliquely placed workpiece relative to the optical center of the camera according to the shot picture and the preset angle alpha.
A storage device storing a plurality of instructions adapted to be loaded and executed by a processor:
controlling a material loading jig to rotate a workpiece placed at an inclined preset angle alpha around a central shaft so as to enable the workpiece to be placed horizontally;
controlling a manipulator to drive a camera to move to a position which is away from a central shaft of a workpiece by a preset distance H, wherein the central shaft is perpendicular to an optical center of the camera and a plane where a machining or assembling position point of the workpiece is located;
controlling the camera to take pictures of the horizontally placed workpieces and transmitting the pictures to the processor and the storage equipment;
and calculating the space coordinate of the processing or assembling position point of the obliquely placed workpiece relative to the optical center of the camera according to the shot picture and the preset angle alpha.
According to the vision measurement positioning system, the vision measurement positioning method and the storage device, the camera is controlled to shoot the picture of the workpiece, and the spatial coordinate of the processing or assembling position point of the workpiece relative to the optical center of the camera is calculated according to the shot picture, so that the processing or assembling position point of the workpiece which is obliquely arranged is positioned, the operation is simple, and the positioning efficiency is improved.
Detailed Description
The technical solutions in the embodiments of the present invention will be clearly and completely described below with reference to the drawings in the embodiments of the present invention, and it is obvious that the described embodiments are only a part of the embodiments of the present invention, and not all of the embodiments. All other embodiments, which can be derived by a person skilled in the art from the embodiments given herein without making any creative effort, shall fall within the protection scope of the present invention.
It will be understood that when an element or component is referred to as being "connected" to another element or component, it can be directly connected to the other element or component or intervening elements or components may also be present. When an element or component is referred to as being "disposed on" another element or component, it can be directly on the other element or component or intervening elements or components may also be present.
Unless defined otherwise, all technical and scientific terms used herein have the same meaning as commonly understood by one of ordinary skill in the art to which this invention belongs. The terminology used in the description of the invention herein is for the purpose of describing particular embodiments only and is not intended to be limiting of the invention. As used herein, the term "and/or" includes any and all combinations of one or more of the associated listed items.
Referring to fig. 1 and fig. 3, fig. 1 is a schematic diagram of a vision measuring and positioning apparatus 100 according to an embodiment of the present invention. The vision measuring and positioning device 100 is used to measure and position a machining or assembling position point a of an obliquely placed workpiece 300. The vision measuring and positioning device 100 comprises a processor 10, a storage device 20, a loading jig 30, a manipulator 40, a camera 50, a tool 60 and a display 70. The storage device 20, the loading jig 30, the manipulator 40, the camera 50, the tool 60 and the display 70 are electrically connected with the processor 10.
The processor 10 may be a central processing unit, a digital signal processor, or a single chip, etc. The processor 10 is used for processing related data and sending a plurality of instructions.
The storage device 20 is capable of storing associated data and a plurality of instructions adapted to be loaded and executed by the processor 10. The storage device 20 also stores a preset distance H from the optical center O of the camera 50 to the central axis K of the workpiece 300 and a length λ of each pixel point of a picture taken by the camera 50.
It is understood that the storage device 20 may be a hard disk, a U disk, a random access memory, or the like.
In at least one embodiment, the storage device 20 may be an internal storage system, such as a flash memory, a random access memory RAM, a readable memory ROM, and the like.
In at least one embodiment, the storage device 20 may also be a storage system, such as a video disc, a memory card, or a data storage medium. The storage device 20 may also include unstable or stable storage devices.
In at least one embodiment, the storage device 20 includes two or more storage devices, for example, one of the storage devices is a memory and the other of the storage devices is a drive. Furthermore, the storage device 20 may also be wholly or partially independent of the vision measurement positioning apparatus 100.
The loading fixture 30 is used for fixing the workpiece 300 and adjusting the position and the inclination angle of the workpiece 300. The loading jig 30 includes a movable driving member 31, a rotary driving member 32, a supporting frame 33, a rotary driving member 34, a rotating shaft 35, a fixing frame 36, a fixing plate 37 and a pressing member 38. The rotary driving member 32 is disposed on the movable driving member 31 and moves under the driving of the movable driving member 31. The support bracket 33 is disposed on the rotary driving member 32 and rotates under the action of the rotary driving member 32. The rotary driving member 34 is disposed on the supporting frame 33. The rotating shaft 35 is rotatably disposed on the supporting frame 33 and connected to the rotating driving member 34. The fixing frame 36 is disposed on the rotating shaft 35. The fixing plate 37 is disposed on the fixing frame 36 to place the workpiece 300. The pressing member 38 is provided on the fixing plate 37 to press and fix the workpiece 300 positioned on the fixing plate 37. The rotary shaft 35 is parallel to the central axis K of the workpiece 300 and is rotated by the rotary drive 34 to adjust the tilt angle of the workpiece 300.
The manipulator 40 is used for driving the camera 50 and the tool 60 to move. In this embodiment, the robot 40 is a six-axis robot.
The camera 50 is provided on the robot 40 and moves by being driven by the robot 40. The camera 50 is used for taking pictures of the workpiece to realize the positioning of the machining or assembling position point a of the workpiece. In this embodiment, the camera 50 is provided with a light source 51. The light source 51 can provide light to the camera 50 so that the camera 50 can take a clear picture. The camera 50 is a CCD image sensor, but is not limited thereto.
The tool 60 is provided on the robot 40 and moves by the robot 40. The tool 60 is used to perform a machining or assembly process on a machining or assembly site a of the workpiece 300.
The display 70 displays a picture taken by the camera 50 and coordinate information of the machining or assembling position point a of the workpiece 300 in real time.
Referring to fig. 2, fig. 2 is a block diagram of a vision measuring and positioning system 200 according to an embodiment of the invention. The vision measuring and positioning system 200 is applied to the vision measuring and positioning device 100. The vision measurement positioning system 200 includes a loading control module 210, a robot control module 220, a camera control module 230, a measurement positioning module 240, and a tool control module 250. In one embodiment, the loading control module 210, the robot control module 220, the camera control module 230, the measurement positioning module 240, and the tool control module 250 are a series of computer program instruction segments stored in the storage device 20 of the vision measurement positioning apparatus 100 that can be executed by the processor 10 of the vision measurement positioning apparatus 100 and can perform a fixed function. In other embodiments, the loading control module 210, the robot control module 220, the camera control module 230, the measurement positioning module 240, and the tool control module 250 of the vision measurement positioning system 200 may also be hardware units that are fixed to the processor 10, such as firmware fixed to the processor 10.
The loading control module 210 is used for controlling the loading fixture 30 to fix the workpiece 300 and adjusting the position and the inclination angle of the workpiece 300.
The robot control module 220 is used for controlling the robot 40 to drive the camera 50 and the tool 60 to move.
The camera control module 230 is used for controlling the camera 50 to take pictures of the workpiece on the loading jig 30, transmitting the pictures to the processor 10 and the storage device 20, and controlling the light source 51 to provide light for the camera 50.
The measurement positioning module 240 is used for measuring and calculating the spatial coordinates of the processing or assembling position point a of the workpiece 300 relative to the optical center O (shown in fig. 3) of the camera 50 according to the shot pictures.
Specifically, the measurement positioning module 240 calculates the number N of pixel points from the processing or assembling position point a of the workpiece 300 to the central axis K of the workpiece 300 in the photograph taken of the horizontally placed workpiece 300 according to the taken photograph, calculates the actual distance from the processing or assembling position point a of the workpiece 300 to the central axis K of the workpiece 300 according to the number N, and calculates the spatial coordinates (0, cos α N λ, H + sin α N λ) of the processing or assembling position point a of the workpiece 300 with the optical center O as the origin according to the preset inclination angle α of the workpiece 300.
The tool control module 250 is used to control the tool 60 to process the machining or assembly site a of the workpiece 300.
Please refer to fig. 4, which is a flowchart illustrating a vision measuring and positioning method applied to the vision measuring and positioning system 200 using the vision measuring and positioning apparatus 100 according to an embodiment of the present invention. The visual measurement positioning method is only an example, as there are many ways to implement the method. Referring to fig. 1 to 4, the following method for positioning a vision measurement can be performed by the modules shown in fig. 1 to 2. One or more steps, methods or sub-flows, etc., represented by each block in fig. 4 are performed by an example method. The visual measurement positioning method for positioning the machining or assembling position point a of the workpiece 300 placed obliquely by using the visual measurement positioning system 200 includes the following steps:
s101: the loading jig 30 is controlled to rotate the workpiece 300 placed with the inclined preset angle α around the central axis K so that the workpiece 300 is horizontally placed.
Specifically, the loading control module 210 controls the rotary driving element 34 of the loading jig 30 to drive the rotary shaft 35 to rotate so that the workpiece 300 on the fixing plate 37 is horizontally placed.
S102: the control robot 40 drives the camera 50 to move to a position where a central axis K of the workpiece 300 has a predetermined distance H, and the central axis K is perpendicular to a plane where an optical center O of the camera 50 and a machining or assembling position point a (shown in fig. 3) of the workpiece 300 are located.
Specifically, the robot control module 220 controls the robot 40 to drive the camera 50 to move to a position having a preset distance H from the central axis K of the workpiece 300.
S103: the control camera 50 takes a picture of the horizontally placed workpiece 300 and transfers the taken picture to the processor 10 and the storage device 20.
Specifically, the camera control module 230 controls the camera 50 to take a picture of the horizontally placed workpiece 300 and transfers the taken picture to the processor 10 and the storage device 20.
S104: the spatial coordinates of the machining or assembling position point a of the workpiece 300 placed obliquely with respect to the optical center O (shown in fig. 3) of the camera 50 are calculated from the shot picture and the preset angle α, thereby positioning the machining or assembling position point a of the workpiece 300.
Specifically, the measurement positioning module 240 calculates the number N of pixel points from the processing or assembling position point a of the workpiece 300 to the central axis K of the workpiece 300 in the photograph taken of the horizontally placed workpiece 300 according to the taken photograph, calculates the actual distance from the processing or assembling position point a of the workpiece 300 to the central axis K of the workpiece 300 according to the number N, and calculates the spatial coordinates (0, cos α N λ, H + sin α N λ) of the processing or assembling position point a of the workpiece 300 with the optical center O as the origin according to the preset inclination angle α of the workpiece 300.
S105: and controlling the loading jig 30 to incline the horizontally placed workpiece 300 by a preset angle alpha around the central axis K.
Specifically, the loading control module 210 controls the rotary driving element 34 of the loading fixture 30 to drive the rotary shaft 35 to rotate so as to incline the workpiece 300 by the preset angle α around the central axis K.
S106: and controlling the mechanical arm 40 to drive the tool 60 to move to the processing or assembling position point A of the workpiece 300 according to the calculated space coordinate.
Specifically, the robot control module 220 controls the robot 40 to drive the tool 60 to move to the machining or assembling position point a of the workpiece 300 according to the calculated spatial coordinates of the machining or assembling position point a of the workpiece 300.
S107: the control tool 60 processes the machining or assembly site a of the workpiece 300.
Specifically, the tool control module 250 controls the tool 60 to process the machining or assembly location point a of the workpiece 300.
It will be appreciated that steps S105-S107 may be eliminated without affecting the positioning of the machining or assembly location point a of the workpiece 300.
It is understood that the sequence of steps S101 and S102 can be interchanged without affecting the positioning of the machining or assembly location point a of the workpiece 300.
The vision measuring and positioning device 100 includes a processor 10, a storage device 20, a loading fixture 30, a robot 40, a camera 50, a tool 60 and a display 70, but is not limited thereto, and the tool 60 and the display 70 can be removed without affecting the positioning of the machining or assembling position point a of the workpiece 300.
The vision measuring and positioning device 100, the vision measuring and positioning system 200 and the vision measuring and positioning method realize positioning of the processing or assembling position point a of the workpiece 300 which is obliquely arranged by controlling the camera 50 to take a picture of the workpiece 300 and calculating the space coordinate of the processing or assembling position point a of the workpiece 300 relative to the optical center O (shown in fig. 3) of the camera 50 according to the taken picture, are simple to operate and improve positioning efficiency.
It will be understood by those skilled in the art that all or part of the processes of the above embodiments may be implemented by hardware instructions of a computer program, and the program may be stored in a computer-readable storage medium, and when executed, may include the processes of the above embodiments of the methods.
In addition, functional units in the embodiments of the present invention may be integrated into the same processor, or each unit may exist alone physically, or two or more units are integrated into the same unit. The integrated unit can be realized in a form of hardware, or in a form of hardware plus a software functional module.
The integrated unit implemented in the form of a software functional unit may be stored in a computer readable storage medium. The software functional unit is stored in a storage medium, and includes a plurality of instructions for enabling an electronic device (which may be a handheld electronic device, such as a smart phone, a notebook computer, a Personal Digital Assistant (PDA), an intelligent wearable device, or a desktop electronic device, such as a desktop computer, an intelligent television, or the like) or a processor (processor) to perform some steps of the method according to each embodiment of the present invention. And the aforementioned storage medium includes: various media capable of storing program codes, such as a usb disk, a removable hard disk, a Read-Only Memory (ROM), a Random Access Memory (RAM), a magnetic disk, or an optical disk.
It will be evident to those skilled in the art that the invention is not limited to the details of the foregoing illustrative embodiments, and that the present invention may be embodied in other specific forms without departing from the spirit or essential attributes thereof. The present embodiments are therefore to be considered in all respects as illustrative and not restrictive, the scope of the invention being indicated by the appended claims rather than by the foregoing description, and all changes which come within the meaning and range of equivalency of the claims are therefore intended to be embraced therein. Any reference sign in a claim should not be construed as limiting the claim concerned. Furthermore, it is obvious that the word "comprising" does not exclude other elements or steps, and the singular does not exclude the plural. Several units or systems recited in the system claims may also be implemented by one and the same unit or system in software or hardware. The terms first, second, etc. are used to denote names, but not any particular order.
Finally, it should be noted that the above embodiments are only intended to illustrate the technical solutions of the present invention and not to limit the same, and although the present invention has been described in detail with reference to the preferred embodiments, it should be understood by those skilled in the art that modifications or equivalent substitutions may be made to the technical solutions of the present invention without departing from the spirit and scope of the technical solutions of the present invention.