Program Example 8.2
Example Type:
Using Part Blob SearchWinType RotatedRectangle
Configuration
- Number of Robots: 1
- Number of Feeders: 1
- Number of Parts Types on the Feeder: 1
- Number of Placement Positions: 1
- Camera Orientation: Fixed Downward Camera over Feeder#1
Description
When the camera’s field of view and feeder tray are not parallel to each other, it can be difficult to properly size the Part Blob’s search window. If the search window is too large, then the Part Blob may detect the tray as parts. If the search window is too small, then the system cannot make proper judgements on the quantity and dispersion of the parts on the tray. Starting with EPSONRC+ 7.5.2, the Part Blob object can use a "RotatedSearchWin" for the SearchWinType property.
Here is an example of when the SearchWinType is set to "Rectangle".
When the Part Blob’s SearchWinType is set to "RotatedRectangle", the camera’s field of view and the feeder’s tray can be aligned.
KEY POINTS
The SearchWin Angle property is restricted to +/-45 degrees for the Part Blob.
No special part feeding code is required.
Sample Code
Main.prg
Function main
If Motor = Off Then
Motor On
EndIf
Power Low
Jump Park
PF_Start 1
Fend
PartFeeding.prg
Function PF_Robot(PartID As Integer) As Integer
Do While PF_QueLen(PartID) > 0
P0 = PF_QueGet(PartID)
Jump P0
On Gripper; Wait 0.2
Jump Place
Off Gripper; Wait 0.2
PF_QueRemove PartID
If PF_IsStopRequested(PartID) = True Then
Exit Do
EndIf
Loop
PF_Robot = PF_CALLBACK_SUCCESS
Fend