Device for acquiring position data pertaining to workpiece, control device, robot system, method, and computer program
Patent Information
- Application Number
- JP2024528153
- Authority / Receiving Office
- JP · JP
- Patent Type
- Applications
- Current Assignee / Owner
- Filing Date
- 2024-10-03
- Publication Date
- 2025-03-04
- Estimated Expiration
- 2042-06-21
AI Technical Summary
Conventional methods for acquiring workpiece position data using shape detection sensors often result in incorrect matching between workpiece models and detection data, leading to inaccurate position data and compromised precision in robotic operations.
A system that includes a shape detection sensor and a control device, which acquires position data by matching a workpiece model with detection data, and utilizes a confirmation area to invalidate position data when shape data from adjacent objects is detected within this area, ensuring accurate positioning and preventing mismatches.
This approach enhances the precision of robotic work by accurately determining the position of workpieces, avoiding errors caused by incorrect model matching and ensuring reliable robotic operations.
Abstract
Description
Apparatus, control device, robot system, method, and computer program for acquiring workpiece position data
[0001] The present disclosure relates to an apparatus, a control device, a robot system, a method, and a computer program for acquiring position data of a workpiece.
[0002] 2. Description of the Related Art There is known an apparatus that acquires position data of a workpiece by matching a workpiece model that models the workpiece with detection data from a shape detection sensor that detects the shape of the workpiece (see, for example, Patent Document 1).
[0003] JP 2017-102529 A
[0004] In the past, there have been cases where a workpiece model was erroneously matched to the detection data of a shape detection sensor, which could result in inaccurate workpiece position data being unable to be obtained, making it impossible to accurately perform work on the workpiece.
[0005] In one aspect of the present disclosure, an apparatus for acquiring position data of a workpiece based on detection data from a shape detection sensor that detects the shape of an object and a workpiece adjacent to the object that has an area into which the object cannot enter includes a position data acquisition unit that acquires position data by matching a workpiece model that models the workpiece and has a confirmation area defined corresponding to the area into the shape data of the workpiece included in the detection data, and a position data cancellation unit that invalidates the position data acquired by the position data acquisition unit when the shape data of the object included in the detection data is present in the confirmation area defined in the workpiece model that the position data acquisition unit matched to the shape data of the workpiece.
[0006] In another aspect of the present disclosure, a method for acquiring position data of a workpiece based on detection data from a shape detection sensor that detects the shape of an object and a workpiece adjacent to the object and having an area that the object cannot enter comprises a processor acquiring position data by matching a workpiece model that models the workpiece and has a confirmation area defined corresponding to the area that the object cannot enter, to the shape data of the workpiece included in the detection data, and invalidating the acquired position data if the shape data of the object included in the detection data is present in the confirmation area defined in the workpiece model that matches the shape data of the workpiece.
[0007] According to the present disclosure, it is possible to avoid having a robot perform work on a workpiece using position data acquired as a result of a mismatch between a workpiece model and shape data, which occurs when a workpiece model is erroneously matched to shape data, thereby improving the accuracy of work performed by the robot.
[0008] 18 is a schematic diagram of a robot system according to one embodiment. FIG. 18 is a block diagram of the robot system shown in FIG. 1. FIG. 18 is a perspective view of a workpiece according to one embodiment. FIG. 18 is a flowchart showing an example of an operation flow of a robot system. FIG. 18 is an example of detection data detected by a shape detection sensor. FIG. 18 is a flowchart showing an example of the flow of step S2 in FIG. 4. FIG. 18 is a perspective view of a workpiece model obtained by modeling the workpiece of FIG. 3. FIG. 18 is a top view of the workpiece model shown in FIG. 8. FIG. 18 shows a state in which a workpiece model is matched to the detection data shown in FIG. 5. FIG. 18 shows a state in which a workpiece model is erroneously matched to the detection data shown in FIG. 5. FIG. 18 is a flowchart showing an example of the flow of step S3 in FIG. 4. FIG. 18 is a flowchart showing another example of the flow of step S3 in FIG. 4. FIG. 18 shows a state in which one shape data item has been deleted from the detection data shown in FIG. 5. FIG. 18 is a block diagram showing other functions of the robot system shown in FIG. 2. FIG. 18 is a flowchart showing an example of a method for setting a confirmation area on a workpiece model. FIG. 18 shows a state in which multiple confirmation areas have been set on a workpiece model. FIG. 18 is a block diagram showing further other functions of the robot system shown in FIG. 2. FIG. 18 is a flowchart showing another example of a method for setting a confirmation area on a workpiece model. FIG. 18 shows a state in which a workpiece model has been quantized into unit voxels. FIG. 18 is a diagram for explaining a simulation of step S51 in FIG. 18.
[0009] Hereinafter, embodiments of the present disclosure will be described in detail with reference to the drawings. In various embodiments described below, like elements will be designated by like reference numerals, and duplicated descriptions will be omitted. First, a robot system 10 according to one embodiment will be described with reference to FIGS. 1 and 2. The robot system 10 includes a robot 12, a shape detection sensor 14, and a control device 16.
[0010] In this embodiment, the robot 12 is a vertical articulated robot and includes a robot base 18, a rotating body 20, a lower arm 22, an upper arm 24, a wrist 26, and an end effector 28. The robot base 18 is fixed on the floor of a work cell. The rotating body 20 is mounted on the robot base 18 so as to be rotatable about a vertical axis.
[0011] The lower arm 22 is rotatably mounted on the rotating body 20 around a horizontal axis, and the upper arm 24 is rotatably mounted at the tip of the lower arm 22. The wrist 26 has a wrist base 26a mounted at the tip of the upper arm 24 so as to be rotatable around two axes that are perpendicular to each other, and a wrist flange 26b mounted on the wrist base 26a so as to be rotatable around a wrist axis A1.
[0012] The end effector 28 is detachably attached to the wrist flange 26 b. The end effector 28 is, for example, a robot hand capable of gripping the workpiece W, a welding torch for welding the workpiece W, or a laser processing head for laser processing the workpiece W, and performs a predetermined operation on the workpiece W (workpiece handling, welding, or laser processing).
[0013] Each component of the robot 12 (robot base 18, rotating body 20, lower arm 22, upper arm 24, wrist 26) is provided with a servo motor 30 ( FIG. 2 ). These servo motors 30 rotate each movable element of the robot 12 (rotating body 20, lower arm 22, upper arm 24, wrist 26, wrist flange 26 b) in response to a command from the control device 16. As a result, the robot 12 can move and position the end effector 28 at any desired position.
[0014] The shape detection sensor 14 detects the shape of an object such as a workpiece W. In this embodiment, the shape detection sensor 14 is a three-dimensional visual sensor that has an image sensor (CMOS, CCD, etc.) and an optical lens (collimator lens, focus lens, etc.) that guides an image of a subject to the image sensor, and is fixed to the end effector 28 (or wrist flange 26 b).
[0015] The shape detection sensor 14 is configured to capture an image of a subject along an optical axis A2 and measure a distance d to the subject image. The shape detection sensor 14 may be fixed to the end effector 28 so that the optical axis A2 and the wrist axis A1 are parallel to (or perpendicular to) each other. The shape detection sensor 14 supplies the detected data DD to the control device 16.
[0016] 1, a robot coordinate system C1 and a tool coordinate system C2 are set for the robot 12. The robot coordinate system C1 is a control coordinate system for controlling the operation of each movable element of the robot 12. In this embodiment, the robot coordinate system C1 is fixed to the robot base 18 so that its origin is located at the center of the robot base 18 and its z axis is parallel to (specifically, coincides with) the rotation axis of the rotating body 20.
[0017] On the other hand, the tool coordinate system C2 is a control coordinate system that defines the position and posture of the end effector 28 in the robot coordinate system C1. In this embodiment, the tool coordinate system C2 is set with respect to the end effector 28 so that its origin (so-called TCP) is located at a work position of the end effector 28 (for example, a workpiece gripping position, a welding position, or a laser beam emission port) and its z-axis is parallel to (specifically, coincides with) the wrist axis A1.
[0018] When moving the end effector 28, the control device 16 sets a tool coordinate system C2 in the robot coordinate system C1 and generates commands to the servo motors 30 of the robot 12 so as to place the end effector 28 at the position and orientation represented by the set tool coordinate system C2. In this way, the control device 16 can position the end effector 28 at any position and orientation in the robot coordinate system C1.
[0019] On the other hand, a sensor coordinate system C3 is set for the shape detection sensor 14. The sensor coordinate system C3 is a control coordinate system that defines the position and orientation of the shape detection sensor 14 in the robot coordinate system C1 (i.e., the position and direction of the optical axis A2). In this embodiment, the sensor coordinate system C3 is set for the shape detection sensor 14 so that its origin is located at the center of the image sensor of the shape detection sensor 14 and its z axis is parallel to (specifically, coincides with) the optical axis A2. The sensor coordinate system C3 defines the coordinates of each pixel of the detection data DD (or the image sensor) detected by the shape detection sensor 14.
[0020] The positional relationship between the sensor coordinate system C3 and the tool coordinate system C2 is known by calibration, and therefore the coordinates of the sensor coordinate system C3 and the coordinates of the tool coordinate system C2 can be mutually converted via a known transformation matrix (e.g., a homogeneous transformation matrix). Furthermore, since the positional relationship between the tool coordinate system C2 and the robot coordinate system C1 is known, the coordinates of the sensor coordinate system C3 and the coordinates of the robot coordinate system C1 can be mutually converted via the tool coordinate system C2. In other words, the position and orientation of the shape detection sensor 14 in the robot coordinate system C1 (specifically, the coordinates of the sensor coordinate system C3) are known.
[0021] The control device 16 controls the operation of the robot 12. Specifically, as shown in Fig. 2, the control device 16 is a computer having a processor 32, a memory 34, and an I / O interface 36. The processor 32 has a CPU or a GPU, etc., and is communicatively connected to the memory 34 and the I / O interface 36 via a bus 38, and performs arithmetic processing to realize various functions described below while communicating with these components.
[0022] The memory 34 includes RAM, ROM, or the like, and temporarily or permanently stores various data. The memory 34 may be configured using a storage medium such as a volatile memory, a non-volatile memory, a magnetic storage medium, or an optical storage medium. The I / O interface 36 includes, for example, an Ethernet (registered trademark) port, a USB port, an optical fiber connector, or an HDMI (registered trademark) terminal, and communicates data with external devices via wired or wireless communication under instructions from the processor 32. The servo motors 30 of the robot 12 and the shape detection sensor 14 are communicatively connected to the I / O interface 36.
[0023] The control device 16 is also provided with a display device 40 and an input device 42. The display device 40 and the input device 42 are communicatively connected to the I / O interface 36. The display device 40 has a liquid crystal display, an organic EL display, or the like, and displays various data in a visually recognizable manner under instructions from the processor 32.
[0024] The input device 42 has push buttons, switches, a keyboard, a mouse, a touch panel, or the like, and receives data input from an operator. The display device 40 and the input device 42 may be integrated into the housing of the control device 16, or may be attached externally to the housing of the control device 16 as a separate computer (such as a PC).
[0025] In this embodiment, the processor 32 acquires position data of the workpieces W in the robot coordinate system C1 based on detection data DD from the shape detection sensor 14 that detects the shapes of multiple workpieces W piled up in the container B. As shown in Fig. 3, in this embodiment, each workpiece W has a shaft portion S, a flange portion F fixed to one end of the shaft portion S, and a hole H that passes through the shaft portion S and the flange portion F in the axial direction.
[0026] When the workpieces are piled up in the container B, one workpiece W 1 and the work W 1 and other adjacent works W 2 and come into contact with each other, but the work W 1 The hole H of the other work W 2 (i.e., the shaft portion S and the flange portion F) cannot enter. That is, in this embodiment, each workpiece W has a hole H as an area into which other workpieces W (objects) cannot enter.
[0027] Next, the function of the robot system 10 will be described with reference to Fig. 4. The flow shown in Fig. 4 starts when the processor 32 receives a work start command from an operator, a host controller, or the computer program PG. In step S1, the processor 32 acquires detection data DD detected by the shape detection sensor 14.
[0028] Specifically, the processor 32 operates the robot 12 to position the shape detection sensor 14 at an imaging position where the workpieces W piled up in the container B are within the detection range of the shape detection sensor 14. Then, the processor 32 operates the shape detection sensor 14 to capture an image of the workpieces W in the container B, thereby detecting detection data DD in which the workpieces W are captured.
[0029] An example of an image of the detection data DD is shown in Fig. 5. In the detection data DD shown in Fig. 5, from the viewpoint of ease of understanding, two adjacent workpieces W among the workpieces W in the container B are shown. 1 and W 2 Although only one workpiece W is shown, it should be understood that in reality, three or more workpieces W stacked randomly may be captured in the detection data DD.
[0030] In this embodiment, the detection data DD is three-dimensional point cloud image data, and includes a plurality of workpieces W. n Shape data SD n (n=1, 2, 3, ...) (in FIG. 5, work W 1 Shape data SD 1 , Work W 2 Shape data SD 2 ). Shape data SD n is Work W n Each point constituting the point group has information about the distance d. n Each point constituting the point group is a three-dimensional coordinate (X S , Y S , Z S The processor 32 acquires the detection data DD detected by the shape detection sensor 14 from the shape detection sensor 14.
[0031] In step S2, the processor 32 acquires position data PD of the workpiece W. That is, in this embodiment, the processor 32 functions as a position data acquisition unit 44 ( FIG. 14 ) that acquires the position data PD of the workpiece W. This step S2 will be described with reference to FIG. 6. The processor 32 functions as the position data acquisition unit 44 and executes the flow of step S2 shown in FIG.
[0032] After the start of step S2, in step S11, the processor 32 acquires a workpiece model WM that models the workpiece W. An example of the workpiece model WM is shown in Fig. 7. The workpiece model WM has a shaft portion model SM that models the shaft portion S, a flange portion model FM that models the flange portion F, and a hole model HM that models the hole H.
[0033] The workpiece model WM is, for example, a CAD model WM of the workpiece W. C and the CAD model WM C A point cloud model WM that represents the model components (edges, faces, etc.) of the P CAD model WM C is a three-dimensional CAD model, which is created in advance by an operator using a CAD device (not shown). The processor 32 receives the CAD model WM from the CAD device. C and then generating the CAD model WM according to a predetermined image generation algorithm. C By adding a point cloud to the model component of P may be generated.
[0034] In this embodiment, in step S11, the processor 32 calculates a workpiece model WM (for example, a point cloud model WM) of a plurality of postures as viewed from different virtual line of sight directions VL. P 7 shows the workpiece model WM in the first orientation when viewed from an oblique imaginary line of sight direction VL.
[0035] 8 shows the workpiece model WM in a second orientation when viewed from a virtual line of sight VL parallel to the central axis of the workpiece model WM. The processor 32 generates various orientations of the workpiece model WM when viewed from various virtual line of sight directions VL as shown in FIGS. 7 and 8.
[0036] The generated workpiece models WM in a plurality of orientations may have only model data of the front side that is visible when viewed from the virtual line of sight direction VL, and may not have model data of the back side that is not visible when viewed from the virtual line of sight direction VL. For example, the processor 32 may convert the workpiece model WM in the first orientation shown in FIG. 7 into a point cloud model WM. P 7, model data of the point cloud of the model components on the front side of the paper, which are visible in Fig. 7, is generated, but model data of the point cloud of the model components on the back side of the paper, which are not visible (i.e., edges, faces, etc. on the back side when viewed from the virtual line of sight direction VL in Fig. 7) is not generated. With this configuration, the amount of data of the generated workpiece model WM can be reduced.
[0037] A workpiece coordinate system C4 is set for each generated workpiece model WM. This workpiece coordinate system C4 is a control coordinate system that defines the position and orientation of the workpiece model WM. In the example shown in Figures 7 and 8, the workpiece coordinate system C4 is set with respect to the workpiece model WM so that its origin is located at the center of the opening of the hole model HM that opens at the end face of the shaft portion model SM, and its z axis coincides with the central axis of the hole model HM (or the workpiece model WM).
[0038] The processor 32 may receive an input from the operator to set a workpiece coordinate system C4 for the workpiece model WM via the input device 42. The processor 32 stores the generated workpiece model WM in a plurality of postures in the memory 34 together with setting information for the workpiece coordinate system C4.
[0039] Here, a confirmation area VE is previously defined for each of the generated workpiece models WM in a plurality of orientations. In this embodiment, the hole model HM of the workpiece model WM (i.e., the area on the model that corresponds to an area of the workpiece W into which other workpieces W cannot enter) is defined as the confirmation area VE. A method for setting the confirmation area VE for the workpiece model WM will be described later.
[0040] In step S12, the processor 32 executes pre-processing PP on the detection data DD acquired in step S1. For example, as the pre-processing PP, the processor 32 may select invalid point clouds (for example, point clouds that exist outside the container B or point clouds that exist outside the workpiece W) from among the point clouds included in the detection data DD. n Shape data SD n A process of deleting points that deviate significantly from the point cloud (point clouds) by more than a predetermined distance from the point cloud of the first embodiment from the detection data DD may be performed.
[0041] In step S13, the processor 32 executes a rough search RS. Specifically, as the rough search RS, the processor 32 sequentially arranges the workpiece models WM of the multiple orientations generated in step S11 in a virtual space defined by the sensor coordinate system C3 of the detection data DD, and calculates the workpiece models WM based on the shape data SD included in the detection data DD. n Match to.
[0042] At this time, the processor 32 repeatedly displaces the position of the workpiece model WM placed in the sensor coordinate system C3 by a predetermined displacement amount. Then, every time the processor 32 displaces the position of the workpiece model WM, the processor 32 calculates the feature points Fm of the workpiece model WM and the shape data SD n The degree of coincidence α with the feature point Fs is calculated.
[0043] The degree of match α includes, for example, an error in the distance between the feature point Fm and the feature point Fs corresponding to the feature point Fm. In this case, the closer the feature point Fm and the feature point Fs match in the sensor coordinate system C3, the smaller the value of the degree of match α. Alternatively, the degree of match α includes a similarity that represents the similarity between the feature point Fm and the feature point Fs corresponding to the feature point FPm. In this case, the closer the feature point Fm and the feature point Fs match in the sensor coordinate system C3, the larger the value of the degree of match α.
[0044] Then, the processor 32 compares the obtained degree of coincidence α with a predetermined threshold value α th and the degree of match α is compared with the threshold value α th (i.e., α≦α th , or α≧α th ), the workpiece model WM and the shape data SD in the sensor coordinate system C3n It is determined that the two are roughly matched.
[0045] FIG. 9 shows the workpiece model WM. 1 Shape data SD 1 The processor 32 matches the shape data SD 1 The coordinate Q1 of the sensor coordinate system C3 of the workpiece coordinate system C4 set in the workpiece model WM matched as a rough search RS S (X1 S , Y1 S , Z1 S , W1 S , P1 S , R1 S ) is obtained. S Of these, (X1 S , Y1 S , Z1 S ) indicates the origin position of the workpiece coordinate system C4 in the sensor coordinate system C3, and (W1 S , P1 S , R1 S ) indicate the attitude (so-called yaw, pitch, and roll) of the workpiece coordinate system C4 in the sensor coordinate system C3.
[0046] Then, the processor 32 calculates the coordinate Q1 in the sensor coordinate system C3. S the coordinate Q1 of the robot coordinate system C1 R (X1 R , Y1 R , Z1 R , W1 R , P1 R , R1 R ) and convert the coordinate Q1 R the initial position data PD 1_1 This initial position data PD 1_1 is the workpiece W in the robot coordinate system C1 1 This represents an estimate of the position and orientation of the
[0047] Similarly, the processor 32 detects other works W that appear in the detection data DD. n Initial position data PD 1_n If the detection data DD contains the workpiece W 1 Shape data SD 1 , Work W2 Shape data SD 2 , ...Work W n Shape data SD n (n is a positive integer), the processor 32 1 Initial position data PD 1_1 , Work W 2 Initial position data PD 1_2 , ...Work W n Initial position data PD 1_n In this way, the processor 32 obtains the workpiece model WM as the shape data SD in the rough search RS. n By matching with the work W n Position data PD 1_n has been obtained.
[0048] In step S14, the processor 32 executes a fine search PR. Specifically, the processor 32 searches for the workpiece W shown in the detection data DD. n Regarding the initial position data PD obtained in step S13 1_n is used as a reference, and the workpiece model WM is matched with the shape data SD in the sensor coordinate system C3 according to a predetermined matching algorithm (for example, a mathematical optimization algorithm such as ICP: Iterative Closest Point). n Search for a location that matches highly with
[0049] For example, the processor 32 calculates the initial position data PD 1_n The point cloud model WM placed as the work model WM P and the shape data SD included in the detection data DD n For example, the degree of coincidence β is calculated by P Point cloud and shape data SD n The error in distance between the 3D point cloud and the point cloud model WM P Point cloud and shape data SD n The similarity to the 3D point cloud is included.
[0050] Then, the processor 32 compares the obtained degree of coincidence β with a predetermined threshold value β thand the degree of match β is compared with the threshold value β th When β is exceeded (for example, β≦β th , or β≧β th ), a workpiece model WM (for example, a point cloud model WM) in the sensor coordinate system C3 P ) and shape data SD n On the other hand, if the matching score β is greater than the threshold value β th If the degree of matching does not exceed the threshold value β, the processor 32 displaces the position of the workpiece model WM placed in the sensor coordinate system C3 by a predetermined displacement amount, and calculates the degree of matching β each time the position of the workpiece model WM is displaced. th Compare with.
[0051] The processor 32 determines whether the degree of match β is greater than or equal to a threshold value β th When it exceeds the limit, the shape data SD is used as a dense search PR. n The coordinate Q2 in the sensor coordinate system C3 of the workpiece coordinate system C4 set in the workpiece model WM that is highly matched with S (X2 S , Y2 S , Z2 S , W2 S , P2 S , R2 S ) to obtain the
[0052] Then, the processor 32 calculates the coordinate Q2 in the sensor coordinate system C3. S coordinate Q2 in the robot coordinate system C1 R (X2 R , Y2 R , Z2 R , W2 R , P2 R , R2 R ) and convert the coordinate Q2 R Work W n Position data PD 2_n This position data PD 2_n is the workpiece W in the robot coordinate system C1 n It represents the highly accurate position and orientation of the
[0053] As a result of step S14, the processor 32 detects the plurality of workpieces W shown in the detection data DD. n Position data PD 2_nThe processor 32 acquires the acquired position data PD 2_n are stored as detection result data DT in the memory 34. An example of the data structure of the detection result data DT is shown in Table 1 below.
[0054]
[0055] The detection result data DT shown in Table 1 includes the workpiece W n Position data PD 2_n (Specifically, coordinate Q2 S (X2 R , Y2 R , Z2 R , W2 R , P2 R , R2 R )) and the degree of agreement β n , plane proportion γ n , and exposure rate δ n The detection result parameters PM are stored in the position data PD. 2_n The work W performed when n Shape data SD n is a parameter that represents the result of matching between the workpiece model WM and the object. Specifically, the degree of match β n In step S14, the workpiece model WM is searched for the shape data SD n This is the degree of match when it is determined that there is a high degree of matching.
[0056] Plane ratio γ n For example, the shape data SD is obtained by dense search PR. n In the workpiece model WM matched to the above, the largest planar model included in the workpiece model WM (specifically, the planar point cloud model WM P ) is the entire workpiece model WM (specifically, the entire point cloud model WM P Alternatively, the plane fraction γ n is the shape data SD obtained by matching the workpiece model WM using dense search PR. n The point group representing the largest plane included in the shape data SD n It may also be the ratio of the total (specifically, the total point cloud).
[0057] Exposure rate δ n For example, the shape data SD is obtained by dense search PR. n The entire workpiece model WM (specifically, the point cloud model WM) matched to P The shape data SD for all points constituting the n The area of the workpiece model WM that matches with the shape data SD n The point cloud model WM P The percentage of points in the cloud is shown.
[0058] The processor 32 receives the position data PD 2_n At the same time, the detection result parameter PM (matching degree β n , plane proportion γ n , and exposure rate δ n ) and obtain the position data PD 2_n The detection result parameter PM is stored in the memory 34 as the detection result data DT in association with the degree of match β n , plane proportion γ n , and exposure rate δ n The parameter is not limited to the above, and may have any other parameters.
[0059] In step S15, the processor 32 executes post-processing OP on the detection result data DT. For example, the processor 32 executes post-processing OP on the position data PD whose detection result parameters PM do not satisfy a predetermined standard. 2_n may be deleted from the detection result data DT.
[0060] Specifically, the processor 32 calculates the degree of match β n , plane proportion γ n , or exposure rate δ n does not exceed the predetermined reference value, it is determined that the detection result parameter PM does not satisfy the reference, and the position data PD associated with the detection result parameter PM 2_n may be deleted from the detection result data DT. As described above, the processor 32 functions as the position data acquisition unit 44, executes step S2 shown in FIG. 6, and n Position data PD 1_n , P.D. 2_nGet.
[0061] Referring again to FIG. 4, in step S3, the processor 32 calculates the workpiece model WM and the shape data SD. n In the above steps S13 and S14, the workpiece model WM is converted into the shape data SD. n When the workpiece model WM is matched with the shape data SD, the processor 32 converts the workpiece model WM into the shape data SD. n By mistakenly matching the workpiece model WM and the shape data SD n Inconsistencies may occur between
[0062] 10 shows an example of a state in which such a mismatch occurs. In the example shown in FIG. 10, the processor 32 1 Shape data SD 1 When the workpiece model WM was matched to the 1 Shape data SD 1 Among these, the shape data SD of the flange portion F 1 The flange part model FM of the workpiece model WM is matched to the above.
[0063] On the other hand, Work W 1 Shape data SD of the shaft portion S 1 As a result, the shaft part model SM of the workpiece model WM does not match the hole model HM of the workpiece model WM, which is set as the confirmation area VE described above. 2 Shape data SD 2 There is a part of the point cloud.
[0064] In this embodiment, in step S3, the processor 32 determines whether the workpiece W in the confirmation area VE is 2 Shape data SD 2 10 has occurred, and if an inconsistency has occurred, the position data PD 2_n That is, in this embodiment, the processor 32 invalidates the position data PD 2_n The position data canceller 46 (FIG. 2) functions as a position data canceller that invalidates the position data.
[0065] Step S3 will be described below with reference to Fig. 11. The processor 32 functions as the position data canceling unit 46 and executes the flow of step S3 shown in Fig. 11. After starting step S3, in step S21, the processor 32 cancels the workpiece W stored in the detection result data DT. n Position data PD 2_n The number "n" that identifies the item is set to "1".
[0066] In step S22, the processor 32 n Position data PD 2_n The shape data SD within the confirmation area VE defined in the workpiece model WM that is matched when acquiring m (For example, m ≠ n) data amount DA n If the number "n" is set to 1 at the start of step S22 (i.e., at the first execution of step S22), the processor 32 calculates the work W 1 Position data PD 2_1 The shape data SD within the confirmation area VE defined in the workpiece model WM that is matched when acquiring m The amount of data DA 1 Calculate.
[0067] For example, in the example shown in FIG. 10, as described above, the workpiece W 1 Shape data SD 1 The workpiece W is located within the confirmation area VE of the workpiece model WM that has been mistakenly matched to the 1 and the workpiece W as an adjacent object 2 Shape data SD 2 Therefore, in this case, the processor 32 calculates the shape data SD within the confirmation area VE defined on the workpiece model WM. 2 The amount of data for the point cloud DA 1 is calculated.
[0068] Specifically, the processor 32 calculates the shape data SD located in the confirmation area VE in the sensor coordinate system C3. 2 The number of points is the amount of data DA 1In this way, in step S22, the processor 32 calculates the work W n Position data PD 2_n The shape data SD within the confirmation area VE defined in the workpiece model WM that is matched when acquiring m The amount of data DA n Calculate.
[0069] In step S23, the processor 32 calculates the data amount DA calculated in the immediately preceding step S22. n Based on this, the work W n Position data PD 2_n When acquiring the workpiece model WM, the shape data SD is stored in the confirmation area VE of the matched workpiece model WM. m Specifically, the processor 32 determines whether the data amount DA calculated in the immediately preceding step S22 exists. n and the data amount DA of the work model WM w By substituting the above into the following equation 1, the mismatch parameter ε n Calculate ε n =DA n / DA w ...(Formula 1)
[0070] The mismatch parameter ε obtained by the calculation of Equation 1 n is the work model WM and the shape data SD n As described above, the confirmation area VE is a parameter that quantitatively represents the degree of mismatch with other objects (for example, workpieces W). 2 ) is defined in the workpiece model WM so that it corresponds to the inaccessible area. 1 Shape data SD 1 If the workpiece model WM is properly matched to the workpiece W, the confirmation area VE of the workpiece model WM contains the workpiece W. 1 Work W as another object adjacent to 2 Shape data SD 2 In reality, the point group does not exist.
[0071] On the other hand, as shown in FIG. 10, the workpiece model WM is 1If the workpiece model WM is erroneously matched with the shape data SD, the shape data SD is added to the confirmation area VE of the workpiece model WM. 2 Therefore, the shape data SD in the confirmation area VE exists. 2 The amount of data DA 1 and the mismatch parameter ε 1 By calculating the above, the workpiece model WM and the workpiece W shown in FIG. 1 Shape data SD 1 The inconsistency can be quantitatively verified.
[0072] In step S23, the processor 32 calculates the mismatch parameter ε n is a predetermined threshold ε th (i.e., ε n ≧ε th ) and determine whether ε n ≧ε th If so, the shape data SD is stored in the confirmation area VE. m On the other hand, the processor 32 determines that ε exists (i.e., YES). n <ε th If so, the result is determined as NO.
[0073] In addition, the above-mentioned formula 1 is ε n =DA n / DA w × 100. In addition to the calculation of the above-mentioned formula 1, the workpiece model WM and the shape data SD n The mismatch parameter that quantitatively represents the degree of mismatch with the data amount DA n It may be obtained by any calculation using
[0074] Alternatively, the processor 32 may determine the mismatch parameter ε n Without calculating the data amount DA calculated in the immediately preceding step S22, n is a predetermined threshold value DA th or more (i.e., DA n ≧DA thIf the processor 32 determines YES, the process proceeds to step S24, whereas if the processor 32 determines NO, the process proceeds to step S25.
[0075] In step S24, the processor 32 functions as the position data canceling unit 46 and invalidates the position data PD of the workpiece W acquired in the above-mentioned step S2. Below, a case will be described in which the above-mentioned number "n" is set to n=1 at the start of this step S24.
[0076] As shown in FIG. 10, the workpiece model WM is 1 When the workpiece model WM is erroneously matched with the workpiece coordinate system C4, the workpiece coordinate system C4 set in the workpiece model WM is 1 Therefore, if the processor 32 were to use the position data PD acquired based on such an inconsistent workpiece coordinate system C4 in step S5 described later, 2_1 , the robot 12 is 1 If an operation is performed on the target object, the operation cannot be performed with high accuracy.
[0077] Therefore, in this embodiment, the processor 32 functions as a position data canceling unit 46 in step S24, and performs control in step S5 described later to cancel the position data PD acquired as a result of the inconsistency. 2_1 In order to avoid using the position data PD 2_1 Disable.
[0078] As an example, the processor 32 determines the work W from the detection result data DT created in step S2. 1 Position data PD 2_1 As another example, the processor 32 may delete the work W stored in the detection result data DT. 1 Position data PD 2_1 An invalid flag FL is assigned to the
[0079] In this case, when executing step S5 described later, the processor 32 calculates the position data PD 2_1 When the position data PD is read out,2_1 The invalid flag FL assigned to the position data PD 2_1 As a result, the processor 32 ignores the work W 1 This will cancel the work on the
[0080] In this way, in step S24, the processor 32 calculates the position data PD stored in the detection result data DT. 2_n is invalidated (for example, deleted or assigned an invalid flag FL), so that the position data PD obtained as a result of the inconsistency is not used in the control of step S5 described later. 2_1 can avoid using
[0081] In step S25, the processor 32 determines whether the number "n" set at this point is equal to or greater than n. MAX It is determined whether this n MAX is the work W obtained in step S2 n Position data PD 2_n (or the total number of works W shown in the detection data DD acquired in the most recent step S1) n If the processor 32 determines YES, it ends the flow shown in FIG. 11, whereas if the processor 32 determines NO, it proceeds to step S26.
[0082] In step S26, the processor 32 increments the number "n" by "1" (n=n+1). Then, the processor 32 returns to step S22. In this way, the processor 32 repeatedly executes the loop of steps S22 to S26 until the determination in step S25 is YES, and the position data PD stored in the detection result data DT is 2_n Among these, the position data PD obtained as a result of the inconsistency 2_n Disable.
[0083] Referring again to FIG. 4, in step S4, the processor 32 2_nSpecifically, the processor 32 determines the detection result data DT after executing the above-mentioned step S3 as formal control data to be used for control in step S5 described later, and stores it in the memory 34 (for example, RAM).
[0084] In step S5, the processor 32 refers to the detection result data DT determined in step S4 and operates the robot 12 to move the workpiece W. n In step S24, the workpiece W is subjected to the work (such as workpiece handling, welding, or laser processing). 1 Position data PD 2_1 is invalidated, while work W 2 Position data PD 2_2 is not invalidated.
[0085] In this case, the processor 32 1 While canceling the work on the work W stored in the detection result data DT, 2 Position data PD 2_2 , the robot 12 is operated to move the end effector 28 (i.e., the origin of the tool coordinate system C2) to the position data PD 2_2 (i.e., coordinate Q2 in the robot coordinate system C1) R (X2 R , Y2 R , Z2 R , W2 R , P2 R , R2 R )) and the workpiece W is 2 Perform work on.
[0086] In step S6, the processor 32 determines whether or not the work on all the workpieces W in the container B has been completed. If the processor 32 determines YES, it ends the flow shown in Fig. 4, whereas if the processor 32 determines NO, it returns to step S1. In this way, the processor 32 repeatedly executes the loop of steps S1 to S6 until it determines YES in step S6, acquires new detection data DD detected by the shape detection sensor 14 in step S1, and executes steps S2 to S5 based on the new detection data DD.
[0087] As described above, in this embodiment, the processor 32 functions as the position data acquisition unit 44 and the position data cancellation unit 46, and determines the position of the workpiece W based on the detection data DD of the shape detection sensor 14. n Position data PD 1_n , P.D. 2_n Therefore, the position data acquisition unit 44 and the position data cancellation unit 46 acquire the position data of the workpiece W based on the detection data DD of the shape detection sensor 14. n Position data PD 1_n , P.D. 2_n The apparatus 50 (FIG. 2) is configured to acquire the
[0088] In this device 50, the position data acquisition unit 44 acquires the position data of an object (e.g., another workpiece W) 2 The workpiece model WM, in which a confirmation area VE corresponding to an area into which the workpiece 100 cannot enter is defined, is included in the detection data DD. n Shape data SD n By matching with the work W n Position data PD 1_n , P.D. 2_n is acquired (steps S13 and S14).
[0089] Then, the position data acquisition unit 44 acquires the workpiece W n Shape data SD n The object shape data SD included in the detection data DD is set in the confirmation area VE defined in the workpiece model that matches the m (For example, the workpiece W in FIG. 10 2 Shape data SD 2 ) exists (YES in step S23), the position data PD 2_n is invalidated (step S24).
[0090] According to this configuration, the position data PD obtained as a result of the mismatch as shown in FIG. 2_n Using the workpiece W n Therefore, it is possible to avoid having the robot 12 perform the work on the target object (step S5). As a result, it is possible to improve the accuracy of the work performed by the robot 12.
[0091] In the device 50, the position data canceling unit 46 cancels the shape data SD n The shape data SD of the object in the confirmation area VE defined in the work model WM that matches m The amount of data DA n (Step S22), and the calculated data amount DA n Based on this, the shape data SD is m In this configuration, when appropriate matching is performed, it is determined whether or not the amount of data DA that cannot exist in the confirmation area VE exists (step S23). n This creates the workpiece model WM and shape data SD. n As a result, the presence or absence of the inconsistency can be effectively detected.
[0092] In the device 50, the position data canceling unit 46 cancels the data amount DA calculated in step S22. n and the data amount DA of the work model WM w By performing a predetermined calculation (specifically, the calculation of the above-mentioned formula 1) using the above, the shape data SD of the object is stored in the confirmation area VE. m It is determined whether or not there exists (step S23).
[0093] According to this configuration, the workpiece model WM and the shape data SD are obtained by a predetermined calculation (calculation of Equation 1). n A parameter that quantitatively expresses the degree of mismatch with the n , or data amount DA n ) and the inconsistency can be verified using the parameter. Therefore, the presence or absence of the inconsistency can be detected with higher accuracy.
[0094] Next, another embodiment of step S3 in Fig. 4 will be described with reference to Fig. 12. In step S3 shown in Fig. 12, after step S21 or S26, in step S31, the processor 32 n Position data PD 2_n In step S22, the data amount DA n It is determined whether to calculate
[0095] As an example, the processor 32 may n Position data PD 2_n In step S22, the data amount DA n Here, it is determined whether it is necessary to calculate the position data PD 2_n The detection result parameter PM obtained when the degree of match β n , plane proportion γ n , or exposure rate δ n If is high, the probability of an inconsistency may be low, while the match β n , plane proportion γ n , or exposure rate δ n If is significantly low, the probability that a mismatch has occurred may increase.
[0096] Therefore, in step S31, the processor 32 calculates the position data PD 2_n The degree of match β is stored in the detection result data DT in association with n , plane proportion γ n , or exposure rate δ n If the data amount DA exceeds the predetermined threshold, the subsequent step S22 is executed. n On the other hand, the processor 32 determines that it is not necessary to calculate the degree of coincidence β n , plane proportion γ n , or exposure rate δ n If the data amount DA does not exceed the predetermined threshold, the subsequent step S22 is executed. n It is determined that it is necessary to calculate (that is, YES).
[0097] As another example, in step S31, the processor 32 n Position data PD 2_n In step S22, the data amount DA n Here, it is determined whether it is necessary to calculate the workpiece W in the detection data DD. n Shape data SD nThe probability of the occurrence of the above-described inconsistency may vary depending on the position or orientation of the workpiece model WM that is matched to the above-described workpiece model WM.
[0098] For example, in the detection data DD, shape data SD located in a position close to the shape data of the container A (i.e., the point cloud indicating the visual characteristics of the container A) n Alternatively, in the detection data DD, the shape data SD located at a position farther away in the positive z-axis direction of the sensor coordinate system C3 (or the negative z-axis direction of the robot coordinate system C1) (i.e., a position closer to the bottom surface of the container A) may be n If the workpiece model WM is matched to the original image, the probability of inconsistency occurring may increase.
[0099] Therefore, in this embodiment, the processor 32 uses the position data PD 2_n (That is, coordinate Q2 R (X2 R , Y2 R , Z2 R , W2 R , P2 R , R2 R If the data is within the predetermined coordinate range QR, the subsequent step S22 is executed to obtain the data amount DA n It is determined that it is necessary to calculate (i.e., YES). As an example, the coordinate range QR can be defined as a range of a predetermined distance from the coordinates of the shape data of the container A included in the detection data DD in the robot coordinate system C1.
[0100] As another example, the coordinate range QR is 2_n : Coordinate Q2 R (X2 R , Y2 R , Z2 R , W2 R , P2 R , R2 R ) z coordinate: Z2 R In contrast, Z2 R ≦Z th The threshold Z that defines this coordinate range QR may be th is, for example, the work W included in the detection data DD nShape data SD n The coordinates may be determined as coordinates that are a predetermined distance away from a point at the end of the robot coordinate system C1 in the positive z-axis direction in the robot coordinate system C1.
[0101] The processor 32 receives the position data PD 2_n Coordinates Q2 R (X2 R , Y2 R , Z2 R , W2 R , P2 R , R2 R ) is in the coordinate range QR, execute the subsequent step S22 to determine the data amount DA n It is determined that it is necessary to calculate (that is, YES).
[0102] 7 is matched, the probability of mismatch occurring may be low, whereas the probability of mismatch occurring may be high when the workpiece model WM in the second orientation shown in FIG. 8 is matched. Therefore, in this embodiment, the processor 32 2_n If the posture of the workpiece model WM matched when the data amount DA is acquired is a predetermined reference posture (for example, the second posture in FIG. 8), the subsequent step S22 is executed to obtain the data amount DA n It is determined that it is necessary to calculate (that is, YES).
[0103] On the other hand, if the posture of the matched workpiece model WM is not the reference posture, the processor 32 executes the subsequent step S22 to obtain the data amount DA n In this way, in step S31, the processor 32 determines that it is not necessary to calculate the data amount DA based on the detection result parameter PM indicating the matching result or the orientation of the matched workpiece model WM. n It is determined whether to calculate
[0104] If the processor 32 determines that the position data PD 2_nCoordinates Q2 R The processor 50 may determine whether the coordinate Q2 is within the coordinate range QR and whether the posture of the matched workpiece model WM is the reference posture. R is within the coordinate range QR and the posture of the workpiece model WM is the reference posture, the determination may be YES.
[0105] If the determination in step S31 or S23 is NO, in step S32, the processor 32 n Shape data SD n is deleted from the detection data DD. If the number "n" is set to n=1 and the work W 1 Position data PD 2_1 9. In this case, the processor 32 determines the workpiece W from the detection data DD shown in FIG. 1 Shape data SD 1 In this way, the shape data SD 1 The detected data DD from which the data has been erased is shown in FIG.
[0106] Thereafter, the processor 32 increments the number "n" to "2" in step S26 and starts the next work W 2 Position data PD 2_2 Steps S31, S22 to S24 are executed for the workpiece W. 2 Position data PD 2_2 Assume that the determination in step S31 is YES and steps S22 and S23 are executed.
[0107] In this case, the processor 32 generates the shape data SD as shown in FIG. 1 Step S22 is executed based on the deleted detection data DD, and the work W 2 Position data PD 2_2 The work W within the confirmation area VE defined in the work model WM matched when the work W is acquired 2 and another adjacent work W m Shape data SD (not shown) m The amount of data DA 2Next, in step S23, the processor 32 calculates the data amount DA 2 Based on this, the work W 2 Position data PD 2_2 When obtaining the workpiece model WM, the workpiece W is m Shape data SD m Determine whether or not
[0108] As described above, in the embodiment shown in FIG. 12, the position data canceling unit 46 cancels the data amount DA based on the detection result parameters PM or the posture of the matched workpiece model WM. n In this configuration, it is determined whether or not to calculate the position data PD 2_n Regarding step S22, steps S22 to S24 can be omitted, so the cycle time of step S3 can be reduced.
[0109] In the embodiment shown in FIG. 12, the position data acquisition unit 44 acquires the position data of the workpiece W included in the detection data DD. 2 A different work W 1 Shape data SD of (third workpiece) 1 By matching the workpiece model WM to the 1 Position data PD 1_1 , P.D. 2_1 (Step S1), and the position data canceling unit 46 detects that the position data acquiring unit 44 has acquired the workpiece W 1 Position data PD 1_1 , P.D. 2_1 After obtaining the work W 1 Shape data SD 1 is deleted from the detection data DD (step S32).
[0110] Then, the position data canceling unit 46 cancels the workpiece W 2 Shape data SD 2 The workpiece W is placed in the confirmation area VE defined in the workpiece model WM that matches the 1 Shape data SD 1 The object (for example, another work W) included in the detection data DD from which m ) shape data SDm It is determined whether or not there exists (step S23).
[0111] According to this configuration, the shape data SD does not need to be verified for inconsistency (i.e., steps S22 to S24). 1 After erasing, the next work W 2 Position data PD 2_2 The workpiece model WM and the workpiece W that were matched when the 2 Shape data SD 2 Therefore, the mismatch can be verified with a higher degree of accuracy.
[0112] 12, step S31 may be omitted, and the processor 32 may execute step S32 when determining "NO" in step S23. Alternatively, step S32 may be omitted from the flow shown in FIG. 12, and the processor 32 may proceed to step S25 when determining "NO" in step S31 or S23.
[0113] Next, other functions of the robot system 10 will be described with reference to Figures 14 and 15. In this embodiment, before executing the flow of Figure 4, the processor 32 executes the flow shown in Figure 15 in order to set the above-mentioned confirmation area VE in the workpiece model WM. The flow shown in Figure 15 is started when the processor 32 receives a confirmation area setting command from an operator, a higher-level controller, or the computer program PG. In step S41, the processor 32 executes the confirmation area setting command in the workpiece model WM (CAD model WM C , or the point cloud model WM P ) and displays it on the display device 40.
[0114] In step S42, the processor 32 determines whether or not an input IP1 specifying a confirmation area VE on the workpiece model WM has been received. Specifically, the operator C , or the point cloud model WM P ), the input device 42 is operated to provide the processor 32 with an input IP1 that specifies the confirmation area VE in the workpiece model WM.
[0115] As described above, each workpiece W randomly piled in the container B has an area (hole H in this embodiment) that other workpieces W (objects) cannot enter, and the confirmation area VE is set on the workpiece model WM as an area corresponding to the inaccessible area. The operator manually specifies the area of the workpiece model WM that corresponds to the inaccessible area.
[0116] In this embodiment, the operator operates the input device 42 to provide the processor 32 with an input IP1 that designates the hole model HM of the workpiece model WM as the confirmation area VE. At this time, the processor 32 may change the attitude of the workpiece model WM displayed on the display device 40 (i.e., the virtual line of sight VL for viewing the workpiece model WM) in accordance with the input operation to the input device 42 by the operator.
[0117] If the processor 32 receives the input IP1 through the input device 42, the processor 32 determines YES and proceeds to step S43, whereas if the processor 32 determines NO, the processor 32 proceeds to step S44. In this manner, in this embodiment, the processor 32 functions as a first input receiving unit 52 (FIG. 14) that receives the input IP1 that specifies the confirmation area VE in the workpiece model WM.
[0118] In step S43, the processor 32 sets a confirmation region VE in the workpiece model WM in accordance with the input IP1 received in the immediately preceding step S42. If the processor 32 receives an input IP1 specifying a hole model HM in the workpiece model WM in the immediately preceding step S42, the processor 32 sets the entire area of the hole model HM as the confirmation region VE in accordance with the input IP1, as shown in FIG.
[0119] The processor 32 associates data of the set confirmation area VE with the model data of the workpiece model WM as, for example, coordinate data of the workpiece coordinate system C4, and stores the data in the memory 34. In this manner, in this embodiment, the processor 32 functions as a confirmation area setting unit 54 ( FIG. 14 ) that sets the confirmation area VE on the workpiece model WM in accordance with the input IP1.
[0120] 7 and 8 based on the workpiece model WM acquired in step S41, and may set a confirmation area VE for each of the generated workpiece models WM in a plurality of postures in accordance with the input IP1. As a result, a confirmation area VE is set for each of the workpiece models WM in each posture, as shown in FIGS.
[0121] The processor 32 associates data of the confirmation area VE set for each orientation of the workpiece model WM with the workpiece model WM in each orientation and stores it in the memory 34. Then, when executing step S2 of Fig. 6, the processor 32 functions as the position data acquisition unit 44, and in step S11, references the data of the confirmation area VE set for each orientation of the workpiece model WM, and generates workpiece models WM in multiple orientations, each with a confirmation area VE set. Then, in steps S13 and S14, the processor 32 compares the generated workpiece models WM in multiple orientations with the workpiece W shown in the detection data DD. n Shape data SD n Match each of them.
[0122] Referring again to FIG. 15, in step S44, the processor 32 calculates the threshold value ε used in step S23 described above for the confirmation area VE set in the workpiece model WM at this time. th (or threshold DA th Specifically, the operator operates the input device 42 to specify the inconsistency parameter ε ) in the above-described step S23 for the confirmation region VE set in the workpiece model WM at this point in time. n (or data amount DA n ) is compared with the threshold ε th (or threshold DA th ) is provided to the processor 32.
[0123] The processor 32 functions as a first input receiving unit 52 and receives an input IP2 from the operator via the input device 42. If the processor 32 receives the input IP2, it determines YES and proceeds to step S45, whereas if it determines NO, it proceeds to step S46.
[0124] In step S45, the processor 32 calculates a threshold value ε for the confirmation area VE set in the workpiece model WM in accordance with the input IP2 received in the immediately preceding step S44. th (or D.A. th The processor 32 sets the set threshold value ε th (or D.A. th ) is stored in the memory 34 in association with the model data of the workpiece model WM and the data of the verification area VE.
[0125] In step S46, the processor 32 determines whether or not an input IP3 for modifying or deleting the confirmation area VE set on the workpiece model WM at this time point has been received. Specifically, the processor 32 displays the workpiece model WM and the confirmation area VE set on the workpiece model WM at this time point on the display device 40.
[0126] While visually checking the workpiece model WM and confirmation area VE displayed on the display device 40, the operator operates the input device 42 to provide the processor 32 with an input IP3 for modifying the confirmation area VE. At this time, the operator may operate the input device 42 to input coordinate values of the confirmation area VE in the workpiece coordinate system C4 as the input IP3 for modifying the confirmation area VE, or may displace, expand, or reduce the confirmation area VE by dragging and dropping the confirmation area VE in the workpiece coordinate system C4. Alternatively, while visually checking the workpiece model WM and confirmation area VE displayed on the display device 40, the operator operates the input device 42 to provide the processor 32 with an input IP3 for deleting the set confirmation area VE.
[0127] If the processor 32 has received the input IP3 through the input device 42, the processor 32 determines that the result is YES and proceeds to step S47, whereas if the processor 32 determines that the result is NO, the processor 32 proceeds to step S48. In this manner, in this embodiment, the processor 32 functions as the second input receiving unit 56 ( FIG. 14 ) that receives the input IP3 for modifying or deleting the confirmation area VE.
[0128] In step S47, the processor 32 updates the data of the confirmation area VE (e.g., coordinate data of the workpiece coordinate system C4) stored in the memory 34 by modifying or deleting the confirmation area VE set in the workpiece model WM at this point in time, in accordance with the input IP3 received in the immediately preceding step S46. Then, the processor 32 returns to step S42.
[0129] In step S48, the processor 32 determines whether or not an input IP4 approving the confirmation area VE set on the workpiece model WM at this point has been received. Specifically, the processor 32 displays the workpiece model WM and the confirmation area VE set on the workpiece model WM at this point, together with an approval button image for approving the confirmation area VE, on the display device 40.
[0130] While visually checking the workpiece model WM and confirmation area VE displayed on the display device 40, the operator operates the input device 42 to provide the processor 32 with an input IP4 for operating the approval button image. The processor 32 functions as a second input receiving unit 56 ( FIG. 14 ) and receives the input IP4 through the input device 42.
[0131] 15. If the processor 32 determines that the input IP4 has been received, it judges YES and ends the flow shown in FIG. 15. If the processor 32 determines that the input IP4 has been received, it returns to step S42. In this way, the processor 32 repeatedly executes steps S42 to S47 to set, modify, or delete the confirmation area VE and the threshold value ε th (or D.A. th ) settings are executed sequentially.
[0132] According to the flow of FIG. 15, the operator determines the confirmation area VE and the threshold value εth (or D.A. th 15, the processor 32 executes the flow of FIG. 4 in response to the above-mentioned work start command. Then, the processor 32 executes the above-mentioned steps S2 and S3 based on the workpiece model WM in which the confirmation area VE has been set by the flow of FIG. 15.
[0133] As described above, in this embodiment, the processor 32 functions as the position data acquisition unit 44, the position data cancellation unit 46, the first input reception unit 52, the confirmation area setting unit 54, and the second input reception unit 56, and sets the confirmation area VE on the workpiece model WM in the flow of FIG. 15, and calculates the workpiece W based on the detection data DD of the shape detection sensor 14 in the flow of FIG. n Position data PD 1_n , P.D. 2_n has been obtained.
[0134] Therefore, the position data acquisition unit 44, the position data cancellation unit 46, the first input reception unit 52, the confirmation area setting unit 54, and the second input reception unit 56 determine the position of the workpiece W based on the detection data DD of the shape detection sensor 14. n Position data PD 1_n , P.D. 2_n The apparatus 60 (FIG. 14) for obtaining the above information is configured.
[0135] In this device 60, the first input receiving unit 52 receives an input IP1 that specifies a confirmation area VE in the work model WM (step S42), and the confirmation area setting unit 54 sets the confirmation area VE in the work model WM in accordance with the input IP1 received by the first input receiving unit 52 (step S43).
[0136] According to this configuration, the operator can consider areas in the workpiece W that cannot be entered by other objects (e.g., other workpieces W), and then arbitrarily set a confirmation area VE corresponding to the area inaccessible on the workpiece model WM. As a result, the confirmation area VE that is the focus of attention in the inconsistency verification in step S3 described above can be appropriately set.
[0137] In the device 60, when the above-mentioned step S2 is executed, the position data acquisition unit 44 generates workpiece models WM of a plurality of orientations in order to execute matching (step S11), and the confirmation area setting unit 54 sets a confirmation area VE for each of the workpiece models WM of a plurality of orientations (step S43). n When matching is performed, the confirmation area VE can be appropriately set for the workpiece model WM of each posture.
[0138] In addition, in the device 60, the second input accepting unit 56 accepts an input IP3 for modifying or deleting the confirmation area VE set by the confirmation area setting unit 54, or an input IP4 for approving the confirmation area VE (steps S46 or S48). With this configuration, the operator can appropriately modify, delete, or approve the set confirmation area VE, thereby easily setting the desired confirmation area VE.
[0139] In step S42, the processor 32 receives a plurality of confirmation areas VE from the operator. j For example, as shown in FIG. 16, the operator may operate the input device 42 to specify three confirmation regions VE in the hole model HM. 1 , V.E. 2 and VE 3 may be specified.
[0140] In the example shown in FIG. 16, a confirmation area VE is formed in one opening area of the hole model HM. 1 is specified, and the other opening region of the hole model HM is set to the confirmation region VE 2 is specified. And the confirmation area VE 1 and confirmation area VE 2 In the central region of the hole model HM between 3 In step S42, the processor 32 determines whether or not such a confirmation area VE 1 , V.E. 2 and VE 3 In step S43, an input IP1 specifying the confirmation area VE 1 , V.E.2 and VE 3 may be set as the hole model HM.
[0141] In this case, the operator, in step S44, 1 , V.E. 2 and VE 3 For each, different thresholds ε th_m (or D.A. th_m For example, the operator may operate the input device 42 to specify the confirmation area VE 1 For threshold ε th_1 Set the confirmation area VE 2 For threshold ε th_2 Set the confirmation area VE 3 For threshold ε th_3 In this case, the threshold value ε th_3 is the threshold ε th_1 and ε th_2 may be set to a value lower than
[0142] In this case, in step S22 described above, the processor 32 1 Shape data SD m The amount of data DA n_1 and the confirmation area VE 2 Shape data SD m The amount of data DA n_2 and the confirmation area VE 3 Shape data SD m The amount of data DA n_3 and are calculated respectively.
[0143] Next, in step S23, the processor 32 calculates the confirmation region VE by the calculation of the above-mentioned Equation 1. 1 The mismatch parameter ε n_1 (=DA n_1 / DA w ) and the confirmation area VE 2 The mismatch parameter ε n_2 (=DA n_2 / DA w ) and the confirmation area VE 3 The mismatch parameter ε n_3 (=DA n_3 / DA w) and the mismatch parameter ε n_1 , ε n_2 and ε n_3 and the threshold value ε set in step S45. th_1 , ε th_2 and ε th_3 and ε n_1 ≧ε th_1 , ε n_2 ≧ε th_2 , or ε n_3 ≧ε th_3 If so, the determination may be YES.
[0144] Here, the multiple confirmation areas VE shown in FIG. 1 , V.E. 2 and VE 3 The work model WM is set as the shape data SD. n When matching is performed with the hole model HM, the confirmation region VE close to the opening of the hole model HM is 1 and VE 2 Other shape data SD m On the other hand, the confirmation area VE set in the central area of the hole model HM is likely to exist. 3 The shape data SD m It is assumed that such a point group is unlikely to exist.
[0145] Therefore, as mentioned above, the threshold ε th_3 , the threshold ε th_1 and ε th_2 By setting it to a value lower than n Check the inconsistency with the area VE 1 , V.E. 2 and VE 3 It can be verified in detail for each threshold ε th_1 and ε th_2 may be set to the same value.
[0146] In the above embodiment, the case has been described where the area in the workpiece W into which other objects (e.g., other workpieces W) cannot enter is the hole H. However, this is not limited to this, and a solid portion of the workpiece W (i.e., a solid portion of the shaft portion S or the flange portion F) can also be an area into which other objects (e.g., other workpieces W) cannot enter. Therefore, in step S42 described above, the operator may set the solid portion of the shaft portion model SM or the flange portion model FM in the workpiece model WM as the confirmation area VE, as an area corresponding to the area into which other objects (e.g., other workpieces W) cannot enter.
[0147] Alternatively, in step S42, the operator may place the hole model HM of the workpiece model WM in the confirmation area VE 1 and the solid part of the workpiece model WM is confirmed as the area VE 2 In this case, the operator may set the confirmation area VE set in the hole model HM in step S44. 1 and the confirmation area VE set in the solid part of the workpiece model WM. 2 In each case, different thresholds ε th_1 and ε th_2 (or threshold DA th_1 and D.A. th_2 ) may be specified separately.
[0148] 15. In this case, in step S43, the processor 32 may generate workpiece models WM of a plurality of postures as shown in FIGS. 7 and 8 based on the workpiece model WM acquired in step S41, and may analyze these workpiece models WM to automatically set a confirmation area VE for each posture of the workpiece model WM. In this case, the first input receiving unit 52 can be omitted from the device 60.
[0149] A method for automatically setting the confirmation area VE will be described below. Specifically, the processor 50 omits step S42 in Fig. 15, and in step S43, functions as a confirmation area setting unit 54, and automatically sets the confirmation area VE on the workpiece model WM based on the workpiece model WM.
[0150] As an example, the processor 50 sets an envelope shape model that covers the workpiece model WM from the outside for the workpiece model WM. Then, the processor 50 may automatically set an area that exists inside the workpiece model WM by a predetermined distance from the boundary between the set envelope shape model and the workpiece model WM as the confirmation area VE.
[0151] As another example, in step S43, the processor 50 analyzes the workpiece model WM and extracts a solid portion of the workpiece model WM (a solid portion of the shaft portion S or the flange portion F). Then, the processor 50 may automatically set the extracted solid portion as the confirmation region VE.
[0152] As yet another example, in step S43, the processor 50 places a virtual surface model (a model of a flat or curved virtual surface) on the workpiece model WM in a virtual three-dimensional space defined by the workpiece coordinate system C4. The processor 50 then extracts an area (e.g., a hole model HM) that is occluded by the virtual surface model and changes to a solid area. The processor 50 may automatically set the extracted area as the confirmation area VE. As described above, the processor 50 functions as the confirmation area setting unit 54 and automatically sets the confirmation area VE on the workpiece model WM based on the workpiece model WM.
[0153] 15. In this case, in step S45, the processor 32 calculates a threshold value ε th (or threshold DA th ) may be automatically set as a predetermined constant, for example. Also, steps S46 to S48 may be omitted from the flow shown in FIG. 15. In this case, the second input receiving unit 56 can be omitted from the device 60.
[0154] Next, further functions of the robot system 10 will be described with reference to Figures 17 and 18. In this embodiment, the processor 32 executes the flow shown in Figure 18 instead of the flow shown in Figure 15. In the flow shown in Figure 18, the same processes as those in the flow shown in Figure 15 are assigned the same step numbers, and duplicated descriptions will be omitted.
[0155] In the flow shown in Fig. 18, after step S41, in step S51, the processor 32 executes a simulation SL in which a plurality of workpiece models WM are brought into contact with each other. Specifically, the processor 32 first quantizes the workpiece model WM acquired in step S41 into voxels VX, which are cubes of unit volume, as shown in Fig. 19. As a result, the solid portions of the workpiece model WM (specifically, the shaft portion model SM and the flange portion model FM) are quantized into voxels VX. S The hole model HM of the workpiece model WM is quantized into voxels VX H is quantized to
[0156] Next, the processor 32 generates the quantized workpiece model WM as shown in FIG. 1 On the other hand, the quantized work model WM 2 In other words, in this embodiment, the processor 32 repeatedly executes a simulation SL in which the workpiece model WM is brought into contact with the workpiece model WM in various postures and from various directions. 2 Work Model WM 1 The simulation unit 58 functions as a simulation execution unit 58 (FIG. 17) that executes a simulation SL in which the object is brought into contact with the object.
[0157] In step S52, the processor 32 functions as the confirmation area setting unit 54 and sets a confirmation area VE on the workpiece model WM based on the simulation result of step S51. Specifically, when one simulation SL is executed in step S51, the processor 32 sets a confirmation area VE on the workpiece model WM. 1 One voxel VX of the hole model HM H , Work Model WM 2 At least one voxel VX of the solid part of S When the voxel VX H The score SC of the item is incremented by "1".
[0158] This score SC is calculated by calculating the workpiece model WM in one simulation SL in step S51. 2 Voxel VX S But, Work Model WM1 One voxel VX H Therefore, the voxel VX H The initial value of the score SC is SC=0, and the workpiece model WM 2 Voxel VX S But, Work Model WM 1 One voxel VX H When entering the voxel VX H The score SC of the item is incremented by "1" to become SC=1.
[0159] Each time the processor 32 executes the simulation SL in step S51, the processor 32 1 Each voxel VX H Then, when all the simulations SL in step S51 are completed, the processor 32 calculates the score SC of the workpiece model WM 1 Each voxel VX H The score SC is substituted into the following equation 2, and each voxel VX H A score judgment value η is calculated for the score: η = SC / i (Equation 2)
[0160] Here, i in Equation 2 is the number of times of the simulation SL (in other words, the number of workpiece models WM in various postures used in the simulation SC). 2 Then, the processor 32 functions as the confirmation region setting unit 54 and calculates the number of voxels VX H The score judgment value η is set to a predetermined threshold value η th Determine whether η≦η th Voxel VX that satisfies H is set in the confirmation region VE. As a result, the voxel VX of the hole model HM shown in FIG. H At least one (for example, all) of the above will be set in the verification area VE.
[0161] The above-mentioned formula 2 can be modified to the formula η=SC / i×100. The processor 32 also determines whether the above-mentioned score SC is equal to or smaller than a predetermined threshold value SC th Determine whether SC≦SCth Voxel VX that satisfies H may be set as the confirmation area VE. In this way, in step S52, the processor 32 functions as the confirmation area setting unit 54 and sets the confirmation area VE on the workpiece model WM based on the simulation results of step S51 (specifically, the score SC and the score determination value η).
[0162] After step S52, the processor 32 executes steps S42 to S48 described above, and specifies a further confirmation region VE based on the confirmation region VE set based on the simulation results (step S42), or sets the confirmation region VE to a threshold value ε th or D.A. th (step S45), modify or delete the confirmation area VE (step S47), and approve the confirmation area VE (step S48).
[0163] As described above, in this embodiment, the processor 32 functions as the position data acquisition unit 44, the position data cancellation unit 46, the first input reception unit 52, the confirmation area setting unit 54, the second input reception unit 56, and the simulation execution unit 58, and after setting the confirmation area VE in the workpiece model WM in the flow of FIG. 18, executes the flow of FIG. 4, and calculates the position of the workpiece W based on the detection data DD of the shape detection sensor 14. n Position data PD 1_n , P.D. 2_n Get.
[0164] Therefore, the position data acquisition unit 44, the position data cancellation unit 46, the first input reception unit 52, the confirmation area setting unit 54, the second input reception unit 56, and the simulation execution unit 58 determine the position of the workpiece W based on the detection data DD of the shape detection sensor 14. n Position data PD 1_n , P.D. 2_n The apparatus 70 (FIG. 16) for obtaining the above information is configured.
[0165] In this device 70, the simulation execution unit 58 executes the workpiece model WM 2 (Object model) to work model WM 1A simulation SL is executed in which the workpiece model WM is brought into contact with the workpiece model WM (step S51), and the confirmation area setting unit 54 sets a confirmation area VE on the workpiece model WM based on the simulation results (score SC, score judgment value η) executed by the simulation execution unit 58. According to this configuration, the confirmation area VE can be set automatically and with high accuracy on the workpiece model WM.
[0166] In this embodiment, two workpiece models WM 1 and W.M. 2 However, the present invention is not limited to this. The processor 32 may also execute a simulation SL in which three or more workpiece models WM are brought into contact with each other in step S51. k A simulation SL may be performed in which (k=1, 2, 3, . . . ) are brought into contact with each other.
[0167] Alternatively, in step S51, the processor 32 may create a plurality of workpiece models WM in a container model BM that models the container B shown in FIG. k The workpieces are piled up in a simulated manner, and multiple workpiece models WM are piled up in a simulated manner. k A simulation SL may be performed in which the arrangement and attitude of the object are repeatedly changed.
[0168] 4, 15, or 18 in accordance with a computer program PG pre-stored in memory 34. Furthermore, the functions of the device 50, 60, or 70 (i.e., the position data acquisition unit 44, the position data cancellation unit 46, the first input acceptance unit 52, the confirmation area setting unit 54, the second input acceptance unit 56, and the simulation execution unit 58) executed by the processor 32 may be functional modules realized by the computer program PG. This computer program PG may be provided in a form recorded on a computer-readable, non-transitory recording medium, such as a semiconductor memory, a magnetic recording medium, or an optical recording medium.
[0169] In addition, in the above-described embodiments, the functions of the device 50, 60, or 70 (i.e., the position data acquisition unit 44, the position data cancellation unit 46, the first input reception unit 52, the confirmation area setting unit 54, the second input reception unit 56, and the simulation execution unit 58) are described as being implemented in the control device 16.
[0170] However, the functions of the device 50, 60, or 70 are not limited to this, and may be implemented in, for example, a teaching device (such as a teaching pendant or a tablet-type mobile terminal) that teaches the robot 12 the operation for the task of step S5, or any other computer such as a PC. In this case, a processor of the teaching device or a computer such as a PC functions as the device 50, 60, or 70.
[0171] In the above embodiment, the processor 32 executes step S3 after step S2 (more specifically, step S15) in the flow of Fig. 4. However, this is not limiting, and the processor 32 may execute step S3 after step S13 or S14 in Fig. 6.
[0172] For example, when step S3 is executed after step S13, the processor 32 performs step S22 (FIG. 11 or 12) of step S3. n Initial position data PD 1_n The shape data SD within the confirmation area VE defined in the workpiece model WM that is matched when acquiring m The amount of data DA n If the determination in step S23 is YES, the processor 32 calculates the workpiece W obtained in step S13 in step S24. n Initial position data PD 1_n may be invalidated (e.g., deleted).
[0173] Note that the coarse search RS in step S13 and the fine search PR in step S14 described above are examples of methods for obtaining the position data PD of the workpiece W, and any modifications may be made to the coarse search RS or the fine search PR, or the position data PD of the workpiece W may be obtained by any other method that does not involve performing the coarse search RS and the fine search PR.
[0174] 4, 6, 11, 12, 15, or 18 can be modified in various ways. For example, step S12 or S15 may be omitted from the flow shown in FIG. 6. Furthermore, step S3 (FIGS. 11 and 12) to step S22 may be omitted, and the processor 32 may, in step S23, obtain the confirmation area VE of the matched workpiece model WM and the shape data SD. m Based on the coordinates of the point cloud and the sensor coordinate system C3, the shape data SD is stored in the confirmation area VE. m It may be determined whether or not
[0175] In the above embodiment, one workpiece W (for example, workpiece W 1 ) and the adjacent object is a second work W (work W 2 ) has been described. However, this is not limited to this, and the object adjacent to one workpiece W may be, for example, a jig placed in the container B, or a protrusion protruding from the inner wall of the container B. In this case, for example, if an object such as a jig or a protrusion cannot enter a hole H in the workpiece W, the hole model HM of the workpiece model WM corresponding to the hole H may be defined as the above-mentioned confirmation area VE. Furthermore, the workpiece W shown in FIG. 3 is just an example, and may have any other shape.
[0176] In the above embodiment, the shape detection sensor 14 is fixed to the end effector 28 (or the wrist flange 26b) and moved by the robot 12. However, this is not limiting, and the shape detection sensor 14 may be fixed to a known position in the robot coordinate system C1, for example, using a support structure. Furthermore, the shape detection sensor 14 is not limited to a three-dimensional visual sensor, and may be a laser scanner capable of detecting the three-dimensional shape of an object.
[0177] Alternatively, the shape detection sensor 14 may include a two-dimensional camera and a distance measurement sensor capable of measuring the distance d to an object. The detection data DD detected by the shape detection sensor 14 is not limited to the three-dimensional point cloud image data shown in Fig. 5, but may include a data set of two-dimensional image data captured by a two-dimensional camera and the distance d measured by a distance measurement sensor, or may be any other type of image data (for example, distance image data).
[0178] Furthermore, the robot 12 is not limited to a vertical articulated robot, but may be any type of robot, such as a horizontal articulated robot, a parallel link robot, etc. While the present disclosure has been described above through the embodiments, the above-described embodiments do not limit the scope of the invention claimed.
[0179] REFERENCE SIGNS LIST 10 Robot system 12 Robot 14 Shape detection sensor 16 Control device 32 Processor 44 Position data acquisition unit 46 Position data cancellation unit 50, 60, 70 Device 52 First input reception unit 54 Confirmation area setting unit 56 Second input reception unit 58 Simulation execution unit
Claims
1. 1. An apparatus for acquiring position data of a workpiece based on detection data of a shape detection sensor that detects a shape of an object and a workpiece adjacent to the object and having an area into which the object cannot enter, comprising: a position data acquisition unit that acquires the position data by matching a workpiece model that is a model of the workpiece and has a confirmation area that corresponds to the inaccessible area to shape data of the workpiece included in the detection data; and a position data cancellation unit that invalidates the position data acquired by the position data acquisition unit when shape data of the object included in the detection data is present in the confirmation area defined in the work model that the position data acquisition unit matches to the shape data of the work.
2. a first input receiving unit that receives an input that designates the confirmation area in the work model; The apparatus according to claim 1 , further comprising: a confirmation area setting unit that sets the confirmation area on the workpiece model in response to the input received by the first input receiving unit.
3. The apparatus according to claim 1 , further comprising a confirmation area setting unit that automatically sets the confirmation area on the work model based on the work model.
4. a simulation execution unit that executes a simulation of bringing an object model obtained by modeling the object into contact with the workpiece model, The apparatus according to claim 3 , wherein the confirmation area setting unit sets the confirmation area in the workpiece model based on a result of a simulation executed by the simulation execution unit.
5. The position data acquisition unit generates the work model in a plurality of postures in order to perform the matching, The apparatus according to any one of claims 2 to 4, wherein the confirmation area setting unit sets the confirmation area for the work model in each of the poses.
6. The device according to any one of claims 2 to 4, further comprising a second input receiving unit that receives an input for modifying, deleting or approving the confirmation area set by the confirmation area setting unit.
7. The position data cancellation unit Calculating a data amount of shape data of the object within the confirmation area defined in the matched work model; 5. The device according to claim 1, further comprising: determining whether or not shape data of the object is present in the confirmation area based on the calculated amount of data.
8. The device according to claim 7 , wherein the position data cancellation unit determines whether or not shape data of the object is present in the confirmation area by performing a predetermined calculation using the calculated data amount and the data amount of the work model.
9. The apparatus according to claim 7 , wherein the position data cancellation unit determines whether or not to calculate the amount of data based on a detection result parameter indicating a result of the matching, or a posture or position of the matched work model.
10. The apparatus according to any one of claims 1 to 4, wherein the object is a second workpiece separate from the workpiece.
11. The position data acquisition unit acquires position data of a third workpiece by matching the workpiece model to shape data of a third workpiece different from the workpiece, the shape data being included in the detection data; and The position data cancellation unit After the position data acquisition unit acquires the position data of the third workpiece, the shape data of the third workpiece is erased from the detection data; An apparatus according to any one of claims 1 to 4, which determines whether or not shape data of the object included in the detection data from which the shape data of the third workpiece has been erased is present in the confirmation area defined in the matched workpiece model.
12. A robot control device comprising the device according to any one of claims 1 to 4.
13. A robot that performs a predetermined task on a workpiece; A shape detection sensor for detecting a shape of the workpiece; 13. A robot system comprising: the control device according to claim 12, which controls the robot so as to perform the predetermined task based on detection data from the shape detection sensor.
14. A method for acquiring position data of a workpiece based on detection data of a shape detection sensor that detects a shape of an object and a workpiece adjacent to the object and having an area into which the object cannot enter, comprising: The processor: A workpiece model is a model of the workpiece, and a confirmation area corresponding to the inaccessible area is defined. The workpiece model is matched with shape data of the workpiece included in the detection data to acquire the position data. A method for invalidating the acquired position data when shape data of the object included in the detection data is present in the confirmation area defined in the work model that matches the shape data of the work.
15. A computer program product causing the processor to perform the method of claim 14.