A robot collision avoidance control method and system for use in an automated production line
By employing a robot gripping system controlled by a line-based programmable logic controller in an automated production line, QR code information is collected and compared in real time. Combined with physical isolation of hard-line I/O, the problem of collisions caused by incorrect model numbers during robot gripping is solved, thus improving the safety and efficiency of the production line.
Patent Information
- Authority / Receiving Office
- CN · China
- Patent Type
- Patents(China)
- Current Assignee / Owner
- JIER MACHINE TOOL GROUP
- Filing Date
- 2026-04-13
- Publication Date
- 2026-07-24
AI Technical Summary
In existing automated production lines, collisions caused by incorrect workpiece models frequently occur during robot gripping. Existing error prevention systems cannot effectively prevent incorrect gripping caused by workpiece stacking and obstruction, adjacent workpiece adhesion, gripping position deviation, etc., and cannot prevent accidents from occurring when software fails or communication is interrupted.
The robot grasping system, controlled by a line-based programmable logic controller, continuously acquires multiple frames of QR code images when the robot enters the grasping trajectory, analyzes them in real time, and performs double comparison. Combined with the physical isolation signal of hard-wired I/O to cut off the power circuit, grasping is only allowed after ensuring that the model is correct; otherwise, it immediately stops.
It enables full-process monitoring of the robot's grasping process, preventing collisions caused by incorrect workpiece models, protecting equipment safety, reducing production downtime, and improving production efficiency and safety.
Smart Images

