Picking robot control method based on improved yolov5 algorithm and picking robot
Patent Information
- Application Number
- CN202410811635.3
- Authority / Receiving Office
- CN · China
- Patent Type
- Applications(China)
- Current Assignee / Owner
- Filing Date
- 2024-06-21
- Publication Date
- 2024-09-06
- Estimated Expiration
- 2044-06-21
AI Technical Summary
Existing picking robots have slow reasoning speed when faced with high-resolution images and cannot meet real-time performance requirements. Moreover, the target detection algorithm is affected by illumination and occlusions in complex scenes, resulting in insufficient recognition accuracy and stability, and the freedom of the picking process. Low degree of flexibility and flexibility.
Using the improved yolov5 algorithm, by building an orchard simulation environment, using the DeepStream video stream processing framework and TensorRT inference engine to accelerate target detection, combined with transposed convolution, global context block and C3GHOST convolution optimization model, video stream processing and calculation of the robotic arm dynamic motion parameters to achieve real-time target recognition and precise positioning.
It improves the real-time performance and accuracy of target detection, reduces resource consumption, enhances the model's perception ability and computing efficiency, and achieves accurate positioning and attitude control for complex picking tasks.
Smart Images

Figure CN118596145A
Abstract
Description
Technical Field
[0001] The present invention relates to the technical field of picking robots, and in particular to a picking robot control method based on an improved yolov5 algorithm and a picking robot. Background Art
[0002] With the development of the times, the degree of automation in all walks of life is constantly increasing, while the existing agriculture has a low level of mechanization and intelligence in some areas. If the fruits are picked after they are ripe, most of them need to be picked manually. The manual labor intensity is high and the picking efficiency is low, which cannot meet the growing demand.
[0003] Therefore, automated picking robots have been proposed. For example, Patent No. 202210311178.2 discloses a strawberry picking method and robot system based on binocular vision. Strawberry fruits are identified in preprocessed images according to a preset recognition model, and the picking point position is determined by the lowest point of the strawberry and the center of mass of the strawberry according to the strawberry fruit recognition result, thereby improving the recognition accuracy and positioning and ranging problems. Patent No. 202210936842.2 discloses a fully automatic fruit picking robot and picking method based on visual technology, which uses a combination of a binocular camera and an inertial navigation module to construct an orchard map, and determines the height of the lifting platform and the initial position of the robotic arm at each picking through an algorithm, which can increase the picking success rate and picking range.
[0004] However, the above prior art still has the following defects:
[0005] (1) The reasoning speed of deep learning models is relatively slow when facing high-resolution images, and cannot meet the real-time performance requirements of target detection. If the detection performance is directly improved, it will lead to increased resource consumption, which will impose a heavy burden on small tools such as picking robots.
[0006] (2) When facing complex scenes, the target detection algorithm is easily affected by factors such as lighting and occlusions, resulting in insufficient accuracy and stability of the target detection results;
[0007] (3) The coordination between the lifting platform and the end of the robotic arm makes the picking process less flexible and has lower degrees of freedom, especially in complex picking scenarios, and cannot meet the precise positioning and posture control of the target picking position.
[0008] Therefore, there is an urgent need for a picking robot control method based on the improved yolov5 algorithm to solve the above problems. Summary of the invention
[0009] In view of the deficiencies in the prior art, the present invention proposes a picking robot control method and a picking robot based on an improved yolov5 algorithm.
[0010] The first aspect of the present invention discloses a harvesting robot control method based on an improved yolov5 algorithm, comprising:
[0011] Build an orchard simulation environment, generate a target picking task to determine the target path of the robot, detect the error value between the robot's moving path and the target path in real time through sensors, calculate the proportional parameter P according to the error value, and adjust the robot's motion state by feeding back the control signal of the proportional parameter P through the PID controller;
[0012] The video stream processing framework is used to load the yolov5 algorithm model to build a video processing channel, and an inference engine is configured on the video processing channel to perform inference acceleration tasks;
[0013] The target video stream is collected as the input of the yolov5 algorithm model, and the yolov5 algorithm model is optimized by using transposed convolution, global context block and C3GHOST convolution respectively, and the recognition result, pixel coordinates and the proportional relationship between the measured pixel distance and the actual distance of the target picked in the target video stream are output, and the relative coordinates of the pixel coordinates are obtained according to the coordinate transformation;
[0014] The static motion parameters of the robotic arm corresponding to the relative coordinates are calculated by inverse kinematics solution, and the dynamic motion parameters of the robotic arm are solved by quintic polynomial interpolation. Based on the static motion parameters, dynamic motion parameters and relative coordinates, the picking robot is controlled to perform the target picking task.
[0015] In an optional embodiment, the step of building an orchard simulation environment, generating a target picking task and determining a target path for the robot includes:
[0016] Orchard map information is obtained by collecting early images of the orchard to simulate the orchard map environment, the starting point location information and the end point location information of the target picking task are planned according to the picking requirements, and one or more target paths are generated according to the starting point location information and the end point location information.
[0017] In an optional embodiment, the sensor is used to detect the error value between the robot's moving path and the target path in real time, a proportional parameter P is calculated according to the error value, and a control signal of the proportional parameter P is fed back by a PID controller to adjust the robot's motion state, including:
[0018] The robot loads the target path, walks according to the starting point-end point map trajectory of the target picking task, detects and feeds back the actual moving path parameters in real time, calculates the error value between the target path and the actual moving path in each unit time in real time, updates the assignment of the proportional parameter P in real time according to the error value and the target path of each unit time to output the motion control parameters of the current time, adjusts the current motion state of the robot according to the motion control parameters until the proportional parameter P is adjusted to the optimal assignment, and continuously outputs the motion control parameters according to the optimal assigned proportional parameter P combined with the error value of the current time to control the motion state of the robot until it reaches the end point.
[0019] In an optional embodiment, the video stream processing framework is used to load the yolov5 algorithm model to build a video processing channel, and the video processing channel is configured with an inference engine to accelerate the target detection task, including:
[0020] The DeepStream video stream processing framework is used to build a video processing channel on the Jetson Nano embedded development board configured with the robot, and the dependency of the TensorRT inference engine is configured for the video processing channel, and the yolov5 algorithm model is loaded into the DeepStream video stream processing framework;
[0021] The yolov5 algorithm model is trained through a cloud server to output a .pt weight file, and the .pt weight file is transferred to the Jetson Nano embedded development board using a WINSCP graphical client. The .pt weight file is converted into a .wts weight file using a conversion program of the TensorRT inference engine to optimize the model parameters of the yolov5 algorithm model. The .wts weight file is converted into an .engine file by compiling and importing it into the target path of the DeepStream video stream processing framework, so that the yolov5 algorithm model is converted into an inference engine configured in a video processing channel and used for one or more tasks of data input, data preprocessing, inference acceleration, post-processing and output results. The output result is that the yolov5 algorithm model performs target detection and tracking recognition on each frame of the video stream in the data input, and the GPU of the Jetson Nano embedded development board executes the inference acceleration task of the yolov5 algorithm model through the TensorRT inference engine.
[0022] In an optional embodiment, the transposed convolution optimizes the yolov5 algorithm model, including:
[0023] The nn.ConvTranspose2d class is used to define a transposed convolution layer transposed_con in the head structure of the yolov5 algorithm model, and the torch.randn function is used to generate a random tensor for simulating the input image as the input of the upsampling operation of the yolov5 algorithm model. The reverse convolution kernel of the transposed convolution layer transposed_con is used to perform a transposed convolution operation on the input random tensor to generate an output tensor as the feature map space dimension expansion training for each frame image in the target video stream. The shape of the random tensor is expressed as (batch_size, input_channels, input_height, input_width), where batch_size represents the batch size of the input, input_channels represents the number of channels of the input, input_height represents the height of the input, and input_width represents the width of the input.
[0024] In an optional embodiment, the adopting of a global context block to optimize the yolov5 algorithm model includes:
[0025] The Global Context Block defines a 1x1 convolutional layer, a softmax layer, and a feature transformation module in sequence. The feature transformation module includes multiple convolutional layers, a normalization layer, and an activation function.
[0026] Extract the input size of the input feature map in each frame of the target video stream, convert the input feature map into a single-channel feature map through the 1x1 convolution layer to obtain global context information of the input feature map, wherein the input size includes the batch size, the number of channels, the height h and the width w of the input feature map, and the single-channel feature map is flattened, and the shape is expressed as (batch, 1, h, w), where 1 represents the number of channels, batch represents the batch size, h represents the height, and w represents the width;
[0027] The single-channel feature map is normalized by the softmax layer for calculating the weight distribution, and the single-channel feature map used to represent the global context information after the flattening operation is fused with the weight distribution by channel multiplication to calculate the global context vector, wherein the shape of the global context vector is (batch, c, 1, 1);
[0028] The feature transformation module uses linear transformation and nonlinear activation to generate a feature map with the same shape as the input feature map on the global context vector, and adds the input feature map and the feature map transformed by the global context vector point by point to obtain a feature representation of the input feature map enhanced by the global context block.
[0029] In an optional embodiment, the C3GHOST convolution optimizes the yolov5 algorithm model, including:
[0030] A lightweight model is constructed by applying Ghost convolution in the backbone feature extraction network of the yolov5 algorithm model through GhostBottleneck, and the GhostBottleneck class defines a residual block including a GhostConv class, a DWConv class, and a direct path residual connection;
[0031] The convolution structure based on the GhostConv class uses a 1x1 convolution kernel to convert the number of input channels to half the number of hidden channels. After feature extraction through a 5x5 convolution kernel, the feature outputs of the two convolution kernel stages are concatenated in the channel dimension to add a Ghost Channel generated by the linear combination of the original input channels to each input channel to represent the feature information of the original input channel.
[0032] The DWConv class performs downsampling according to the stride parameter, and performs model calculation and feature extraction simultaneously through depthwise separable convolution.
[0033] The information flow and feature reuse within the model are constructed through the direct path residual connection of the GhostConv class and the DWConv class.
[0034] In an optional embodiment, obtaining the relative coordinates of the pixel coordinates according to the coordinate conversion includes:
[0035] According to the pixel coordinates (x, y, w, h) determined by the recognition result, the image midpoint coordinates (cx, cy) and the target midpoint coordinates (zx, zy) corresponding to the recognition result are calculated respectively. The calculation formulas of the image midpoint coordinates and the target midpoint coordinates are as follows:
[0036]
[0037] The coordinates of the midpoint of the image are set as the origin, and the target midpoint coordinates (zx, zy) are transferred relative to the origin by measuring the proportional relationship between the pixel distance and the actual distance (bx, by) to generate the target coordinates (nx, ny), and the target coordinates (nx, ny) are converted into relative coordinates (rx, ry) measured in centimeters according to the proportional relationship (bx, by), where the calculation formulas for the target coordinates and the relative coordinates are:
[0038]
[0039] The relative coordinates are used to help the robot locate and navigate the picking target.
[0040] In an optional embodiment, the calculating the static motion parameters of the manipulator corresponding to the relative coordinates by inverse kinematics solution includes:
[0041] Construct a mapping relationship between the joint angle of the robot's three-degree-of-freedom manipulator and the manipulator base, and collect the bottom height H1, upper arm length L1, lower arm length L2, and arm compensation B of the manipulator;
[0042] The centimeter coordinates (X, Y) between the picking target and the base of the robotic arm are calculated according to the relative coordinates (rx, ry), and the static motion parameters of the robotic arm are calculated based on the robotic arm parameters and the centimeter coordinates (x1, y1). The calculation formula of the static motion parameters is:
[0043]
[0044] The static motion parameters include the vertical projection T, the base angle J0, the upper arm angle J1, the lower arm angle J2, the short side D and the hypotenuse X0.
[0045] In an optional embodiment, the method of using quintic polynomial interpolation to solve the dynamic motion parameters of the robot arm includes:
[0046] The starting angle INIT, target angle TARGET, initial angular velocity W0, target angular velocity W1, initial angular acceleration AC0, target angular acceleration AC1, total motion time TF, time step TS and motion time point T of the dynamic motion of the manipulator servo are defined. The initial angle A0, initial angular velocity A1, half of the initial angular velocity A2, acceleration A3, square of acceleration A4 and cube of acceleration A5 of the servo are calculated by defining the parameters. Based on the angles Theta, WC0 and ACC0 of the manipulator servo, the angle, angular velocity and angular acceleration position of the servo at different time points are calculated to provide the dynamic motion parameters of the servo smooth motion. The calculation formula is:
[0047] A0=INIT
[0048] A1=W0
[0049]
[0050] A3=(20*TARGET-20*INIT-(8*W1+12*W0)*TF-(3*AC0-AC1)*TF 2 / (2*TF 3 )
[0051] A4=(30*TARGET-30*INIT+(14*W1+16*W0)*TF-(3*AC0-2*AC1)*TF 2 / (2*TF 4)
[0052] A5=(12*TARGET-12*INIT-(6*W1+6*W0)*TF-(AC0-AC1)*TF 2 / (2*TF 5 )
[0053] Theta=A0+A1*T+A2*T 2 +A3*T 3 +A4*T 4 +A5*T 5
[0054] WC0=A1+2*A2*T+3*A3*T 2 +4*A4*T 3 +5*A5*T 4
[0055] ACC0=2*A2+6*A3*T+12*A4*T 2 +20*A5*T 3
[0056] The second aspect of the present invention discloses a picking robot, which is used to execute the steps of a picking robot control method based on an improved yolov5 algorithm disclosed in the first aspect of the present invention, including:
[0057] A mobile platform component, a mechanical arm component mounted on the mobile platform, and a control system mounted in the mobile platform;
[0058] The mobile platform assembly includes a chassis composed of a top plate, a bottom plate and a first support column, a Mecanum wheel arranged at the bottom of the bottom plate, and a reduction motor driving the Mecanum wheel;
[0059] The mechanical arm assembly includes a tray, an arm, a wrist, a clamping claw, a screw for driving the arm to extend and retract, a steering gear for driving the wrist to rotate, a driving motor for driving the clamping claw to operate, and a camera mounted at the rear end of the clamping claw for collecting a target video stream;
[0060] The control system includes a main control module, a wireless control module, a sensor module, a motor drive module and a power module. The main control module includes an STM32RCT6 single-chip microcomputer for controlling the robot motion trajectory and wireless control, a JETSON NANO embedded development board for controlling target video stream image processing, and a PCA9685 module for controlling the mechanical arm according to the image processing result of the JETSON NANO embedded development board. The PCA9685 module uses an I2C interface to control the angle of the mechanical arm servo. The JETSON NANO embedded development board accelerates the reasoning of the yolov5 algorithm model through the DeepStream video stream processing framework and the TensorRT reasoning engine. The STM32RCT6 single-chip microcomputer and the JETSON NANO embedded development board are interconnected through a TX pin and a RX pin to enable the main control module to perform bidirectional transmission of information.
[0061] The wireless control module is configured as an HC-05 Bluetooth module, and is connected to a mobile terminal device through communication with the Bluetooth module to remotely control the picking robot;
[0062] The sensor module is configured as an MPU6050 module integrating a three-axis gyroscope and a three-axis accelerometer, so as to measure the rotation angle and rotation acceleration of the robot arm;
[0063] The motor drive module is configured as a TB6612 dual H-bridge driver to control one or more motors carried by the picking robot to perform motor drive;
[0064] The power supply module includes a 12V power supply for the STM32RCT6 single-chip microcomputer through a DC socket, a 5V4A DC power supply configured on the JETSONNANO embedded development board, and an LM2596 voltage regulator module that provides a stable 5V power supply for the HC-05 Bluetooth module, the MPU6050 module, and the PID tracking module. The JETSON NANO embedded development board and the PCA9685 module output 5V through a step-down module to step down the voltage to the PCA9685 module to execute the robot arm servo control.
[0065] In an optional embodiment, the control system also includes a display module, which is configured as an OLED display screen to visually display the robot's status information and provide a click button for adjusting the tracking parameters for the PID tracking module. The status information includes the robot's elevation angle, depression angle, yaw angle, picking target category and number of picking targets.
[0066] The third aspect of the present invention discloses a harvesting robot control device based on an improved yolov5 algorithm, comprising:
[0067] at least one processor, and
[0068] a memory communicatively connected to the at least one processor; wherein,
[0069] The memory stores instructions executable by the at least one processor, and the instructions are executed by the at least one processor so that the at least one processor can execute the picking robot control method based on the improved yolov5 algorithm as described in any one of the items disclosed in the first aspect of the present invention.
[0070] The fourth aspect of the present invention discloses a computer-readable storage medium, which stores computer-executable instructions, and the computer-executable instructions are used to enable a computer to execute the harvesting robot control method based on the improved yolov5 algorithm as described in any one of the items disclosed in the first aspect of the present invention.
[0071] Compared with the prior art, the present invention has the following advantages:
[0072] (1) The present invention uses the high-performance, low-latency real-time video stream processing framework DeepStream, combined with the TensorRT inference engine (deep learning inference acceleration library), to efficiently infer models such as YOLOV5. TensorRT uses GPU to accelerate the inference process, improves the inference speed of the model, meets the real-time performance requirements of target detection, and reduces the resource consumption of target detection, especially on small devices such as picking robots.
[0073] (2) The present invention introduces global context information through the global context block to enhance the perception ability and classification accuracy of the model, uses transposed convolution in the model head structure to improve the accuracy and stability of target detection, and introduces Ghost convolution in the Neck part of the model to reduce the number of model parameters and the amount of calculation, improve the feature extraction ability, optimize the yolov5 algorithm model, improve the perception ability, accuracy and calculation efficiency of the model, and reduce the influence of interference factors on target detection results in complex scenarios.
[0074] (3) The present invention jointly optimizes the motion control of the three-axis robot arm through the inverse solution of the kinematics of the three-axis robot arm and polynomial interpolation. The inverse solution algorithm calculates the final joint angle according to the kinematic characteristics of the robot arm and the target position, which helps the three-axis robot arm to accurately locate the target position and control the posture, thereby realizing the execution of complex picking tasks. The polynomial interpolation utilizes the continuity of the local interpolation polynomial and the continuity of the first-order derivative to realize the fitting of the smooth curve, which can effectively approximate the target motion trajectory in the servo control system and obtain a continuous and smooth servo trajectory, making the servo movement more stable. BRIEF DESCRIPTION OF THE DRAWINGS
[0075] In order to more clearly illustrate the embodiments of the present invention or the technical solutions in the prior art, the drawings required for use in the embodiments or the description of the prior art will be briefly introduced below. Obviously, the drawings described below are only some embodiments of the present invention. For ordinary technicians in this field, other drawings can be obtained based on these drawings without paying creative labor.
[0076] Figure 1 It is a flow chart of the picking robot control method based on the improved yolov5 algorithm of the present invention;
[0077] Figure 2 It is a schematic diagram of the structure of the picking robot in the present invention.
[0078] Reference numerals:
[0079] 1-top plate, 2-bottom plate, 3-pillar, 4-Mecanum wheel, 5-reduction motor, 6-tray, 7-arm, 8-wrist, 9-grip, 10-screw, 11-servo, 12-drive motor, 13-camera. DETAILED DESCRIPTION
[0080] In order to make the purpose, technical solutions and advantages of the present application clearer, the present application is described and illustrated below in conjunction with the accompanying drawings and embodiments. It should be understood that the specific embodiments described herein are only used to explain the present application and are not intended to limit the present application. Based on the embodiments provided in the present application, all other embodiments obtained by ordinary technicians in the field without making creative work are within the scope of protection of the present application.
[0081] Obviously, the drawings described below are only some examples or embodiments of the present application. For ordinary technicians in this field, the present application can also be applied to other similar scenarios based on these drawings without creative work. In addition, it can also be understood that although the efforts made in this development process may be complicated and lengthy, for ordinary technicians in this field related to the content disclosed in this application, some changes in design, manufacturing or production based on the technical content disclosed in this application are just conventional technical means, and should not be understood as insufficient content disclosed in this application.
[0082] Reference to "embodiments" in this application means that a particular feature, structure, or characteristic described in conjunction with the embodiments may be included in at least one embodiment of the present application. The appearance of the phrase in various locations in the specification does not necessarily refer to the same embodiment, nor is it an independent or alternative embodiment that is mutually exclusive with other embodiments. It is explicitly and implicitly understood by those of ordinary skill in the art that the embodiments described in this application may be combined with other embodiments without conflict.
[0083] Unless otherwise defined, the technical terms or scientific terms involved in this application should be understood by people with ordinary skills in the technical field to which this application belongs. The words "one", "a", "a", "the" and the like involved in this application do not indicate a quantitative limitation, and may represent the singular or plural. The terms "include", "comprise", "have" and any of their variations involved in this application are intended to cover non-exclusive inclusions; for example, a process, method, system, product or device that includes a series of steps or modules (units) is not limited to the listed steps or units, but may also include steps or units that are not listed, or may also include other steps or units inherent to these processes, methods, products or devices. The words "connect", "connected", "coupled" and the like involved in this application are not limited to physical or mechanical connections, but may include electrical connections, whether direct or indirect. The "multiple" involved in this application refers to two or more. "And / or" describes the association relationship of associated objects, indicating that there may be three relationships, for example, "A and / or B" can represent: A exists alone, A and B exist at the same time, and B exists alone. The character " / " generally indicates that the objects before and after are in an "or" relationship. The terms "first", "second", "third", etc. involved in this application are only used to distinguish similar objects and do not represent a specific ordering of the objects.
[0084] Example 1
[0085] See also Figure 1 The embodiment of the present invention discloses a control method of a picking robot based on an improved yolov5 algorithm. The first aspect of the present invention discloses a control method of a picking robot based on an improved yolov5 algorithm, comprising:
[0086] Build an orchard simulation environment, generate a target picking task to determine the target path of the robot, detect the error value between the robot's moving path and the target path in real time through sensors, calculate the proportional parameter P according to the error value, and adjust the robot's motion state by feeding back the control signal of the proportional parameter P through the PID controller;
[0087] The video stream processing framework is used to load the yolov5 algorithm model to build a video processing channel, and an inference engine is configured on the video processing channel to perform inference acceleration tasks;
[0088] The target video stream is collected as the input of the yolov5 algorithm model, and the yolov5 algorithm model is optimized by using transposed convolution, global context block and C3GHOST convolution respectively, and the recognition result, pixel coordinates and the proportional relationship between the measured pixel distance and the actual distance of the target picked in the target video stream are output, and the relative coordinates of the pixel coordinates are obtained according to the coordinate transformation;
[0089] The static motion parameters of the robotic arm corresponding to the relative coordinates are calculated by inverse kinematics solution, and the dynamic motion parameters of the robotic arm are solved by quintic polynomial interpolation. Based on the static motion parameters, dynamic motion parameters and relative coordinates, the picking robot is controlled to perform the target picking task.
[0090] Specifically, the design idea of the control method of the picking robot based on the improved yolov5 algorithm of the present invention is to adopt a four-wheeled robot, set the orchard route by building a simple simulated orchard, and in order to achieve efficient motion control, the present invention selects the STM32RCT6 with powerful processing power as the main controller, which can accurately control the motion and plan the path of the robot. In order to perform image processing, the present invention is equipped with JETSON NANO and is equipped with a high-definition camera module. JETSONNANO communicates with STM32RCT6 through a serial port to achieve data exchange and collaboration between the two. The PCA9685 module uses the I2C interface to control the angle of the four-way steering gear, and JETSON NANO uses DeepStream and TensorRT to accelerate the reasoning of YOLOV5, thereby realizing the function of calling the camera to perform real-time detection of fruits, and at the same time calling the fruit coordinates obtained by the detection, and solving the angle required for the steering gear to rotate through the inverse operation, picking the target fruit to the specified area, and the system can realize the fully automated picking function.
[0091] In an optional embodiment, the step of building an orchard simulation environment, generating a target picking task and determining a target path for the robot includes:
[0092] Orchard map information is obtained by collecting early images of the orchard to simulate the orchard map environment, the starting point location information and the end point location information of the target picking task are planned according to the picking requirements, and one or more target paths are generated according to the starting point location information and the end point location information.
[0093] In an optional embodiment, the sensor is used to detect the error value between the robot's moving path and the target path in real time, a proportional parameter P is calculated according to the error value, and a control signal of the proportional parameter P is fed back by a PID controller to adjust the robot's motion state, including:
[0094] The robot loads the target path, walks according to the starting point-end point map trajectory of the target picking task, detects and feeds back the actual moving path parameters in real time, calculates the error value between the target path and the actual moving path in each unit time in real time, updates the assignment of the proportional parameter P in real time according to the error value and the target path of each unit time to output the motion control parameters of the current time, adjusts the current motion state of the robot according to the motion control parameters until the proportional parameter P is adjusted to the optimal assignment, and continuously outputs the motion control parameters according to the optimal assigned proportional parameter P combined with the error value of the current time to control the motion state of the robot until it reaches the end point.
[0095] Specifically, when the PID algorithm is used to control the robot's motion, it is based on three main control parameters: proportional, integral, and differential. In this robot motion control, the PID algorithm is combined with the MPU6050 to control the robot. The data from the MPU6050 can be used in the feedback loop to monitor the robot's posture and motion state in real time. This real-time feedback can help the robot respond to external changes more accurately and make corresponding adjustments. The posture and motion data provided by the MPU6050 sensor can monitor the robot's roll and pitch angles in real time. These data can be used as feedback signals for PID control to calculate errors and achieve precise motion control by adjusting control parameters.
[0096] Furthermore, in robot motion control, only adjusting the P value can achieve very good control effects. The proportional parameter (P) determines the response speed and the degree of error adjustment. By properly adjusting the P value, the robot can respond to errors quickly and accurately control the posture and motion state. In this robot motion control, by reading the MPU6050 data, the error between the target angle and the actual angle is calculated, and the deviation in the robot motion is corrected.
[0097] In an optional embodiment, the video stream processing framework is used to load the yolov5 algorithm model to build a video processing channel, and the video processing channel is configured with an inference engine to accelerate the target detection task, including:
[0098] The DeepStream video stream processing framework is used to build a video processing channel on the Jetson Nano embedded development board configured with the robot, and the dependency of the TensorRT inference engine is configured for the video processing channel, and the yolov5 algorithm model is loaded into the DeepStream video stream processing framework;
[0099] The yolov5 algorithm model is trained through a cloud server to output a .pt weight file, and the .pt weight file is transferred to the Jetson Nano embedded development board using a WINSCP graphical client. The .pt weight file is converted into a .wts weight file using a conversion program of the TensorRT inference engine to optimize the model parameters of the yolov5 algorithm model. The .wts weight file is converted into an .engine file by compiling and importing it into the target path of the DeepStream video stream processing framework, so as to convert the yolov5 algorithm model into an inference engine configured in a video processing channel and used for one or more tasks of data input, data preprocessing, inference acceleration, post-processing and output results, wherein the output result is that the yolov5 algorithm model performs target detection and tracking recognition on each frame of the video stream in which the data is input, and the GPU of the JetsonNano embedded development board executes the inference acceleration task of the yolov5 algorithm model through the TensorRT inference engine.
[0100] Specifically, the DeepStream framework is used to build a video analysis application. Secondly, the YOLOv5 model is loaded into DeepStream and optimized and accelerated using TensorRT. Finally, the optimized YOLOv5 model is applied to the video stream through the DeepStream pipeline to achieve efficient real-time target detection and tracking. When using DeepStream and TensorRT to accelerate YOLOv5 inference, you first need to install and configure the DeepStream framework and ensure that dependencies such as TensorRT and CUDA are correctly installed. Then, DeepStream's plug-ins and modules are used to build a video processing pipeline, including steps such as data source input, preprocessing, inference acceleration, post-processing, and result output. After loading the YOLOv5 model, it is optimized using TensorRT. TensorRT can automatically optimize the model structure and use GPU to accelerate the inference process, thereby improving the inference speed and efficiency. Through TensorRT optimization, the YOLOv5 model can be converted into an efficient inference engine, reducing the consumption of computing resources and achieving faster inference speed. Once the optimization is completed, the optimized YOLOv5 model is integrated into the DeepStream pipeline. In the pipeline, the model will receive the video stream as input and perform target detection and tracking for each frame. Since TensorRT is used for acceleration, the inference process will be more efficient and real-time performance requirements can be achieved. Finally, DeepStream can display, store or transmit the processed results through different output modules. For example, the detected targets can be drawn on the video stream and the results can be displayed on the screen in real time, or the results can be saved to a file for subsequent analysis and processing. Through the combination of DeepStream and TensorRT, efficient and fast target detection and tracking applications can be achieved, which is suitable for various video analysis scenarios, such as fruit picking, real-time detection and other target detection tasks.
[0101] Furthermore, Jetson Nano deep learning is used to determine the type of inspected fruit. Jetson Nano uses the YOLOV5 algorithm to train fruit images, and the trained model is used by Jetson Nano to perform artificial intelligence detection through the corresponding algorithm. Jetson Nano communicates with STM32 through the serial port, and Jetson Nano sends the corresponding data to STM32 through the serial port. The single-chip microcomputer STM32 performs the next step based on the acquired data.
[0102] In an optional embodiment, the transposed convolution optimizes the yolov5 algorithm model, including:
[0103] The nn.ConvTranspose2d class is used to define a transposed convolution layer transposed_con in the head structure of the yolov5 algorithm model, and the torch.randn function is used to generate a random tensor for simulating the input image as the input of the upsampling operation of the yolov5 algorithm model. The reverse convolution kernel of the transposed convolution layer transposed_con is used to perform a transposed convolution operation on the input random tensor to generate an output tensor as the feature map space dimension expansion training for each frame image in the target video stream. The shape of the random tensor is expressed as (batch_size, input_channels, input_height, input_width), where batch_size represents the batch size of the input, input_channels represents the number of channels of the input, input_height represents the height of the input, and input_width represents the width of the input.
[0104] Specifically, by using transposed convolution in the head structure of YOLOv5, the size of the feature map can be enlarged, thereby improving the accuracy and stability of target detection. Transposed convolution can better retain feature information and learn richer and more complex feature representations, thereby improving the model's ability to recognize targets. In addition, transposed convolution can effectively reduce the number of model parameters and computational complexity, improve the model's operating efficiency and speed, and have better applicability and performance in deployment scenarios on mobile terminals and embedded devices. The advantages of transposed convolution include: (1) Transposed convolution can enlarge low-resolution feature maps to the size of the original input image, thereby increasing the resolution and receptive field of the feature map. (2) Similar to ordinary convolution operations, transposed convolution also has the characteristic of parameter sharing, which can share weights during the learning process, thereby reducing the number of model parameters and computational complexity. (3) Transposed convolution can be flexibly applied to different structures of neural networks, including autoencoders, generative adversarial networks (GANs), and convolutional neural networks (CNNs), and can be combined and adjusted according to actual needs.
[0105] Furthermore, in fruit picking robots, transposed convolution can upsample low-resolution feature maps to high resolution, making the feature maps more detailed. This is especially important for fruit detection, because higher resolution can capture the detailed features of the fruit, thereby improving the accuracy of detection. At the same time, high-resolution feature maps help to finely locate the edges and contours of the fruit, which is crucial for accurately locating and grasping the fruit. Transposed convolution can be used in the decoding part of the detection network to help restore the spatial details of the input image.
[0106] In an optional embodiment, the adopting of a global context block to optimize the yolov5 algorithm model includes:
[0107] The Global Context Block defines a 1x1 convolutional layer, a softmax layer, and a feature transformation module in sequence. The feature transformation module includes multiple convolutional layers, a normalization layer, and an activation function.
[0108] Extract the input size of the input feature map in each frame of the target video stream, convert the input feature map into a single-channel feature map through the 1x1 convolution layer to obtain global context information of the input feature map, wherein the input size includes the batch size, the number of channels, the height h and the width w of the input feature map, and the single-channel feature map is flattened, and the shape is expressed as (batch, 1, h, w), where 1 represents the number of channels, batch represents the batch size, h represents the height, and w represents the width;
[0109] The single-channel feature map is normalized by the softmax layer for calculating the weight distribution, and the single-channel feature map used to represent the global context information after the flattening operation is fused with the weight distribution by channel multiplication to calculate the global context vector, wherein the shape of the global context vector is (batch, c, 1, 1);
[0110] The feature transformation module uses linear transformation and nonlinear activation to generate a feature map with the same shape as the input feature map on the global context vector, and adds the input feature map and the feature map transformed by the global context vector point by point to obtain a feature representation of the input feature map enhanced by the global context block.
[0111] Specifically, the Global Context Block is a structure used to enhance the perception and representation capabilities of convolutional neural networks (CNNs). It improves the network's ability to understand and analyze input data by introducing global context information. This module can effectively encode global context information into feature maps through global average pooling and channel-dimensional attention mechanisms. By fusing and rescaling with the original feature maps, the global context information is integrated into the middle layer of the network, so that the network pays more attention to global semantics and contextual relationships, enhancing the network's perception and representation capabilities. The global context block has the following advantages for optimizing the yolov5 algorithm model:
[0112] (1) Global Context Block can improve the perception ability of the yolov5 algorithm model. The global context block enhances the perception ability of the convolutional neural network by introducing global context information. It can capture the global semantics and contextual relationships of the input data, making the network more capable of understanding and analyzing the input data. This helps improve the performance of the model for complex and context-dependent tasks.
[0113] (2) Global Context Block can improve the classification accuracy of the yolov5 algorithm model. By introducing global context information, the global context block can make the network focus more on global semantics and important features, thereby improving classification accuracy. It can help the network better distinguish feature differences between different categories, thereby reducing misclassification.
[0114] (3) The global context block can improve the positioning accuracy of the YOLOv5 algorithm model. The global context module is particularly beneficial for target positioning tasks. It can enhance the network's understanding of the contextual information around the target and provide more accurate target positioning and bounding box prediction. This helps reduce target positioning errors and improve positioning accuracy. It can strengthen global semantics. The global context module incorporates global semantic information into the feature map through global average pooling and channel-dimensional attention mechanisms. This helps the network better understand the overall semantics and context of the input data, and has more advantages in processing overall scenes and global dependencies.
[0115] Furthermore, the code implementation of Global Context Block applied to the yolov5 algorithm model is expressed as follows: In the code, the GlobalContextBlock class is defined to implement the general global context block (GCB) to capture the global context information of the feature map. During the initialization process, according to the number of channels of the input feature map, the pooling method ('att' is attention pooling, 'avg' is average pooling) and the fusion method ('channel_add' is channel addition, 'channel_mul' is channel multiplication), the relevant convolutional layer and pooling layer are defined, and the initialize_weights method is called to initialize the weights. The initialize_weights method is specifically used to initialize the weights of the attention pooling convolutional layer and the fusion convolutional layer. The compute_context method is responsible for calculating the global context information of the input feature map: for attention pooling, the attention mask is calculated through the convolutional layer and the softmax layer, and the weighted sum is performed to obtain the context vector; for average pooling, the context vector is calculated using the adaptive average pooling layer. During the forward propagation process, the compute_context method is first called to calculate the context vector, and then the context vector is added and multiplied by channel_add_conv and channel_mul_conv respectively, and the result is applied to the input feature map to finally obtain the output feature map.
[0116] In an optional embodiment, the C3GHOST convolution optimizes the yolov5 algorithm model, including:
[0117] A lightweight model is constructed by applying Ghost convolution in the backbone feature extraction network of the yolov5 algorithm model through GhostBottleneck, and the GhostBottleneck class defines a residual block including a GhostConv class, a DWConv class, and a direct path residual connection;
[0118] The convolution structure based on the GhostConv class uses a 1x1 convolution kernel to convert the number of input channels to half the number of hidden channels. After feature extraction through a 5x5 convolution kernel, the feature outputs of the two convolution kernel stages are concatenated in the channel dimension to add a Ghost Channel generated by the linear combination of the original input channels to each input channel to represent the feature information of the original input channel.
[0119] The DWConv class performs downsampling according to the stride parameter, and performs model calculation and feature extraction simultaneously through depthwise separable convolution.
[0120] The information flow and feature reuse within the model are constructed through the direct path residual connection of the GhostConv class and the DWConv class.
[0121] Specifically, Ghost convolution is a lightweight convolution operation that aims to reduce the number of model parameters and computation while maintaining good performance. This is achieved by introducing a small number of Ghost Channels on each channel, that is, adding a corresponding Ghost Channel on the basis of each input channel. Ghost Channel is generated by a linear combination of the original channels, and can approximate the feature information of the original channels with fewer parameters. The C3Ghost module applies Ghost convolution to the C3 module, which is one of the modules in YOLOv5 used to extract and fuse features of different scales. By introducing C3Ghost, the model can be kept lightweight while enhancing the feature extraction capability of the model, improving the performance and efficiency of the model. The introduction of Ghost convolution into the C3 module of YOLOv5C3 has the following advantages: (1) Ghost convolution can share parameters on each channel, thereby reducing the number of model parameters, the complexity of the model and the amount of computation. (2) Since Ghost convolution introduces Ghost Channel, the feature information of the original channel can be represented with fewer parameters, making the model more lightweight. In addition, by introducing Ghost convolution in the C3 module, the model's ability to extract features of different scales can be enhanced, and the model's perception and generalization capabilities can be improved. (3) Since Ghost convolution reduces the number of model parameters and the amount of calculation, it can accelerate the model's training and reasoning process, and improve the model's efficiency and speed. Experiments have shown that since Backbone is in a key position for extracting data features, introducing C3Ghost at the Backbone will result in a lack of rich features due to the non-dense lightweight convolution structure, resulting in poor evaluation results. Therefore, it is necessary to introduce C3Ghost into the Neck part to optimize the yolov5 algorithm model.
[0122] Furthermore, the code implementation of C3GHOST convolution applied to the yolov5 algorithm model is expressed as:
[0123] In the code, the GhostConv class implements a special convolution structure, which enhances the feature extraction capability through a two-stage operation: first, a 1x1 convolution kernel is used to convert the number of input channels to half the number of hidden channels, and then a 5x5 convolution kernel is used to extract features, and the outputs of the two stages are spliced in the channel dimension to increase the nonlinear expression capability. Next, the DWConv class implements a depth-separable convolution, and decides whether to perform a downsampling operation based on the stride parameter, thereby effectively extracting features while maintaining computational efficiency. Furthermore, the GhostBottleneck class defines a residual block structure that includes a combination of GhostConv and DWConv, as well as a residual connection for a direct path, in this way achieving efficient information flow and feature reuse. Finally, the C3Ghost class inherits from C3, and stacks multiple GhostBottleneck instances on its basis to build a complete neural network structure.
[0124] Furthermore, the design of GhostConv and DWConv classes enables convolution operations to effectively extract features of different scales and complexities in images while maintaining efficient computation. For fruit detection, this means that the network can accurately capture the features of fruits of various sizes and shapes, and can effectively detect and identify both small fruits such as strawberries and large fruits such as oranges. And the structure of GhostBottleneck allows information to be efficiently transmitted and reused in the network. This design helps to improve the perception and representation capabilities of the network, allowing the fruit detector to maintain stable detection performance under different backgrounds, lighting and occlusion conditions. The combined effect of the above advantages enables the network model to achieve high accuracy and stability in fruit detection tasks.
[0125] As an example, the transposed convolution, global context block and C3GHOST convolution optimized yolov5 algorithm model are experimentally verified. The labeled data sets used in the experimental process are used as training sets and test sets. The experimental results use Precision and Recall as evaluation indicators. For the transposed convolution, global context block and C3GHOST convolution optimized yolov5 algorithm model, the same training set and verification set are guaranteed to be used for training and testing.
[0126] Furthermore, the CSPDarknet53 network and Upsample upsampling layer of the original yolov5 algorithm model are used as the control group to compare with Global Context Block, Transposed Convolution, and C3Ghost to show the optimization results, as shown in Table 1 below:
[0127]
[0128] From Table 1, we can see that when using Global Context Block, Transposed Convolution, and C3Ghost, we can observe that the precision (Precision) is significantly improved while the recall rate (Recall) is reduced. Although this may reduce the recall rate, in scenarios such as fruit picking, higher precision is more important than higher recall rate. More attention should be paid to accuracy rather than missed detection. Therefore, the optimization of the backbone network Backbone and the head structure Head of the yolov5 algorithm model greatly improves the application requirements of picking target detection.
[0129] Furthermore, for C3Ghost, since the Jetson Nano carried by the robot is a small computer for embedded devices, it has restrictions on power consumption. The model optimized by C3Ghost has less computational complexity than the original model, which can reduce the power consumption of the device, extend the use time of the device, have higher computational efficiency, and can achieve higher real-time performance on JetsonNano. This is very important for real-time processing of video streams or other real-time detection tasks. While the model is lightweight, the performance and accuracy of the model are not sacrificed. On the contrary, the model optimized by C3Ghost can achieve higher running speed and efficiency while maintaining high accuracy. This greatly improves the efficiency of deploying the YOLOv5 model on devices such as Jetson Nano without reducing the performance level of the model. Therefore, applying the weight file optimized by C3Ghost to JETSON NANO fruit recognition greatly simplifies the model parameters and GFLops.
[0130] In an optional embodiment, obtaining the relative coordinates of the pixel coordinates according to the coordinate conversion includes:
[0131] According to the pixel coordinates (x, y, w, h) determined by the recognition result, the image midpoint coordinates (cx, cy) and the target midpoint coordinates (zx, zy) corresponding to the recognition result are calculated respectively. The calculation formulas of the image midpoint coordinates and the target midpoint coordinates are as follows:
[0132]
[0133] The coordinates of the midpoint of the image are set as the origin, and the target midpoint coordinates (zx, zy) are transferred relative to the origin by measuring the proportional relationship between the pixel distance and the actual distance (bx, by) to generate the target coordinates (nx, ny), and the target coordinates (nx, ny) are converted into relative coordinates (rx, ry) measured in centimeters according to the proportional relationship (bx, by), where the calculation formulas for the target coordinates and the relative coordinates are:
[0134]
[0135] The relative coordinates are used to help the robot locate and navigate the picking target.
[0136] Specifically, the above coordinate conversion process ensures that the captured fruit coordinates can accurately represent their actual position in the image in centimeters. In the fruit picking robot, the USB high-definition camera is used as a visual module, and JETSON NANO is responsible for real-time processing and conversion of the fruit's coordinate information. By passing the actual coordinates of the fruit to the program that controls the robotic arm, the robot can accurately locate and grab the fruit, providing accurate position information, thereby improving the efficiency and accuracy of the operation.
[0137] In an optional embodiment, the calculating the static motion parameters of the manipulator corresponding to the relative coordinates by inverse kinematics solution includes:
[0138] Construct a mapping relationship between the joint angle of the robot's three-degree-of-freedom manipulator and the manipulator base, and collect the bottom height H1, upper arm length L1, lower arm length L2, and arm compensation B of the manipulator;
[0139] The centimeter coordinates (X, Y) between the picking target and the base of the robotic arm are calculated according to the relative coordinates (rx, ry), and the static motion parameters of the robotic arm are calculated based on the robotic arm parameters and the centimeter coordinates (x1, y1). The calculation formula of the static motion parameters is:
[0140]
[0141] The static motion parameters include the vertical projection T, the base angle J0, the upper arm angle J1, the lower arm angle J2, the short side D and the hypotenuse X0.
[0142] Furthermore, when the height of the picked object is lower than the height of the base, the calculation formula of the arm angle J2 is:
[0143] J2=tan -1 (T / D)
[0144] When the height of the picked object is equal to the base height, the arm angle J2 is 0. When the height of the picked object is higher than the base height, the calculation formula of the arm angle J2 is:
[0145] J2=tan -1 (D / T)
[0146] Furthermore, the algorithm for the inverse kinematic solution of the three-axis manipulator is based on mathematical models and geometric derivation. By analyzing the structure and kinematic characteristics of the manipulator, the mapping relationship between the joint angle and the end effector coordinates is established. In this process, it is assumed that the manipulator has three degrees of freedom, namely three joints. First, the structural parameters of the manipulator are determined, including the base height, the length of the upper arm, the length of the lower arm, and the arm compensation. These parameters are obtained by measurement. Then, for a given end effector target position and posture, we need to calculate the angle of each joint. According to the established mathematical model, we can calculate the vertical projection by the formula: the vertical distance to the base of the manipulator is calculated according to the coordinates of the end effector, the base angle: the angle with the base of the manipulator is calculated according to the coordinates of the end effector, the upper arm angle: the possible values of the upper arm angle are calculated according to the cosine theorem and the arccosine function, and the lower arm angle: the possible values of the lower arm angle are calculated according to the cosine theorem and the arccosine function. Finally, according to the kinematic characteristics of the manipulator and the different situations of the target position, different calculation formulas are used to obtain the final joint angle. This inverse solution algorithm can help the three-axis robotic arm achieve accurate positioning and posture control of the target position, thereby realizing the execution of complex tasks.
[0147] In an optional embodiment, the method of using quintic polynomial interpolation to solve the dynamic motion parameters of the robot arm includes:
[0148] The starting angle INIT, target angle TARGET, initial angular velocity W0, target angular velocity W1, initial angular acceleration AC0, target angular acceleration AC1, total motion time TF, time step TS and motion time point T of the dynamic motion of the manipulator servo are defined. The initial angle A0, initial angular velocity A1, half of the initial angular velocity A2, acceleration A3, square of acceleration A4 and cube of acceleration A5 of the servo are calculated by defining the parameters. Based on the angles Theta, WC0 and ACC0 of the manipulator servo, the angle, angular velocity and angular acceleration position of the servo at different time points are calculated to provide the dynamic motion parameters of the servo smooth motion. The calculation formula is:
[0149] A0=INIT
[0150] A1=W0
[0151]
[0152] A3=(20*TARGET-20*INIT-(8*W1+12*W0)*TF-(3*AC0-AC1)*TF 2 / (2*TF 3<h2 style=";text-align:left;direction:ltr">)<h2 style=";text-align:left;direction:ltr"> <h2 style=";text-align:left;direction:ltr">
[0153] <h2 style=";text-align:left;direction:ltr"> A4=(30*TARGET-30*INIT+(14*W1+16*W0)*TF-(3*AC0-2*AC1)*TF<h2 style=";text-align:left;direction:ltr"> 2 <h2 style=";text-align:left;direction:ltr"> / (2*TF<h2 style=";text-align:left;direction:ltr"> 4 <h2 style=";text-align:left;direction:ltr"> )<h2 style=";text-align:left;direction:ltr"> <h2 style=";text-align:left;direction:ltr">
[0154] <h2 style=";text-align:left;direction:ltr"> A5=(12*TARGET-12*INIT-(6*W1+6*W0)*TF-(AC0-AC1)*TF<h2 style=";text-align:left;direction:ltr"> 2 <h2 style=";text-align:left;direction:ltr"> / (2*TF<h2 style=";text-align:left;direction:ltr"> 5 <h2 style=";text-align:left;direction:ltr"> )<h2 style=";text-align:left;direction:ltr"> <h2 style=";text-align:left;direction:ltr">
[0155] <h2 style=";text-align:left;direction:ltr"> Theta = A0 + A1 * T + A2 * T<h2 style=";text-align:left;direction:ltr"> 2 <h2 style=";text-align:left;direction:ltr"> +A3*T<h2 style=";text-align:left;direction:ltr"> 3 <h2 style=";text-align:left;direction:ltr"> +A4*T<h2 style=";text-align:left;direction:ltr"> 4 <h2 style=";text-align:left;direction:ltr"> +A5*T<h2 style=";text-align:left;direction:ltr"> 5 <h2 style=";text-align:left;direction:ltr"> <h2 style=";text-align:left;direction:ltr">
[0156] <h2 style=";text-align:left;direction:ltr"> WC0 = A1 + 2 * A2 * T + 3 * A3 * T<h2 style=";text-align:left;direction:ltr"> 2 <h2 style=";text-align:left;direction:ltr"> +4*A4*T<h2 style=";text-align:left;direction:ltr"> 3 <h2 style=";text-align:left;direction:ltr"> +5*A5*T<h2 style=";text-align:left;direction:ltr"> 4 <h2 style=";text-align:left;direction:ltr"> <h2 style=";text-align:left;direction:ltr">
[0157] <h2 style=";text-align:left;direction:ltr"> ACC0 = 2*A2 + 6*A3*T + 12*A4*T<h2 style=";text-align:left;direction:ltr"> 2 <h2 style=";text-align:left;direction:ltr"> +20*A5*T<h2 style=";text-align:left;direction:ltr"> 3 <h2 style=";text-align:left;direction:ltr"> <h2 style=";text-align:left;direction:ltr">
[0158] Furthermore, in order to achieve smooth control of the servo of the robot arm, a quintic polynomial is designed to optimize the motion control of the servo. The quintic spline interpolation is an interpolation method that approximates the data by inserting a smooth spline curve between given data points. The continuity of the local interpolation polynomial and the continuity of the first-order derivative are used to achieve the fitting of the smooth curve, which can effectively approximate the target motion trajectory in the servo control system. By interpolating between known data points, a continuous and smooth servo trajectory can be obtained, making the servo motion smoother. Using the quintic polynomial trajectory to control the servo has the following advantages: (1) Smoothness: The quintic polynomial trajectory can achieve a smooth motion process, and the servo will not experience sudden changes or jitters during the motion process, thereby ensuring the stability and comfort of the system. (2) Accuracy: By accurately controlling the coefficients of the polynomial, the position, speed and acceleration of the servo can be accurately controlled to achieve the expected target position, thereby meeting the system's high requirements for position control. (3) Controllability: The shape and motion parameters of the polynomial trajectory can be adjusted according to specific needs, including the starting angle, target angle, starting angular velocity, target angular velocity and acceleration, so that the motion process of the servo can be flexibly adapted to different application scenarios. (4) Real-time: The calculation of the quintic polynomial trajectory is simple and efficient, and can quickly generate control instructions in the real-time system to achieve real-time response to the servo and meet the needs of real-time control. (5) Easy to implement: The quintic polynomial trajectory control algorithm is relatively simple, does not require complex control logic and a large amount of calculation, is easy to implement and deploy, and is suitable for various embedded systems and control platforms.
[0159] The present invention uses the high-performance, low-latency real-time video stream processing framework DeepStream, combined with the TensorRT inference engine (deep learning inference acceleration library), to efficiently infer models such as YOLOV5. TensorRT uses GPU to accelerate the inference process, improves the inference speed of the model, meets the real-time performance requirements of target detection, and reduces the resource consumption of target detection, especially on small devices such as picking robots.
[0160] The present invention optimizes the YOLOv5 algorithm model by adopting three methods: global context block, transposed convolution and C3Ghost, thereby improving the perception ability, accuracy and computational efficiency of the model and reducing the influence of interference factors on target detection results in complex scenes.
[0161] The present invention jointly optimizes the motion control of the three-axis manipulator through the inverse solution of the kinematics of the three-axis manipulator and polynomial interpolation. The inverse solution algorithm obtains the final joint angle according to the calculation formula of the kinematic characteristics of the manipulator and the target position, which helps the three-axis manipulator to accurately locate the target position and control the posture, thereby realizing the execution of complex picking tasks. The polynomial interpolation utilizes the continuity of the local interpolation polynomial and the continuity of the first-order derivative to realize the fitting of the smooth curve, which can effectively approximate the target motion trajectory in the servo control system, and can obtain a continuous and smooth servo trajectory, making the servo movement smoother.
[0162] like Figure 2 As shown, the second aspect of the present invention discloses a picking robot, comprising:
[0163] A mobile platform component, a mechanical arm component mounted on the mobile platform, and a control system mounted in the mobile platform;
[0164] The mobile platform assembly includes a chassis composed of a top plate 1, a bottom plate 2 and a first support column 3, a Mecanum wheel 4 disposed at the bottom of the bottom plate 2, and a reduction motor 5 driving the Mecanum wheel 4;
[0165] The robot arm assembly includes a tray 6, an arm portion 7, a wrist portion 8, a clamping claw portion 9, a screw rod 10 for driving the arm portion 7 to extend and retract, a steering gear 11 for driving the wrist portion 8 to rotate, a driving motor 12 for driving the clamping claw portion 9 to operate, and a camera 13 mounted on the rear end of the clamping claw portion 9 for collecting a target video stream;
[0166] The control system includes a main control module, a wireless control module, a sensor module, a motor drive module and a power module. The main control module includes an STM32RCT6 single-chip microcomputer for controlling the robot motion trajectory and wireless control, a JETSON NANO embedded development board for controlling target video stream image processing, and a PCA9685 module for controlling the mechanical arm according to the image processing result of the JETSON NANO embedded development board. The PCA9685 module uses an I2C interface to control the angle of the mechanical arm servo. The JETSON NANO embedded development board accelerates the reasoning of the yolov5 algorithm model through the DeepStream video stream processing framework and the TensorRT reasoning engine. The STM32RCT6 single-chip microcomputer and the JETSON NANO embedded development board are interconnected through a TX pin and a RX pin to enable the main control module to perform bidirectional transmission of information.
[0167] Specifically, in the design of system hardware and software solutions, the robot control solution is a crucial link. The picking robot uses STM32RCT6 and JETSON NANO as the main control. Among them, STM32RCT6 is responsible for the robot's tracking, Bluetooth and other aspects of motion control. Its low power consumption and high performance make it an ideal choice for embedded systems. JETSONNANO is responsible for image processing and controls PCA9685 for servo control. Its GPU accelerated computing capability provides strong support for the robot's perception and decision-making. In order to achieve effective communication between the two, a serial port is used for connection. Specifically, the serial port TX pin of STM32RCT6 is connected to the serial port RX pin of Jetson Nano, and the serial port RX pin of STM32RCT6 is connected to the serial port TX pin of Jetson Nano, ensuring the two-way transmission of information and realizing the overall collaborative work of the system.
[0168] The wireless control module is configured as an HC-05 Bluetooth module, and is connected to a mobile terminal device through communication with the Bluetooth module to remotely control the picking robot;
[0169] Specifically, the HC-05 Bluetooth module is used to build a mobile phone app to remotely control the picking robot. The HC-05 has a simple serial communication interface, which provides a standard AT command set to simplify configuration and control. The HC-05 supports basic Bluetooth protocols and is compatible with most Bluetooth devices. It can communicate wirelessly with smartphones, tablets and other devices. The HC-05 has long-distance transmission characteristics, and the transmission distance can reach more than 10 meters. At the same time, the HC-05 supports low-power mode and can enter a dormant state when idle to save power and extend battery life.
[0170] The sensor module is configured as an MPU6050 module integrating a three-axis gyroscope and a three-axis accelerometer, so as to measure the rotation angle and rotation acceleration of the robot arm;
[0171] Specifically, the MPU6050 module integrates a three-axis gyroscope and a three-axis accelerometer, providing measurement of the rotation and acceleration of an object. It has high measurement accuracy. The data of the gyroscope and accelerometer can be measured at a 16-bit resolution, providing high precision and accuracy.
[0172] The motor drive module is configured as a TB6612 dual H-bridge driver to control one or more motors carried by the picking robot to perform motor drive;
[0173] Specifically, in the motor drive control scheme, an H-bridge driver is used as the motor driver, where TB6612 is selected between the two motor drivers L298N and TB6612. There are two main reasons for choosing TB6612 as the motor driver compared to L298N: package size and space layout considerations. First, TB6612 uses a smaller package, which makes TB6612 more suitable for integration and layout in a limited space compared to the larger multi-pin package of L298N. The small package of TB6612 makes it easier to install in a limited space, while reducing the occupied area on the circuit board, leaving more space for other components. Secondly, TB6612 is comparable to L298N in terms of performance and functionality, and even has some advantages. TB6612 is a dual H-bridge driver that can control two DC motors or stepper motors. It has a high operating voltage and current capability, and can provide stable and reliable motor drive. In addition, TB6612 also has safety features such as overcurrent protection, overtemperature protection, and short-circuit protection, which can effectively protect motors and circuits. Therefore, in terms of performance and functions, TB6612 can meet most motor drive needs.
[0174] The power supply module includes a 12V power supply for the STM32RCT6 single-chip microcomputer through a DC socket, a 5V4A DC power supply configured on the JETSONNANO embedded development board, and an LM2596 voltage regulator module that provides a stable 5V power supply for the HC-05 Bluetooth module, the MPU6050 module, and the PID tracking module. The JETSON NANO embedded development board and the PCA9685 module output 5V through a step-down module to step down the voltage to the PCA9685 module to execute the robot arm servo control.
[0175] Furthermore, the above-mentioned module designs the shape and size of the PCB according to the size and structure of the robot, layouts and designs each module according to its function and connection relationship, and reasonably arranges their position and direction to ensure short-distance connection of the signal line and stable power supply of the power line, and adopts a double-layer board design for the PCB board.
[0176] In an optional embodiment, the control system also includes a display module, which is configured as an OLED display screen to visually display the robot's status information and provide a click button for adjusting the tracking parameters for the PID tracking module. The status information includes the robot's elevation angle, depression angle, yaw angle, picking target category and number of picking targets.
[0177] Specifically, the working principle of the harvesting robot through the control method disclosed in the second aspect of the present invention is:
[0178] After the picking robot is powered on and initialized, the Bluetooth module starts to wait for the serial port signal from the mobile device (such as a mobile phone APP). Once the signal is received, the picking robot starts the PID line-finding algorithm to keep driving on the lane. When the picking robot encounters a left translation intersection, it performs a left translation operation until it reaches the end position and stops. At this time, STM32RCT6 sends a serial port signal to JETSON NANO. After receiving the signal, JETSON NANO starts to read the image captured by the camera and recognize the fruit. The coordinate information of the fruit is stored in a TXT file in a predetermined path. JETSON NANO performs coordinate transformation and kinematic inverse solution calculation on the read coordinate information to determine the required rotation angle of each axis of the robot arm. At the same time, JETSON NANO controls the PCA9685 module to start the grasping operation and move the robot arm to the appropriate position to grasp the fruit. After the grasping is completed, the robot arm places the fruit at the specified position. After the entire program is executed, the task ends. This solution combines the driving control of the picking robot with the image processing and robotic arm control of JETSON NANO to achieve automated fruit grabbing tasks. Through serial communication and coordinated control, the picking robot and JETSON NANO achieve information exchange and task coordination, improving the intelligence and autonomy of the system.
[0179] The third aspect of the present invention discloses a harvesting robot control device based on an improved yolov5 algorithm, comprising:
[0180] at least one processor, and
[0181] a memory communicatively connected to the at least one processor; wherein,
[0182] The memory stores instructions executable by the at least one processor, and the instructions are executed by the at least one processor so that the at least one processor can execute the picking robot control method based on the improved yolov5 algorithm as described in any one of the items disclosed in the first aspect of the present invention.
[0183] The computer device may be a terminal, and the computer device includes a processor, a memory, a network interface, a display screen and an input device connected through a system bus. Among them, the processor of the computer device is used to provide computing and control capabilities. The memory of the computer device includes a non-volatile storage medium and an internal memory. The non-volatile storage medium stores an operating system and a computer program. The internal memory provides an environment for the operation of the operating system and the computer program in the non-volatile storage medium. The network interface of the computer device is used to communicate with an external terminal through a network connection. When the computer program is executed by the processor, a control method for a picking robot based on an improved yolov5 algorithm is implemented. The display screen of the computer device may be a liquid crystal display screen or an electronic ink display screen, and the input device of the computer device may be a touch layer covering the display screen, or a key, trackball or touchpad provided on the housing of the computer device, or an external keyboard, touchpad or mouse, etc.
[0184] The fourth aspect of the present invention discloses a computer-readable storage medium, which stores computer-executable instructions, and the computer-executable instructions are used to enable a computer to execute the harvesting robot control method based on the improved yolov5 algorithm as described in any one of the items disclosed in the first aspect of the present invention.
[0185] Those of ordinary skill in the art can understand that all or part of the processes in the above-mentioned embodiment method can be completed by instructing the relevant hardware through a computer program, and the computer program can be stored in a non-volatile computer-readable storage medium. When the computer program is executed, it may include the processes of the above-mentioned embodiments of the picking robot control method based on the improved yolov5 algorithm. Among them, any reference to memory, storage, database or other media used in the embodiments provided in this application may include non-volatile and / or volatile memory. Non-volatile memory may include read-only memory (ROM), programmable ROM (PROM), electrically programmable ROM (EPROM), electrically erasable programmable ROM (EEPROM) or flash memory. Volatile memory may include random access memory (RAM) or external cache memory. By way of illustration and not limitation, RAM is available in many forms, such as static RAM (SRAM), dynamic RAM (DRAM), synchronous DRAM (SDRAM), double data rate SDRAM (DDRSDRAM), enhanced SDRAM (ESDRAM), synchronous link (Synchlink) DRAM (SLDRAM), memory bus (Rambus) direct RAM (RDRAM), direct memory bus dynamic RAM (DRDRAM), and memory bus dynamic RAM (RDRAM), etc.
[0186] Alternatively, if the above modules of the present invention are implemented in the form of software function modules and sold or used as independent products, they can also be stored in a computer-readable storage medium. Based on this understanding, the technical solution of the embodiment of the present invention can be essentially or partly reflected in the form of a software product that contributes to the relevant technology. The computer software product is stored in a storage medium and includes several instructions for a computer device (which can be a personal computer, terminal, or network device, etc.) to execute all or part of the methods of each embodiment of the present invention. The aforementioned storage medium includes: various media that can store program codes, such as mobile storage devices, RAM, ROM, magnetic disks or optical disks.
[0187] The above description is only a preferred embodiment of the present invention and is not intended to limit the present invention. Any modifications, equivalent substitutions, improvements, etc. made within the spirit and principle of the present invention should be included in the protection scope of the present invention.
Claims
1. A picking robot control method based on improved yolov5 algorithm, It is characterized in that The method comprises: Build an orchard simulation environment, generate a target picking task to determine the target path of the robot, detect the error value between the robot's moving path and the target path in real time through sensors, calculate the proportional parameter P according to the error value, and adjust the robot's motion state by feeding back the control signal of the proportional parameter P through the PID controller; The video stream processing framework is used to load the yolov5 algorithm model to build a video processing channel, and an inference engine is configured on the video processing channel to perform inference acceleration tasks; The target video stream is collected as the input of the yolov5 algorithm model, and the yolov5 algorithm model is optimized by using transposed convolution, global context block and C3GHOST convolution respectively, and the recognition result, pixel coordinates and the proportional relationship between the measured pixel distance and the actual distance of the target picked in the target video stream are output, and the relative coordinates of the pixel coordinates are obtained according to the coordinate transformation; The static motion parameters of the robotic arm corresponding to the relative coordinates are calculated by inverse kinematics solution, and the dynamic motion parameters of the robotic arm are solved by quintic polynomial interpolation. Based on the static motion parameters, dynamic motion parameters and relative coordinates, the picking robot is controlled to perform the target picking task.
2. According to claim 1, the control method of the picking robot based on the improved yolov5 algorithm, It is characterized in that The construction of the orchard simulation environment and the generation of the target picking task to determine the target path of the robot include: Orchard map information is obtained by collecting early images of the orchard to simulate the orchard map environment, the starting point location information and the end point location information of the target picking task are planned according to the picking requirements, and one or more target paths are generated according to the starting point location information and the end point location information.
3. According to claim 2, the control method of the picking robot based on the improved yolov5 algorithm, It is characterized in that The sensor detects the error value between the robot's moving path and the target path in real time, calculates the proportional parameter P according to the error value, and feeds back the control signal of the proportional parameter P through the PID controller to adjust the robot's motion state, including: The robot loads the target path, walks according to the starting point-end point map trajectory of the target picking task, detects and feeds back the actual moving path parameters in real time, calculates the error value between the target path and the actual moving path in each unit time in real time, updates the assignment of the proportional parameter P in real time according to the error value and the target path of each unit time to output the motion control parameters of the current time, adjusts the current motion state of the robot according to the motion control parameters until the proportional parameter P is adjusted to the optimal assignment, and continuously outputs the motion control parameters according to the optimal assigned proportional parameter P combined with the error value of the current time to control the motion state of the robot until it reaches the end point.
4. The picking robot control method based on the improved yolov5 algorithm according to claim 1, It is characterized in that The video processing channel is constructed by using a video stream processing framework to load the yolov5 algorithm model, and the video processing channel is configured with an inference engine to accelerate the target detection task, including: The DeepStream video stream processing framework is used to build a video processing channel on the Jetson Nano embedded development board configured with the robot, and the dependency of the TensorRT inference engine is configured for the video processing channel, and the yolov5 algorithm model is loaded into the DeepStream video stream processing framework; The yolov5 algorithm model is trained through a cloud server to output a .pt weight file, and the .pt weight file is transferred to the Jetson Nano embedded development board using a WINSCP graphical client. The .pt weight file is converted into a .wts weight file using a conversion program of the TensorRT inference engine to optimize the model parameters of the yolov5 algorithm model. The .wts weight file is converted into an .engine file by compiling and importing it into the target path of the DeepStream video stream processing framework, so that the yolov5 algorithm model is converted into an inference engine configured in a video processing channel and used for one or more tasks of data input, data preprocessing, inference acceleration, post-processing and output results. The output result is that the yolov5 algorithm model performs target detection and tracking recognition on each frame of the video stream in the data input, and the GPU of the Jetson Nano embedded development board executes the inference acceleration task of the yolov5 algorithm model through the TensorRT inference engine.
5. The picking robot control method based on the improved yolov5 algorithm according to claim 1, It is characterized in that The transposed convolution optimizes the yolov5 algorithm model, including: The nn.ConvTranspose2d class is used to define a transposed convolution layer transposed_con in the head structure of the yolov5 algorithm model, and the torch.randn function is used to generate a random tensor for simulating the input image as the input of the upsampling operation of the yolov5 algorithm model. The reverse convolution kernel of the transposed convolution layer transposed_con is used to perform a transposed convolution operation on the input random tensor to generate an output tensor as the feature map space dimension expansion training for each frame image in the target video stream. The shape of the random tensor is expressed as (batch_size, input_channels, input_height, input_width), where batch_size represents the batch size of the input, input_channels represents the number of channels of the input, input_height represents the height of the input, and input_width represents the width of the input.
6. The picking robot control method based on the improved yolov5 algorithm according to claim 1, It is characterized in that The global context block is used to optimize the yolov5 algorithm model, including: The Global Context Block defines a 1x1 convolutional layer, a softmax layer, and a feature transformation module in sequence. The feature transformation module includes multiple convolutional layers, a normalization layer, and an activation function. Extract the input size of the input feature map in each frame of the target video stream, convert the input feature map into a single-channel feature map through the 1x1 convolution layer to obtain global context information of the input feature map, wherein the input size includes the batch size, the number of channels, the height h and the width w of the input feature map, and the single-channel feature map is flattened, and the shape is expressed as (batch, 1, h, w), where 1 represents the number of channels, batch represents the batch size, h represents the height, and w represents the width; The single-channel feature map is normalized by the softmax layer for calculating the weight distribution, and the single-channel feature map used to represent the global context information after the flattening operation is fused with the weight distribution by channel multiplication to calculate the global context vector, wherein the shape of the global context vector is (batch, c, 1, 1); The feature transformation module uses linear transformation and nonlinear activation to generate a feature map with the same shape as the input feature map on the global context vector, and adds the input feature map and the feature map transformed by the global context vector point by point to obtain a feature representation of the input feature map enhanced by the global context block.
7. The picking robot control method based on the improved yolov5 algorithm according to claim 6, It is characterized in that The C3GHOST convolution optimizes the yolov5 algorithm model, including: A lightweight model is constructed by applying Ghost convolution in the backbone feature extraction network of the yolov5 algorithm model through GhostBottleneck, and the GhostBottleneck class defines a residual block including a GhostConv class, a DWConv class, and a direct path residual connection; The convolution structure based on the GhostConv class uses a 1x1 convolution kernel to convert the number of input channels to half the number of hidden channels. After feature extraction through a 5x5 convolution kernel, the feature outputs of the two convolution kernel stages are concatenated in the channel dimension to add a Ghost Channel generated by the linear combination of the original input channels to each input channel to represent the feature information of the original input channel. The DWConv class performs downsampling according to the stride parameter, and performs model calculation and feature extraction simultaneously through depthwise separable convolution. The information flow and feature reuse within the model are constructed through the direct path residual connection of the GhostConv class and the DWConv class.
8. The picking robot control method based on the improved yolov5 algorithm according to claim 1, It is characterized in that The obtaining the relative coordinates of the pixel coordinates according to the coordinate conversion includes: According to the pixel coordinates (x, y, w, h) determined by the recognition result, the image midpoint coordinates (cx, cy) and the target midpoint coordinates (zx, zy) corresponding to the recognition result are calculated respectively. The calculation formulas of the image midpoint coordinates and the target midpoint coordinates are as follows: The coordinates of the midpoint of the image are set as the origin, and the target midpoint coordinates (zx, zy) are transferred relative to the origin by measuring the proportional relationship between the pixel distance and the actual distance (bx, by) to generate the target coordinates (nx, ny), and the target coordinates (nx, ny) are converted into relative coordinates (rx, ry) measured in centimeters according to the proportional relationship (bx, by), where the calculation formulas for the target coordinates and the relative coordinates are: The relative coordinates are used to help the robot locate and navigate the picking target.
9. The picking robot control method based on the improved yolov5 algorithm according to claim 8, It is characterized in that The calculating the static motion parameters of the robot arm corresponding to the relative coordinates by inverse kinematics solution includes: Construct a mapping relationship between the joint angle of the robot's three-degree-of-freedom manipulator and the manipulator base, and collect the bottom height H1, upper arm length L1, lower arm length L2, and arm compensation B of the manipulator; The centimeter coordinates (X, Y) between the picking target and the base of the robot arm are calculated based on the relative coordinates (rx, ry). 1 ,y 1 ) Calculate the static motion parameters of the robot arm, the calculation formula of the static motion parameters is: The static motion parameters include the vertical projection T, the base angle J0, the upper arm angle J1, the lower arm angle J2, the short side D and the hypotenuse X0.
10. The picking robot control method based on the improved yolov5 algorithm according to claim 9, It is characterized in that The method of using quintic polynomial interpolation to solve the dynamic motion parameters of the robot arm includes: The starting angle INIT, target angle TARGET, initial angular velocity W0, target angular velocity W1, initial angular acceleration AC0, target angular acceleration AC1, total motion time TF, time step TS and motion time point T of the dynamic motion of the manipulator servo are defined. The initial angle A0, initial angular velocity A1, half of the initial angular velocity A2, acceleration A3, square of acceleration A4 and cube of acceleration A5 of the servo are calculated by defining the parameters. Based on the angles Theta, WC0 and ACC0 of the manipulator servo, the angle, angular velocity and angular acceleration position of the servo at different time points are calculated to provide the dynamic motion parameters of the servo smooth motion. The calculation formula is: A0=INIT A1=W0 <h2 style=";text-align:left;direction:ltr">A3=(20*TARGET-20*INIT-(8*W1+12*W0)*TF-(3*AC0-AC1)*TF<h2 style=";text-align:left;direction:ltr"> 2 <h2 style=";text-align:left;direction:ltr"> / (2*TF<h2 style=";text-align:left;direction:ltr"> 3 <h2 style=";text-align:left;direction:ltr"> ) <h2 style=";text-align:left;direction:ltr">A4=(30*TARGET-30*INIT+(14*W1+16*W0)*TF-(3*AC0-2*AC1)*TF<h2 style=";text-align:left;direction:ltr"> 2 <h2 style=";text-align:left;direction:ltr"> / (2*TF<h2 style=";text-align:left;direction:ltr"> 4 <h2 style=";text-align:left;direction:ltr"> ) <h2 style=";text-align:left;direction:ltr">A5=(12*TARGET-12*INIT-(6*W1+6*W0)*TF-(AC0-AC1)*TF<h2 style=";text-align:left;direction:ltr"> 2 <h2 style=";text-align:left;direction:ltr"> / (2*TF<h2 style=";text-align:left;direction:ltr"> 5 <h2 style=";text-align:left;direction:ltr"> ) Theta=A0+A1*T+A2*T 2 +A3*T 3 +A4*T 4 +A5*T 5 WC0=A1+2*A2*T+3*A3*T 2 +4*A4*T 3 +5*A5*T 4 ACC0=2*A2+6*A3*T+12*A4*T 2 +20*A5*T 3 。 11. A picking robot, used to execute the steps of the picking robot control method based on the improved yolov5 algorithm as described in claims 1-10, It is characterized in that include: A mobile platform component, a mechanical arm component mounted on the mobile platform, and a control system mounted in the mobile platform; The mobile platform assembly comprises a chassis composed of a top plate (1), a bottom plate (2) and pillars (3), a Mecanum wheel (4) arranged at the bottom of the bottom plate (2), and a reduction motor (5) driving the Mecanum wheel (4); The mechanical arm assembly comprises a tray (6), an arm portion (7), a wrist portion (8), a clamping claw portion (9), a screw rod (10) for driving the arm portion (7) to telescope, a steering gear (11) for driving the wrist portion (8) to rotate, a driving motor (12) for driving the clamping claw portion (9) to operate, and a camera (13) mounted on the rear end of the clamping claw portion (9) for collecting a target video stream; The control system includes a main control module, a wireless control module, a sensor module, a motor drive module and a power module. The main control module includes an STM32RCT6 single-chip microcomputer for controlling the robot motion trajectory and wireless control, a JETSON NANO embedded development board for controlling target video stream image processing, and a PCA9685 module for controlling the mechanical arm according to the image processing result of the JETSON NANO embedded development board. The PCA9685 module uses an I2C interface to control the angle of the mechanical arm servo. The JETSON NANO embedded development board accelerates the reasoning of the yolov5 algorithm model through the DeepStream video stream processing framework and the TensorRT reasoning engine. The STM32RCT6 single-chip microcomputer and the JETSON NANO embedded development board are interconnected through a TX pin and a RX pin to enable the main control module to perform bidirectional transmission of information. The wireless control module is configured as an HC-05 Bluetooth module, and is connected to a mobile terminal device through communication with the Bluetooth module to remotely control the picking robot; The sensor module is configured as an MPU6050 module integrating a three-axis gyroscope and a three-axis accelerometer, so as to measure the rotation angle and rotation acceleration of the robot arm; The motor drive module is configured as a TB6612 dual H-bridge driver to control one or more motors carried by the picking robot to perform motor drive; The power supply module includes a 12V power supply for the STM32RCT6 single-chip microcomputer through a DC socket, a 5V4A DC power supply configured on the JETSONNANO embedded development board, and an LM2596 voltage regulator module that provides a stable 5V power supply for the HC-05 Bluetooth module, the MPU6050 module, and the PID tracking module. The JETSON NANO embedded development board and the PCA9685 module output 5V through a step-down module to step down the voltage to the PCA9685 module to execute the robot arm servo control.
12. The harvesting robot according to claim 11, It is characterized in that The control system also includes a display module, which is configured as an OLED display screen to visually display the robot's status information and provide a click button for adjusting the tracking parameters for the PID tracking module. The status information includes the robot's elevation angle, depression angle, yaw angle, picking target category and picking target quantity.
13. A picking robot control device based on improved yolov5 algorithm, It is characterized in that include: at least one processor, and a memory communicatively connected to the at least one processor; wherein, The memory stores instructions that can be executed by the at least one processor, and the instructions are executed by the at least one processor so that the at least one processor can execute the picking robot control method based on the improved yolov5 algorithm as described in any one of claims 1 to 10.
14. A computer-readable storage medium, It is characterized in that The computer-readable storage medium stores computer-executable instructions, and the computer-executable instructions are used to enable a computer to execute the picking robot control method based on the improved YOLOv5 algorithm as described in any one of claims 1 to 10.
Citation Information
Patent Citations
A robotic fruit picking system
CN110139552A
Picking mechanical arm trajectory planning method and device based on dynamic multi-objective optimization
CN116834037A
Robot device for crop harvesting with and controlling method thereof
KR102647681B1
Robot system and mobile robot for picking stem fruit of a plant
WO2022038057A1
Systems and methods for robotic fruit harvesting
WO2022195491A1
Cited By
Mechanical arm precise shaft hole assembling method based on lunar eclipse heuristic scene observation and simulation
CN119238518A
Intelligent pepper picking system and picking method
CN119302125A
Fruit picking mechanical system controller optimization method
CN120010232A
Multi-modal fusion corn harvester header height self-adaptive adjusting method and multi-modal fusion corn harvester header height self-adaptive adjusting system
CN120235948A
A multi-modal fusion corn harvester header height adaptive adjustment method and system
CN120235948B