Figure CN122008254B_ABST
Abstract
Description
Technical Field
[0001] This application relates to the field of automated production line control technology, specifically to a robot grasping anti-collision control method and system for automated production lines. Background Technology
[0002] As the manufacturing industry shifts towards small-batch, multi-variety production, an automated production line often needs to accommodate mixed production of various workpiece models. In this production model, materials are typically prepared by manual labor or AGVs (Automated Guided Vehicles) to grab workstations on the production line. However, in actual production, due to human error or management loopholes, workpieces of other models frequently end up mixed in with the loading trays. When a workpiece that doesn't match the current production task is mixed into the tray, existing error-proofing systems typically use a single-scan verification method: a barcode scanner is placed at a fixed location; when the workpiece is transported to that location, the QR code information is read and compared with a preset model number; if they don't match, the conveyor mechanism stops or an alarm is triggered.
[0003] However, the single-check method has significant drawbacks: single-check is only performed before the workpiece enters the gripping station, and cannot detect incorrect gripping caused by workpiece stacking, adjacent workpieces sticking together, or gripping position deviation at the moment of gripping; when the robot grips the wrong type of workpiece according to the preset trajectory, the workpiece size and shape may not match the expectation, causing the robot to collide violently with the material frame or surrounding equipment, resulting in equipment damage, production line stoppage, or even personnel safety accidents; existing systems only stop the equipment through software commands in case of abnormalities, and once the software program fails or communication is interrupted, it will not be able to effectively prevent accidents from occurring.
[0004] Therefore, how to achieve full-process monitoring of the robot's grasping process and prevent collisions caused by incorrect workpiece models has become a technical problem that urgently needs to be solved in this field. Summary of the Invention
[0005] To address the aforementioned issues, this invention provides a robot-assisted anti-collision control method and system for use in automated production lines. This system prevents collisions and safety accidents caused by the robot colliding with other vehicle model blanks in the loading frame due to missed inspections in the previous process.
[0006] In a first aspect, the present invention provides a collision avoidance control method for robot gripping in an automated production line, applied to a robot gripping system controlled by a line programmable logic controller, comprising the following steps:
[0007] S1. When the trigger signal for the robot to enter the grasping trajectory is received, the line programmable logic controller sends a start command to the barcode scanner. During the process of the robot gripper moving towards the workpiece in the material box, the barcode scanner continuously collects multiple frames of QR code images at a preset frequency.
[0008] S2. Perform real-time analysis on multiple frames of images, extract clear and readable QR code information frames, and parse to obtain the first workpiece model data;
[0009] S3. At the moment the robot gripper contacts and grasps the workpiece, the barcode scanner is triggered again to acquire the QR code image at the moment of grasping and to parse the second workpiece model data.
[0010] S4. Compare the first workpiece model data and the second workpiece model data with the target model data preset on the touch screen.
[0011] S5. If the double comparison results are consistent, send a lifting permission signal to the robot control system to control the robot to take the workpiece out of the material box and transfer it to the processing station.
[0012] S6. If any comparison result is inconsistent, immediately execute the emergency stop procedure:
[0013] The robot's grasping program is interrupted by software commands, triggering an audible and visual alarm.
[0014] By outputting a physically isolated signal through an independent hardwired I / O, the safety relay coil connected in series in the robot's grasping power circuit is cut off, keeping the robot in its current safe posture and preventing collision accidents.
[0015] By independently collecting and parsing QR codes twice—before and immediately after grasping—the entire process from grasping decision to grasping execution is monitored, solving the problem that existing technologies, with only a single verification, cannot detect state changes during grasping. When an incorrect workpiece model is detected, the program is interrupted not only through software instructions but also by physically cutting off the power source through independent hard-wired I / O, forming a dual safety barrier of logical interruption and physical isolation. This effectively prevents collisions caused by software failures or communication malfunctions. During emergency stops, the robot maintains its current safe posture, preventing falls or swings caused by emergency braking and avoiding secondary injuries to surrounding equipment and personnel. This fundamentally eliminates robot collisions caused by incorrect workpiece models, protecting equipment safety, reducing production downtime, and improving overall production efficiency and safety.
[0016] As a preferred embodiment of the technical solution of the present invention, the trigger signal for the robot to enter the grasping trajectory in S1 is generated through a dual confirmation mechanism involving both hardware and software:
[0017] Condition 1: Receive the path planning completion signal from the robot control system to confirm that the robot has generated a complete grasping motion trajectory;
[0018] Condition 2: Receive the detection signal from the proximity switch installed at the starting point of the grasping trajectory to confirm that the robot has physically reached the preset trigger position;
[0019] A trigger signal for the robot to enter the grasping trajectory is generated only when both conditions one and two are met simultaneously.
[0020] The path planning completion signal ensures the robot is ready to perform the grasping action, while the proximity switch detection signal provides independent physical position confirmation. This dual confirmation prevents scanning timing errors caused by false or missed triggering from a single signal source. It ensures the scanning action starts at the optimal moment when the robot enters the grasping trajectory, avoiding image acquisition quality degradation due to premature or delayed triggering.
[0021] As a preferred embodiment of the technical solution of the present invention, in step S2, multiple frames of images are analyzed in real time to extract clear and readable QR code information frames and parse the data to obtain the first workpiece model data, specifically including:
[0022] S21. Perform QR code region detection and positioning on the acquired continuous image frames;
[0023] S22. Evaluate the quality of the located QR code area and select valid image frames that meet the decoding requirements.
[0024] S23. Perform image optimization processing on the selected valid image frames to obtain a decodeable QR code image;
[0025] S24. Decode the optimized QR code image and extract the first workpiece model data.
[0026] First, QR code region detection is performed. Only the located regions are evaluated and optimized to avoid wasting computational resources on full-image processing and improve real-time processing capabilities. Valid frames are selected through quality evaluation and then optimized specifically to ensure that the image quality input to the decoder meets decoding requirements, thereby improving the overall recognition rate.
[0027] As a preferred embodiment of the technical solution of the present invention, in S22, the quality of the located QR code area is evaluated, and valid image frames that meet the decoding requirements are selected. This is achieved using a multi-frame fusion method, specifically including:
[0028] S221. Calculate the overall quality score of each frame image, wherein the overall quality score includes at least the sharpness index, the contrast index, and the motion blur index.
[0029] S222. Select the top K images based on the overall quality score as candidate valid frames, where K is a preset integer greater than 1;
[0030] In S23, the selected valid image frames are subjected to image optimization processing, specifically including: image registration and pixel-level fusion of K candidate valid frames to generate a fused QR code image.
[0031] By fusing multiple frames, interference factors such as random noise, momentary occlusion, and lighting fluctuations in a single-frame image are effectively eliminated, resulting in a clearer and more stable QR code image. Different frames may capture different local details of the QR code; multi-frame fusion can achieve information complementarity, generating a more complete QR code image and improving the decoding success rate. During robot movement, different frames may capture QR codes from different angles and distances; multi-frame fusion integrates information from multiple perspectives, overcoming the limitations of a single perspective.
[0032] As a preferred embodiment of the technical solution of the present invention, in S22, the quality of the located QR code area is evaluated to select valid image frames that meet the decoding requirements, and in S23, the selected valid image frames are subjected to image optimization processing using an adaptive strategy.
[0033] The highest quality single-frame image is directly enhanced and decoded;
[0034] If single-frame decoding fails, multi-frame fusion mode is activated, and image registration and pixel-level fusion of multiple frames are performed before attempting decoding again.
[0035] When image quality is sufficiently good, single-frame processing is prioritized to save computational resources and processing time; multi-frame fusion, which requires significant computation, is only initiated when necessary, achieving a dynamic balance between efficiency and success rate. This adapts to the high-speed cycle requirements of automated production lines, completing single-frame processing quickly in most cases without slowing down production. It avoids using computationally intensive multi-frame fusion processing in all situations, reducing system power consumption and hardware costs, and extending equipment lifespan.
[0036] As a preferred embodiment of the technical solution of this invention, in step S3, at the instant the robot gripper contacts and grasps the workpiece, the barcode scanner is triggered to collect and parse the second workpiece model data again. This is achieved using a multi-source signal fusion triggering method, specifically including:
[0037] S31a. The force feedback signal when the gripper contacts the workpiece is monitored in real time by force sensors installed on the robot gripper. When the force feedback signal exceeds the preset threshold, it is determined that the gripping moment has arrived and a first trigger signal is generated.
[0038] S32a. Simultaneously receive the grasping action execution status signal fed back by the robot control system. When the grasping action execution status signal indicates that the gripper has reached the grasping position and the gripper begins to close, generate a second trigger signal.
[0039] S33a. Perform a logical AND operation on the first trigger signal and the second trigger signal. Only when both signals are valid at the same time, generate the final instantaneous trigger command for grabbing.
[0040] S34a. In response to the instantaneous trigger command for grasping, control the barcode scanner to perform single-frame or multi-frame image acquisition, and simultaneously activate the supplementary lighting device to ensure that a clear QR code image is captured the instant the gripper contacts the workpiece.
[0041] S35a. Detect the QR code region in the captured image at the moment of capture, and quickly locate the QR code region in the image by combining the prior information of the QR code position obtained in stage S2.
[0042] S36a. Perform targeted image enhancement processing on the located QR code area to compensate for motion blur and lighting changes caused by the moment of contact.
[0043] S37a. Decode the processed QR code image, extract the workpiece model information, and output it as the second workpiece model data after format verification.
[0044] Force sensors ensure triggering the gripper at the instant of physical contact with the workpiece, while robot status signals ensure the gripping action has reached the correct stage. This dual confirmation guarantees strict synchronization between triggering and gripping. Logic and computation require two independent signals to be valid simultaneously, effectively preventing false triggering due to sensor noise, signal interference, or single sensor failure. Simultaneous activation of the supplementary lighting device ensures optimal illumination conditions at the moment of contact, capturing a clear image. Combined with prior information about the QR code position obtained in stage S2, the QR code area in the image at the moment of gripping can be quickly located, improving processing speed. Compensation and optimization are performed to address the motion blur and illumination changes unique to the moment of contact, further improving decoding success rate.
[0045] As a preferred embodiment of the technical solution of this invention, in step S3, at the instant the robot gripper contacts and grasps the workpiece, the barcode scanner is triggered to collect and parse the second workpiece model data again. This is achieved using a multi-source signal comprehensive judgment method, specifically including:
[0046] S31b, Real-time acquisition of the status of at least two of the following trigger signal sources:
[0047] Force sensor signal used to detect changes in force feedback when the gripper comes into contact with the workpiece;
[0048] Position sensor signal used to detect whether the gripper has reached the preset gripping position;
[0049] Status signals of the robot control system used to monitor the progress of the grasping action;
[0050] Grip opening sensor signal used to monitor the degree of gripper closure;
[0051] S32b. Based on the preset triggering logic, the multi-source signals are comprehensively judged, and a triggering command is generated when the judgment condition for the grasping moment is met; the triggering logic includes: the force sensor signal exceeds the set threshold and the gripper opening sensor signal begins to change, or the force sensor signal exceeds the set threshold and the robot control system reports that the grasping action has been executed to the preset stage.
[0052] S33b responds to the generated trigger command and controls the barcode scanner to complete image acquisition, ensuring that the acquisition moment is strictly synchronized with the grab moment;
[0053] S34b: Perform QR code recognition and decoding on the acquired image, and output the second workpiece model data.
[0054] By integrating multiple signals such as force feedback, position, robot status, and gripper opening, the system achieves more accurate judgment at the moment of grasping, unaffected by the failure or interference of a single sensor. The scanning process is strictly synchronized with the grasping action, ensuring image acquisition is completed before the workpiece is moved or obstructed, improving the stability and accuracy of the second scanning stage and enhancing anti-collision protection.
[0055] As a preferred embodiment of the technical solution of this invention, in step S3, at the instant the robot gripper contacts and grasps the workpiece, the barcode scanner is triggered to collect and parse the second workpiece model data again. This is achieved using a predictive triggering strategy to overcome the problem of the gripper obscuring the QR code. Specifically, this includes:
[0056] S31c: Based on the robot's current speed and remaining distance, dynamically calculate the remaining time required for the gripper to contact the workpiece. ;
[0057] S32c, based on barcode scanner system delay time Set an early trigger threshold ,in, This is a preset safety margin;
[0058] S33c, Real-time monitoring ,when ≤ At the same time, the barcode scanner is triggered to capture images before the gripper contacts the workpiece, ensuring that the image is captured within the window period before the gripper obscures the QR code;
[0059] S34c: Perform QR code recognition on the acquired image and parse it to obtain the second workpiece model data.
[0060] By employing a predictive, pre-triggered approach, the robot dynamically calculates the optimal time for data collection based on its speed and distance, completing the scan before the gripper obstructs the QR code. This fundamentally solves the problem of scan failure and verification failure caused by gripper obstruction. It ensures that valid workpiece model information is still obtained at the moment of grasping, maintaining the integrity of the dual comparison logic and preventing collisions caused by scan failure.
[0061] As a preferred embodiment of the technical solution of the present invention, in S3, at the instant the robot gripper contacts and grasps the workpiece, the barcode scanner is triggered to collect and parse the second workpiece model data again, which is achieved by a dual-camera collaborative method, specifically including:
[0062] S31d. A first barcode scanner and a second barcode scanner are set on the robot gripper. The first barcode scanner faces the front of the workpiece, and the second barcode scanner faces the side or oblique direction of the workpiece to cover the QR code positions at different angles.
[0063] S32d: When the moment of grabbing is detected, the first barcode scanner and the second barcode scanner are simultaneously triggered to acquire images, obtaining at least two images of the moment of grabbing from different perspectives.
[0064] S33d: Perform QR code region detection on two images from different perspectives;
[0065] S34d: Execute the corresponding decoding strategy based on the detection results.
[0066] If any image successfully detects a QR code, that image will be used first for decoding to obtain the first candidate result;
[0067] If both images detect a QR code but the decoding results are inconsistent, the decoding result with higher quality is selected based on the image quality evaluation index to obtain the first candidate result.
[0068] If neither image can be decoded independently, then the two images are subjected to viewpoint fusion processing to generate a fused QR code image, and the fused QR code image is decoded to obtain the first candidate result;
[0069] S35d. Perform format verification on the first candidate result. If the verification passes, output the second workpiece model data.
[0070] Dual barcode scanners work together to collect data from multiple angles, covering the front, side, and oblique QR code locations. If a single view fails, decoding can be performed from the other view; if both views are unsatisfactory, view fusion processing is used. This completely solves the problem of single-angle scanning being easily limited by workpiece placement, gripper obstruction, and QR code printing position, achieving scanning without blind spots and zero omissions in model recognition, allowing the error-proofing and foolproofing system to operate reliably under complex working conditions.
[0071] Secondly, the present invention also provides a robot gripping anti-collision control system for automated production lines, comprising:
[0072] The touchscreen human-machine interface module is used to preset the target model data required for the current production task and display the production status and alarm information;
[0073] The robot grasping module includes a robot with multiple degrees of freedom and a barcode scanner installed at the end of the robot gripper. The robot is used to perform grasping trajectory movements, and the barcode scanner is used to collect QR code images on the workpiece during the robot's movement and at the moment of grasping.
[0074] The signal acquisition module includes a proximity switch installed at the starting point of the grasping trajectory, a force sensor installed on the robot gripper, and a control system interface for monitoring the robot's status, used to generate trigger signals and status signals;
[0075] The line-type programmable logic controller (PLC) module is connected to the touchscreen human-machine interface module, the robot grasping module, and the signal acquisition module, respectively. It is used to generate trigger signals for the robot to enter the grasping trajectory and for the moment of grasping, based on multi-source signals acquired by the signal acquisition module; to perform real-time analysis of multi-frame QR code images acquired by the barcode scanner, extracting clear and readable QR code information frames, and parsing to obtain first and second workpiece model data; to perform dual comparisons of the first and second workpiece model data with preset target model data on the touchscreen, generating comparison result signals; and to send a lifting permission signal or an emergency stop command to the robot grasping module based on the comparison result signals.
[0076] The safety execution module includes a safety relay connected in series in the robot's grasping power circuit. The safety relay is controlled by the inline programmable logic controller module through an independent hardwired I / O output and is used to physically cut off the robot's grasping power source in the event of an emergency stop.
[0077] The alarm module, connected to the line programmable logic controller module, is used to trigger an audible and visual alarm during an emergency stop.
[0078] As can be seen from the above technical solution, this application has the following advantages: Through a complete control logic including robot grasping trajectory triggering, continuous scanning during movement, secondary scanning at the moment of grasping, dual model comparison, and dual-path emergency stop (software / hardware), it achieves a closed-loop error-proof system throughout the entire process, building upon the existing communication between the line's programmable logic controller and the barcode scanner, and model comparison error prevention. Continuous data acquisition during movement allows for advance identification of the workpiece model; secondary verification at the moment of grasping eliminates misjudgment and obstruction interference; grasping is only allowed if the dual comparisons match; if they do not match, the software immediately interrupts the program and the hardware cuts off the power circuit. This thoroughly prevents the robot from grasping the wrong workpiece and colliding with the machine from both software logic and physical safety perspectives, effectively protecting equipment, reducing line downtime, and improving the stability and production efficiency of multi-variety mixed-line production. Attached Figure Description
[0079] To more clearly illustrate the technical solution of this application, the accompanying drawings used in the description will be briefly introduced below. Obviously, the accompanying drawings described below are only some embodiments of this application. For those skilled in the art, other drawings can be obtained based on these drawings without creative effort.
[0080] Figure 1 This is a flowchart illustrating the method provided in an embodiment of the present invention.
[0081] Figure 2 A block diagram of a system provided in an embodiment of the present invention. Detailed Implementation
[0082] To make the purpose, features, and advantages of this application more apparent and understandable, specific embodiments and accompanying drawings will be used to clearly and completely describe the technical solution protected by this application. Obviously, the embodiments described below are only some embodiments of this application, and not all embodiments. Based on the embodiments in this application, all other embodiments obtained by those skilled in the art without creative effort are within the scope of protection of this application.
[0083] Unless otherwise defined, all technical and scientific terms used in this application have the same meaning as commonly understood by one of ordinary skill in the art to which this invention pertains. The terminology used in this application and in the specification of this invention is for the purpose of describing particular embodiments only and is not intended to be limiting of the invention.
[0084] like Figure 1 As shown, this embodiment of the invention provides a robot gripping anti-collision control method for use in automated production lines, applied to a robot gripping system controlled by a line programmable logic controller, including the following steps:
[0085] S1. In response to the trigger signal that the robot enters the grasping trajectory, the line programmable logic controller (PLC) sends a start command to the barcode scanner. During the process of the robot gripper moving towards the workpiece in the material box, the barcode scanner continuously collects multiple frames of QR code images at a preset frequency; the line PLC receives and buffers the image data in real time.
[0086] S2. Perform real-time analysis on multiple frames of images, extract clear and readable QR code information frames, and parse to obtain the first workpiece model data;
[0087] In this step, the line PLC performs real-time analysis on the continuously acquired multiple frames of images: detects and locates the QR code area in the image; filters out image frames whose clarity and contrast meet the decoding requirements; optimizes the filtered images; and parses the QR code information to extract the first workpiece model data.
[0088] S3. At the moment the robot gripper contacts and grasps the workpiece, the barcode scanner is triggered again to acquire the QR code image at the moment of grasping and to parse the second workpiece model data.
[0089] In this step, the moment the robot gripper moves to contact the workpiece and performs the gripping action, the line PLC triggers the barcode scanner again to acquire an image based on the acquired signal, obtaining a QR code image at the moment of gripping. The line PLC then decodes this image to extract the second workpiece model data.
[0090] S4. Compare the first workpiece model data and the second workpiece model data with the target model data preset on the touch screen.
[0091] Here, the line PLC will independently compare the parsed first workpiece model data and second workpiece model data with the target workpiece model data that the operator has preset and confirmed on the touch screen, generating two sets of comparison results.
[0092] S5. If the double comparison results are consistent, send a lifting permission signal to the robot control system to control the robot to take the workpiece out of the material box and transfer it to the processing station.
[0093] If the model numbers of the first and second workpieces are consistent with the target model, the line PLC sends a lifting permission signal to the robot control system. The robot then performs the grasping, lifting, and transferring actions to remove the workpiece from the material frame and deliver it to the processing station, and the production line operates normally.
[0094] S6. If any comparison result is inconsistent, immediately execute the emergency stop procedure and simultaneously activate two levels of protection:
[0095] Software stop: The robot's grasping program is immediately interrupted via the PLC program, an alarm signal is output, and an on-site audible and visual alarm is triggered;
[0096] Hardware emergency stop: By outputting a physical isolation signal through an independent hardwired IO port, the safety relay coil connected in series in the robot's gripping power circuit is cut off, forcibly cutting off the gripping power, so that the robot maintains its current safe posture and no longer performs gripping or moving actions, thus completely avoiding robot collisions, equipment damage and production line stoppages caused by incorrect workpiece models.
[0097] In some embodiments, the trigger signal for the robot to enter the grasping trajectory in S1 is generated through a dual confirmation mechanism involving both hardware and software:
[0098] Condition 1: Receive the path planning completion signal from the robot control system to confirm that the robot has generated a complete grasping motion trajectory;
[0099] Condition 2: Receive the detection signal from the proximity switch installed at the starting point of the grasping trajectory to confirm that the robot has physically reached the preset trigger position;
[0100] A trigger signal for the robot to enter the grasping trajectory is generated only when both conditions one and two are met simultaneously.
[0101] The line PLC interacts with the robot control system in real time, continuously receiving path planning completion signals from the robot. Condition one is met when the robot completes its grasping trajectory planning, generates an executable motion path, and sends a ready status to the PLC.
[0102] A proximity switch is installed at the starting trigger position of the robot's grasping trajectory as a position detection element, and the proximity switch is connected to the digital input terminal of the line PLC. When the robot body or actuator moves to the preset position and is detected by the proximity switch, the PLC acquires a valid level signal, and the second judgment condition is met.
[0103] The PLC inside the production line performs a logical AND operation on conditions one and two:
[0104] The PLC will only output a valid trigger signal for the robot to enter the grasping trajectory when both the path planning completion signal and the proximity switch position detection signal are valid. If either condition is invalid or missing, no trigger signal will be generated, the barcode scanner will not start, and the robot will not enter the scanning and grasping execution phase.
[0105] By verifying both hardware and software, the timing of scanning is strictly synchronized with the robot's movement state and physical position, avoiding accidental triggering, empty scanning, premature scanning, or delayed scanning, thus improving the reliability of the error prevention system.
[0106] In some embodiments, S2 involves real-time analysis of multiple image frames to extract clearly readable QR code information frames and parsing them to obtain the first workpiece model data, specifically including:
[0107] S21. Perform QR code region detection and positioning on the acquired continuous image frames;
[0108] S22. Evaluate the quality of the located QR code area and select valid image frames that meet the decoding requirements.
[0109] S23. Perform image optimization processing on the selected valid image frames to obtain a decodeable QR code image;
[0110] S24. Decode the optimized QR code image and extract the first workpiece model data.
[0111] In this embodiment of the invention, in step S22, the quality of the located QR code area is evaluated, and valid image frames that meet the decoding requirements are selected. This is achieved using a multi-frame fusion method, specifically including:
[0112] S221. Calculate the overall quality score of each frame image, wherein the overall quality score includes at least the sharpness index, the contrast index, and the motion blur index.
[0113] Sharpness index The variance is calculated using the Laplace method, formula:
[0114]
[0115] The current frame's QR code region image. Extracting Laplacian edges operator, Variance calculation: the larger the variance, the clearer the image. The higher.
[0116] Contrast Ratio The gray-scale standard deviation method is used for calculation. The formula is:
[0117]
[0118] This is the set of grayscale values for all pixels in the QR code area. This represents the grayscale standard deviation; the larger the standard deviation, the higher the contrast. The higher.
[0119] Motion blur index The gradient energy method is used for calculation, and the formula is as follows:
[0120]
[0121] The gradient function calculates the gradient value of each pixel in an image. This is a summation operator that accumulates and sums the gradient magnitudes of all pixels in the image.
[0122] After normalizing the three indicators to the [0, 1] interval, they are then summed using preset weights:
[0123] Overall quality score
[0124] in, This is the normalized value of the sharpness index. This is the normalized value of the contrast index. The normalized value of the motion ambiguity index. Let be the weighting coefficient, satisfying .
[0125] S222. Select the top K images based on the overall quality score as candidate valid frames, where K is a preset integer greater than 1;
[0126] In S23, the selected valid image frames are subjected to image optimization processing, specifically including: image registration and pixel-level fusion of K candidate valid frames to generate a fused QR code image.
[0127] In this embodiment of the invention, in step S22, the quality of the located QR code region is evaluated to select valid image frames that meet the decoding requirements; and in step S23, the selected valid image frames are subjected to image optimization processing using an adaptive strategy.
[0128] The highest quality single-frame image is directly enhanced and decoded;
[0129] If single-frame decoding fails, multi-frame fusion mode is activated, and image registration and pixel-level fusion of multiple frames are performed before attempting decoding again.
[0130] In some embodiments, in step S3, at the instant the robot gripper contacts and grasps the workpiece, the barcode scanner is triggered to collect and parse the second workpiece model data again. This is achieved using a multi-source signal fusion triggering method, specifically including:
[0131] S31a. The force feedback signal when the gripper contacts the workpiece is monitored in real time by force sensors installed on the robot gripper. When the force feedback signal exceeds the preset threshold, it is determined that the gripping moment has arrived and a first trigger signal is generated.
[0132] S32a. Simultaneously receive the grasping action execution status signal fed back by the robot control system. When the grasping action execution status signal indicates that the gripper has reached the grasping position and the gripper begins to close, generate a second trigger signal.
[0133] S33a. Perform a logical AND operation on the first trigger signal and the second trigger signal. Only when both signals are valid at the same time, generate the final instantaneous trigger command for grabbing.
[0134] S34a. In response to the instantaneous trigger command for grasping, control the barcode scanner to perform single-frame or multi-frame image acquisition, and simultaneously activate the supplementary lighting device to ensure that a clear QR code image is captured the instant the gripper contacts the workpiece.
[0135] S35a. Detect the QR code region in the captured image at the moment of capture, and quickly locate the QR code region in the image by combining the prior information of the QR code position obtained in stage S2.
[0136] S36a. Perform targeted image enhancement processing on the located QR code area to compensate for motion blur and lighting changes caused by the instant of contact; specifically including:
[0137] Gradient analysis is performed on the QR code image captured at the moment of capture to estimate the direction and degree of motion blur of the image and generate blur parameters.
[0138] Based on the blur parameters, Wiener filtering or unsharpening masking methods are used to deblur the image, restore edge sharpness, and obtain a first intermediate image. Specifically, when the blur parameters can be accurately estimated, Wiener filtering is used: a point spread function for motion blur is constructed based on the estimated blur direction and blur length, and Wiener filtering is performed in the frequency domain to restore a clear image. When the blur parameters are difficult to estimate accurately or to meet real-time requirements, unsharpening masking is used: a Gaussian blur is applied to the image to generate a blurred version, high-frequency details are extracted, and the high-frequency details are multiplied by an enhancement coefficient and then superimposed back onto the original image to achieve rapid sharpening.
[0139] Background illumination is estimated for the first intermediate image to generate a relative illumination map, and shadow areas and overexposed areas are identified based on the relative illumination map;
[0140] The identified shadow areas and overexposed areas are compensated for illumination using adaptive gamma correction or local histogram equalization, respectively, to obtain a second intermediate image. The specific implementation of local illumination correction is as follows: For shadow areas, the gamma correction parameters are dynamically adjusted according to the ratio of local illumination to normal area illumination to enhance the brightness and restore the contrast of the shadow areas; For overexposed areas, a homomorphic filtering method is used to suppress low-frequency illumination components and enhance high-frequency reflection components in the frequency domain to restore the texture information of the overexposed areas.
[0141] The second intermediate image is enhanced by using a contrast-limited adaptive histogram equalization method to improve the distinguishability of the black and white modules of the QR code, resulting in the third intermediate image. The specific implementation of the contrast-adaptive enhancement is as follows: the image is divided into several sub-blocks, a gray-level histogram is calculated for each sub-block, the histogram is cropped to limit the contrast magnification factor, the cropped histogram is equalized, and finally the sub-blocks are stitched together by bilinear interpolation to eliminate block artifacts and obtain the enhanced image.
[0142] The sharpness and contrast metrics of the third intermediate image are calculated and compared with the original image before enhancement. If the enhancement effect is lower than a preset threshold or over-enhancement artifacts are detected, the image is reverted to the second intermediate image or the original image, and the final enhanced image is output. Specifically, the Laplacian variance of the enhanced image is calculated as the sharpness metric, and the grayscale standard deviation is calculated as the contrast metric. If the sharpness metric of the enhanced image is less than 1.2 times that of the original image, or the contrast metric is less than 1.1 times that of the original image, the enhancement effect is deemed insufficient, and the original image before enhancement is output. If the gradient direction consistency of the enhanced image is detected to be lower than a preset threshold, over-enhancement artifacts are determined to exist, and the second intermediate image is output.
[0143] S37a. Decode the processed QR code image, extract the workpiece model information, and output it as the second workpiece model data after format verification.
[0144] In some embodiments, in step S3, at the instant the robot gripper contacts and grasps the workpiece, the barcode scanner is triggered to collect and parse the second workpiece model data again. This is achieved using a multi-source signal comprehensive judgment method, specifically including:
[0145] S31b, Real-time acquisition of the status of at least two of the following trigger signal sources:
[0146] Force sensor signal used to detect changes in force feedback when the gripper comes into contact with the workpiece;
[0147] Position sensor signal used to detect whether the gripper has reached the preset gripping position;
[0148] Status signals of the robot control system used to monitor the progress of the grasping action;
[0149] Grip opening sensor signal used to monitor the degree of gripper closure;
[0150] S32b. Based on the preset triggering logic, the multi-source signals are comprehensively judged, and a triggering command is generated when the judgment condition for the grasping moment is met; the triggering logic includes: the force sensor signal exceeds the set threshold and the gripper opening sensor signal begins to change, or the force sensor signal exceeds the set threshold and the robot control system reports that the grasping action has been executed to the preset stage.
[0151] S33b responds to the generated trigger command and controls the barcode scanner to complete image acquisition, ensuring that the acquisition moment is strictly synchronized with the grab moment;
[0152] S34b: Perform QR code recognition and decoding on the acquired image, and output the second workpiece model data.
[0153] In some embodiments, in step S3, at the instant the robot gripper contacts and grasps the workpiece, the barcode scanner is triggered to collect and parse the second workpiece model data again. This is achieved using a predictive triggering strategy to overcome the problem of the gripper obscuring the QR code. Specifically, this includes:
[0154] S31c: Based on the robot's current speed and remaining distance, dynamically calculate the remaining time required for the gripper to contact the workpiece. ;
[0155] S32c, based on barcode scanner system delay time Set an early trigger threshold ,in, This is a preset safety margin;
[0156] S33c, Real-time monitoring ,when ≤ At the same time, the barcode scanner is triggered to capture images before the gripper contacts the workpiece, ensuring that the image is captured within the window period before the gripper obscures the QR code;
[0157] S34c: Perform QR code recognition on the acquired image and parse it to obtain the second workpiece model data.
[0158] In some embodiments, in step S3, at the instant the robot gripper contacts and grasps the workpiece, the barcode scanner is triggered to collect and parse the second workpiece model data again. This is achieved using a dual-camera collaborative approach, specifically including:
[0159] S31d. A first barcode scanner and a second barcode scanner are set on the robot gripper. The first barcode scanner faces the front of the workpiece, and the second barcode scanner faces the side or oblique direction of the workpiece to cover the QR code positions at different angles.
[0160] S32d: When the moment of grabbing is detected, the first barcode scanner and the second barcode scanner are simultaneously triggered to acquire images, obtaining at least two images of the moment of grabbing from different perspectives.
[0161] S33d: Perform QR code region detection on two images from different perspectives;
[0162] S34d: Execute the corresponding decoding strategy based on the detection results.
[0163] If any image successfully detects a QR code, that image will be used first for decoding to obtain the first candidate result;
[0164] If both images detect a QR code but the decoding results are inconsistent, the decoding result with higher quality is selected based on the image quality evaluation index to obtain the first candidate result.
[0165] If neither image can be decoded independently, then the two images are subjected to viewpoint fusion processing to generate a fused QR code image, and the fused QR code image is decoded to obtain the first candidate result;
[0166] S35d. Perform format verification on the first candidate result. If the verification passes, output the second workpiece model data.
[0167] like Figure 2 As shown, this embodiment of the invention provides a robot gripping anti-collision control system for use in an automated production line, comprising:
[0168] The touchscreen human-machine interface module is used to preset the target model data required for the current production task and display the production status and alarm information;
[0169] The robot grasping module includes a robot with multiple degrees of freedom and a barcode scanner installed at the end of the robot gripper. The robot is used to perform grasping trajectory movements, and the barcode scanner is used to collect QR code images on the workpiece during the robot's movement and at the moment of grasping.
[0170] The signal acquisition module includes a proximity switch installed at the starting point of the grasping trajectory, a force sensor installed on the robot gripper, and a control system interface for monitoring the robot's status, used to generate trigger signals and status signals;
[0171] The line-type programmable logic controller module is connected to the touch screen human-machine interface module, the robot grasping module, and the signal acquisition module, respectively. The line-type programmable logic controller module includes:
[0172] The trigger signal generation unit is used to generate trigger signals for the robot to enter the grasping trajectory and trigger signals at the moment of grasping, based on the multi-source signals collected by the signal acquisition module.
[0173] The image processing unit is used to perform real-time analysis on multiple frames of QR code images captured by the barcode scanner, extract clear and readable QR code information frames, and parse them to obtain the first workpiece model data and the second workpiece model data.
[0174] The dual comparison unit is used to perform dual comparisons of the first workpiece model data and the second workpiece model data with the target model data preset on the touch screen, and generate a comparison result signal.
[0175] The control command output unit is used to send a lifting permission signal or an emergency stop command to the robot grasping module based on the comparison result signal.
[0176] The safety execution module includes a safety relay connected in series in the robot's grasping power circuit. The safety relay is controlled by the inline programmable logic controller module through an independent hardwired I / O output and is used to physically cut off the robot's grasping power source in the event of an emergency stop.
[0177] The alarm module, connected to the line programmable logic controller module, is used to trigger an audible and visual alarm during an emergency stop.
[0178] In some embodiments, the trigger signal generation unit includes a hardware-software co-operated dual confirmation subunit:
[0179] The software confirmation subunit is used to receive the path planning completion signal from the robot control system and confirm that the robot has generated a complete grasping motion trajectory.
[0180] The hardware confirmation subunit is used to receive the detection signal from the proximity switch installed at the starting point of the grasping trajectory to confirm that the robot has physically reached the preset trigger position;
[0181] The trigger signal generation unit generates a trigger signal for the robot to enter the grasping trajectory only when it receives confirmation signals from both the software confirmation subunit and the hardware confirmation subunit simultaneously.
[0182] In some embodiments, the image processing unit includes:
[0183] The region detection subunit is used to detect and locate QR code regions in continuous image frames.
[0184] The quality evaluation subunit is used to evaluate the quality of the located QR code area and select valid image frames that meet the decoding requirements.
[0185] The image optimization subunit is used to perform image optimization processing on the selected valid image frames to obtain a decodeable QR code image;
[0186] The decoding subunit is used to decode the optimized QR code image and extract the workpiece model information.
[0187] In some embodiments, the quality evaluation subunit is implemented using a multi-frame fusion method, specifically including:
[0188] The overall quality score calculation module is used to calculate the overall quality score of each frame image. The overall quality score includes at least the sharpness index, the contrast index, and the motion blur index.
[0189] The candidate frame selection module is used to select the top K images as candidate valid frames based on the overall quality score, where K is a preset integer greater than 1.
[0190] The image optimization subunit includes a multi-frame fusion processing module, which is used to perform image registration and pixel-level fusion on K candidate valid frames to generate a fused QR code image.
[0191] In some embodiments, the quality assessment subunit and the image optimization subunit are implemented using an adaptive strategy:
[0192] The quality evaluation subunit prioritizes selecting the single frame image with the highest quality.
[0193] The image optimization subunit first enhances the highest quality single-frame image, and then the decoding subunit decodes it.
[0194] If decoding of a single frame fails, the quality evaluation subunit selects multiple frames of images, and the image optimization subunit performs image registration and pixel-level fusion on the multiple frames of images before the decoding subunit attempts to decode again.
[0195] In some embodiments, the trigger signal generation unit includes a grasp-instant trigger subunit, which is implemented using a multi-source signal fusion triggering method, specifically including:
[0196] The first trigger signal generation module is connected to the force sensor installed on the robot gripper and is used to generate a first trigger signal when the force feedback signal exceeds a preset threshold.
[0197] The second trigger signal generation module is connected to the robot control system and is used to generate a second trigger signal when it receives a state signal that the gripper has reached the gripping position and the gripper has begun to close.
[0198] The logic AND operation module is used to perform a logic AND operation on the first trigger signal and the second trigger signal. Only when both signals are valid at the same time will the final capture instant trigger command be generated.
[0199] In some embodiments, the trigger signal generation unit includes a grasp-instant trigger subunit, which is implemented using a multi-source signal comprehensive judgment method, specifically including:
[0200] A multi-source signal acquisition module is used to acquire the status of at least two of the following trigger signal sources in real time:
[0201] Force sensor signal used to detect changes in force feedback when the gripper comes into contact with the workpiece;
[0202] Position sensor signal used to detect whether the gripper has reached the preset gripping position;
[0203] Status signals of the robot control system used to monitor the progress of the grasping action;
[0204] Grip opening sensor signal used to monitor the degree of gripper closure;
[0205] The comprehensive judgment module is used to comprehensively judge the multi-source signals according to the preset triggering logic, and generate a triggering command when the judgment conditions at the moment of grasping are met; the triggering logic includes: the force sensor signal exceeds the set threshold and the gripper opening sensor signal begins to change, or the force sensor signal exceeds the set threshold and the robot control system reports that the grasping action has been executed to the preset stage.
[0206] In some embodiments, the trigger signal generation unit includes a grasp-instant trigger subunit, which employs a predictive triggering strategy to overcome the problem of the grabber obscuring the QR code. Specifically, it includes:
[0207] The remaining time calculation module is used to dynamically calculate the remaining time required for the gripper to contact the workpiece based on the robot's current speed and remaining distance. ;
[0208] The advance trigger threshold setting module is used to determine the delay time of the barcode scanner system. Set early trigger threshold ,in This is a preset safety margin;
[0209] Predictive triggering module, used for real-time monitoring ,when ≤ At the same time, the barcode scanner is triggered to capture images before the gripper contacts the workpiece, ensuring that the image is captured within the window period before the gripper obscures the QR code.
[0210] In some embodiments, the robot grasping module includes a dual-camera collaborative submodule, specifically comprising:
[0211] The first barcode scanner is mounted on the robot gripper, facing the front of the workpiece;
[0212] The second barcode scanner is mounted on the robot gripper and faces the side or diagonal direction of the workpiece to cover the QR code positions at different angles.
[0213] The synchronous triggering unit is used to simultaneously trigger the first barcode scanner and the second barcode scanner to acquire images at the same time when the moment of grabbing is detected, so as to obtain at least two images of the moment of grabbing from different perspectives.
[0214] The dual image processing unit is used to detect QR code regions in two images from different perspectives and execute corresponding decoding strategies based on the detection results.
[0215] If any image successfully detects a QR code, that image will be used first for decoding to obtain the first candidate result;
[0216] If both images detect a QR code but the decoding results are inconsistent, the decoding result with higher quality is selected based on the image quality evaluation index to obtain the first candidate result.
[0217] If neither image can be decoded independently, then the two images are subjected to viewpoint fusion processing to generate a fused QR code image, and the fused QR code image is decoded to obtain the first candidate result;
[0218] The result verification unit is used to perform format verification on the first candidate result, and outputs the second workpiece model data after the verification is passed.
[0219] In some embodiments, the secure execution module further includes:
[0220] The attitude holding unit, connected to the robot control system, is used to send attitude holding commands to the robot during emergency stops. At the same time, it locks the brakes of the robot's servo motors through an independent safety circuit to prevent the robot from falling or swinging due to gravity.
[0221] In some embodiments, it also includes:
[0222] The fault recording and traceability module is connected to the line PLC module. It is used to automatically record the robot posture parameters, barcode image data, and dual comparison results at the time of the fault during emergency stop, and store them as a traceable quality file.
[0223] Those skilled in the art will clearly understand that the techniques in the embodiments of the present invention can be implemented using software plus necessary general-purpose hardware platforms. Based on this understanding, the technical solutions in the embodiments of the present invention, or the parts that contribute to the prior art, can be embodied in the form of a software product. This computer software product is stored in a storage medium such as a USB flash drive, mobile hard drive, read-only memory (ROM), random access memory (RAM), magnetic disk, or optical disk, or other media capable of storing program code. It includes several instructions to cause a computer terminal (which may be a personal computer, server, or a second terminal, network terminal, etc.) to execute all or part of the steps of the methods described in the various embodiments of the present invention.
[0224] In the embodiments provided by this invention, it should be understood that the disclosed systems, apparatuses, and methods can be implemented in other ways. For example, the apparatus embodiments described above are merely illustrative; for instance, the division of units is only a logical functional division, and in actual implementation, there may be other division methods. For example, multiple units or components may be combined or integrated into another system, or some features may be ignored or not executed. Furthermore, the coupling or direct coupling or communication connection shown or discussed may be through some interfaces; the indirect coupling or communication connection between devices or units may be electrical, mechanical, or other forms.
[0225] The units described as separate components may or may not be physically separate. The components shown as units may or may not be physical units; that is, they may be located in one place or distributed across multiple network units. Some or all of the units can be selected to achieve the purpose of this embodiment according to actual needs.
[0226] In addition, the functional units in the various embodiments of the present invention can be integrated into one processing unit, or each unit can exist physically separately, or two or more units can be integrated into one unit.
[0227] The above description of the disclosed embodiments enables those skilled in the art to make or use the invention. Various modifications to these embodiments will be readily apparent to those skilled in the art, and the general principles defined herein may be implemented in other embodiments without departing from the spirit or scope of the invention. Therefore, the invention is not to be limited to the embodiments shown herein, but is to be accorded the widest scope consistent with the principles and novel features disclosed herein.
Claims
1. A collision avoidance control method for robot gripping in an automated production line, applied to a robot gripping system controlled by a line programmable logic controller, characterized in that, Includes the following steps: S1. When the trigger signal for the robot to enter the grasping trajectory is received, the line programmable logic controller sends a start command to the barcode scanner. During the process of the robot gripper moving towards the workpiece in the material box, the barcode scanner continuously collects multiple frames of QR code images at a preset frequency. S2. Perform real-time analysis on multiple frames of images, extract clear and readable QR code information frames, and parse to obtain the first workpiece model data; S3. At the moment the robot gripper contacts and grasps the workpiece, the barcode scanner is triggered again to acquire the QR code image at the moment of grasping and to parse the second workpiece model data. S4. Compare the first workpiece model data and the second workpiece model data with the target model data preset on the touch screen. S5. If the double comparison results are consistent, send a lifting permission signal to the robot control system to control the robot to take the workpiece out of the material box and transfer it to the processing station. S6. If any comparison result is inconsistent, immediately execute the emergency stop procedure: The robot's grasping program is interrupted by software commands, triggering an audible and visual alarm. By outputting a physically isolated signal through an independent hardwired I / O, the safety relay coil connected in series in the robot's grasping power circuit is cut off, keeping the robot in its current safe posture and preventing collision accidents.
2. The anti-collision control method for robot gripping in an automated production line according to claim 1, characterized in that, The trigger signal for the robot to enter the grasping trajectory in S1 is generated through a dual confirmation mechanism involving both hardware and software: Condition 1: Receive the path planning completion signal from the robot control system to confirm that the robot has generated a complete grasping motion trajectory; Condition 2: Receive the detection signal from the proximity switch installed at the starting point of the grasping trajectory to confirm that the robot has physically reached the preset trigger position; A trigger signal for the robot to enter the grasping trajectory is generated only when both conditions one and two are met simultaneously.
3. The anti-collision control method for robot grasping in an automated production line according to claim 2, characterized in that, In S2, multiple frames of images are analyzed in real time to extract clear and readable QR code information frames, and the first workpiece model data is obtained through parsing, specifically including: S21. Perform QR code region detection and positioning on the acquired continuous image frames; S22. Evaluate the quality of the located QR code area and select valid image frames that meet the decoding requirements. S23. Perform image optimization processing on the selected valid image frames to obtain a decodeable QR code image; S24. Decode the optimized QR code image and extract the first workpiece model data.
4. The anti-collision control method for robot grasping in an automated production line according to claim 3, characterized in that, In S22, the quality of the located QR code area is evaluated, and valid image frames that meet the decoding requirements are selected. This is achieved using a multi-frame fusion method, specifically including: S221. Calculate the overall quality score of each frame image, wherein the overall quality score includes at least the sharpness index, the contrast index, and the motion blur index. S222. Select the top K images based on the overall quality score as candidate valid frames, where K is a preset integer greater than 1; In S23, the selected valid image frames are subjected to image optimization processing, specifically including: image registration and pixel-level fusion of K candidate valid frames to generate a fused QR code image.
5. The anti-collision control method for robot grasping in an automated production line according to claim 3, characterized in that, In step S22, the quality of the located QR code area is evaluated, and valid image frames that meet the decoding requirements are selected. In step S23, the selected valid image frames are subjected to image optimization processing, which is implemented using an adaptive strategy. The highest quality single-frame image is directly enhanced and decoded; If single-frame decoding fails, multi-frame fusion mode is activated, and image registration and pixel-level fusion of multiple frames are performed before attempting decoding again.
6. The anti-collision control method for robot grasping in an automated production line according to claim 1, characterized in that, In S3, the barcode scanner is triggered to collect and parse the second workpiece model data the instant the robot gripper contacts and grasps the workpiece. This is achieved using a multi-source signal fusion triggering method, specifically including: S31a. The force feedback signal when the gripper contacts the workpiece is monitored in real time by force sensors installed on the robot gripper. When the force feedback signal exceeds the preset threshold, it is determined that the gripping moment has arrived and a first trigger signal is generated. S32a. Simultaneously receive the grasping action execution status signal fed back by the robot control system. When the grasping action execution status signal indicates that the gripper has reached the grasping position and the gripper begins to close, generate a second trigger signal. S33a. Perform a logical AND operation on the first trigger signal and the second trigger signal. Only when both signals are valid at the same time, generate the final instantaneous trigger command for grabbing. S34a. In response to the instantaneous trigger command for grasping, control the barcode scanner to perform single-frame or multi-frame image acquisition, and simultaneously activate the supplementary lighting device to ensure that a clear QR code image is captured the instant the gripper contacts the workpiece. S35a. Detect the QR code region in the captured image at the moment of capture, and quickly locate the QR code region in the image by combining the prior information of the QR code position obtained in stage S2. S36a. Perform targeted image enhancement processing on the located QR code area to compensate for motion blur and lighting changes caused by the moment of contact. S37a. Decode the processed QR code image, extract the workpiece model information, and output it as the second workpiece model data after format verification.
7. The anti-collision control method for robot grasping in an automated production line according to claim 1, characterized in that, In S3, the moment the robot gripper contacts and grasps the workpiece, the barcode scanner is triggered to collect and parse the second workpiece model data again. This is achieved using a multi-source signal comprehensive judgment method, specifically including: S31b, Real-time acquisition of the status of at least two of the following trigger signal sources: Force sensor signal used to detect changes in force feedback when the gripper comes into contact with the workpiece; Position sensor signal used to detect whether the gripper has reached the preset gripping position; Status signals of the robot control system used to monitor the progress of the grasping action; Grip opening sensor signal used to monitor the degree of gripper closure; S32b. Based on the preset triggering logic, the multi-source signals are comprehensively judged, and a triggering command is generated when the judgment condition for the grasping moment is met; the triggering logic includes: the force sensor signal exceeds the set threshold and the gripper opening sensor signal begins to change, or the force sensor signal exceeds the set threshold and the robot control system reports that the grasping action has been executed to the preset stage. S33b responds to the generated trigger command and controls the barcode scanner to complete image acquisition, ensuring that the acquisition moment is strictly synchronized with the grab moment; S34b: Perform QR code recognition and decoding on the acquired image, and output the second workpiece model data.
8. The anti-collision control method for robot gripping in an automated production line according to claim 1, characterized in that, In S3, the barcode scanner is triggered to collect and parse the second workpiece model data the instant the robot gripper contacts and grasps the workpiece. This is achieved using a predictive triggering strategy to overcome the problem of the gripper obscuring the QR code. Specifically, this includes: S31c: Based on the robot's current speed and remaining distance, dynamically calculate the remaining time required for the gripper to contact the workpiece. ; S32c, based on barcode scanner system delay time Set an early trigger threshold ,in, This is a preset safety margin; S33c, Real-time monitoring ,when ≤ At the same time, the barcode scanner is triggered to capture images before the gripper contacts the workpiece, ensuring that the image is captured within the window period before the gripper obscures the QR code; S34c: Perform QR code recognition on the acquired image and parse it to obtain the second workpiece model data.
9. The anti-collision control method for robot grasping in an automated production line according to claim 1, characterized in that, In S3, the moment the robot gripper contacts and grasps the workpiece, the barcode scanner is triggered to collect and parse the second workpiece model data again. This is achieved using a dual-camera collaborative approach, specifically including: S31d. A first barcode scanner and a second barcode scanner are set on the robot gripper. The first barcode scanner faces the front of the workpiece, and the second barcode scanner faces the side or oblique direction of the workpiece to cover the QR code positions at different angles. S32d: When the moment of grabbing is detected, the first barcode scanner and the second barcode scanner are simultaneously triggered to acquire images, obtaining at least two images of the moment of grabbing from different perspectives. S33d: Perform QR code region detection on two images from different perspectives; S34d: Execute the corresponding decoding strategy based on the detection results. If any image successfully detects a QR code, that image will be used first for decoding to obtain the first candidate result; If both images detect a QR code but the decoding results are inconsistent, the decoding result with higher quality is selected based on the image quality evaluation index to obtain the first candidate result. If neither image can be decoded independently, then the two images are subjected to viewpoint fusion processing to generate a fused QR code image, and the fused QR code image is decoded to obtain the first candidate result; S35d. Perform format verification on the first candidate result. If the verification passes, output the second workpiece model data.
10. A collision avoidance control system for robot gripping in an automated production line, characterized in that, include: The touchscreen human-machine interface module is used to preset the target model data required for the current production task and display the production status and alarm information; The robot grasping module includes a robot with multiple degrees of freedom and a barcode scanner installed at the end of the robot gripper. The robot is used to perform grasping trajectory movements, and the barcode scanner is used to collect QR code images on the workpiece during the robot's movement and at the moment of grasping. The signal acquisition module includes a proximity switch installed at the starting point of the grasping trajectory, a force sensor installed on the robot gripper, and a control system interface for monitoring the robot's status, used to generate trigger signals and status signals; The line-type programmable logic controller (PLC) module is connected to the touchscreen human-machine interface module, the robot grasping module, and the signal acquisition module, respectively. It is used to generate trigger signals for the robot to enter the grasping trajectory and for the moment of grasping, based on multi-source signals acquired by the signal acquisition module; to perform real-time analysis of multi-frame QR code images acquired by the barcode scanner, extracting clear and readable QR code information frames, and parsing to obtain first and second workpiece model data; to perform dual comparisons of the first and second workpiece model data with preset target model data on the touchscreen, generating comparison result signals; and to send a lifting permission signal or an emergency stop command to the robot grasping module based on the comparison result signals. The safety execution module includes a safety relay connected in series in the robot's grasping power circuit. The safety relay is controlled by the inline programmable logic controller module through an independent hardwired I / O output and is used to physically cut off the robot's grasping power source in the event of an emergency stop. The alarm module, connected to the line programmable logic controller module, is used to trigger an audible and visual alarm during an emergency stop.