Wolfberry tree plant protection pesticide spraying device and method based on visual device and ultrasonic sensor

By combining visual devices and ultrasonic sensors in the wolfberry tree plant protection spray device, the density and spray head distance of wolfberry tree are obtained in real time, and the spray volume and wind speed are adjusted, the problem of inaccurate spraying in the existing technology is solved, and efficient and environmentally friendly wolfberry tree spraying is achieved.

CN120021602APending Publication Date: 2025-05-23JIAXING UNIV +1
View PDF 0 Cites 0 Cited by

Patent Information

Application Number
CN202510066207.7
Authority / Receiving Office
CN · China
Patent Type
Applications(China)
Current Assignee / Owner
Filing Date
2025-01-16
Publication Date
2025-05-23

AI Technical Summary

Technical Problem

The prior art is difficult to achieve accurate spraying during the spraying process of wolfberry trees, resulting in waste of medicine and pesticide residues, affecting the fruit rate and quality of wolfberry trees.

Method used

The plant protection spraying device based on visual devices and ultrasonic sensors is adopted to obtain the density of wolfberry trees in real time through the visual device and adjust the spray amount; the distance between the nozzle and the tree is obtained through the ultrasonic sensor, and the wind speed of the fan is adjusted to achieve accurate spraying of the target.

Benefits of technology

It improves the utilization rate of medicine liquid, reduces environmental pollution, reduces pesticide residues, and improves the fruiting rate and quality of wolfberry trees.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN120021602A_ABST
    Figure CN120021602A_ABST
Patent Text Reader

Abstract

The invention discloses a lycium barbarum tree plant protection pesticide spraying device and method based on a visual device and an ultrasonic sensor, and relates to the field of agricultural machinery. The density of the lycium barbarum trees arranged in rows is obtained in real time through a visual device, and the spraying amount of the liquid medicine is adjusted according to the difference of the density; through the ultrasonic sensor, the distance between the visual device and the lycium barbarum tree and the distance between the nozzle and the lycium barbarum tree are obtained in real time, the wind power of the fan is adjusted, and targeted accurate spraying is conducted on the lycium barbarum Aiming at wolfberry trees in different growth stages, the pesticide spraying amount is accurately adjusted according to the density of the wolfberry trees, and pesticide residues are reduced.
Need to check novelty before this filing date? Find Prior Art

Description

Technical Field

[0001] The present invention relates to the technical field of agricultural machinery, and in particular to a plant protection spraying device and method for wolfberry trees based on a visual device and an ultrasonic sensor. Background Art

[0002] The wolfberry tree is a sun-loving, drought-tolerant, and alkali-tolerant shrub economic forest species. Its fruit is a traditional Chinese medicinal material with high medicinal and edible value, and has a unique health-care effect. At present, the pesticide application machinery in wolfberry orchards mostly adopts continuous spray technology, but the spray volume is often fixed, which easily causes waste of liquid medicine. Precise variable spraying of wolfberry trees is an inevitable requirement for improving the green and sustainable development of wolfberry orchards, and is also required by other fruit trees. It can solve the problems of excessive spraying and pesticide residue in orchards, improve the utilization rate of pesticides, reduce environmental pollution, and reduce pesticide residues.

[0003] During the growth and maturity of wolfberry, pesticides must be sprayed on it at different growth stages and under different environmental background conditions to prevent and control crop diseases and pests and enable the plants to grow healthily. During the growth stage, the leaf surface index of the canopy of wolfberry trees changes greatly. During the spraying period from April to October each year, although there have been reports on the use of ultrasonic sensors to measure wolfberry trees, due to the characteristics of wolfberry trees, when spraying, the inner leaves of the wolfberry trees cannot be reached, resulting in insects on the inner leaves, affecting the fruit yield and quality of the wolfberry trees. According to the principle of targeted precision spraying, when the branches and leaves of the wolfberry tree are sparse, the air resistance on the spray path is small, and no high wind pressure is required, and the spray droplets can easily reach the destination. When the leaves are dense, the air resistance on the spray path is large, and a large wind pressure is required for the spray droplets to reach the destination. Summary of the invention

[0004] Based on the above description, the present invention proposes a plant protection spraying device and method for wolfberry trees based on a visual device and an ultrasonic sensor. The density of wolfberry trees arranged in rows is obtained in real time through the visual device, and the spray amount of the liquid medicine is adjusted according to the density. The ultrasonic sensor is used to obtain the distance between the visual device and the nozzle and the wolfberry tree in real time to adjust the wind force of the fan, so as to carry out targeted and precise spraying of the wolfberry tree.

[0005] The technical solutions adopted are: A plant protection spraying device for wolfberry trees based on a visual device and an ultrasonic sensor comprises a frame, a walking crawler module is installed below the frame, a visual device and an ultrasonic sensor are installed in front of the frame, a spraying device is installed at the rear of the frame, and a medicine box is installed at the center of the frame; Ultrasonic sensors are installed on both sides of the front of the frame, namely, a first ultrasonic sensor, a second ultrasonic sensor and a third ultrasonic sensor from top to bottom; a speed sensor is installed below one of the third ultrasonic sensors; A visual device is installed on one side of the second ultrasonic sensor; Platforms are installed on both sides of the rear of the frame, and spray devices are installed on the platforms, which are the first spray device, the second spray device and the third spray device from top to bottom, and the structures of the first spray device, the second spray device and the third spray device are the same; The first spray device includes a duct, a fan and a spray module. The duct and the fan are installed on one side of the spray module, close to the frame, and the fan is installed in the duct. The first spray device corresponds to the first ultrasonic sensor; the second spray device corresponds to the second ultrasonic sensor; the third spray device corresponds to the third ultrasonic sensor; the corresponding spray devices and ultrasonic sensors are at the same level and on the same side of the frame; The duct is a hollow cylindrical shape; The liquid medicine in the medicine box is pumped out of the medicine box by a diaphragm pump and divided into two paths by a pressure regulating diverter valve, one path of liquid medicine enters the pipeline, and the other path of liquid medicine flows back to the medicine box; the liquid medicine in the pipeline is divided into two paths by a solenoid valve, and each path is connected to a three-way connector to form a six-path liquid medicine pipeline, and each liquid medicine pipeline is connected to a spray device; Each fan is connected to a three-phase brushless controller and a relay to achieve individual control of the wind speed of each fan.

[0006] Furthermore, the visual device is a Dahua industrial camera.

[0007] Furthermore, the spray module includes a circular tube and three nozzles; the circular tube is fixed on the edge of the platform and communicates with the pipeline; the three nozzles are evenly distributed on the outside of the circular tube; the center points of the three nozzles are connected in sequence to form an equilateral triangle; the center of the circular tube and the center of the duct are on the same horizontal line; the second spray device and the visual device are at the same horizontal height.

[0008] A method for spraying wolfberry trees for plant protection based on a visual device and an ultrasonic sensor. The method uses a visual device to obtain the density of wolfberry trees in real time, and a valve to adjust the spray volume of a nozzle in the spray device. The ultrasonic sensor is used to obtain the distance between the visual device and the nozzle and the wolfberry tree in real time to control the wind speed of the fan.

[0009] The calculation method of wolfberry tree density is as follows: S1: Image acquisition, acquired through a visual device, assuming that the forward speed of the visual device is Vm / s, and a frame of image is captured every H / V seconds. After Ts, a color image with a fixed height and a width of Hm is obtained; S2: Image partitioning, partitioning the color image obtained in S1, and dividing the color image into three equal regions: an upper region, a middle region, and a lower region; the upper third of the color image is the upper region; the lower third is the lower region; and the middle is the middle region; S3: Grayscale conversion and edge detection: grayscale conversion and edge detection are performed on the three regions obtained in S2 to obtain binary images of the three regions of the wolfberry tree. The specific steps are as follows: According to the grayscale conversion formula, gray=0.3R+0.59G+0.11B, each area in S2 is converted into a grayscale image; R, G, B represent the red, green, and blue components respectively, and gray is the grayscale value of the pixel; Calculate the difference between the gray value of a pixel point P in each area and the gray value of its lower right adjacent pixel point, P(x,y)-P(x+1,y+1). If the difference exceeds the threshold, set P(x,y)=0. Otherwise, set P(x,y)=255. According to the above rules, all points in each area are traversed to obtain two types of point sets: pixel value 0 and pixel value 255; pixel value 0 is an edge point, and pixel value 255 is a non-edge point; S4: Density calculation, calculate the ratio of edge points obtained in S3 3) to the total pixel points in the region. Let the image pixel set of edge points be A, and the total pixel set of the region be W. Then the density D of the region is 1 for: D 1 =(A / W)×%; A is related to the imaging distance. As the imaging distance increases, the image of the wolfberry tree in the visual device will become smaller, and the set of edge points A will become smaller. It is necessary to use the distance from the visual device to the edge point to correct it. D 2 =[ (A / W) ×%] ×b, D 2 is the corrected density, b is the correction ratio; The calibration method of b is as follows: a calibration object with a known area of ​​1 is used as the object, and the object is respectively 1 and d2 to obtain the imaging pixel sets A1 and A2 of the two measured pixel points, d 1 / d 2 =A 1 / A 2 =b S5: Calculation of spray quantity, Q = Q 1 ×D 2 +t, where: Q is the optimized application rate, Q 1 is the known application amount of wolfberry trees at different growth stages, D2 is the corrected sparseness, t is a constant; Calculate the corrected density D of each area separately 2 , the application amount of the upper, middle and lower areas of the wolfberry trees at different growth stages can be obtained.

[0010] Furthermore, the ultrasonic sensor acquires the distance between the visual device and the nozzle and the wolfberry tree in real time, obtains the distance between each nozzle and the wolfberry tree, and controls the wind speed of the fan corresponding to each nozzle respectively: when the ventilation volume of the fan is constant, its wind pressure is proportional to the wind speed, and the change of wind pressure is achieved by adjusting the wind speed of the fan; wolfberry trees at different growth stages are set to obtain the average distance value L between the nozzle and the wolfberry tree; when the ultrasonic sensor obtains that the distance between the nozzle and the wolfberry tree is greater than L, the single-chip microcomputer transmits the information to the three-phase brushless controller, increases the wind speed of the fan, and the wind pressure increases, which can blow the liquid medicine sprayed from the nozzle farther into the wolfberry bushes.

[0011] When the ultrasonic sensor obtains that the distance between the nozzle and the wolfberry tree is less than or equal to L, there is no need to increase the fan speed.

[0012] Furthermore, the method for controlling the wind speed of the fan is as follows: N = d×C+t, where: N is the wind speed of the fan; d is the distance between the nozzle and the wolfberry tree, measured by an ultrasonic sensor; C is the adjustment coefficient, and t is a constant.

[0013] Furthermore, the horizontal height of the first ultrasonic sensor is not lower than the lowest edge of the first area; the horizontal height of the third ultrasonic sensor is not higher than the highest edge of the third area; and the horizontal height of the second ultrasonic sensor is within the second area.

[0014] The beneficial effects of the present invention compared to the prior art are as follows: when spraying Chinese wolfberry trees, in order to improve the uniformity of droplet deposition after atomization of the liquid medicine and the effective utilization rate of pesticides, the spray device adopts an atomization unit composed of a spray module and a fan. The nozzles in each spray module are arranged in an equilateral triangle, and a duct and a fan are installed at the rear end of the spray module, and the fan is installed in the duct; the liquid flow rate of the nozzle of each spray device and the wind speed of the fan can be independently controlled by an industrial camera and an ultrasonic sensor, so that the high-speed airflow at the outlet of the duct passes through the circular tube in the spray module, assisting the droplet-shaped liquid medicine to generate vortexes to penetrate the dense leaf layer and spray the Chinese wolfberry leaves, and the speed sensor on the frame calculates the interval of the Chinese wolfberry trees by measuring the speed, which is convenient for precise spraying. Compared with the atomization of a single nozzle, the nozzle, duct, and fan combination of this spray device can form three fan-shaped atomization areas, which is conducive to local adjustment of the amount of liquid medicine spray.

[0015] The distribution of the spray devices corresponds to the upper, middle and lower areas of the wolfberry trees, which correspond to the crown, middle and trunk layers of the wolfberry trees in turn, achieving targeted and precise spraying of different areas of the wolfberry trees; the liquid medicine in the medicine box is pumped out of the medicine box by a diaphragm pump, and is divided into two paths by a pressure regulating and diverting device and a solenoid valve, one path of liquid medicine enters the pipeline, and the other path of liquid medicine flows back to the medicine box; the liquid medicine in the pipeline is divided into two by a two-branch joint, and then each is connected to a one-to-three joint to form a six-path pipeline, each pipeline is connected to a spray device through a pipe, and the liquid medicine in the pipeline is finally sprayed out through a nozzle.

[0016] The present invention calculates the density of the trunk layer in the upper, middle and lower areas of wolfberry trees at different growth stages, and accurately controls the amount of pesticide applied to each layer of the wolfberry trees. Each color image taken by the Dahua industrial camera is divided into three equal areas: the upper third is the upper area; the lower third is the lower area; the middle is the middle area; the upper area is the canopy layer, the middle area is the middle layer, and the lower area is the trunk layer above the roots. The density of branches and leaves in these three parts is calculated respectively, and finally the spray amount of each spray device is controlled respectively.

[0017] The present invention is equipped with six ultrasonic sensors, which correspond to six spray devices respectively. Specifically, the first spray device corresponds to the first ultrasonic sensor; the second spray device corresponds to the second ultrasonic sensor; the third spray device corresponds to the third ultrasonic sensor; the corresponding spray devices and ultrasonic sensors are at the same horizontal height and on the same side of the frame, and the distance between each nozzle and the wolfberry tree is measured by the ultrasonic sensor. The greater the distance, the faster the wind speed of the fan is driven, and a greater wind speed is formed, that is, a greater wind pressure is formed, and the spray droplets are transported to a farther distance.

[0018] Through visual devices, ultrasonic sensors and density calculation methods, the density of wolfberry trees can be obtained in real time, achieving targeted and precise spraying of wolfberry trees. BRIEF DESCRIPTION OF THE DRAWINGS

[0019] Figure 1 It is a structural schematic diagram of a wolfberry tree plant protection spraying device based on a visual device and an ultrasonic sensor in the present invention; Figure 2 It is a structural schematic diagram of the spray device in the present invention; Figure 3 It is a schematic diagram of the process of the wolfberry tree plant protection spraying method based on the visual device and the ultrasonic sensor in the present invention; Figure 4 It is the overall flow chart of the present invention; Figure 5 These are the original image and the binarized image in the present invention. DETAILED DESCRIPTION

[0020] The present invention is further described in detail below with reference to the accompanying drawings and through embodiments. The following embodiments are for explanation of the present invention and the invention is not limited to the following embodiments. The front in the present invention is the forward direction of the device; the upper layer, middle layer and lower layer are the directions from top to bottom.

[0021] A plant protection spraying device for wolfberry trees based on a visual device and an ultrasonic sensor comprises a frame 1, a walking crawler module 17 is installed under the frame, a Dahua industrial camera 11 and an ultrasonic sensor are installed in front of the frame 1, a spray device 2 is installed behind the frame 1, and the spray device 2 is installed on platforms 3 on the left and right sides of the rear of the frame 1; the spray device 2 is composed of a first spray device 24, a second spray device 25 and a third spray device 26 from top to bottom, and they have the same structure; a medicine box 9 is installed at the center of the first frame 1; Ultrasonic sensors are installed on the left and right sides of the front of the rack 1, including the first ultrasonic sensor 10, the second ultrasonic sensor 15 and the third ultrasonic sensor 16 from top to bottom; a speed sensor 14 is installed under one of the third ultrasonic sensors 16; a Dahua industrial camera 11 is installed on one side of the second ultrasonic sensor 15; the heights of wolfberry trees are basically the same, and the height of the rack does not exceed the average height of the wolfberry trees in the wolfberry garden.

[0022] The first spray device 24 includes a duct 22, a fan 23 and a spray module 21. The duct 22 and the fan 23 are installed on one side of the spray module 21, close to the frame 1. The fan 23 is installed in the duct 22, and the duct is a hollow cylindrical shape.

[0023] The spray module 21 includes a circular tube 211 and three nozzles 212. The three nozzles 212 are evenly distributed on the outside of the circular tube 211, and the directions of the nozzles are aimed at the direction of the wolfberry tree; the center points of the three nozzles are connected in sequence to form an equilateral triangle; the center of the circular tube and the center of the duct are on the same horizontal line.

[0024] Each spray device corresponds to an ultrasonic sensor, the first spray device 24 corresponds to the ultrasonic sensor 10, the second spray device 25 corresponds to the second ultrasonic sensor 15, and the third spray device 26 corresponds to the third ultrasonic sensor 16; the corresponding spray devices and ultrasonic sensors are on the same horizontal line, and each ultrasonic sensor controls the spray device at the same horizontal height and on the same side of the rack as it.

[0025] The liquid medicine in the medicine box 9 is pumped out of the medicine box by the diaphragm pump 6, and is divided into two paths by the pressure regulating diverter valve 5, one path of liquid medicine enters the pipeline, and the other path of liquid medicine flows back to the medicine box; the liquid medicine in the pipeline is divided into two paths by the electromagnetic valve 7, and each path is connected to a three-way connector 4 to form six liquid medicine pipelines, and each liquid medicine pipeline is connected to a spray device 2. That is, each spray module 21 is connected to a three-way connector 4, a solenoid valve 7, a pressure regulating diverter valve 5, and a diaphragm pump 6 in sequence through pipelines; each component is a universal component purchased on the market, and each component is connected through pipelines. Each of the six spray devices is connected to a liquid medicine pipeline.

[0026] Each fan 23 is connected to a three-phase brushless controller 12 and a relay 13 respectively, so as to realize individual control of the wind speed of each fan.

[0027] A plant protection spraying method for wolfberry trees based on a visual device and an ultrasonic sensor, wherein the density of wolfberry trees is obtained in real time by a visual device in a plant protection spraying device for wolfberry trees based on a visual device and an ultrasonic sensor, so as to adjust the spray volume of a nozzle in a spraying device; and the distance between the visual device and the nozzle and the wolfberry tree is obtained in real time by an ultrasonic sensor, so as to adjust the wind speed of a fan.

[0028] The calculation method of wolfberry tree density is as follows: S1: Image acquisition, acquired through a visual device, assuming that the forward speed of the visual device is Vm / s, and a frame of image is captured every H / V seconds. After Ts, a color image with a fixed height and a width of Hm is obtained; S2: Image partitioning, partitioning the color image obtained in S1, and dividing the color image into three equal regions: an upper region, a middle region, and a lower region; the upper third of the color image is the upper region; the lower third is the lower region; and the middle is the middle region; S3: Grayscale conversion and edge detection: grayscale conversion and edge detection are performed on the three regions obtained in S2 to obtain binary images of the three regions of the wolfberry tree. The specific steps are as follows: According to the grayscale conversion formula, gray=0.3R+0.59G+0.11B, each area in S2 is converted into a grayscale image; R, G, B represent the red, green, and blue components respectively, and gray is the grayscale value of the pixel; Calculate the difference between the gray value of a pixel point P in each area and the gray value of its lower right adjacent pixel point, P(x,y)-P(x+1,y+1). If the difference exceeds the threshold, set P(x,y)=0. Otherwise, set P(x,y)=255. According to the above rules, all points in each area are traversed to obtain two types of point sets: pixel value 0 and pixel value 255; pixel value 0 is an edge point, and pixel value 255 is a non-edge point; S4: Density calculation, calculate the ratio of edge points obtained in S3 3) to the total pixel points in the region. Let the image pixel set of edge points be A, and the total pixel set of the region be W. Then the density D of the region is 1 for: D 1 =(A / W)×%; A is related to the imaging distance. As the imaging distance increases, the image of the wolfberry tree in the visual device will become smaller, and the set of edge points A will become smaller. It is necessary to use the distance from the visual device to the edge point to correct it. D 2 =[ (A / W) ×%] ×b, D 2 is the corrected density, b is the correction ratio; The calibration method of b is as follows: a calibration object with a known area of ​​1 is used as the object, and the object is respectively 1 and d2 to obtain the imaging pixel sets A1 and A2 of the two measured pixel points, d 1 / d 2 =A 1 / A 2 =b S5: Calculation of spray quantity, Q = Q 1 ×D 2 +t, where: Q is the optimized application rate, Q 1 is the known application amount of wolfberry trees at different growth stages, D 2 is the corrected sparseness, t is a constant; Calculate the corrected density D of each area separately 2 , the application amount of the upper, middle and lower areas of the wolfberry trees at different growth stages can be obtained.

[0029] The ultrasonic sensor acquires the distance between the visual device and the sprinkler and the wolfberry tree in real time, obtains the distance between each sprinkler and the wolfberry tree, and controls the wind speed of the fan corresponding to each sprinkler respectively: when the ventilation volume of the fan is constant, its wind pressure is proportional to the wind speed, and the change of wind pressure is achieved by adjusting the wind speed of the fan; wolfberry trees at different growth stages are set to obtain the average distance value L between the sprinkler and the wolfberry tree; when the ultrasonic sensor obtains that the distance between the sprinkler and the wolfberry tree is greater than L, the single-chip microcomputer transmits the information to the three-phase brushless controller, increases the wind speed of the fan, and increases the wind pressure, which can blow the liquid medicine sprayed from the sprinkler farther into the wolfberry bushes.

[0030] When the ultrasonic sensor obtains that the distance between the nozzle and the wolfberry tree is less than or equal to L, there is no need to increase the fan speed.

[0031] The wind speed of the fan can also be controlled by the following method: N = d×C+t, where: N is the wind speed of the fan; d is the distance between the nozzle and the wolfberry tree, measured by an ultrasonic sensor; C is the adjustment coefficient, and t is a constant.

[0032] The horizontal height of the first ultrasonic sensor is not lower than the lowest edge of the first area; the horizontal height of the third ultrasonic sensor is not higher than the highest edge of the third area; and the horizontal height of the second ultrasonic sensor is within the second area.

Claims

1. A plant protection spraying device for wolfberry trees based on a visual device and an ultrasonic sensor, comprising a frame, a walking crawler module is installed below the frame, and is characterized in that: A visual device and an ultrasonic sensor are installed in front of the rack, a spray device is installed at the rear of the rack, and a medicine box is installed in the center of the rack; Ultrasonic sensors are installed on both sides of the front of the frame, namely, a first ultrasonic sensor, a second ultrasonic sensor and a third ultrasonic sensor from top to bottom; a speed sensor is installed below one of the third ultrasonic sensors; The visual device is installed on one side of the second ultrasonic sensor; Platforms are installed on both sides of the rear of the frame, and spray devices are installed on the platforms, which are the first spray device, the second spray device and the third spray device from top to bottom, and the structures of the first spray device, the second spray device and the third spray device are the same; The first spray device comprises a duct, a fan and a spray module, wherein the duct and the fan are installed on one side of the spray module, close to the frame, and the fan is installed in the duct; The first spray device corresponds to the first ultrasonic sensor; the second spray device corresponds to the second ultrasonic sensor; the third spray device corresponds to the third ultrasonic sensor; the corresponding spray devices and ultrasonic sensors are at the same level and on the same side of the frame; The duct is a hollow cylindrical shape; The liquid medicine in the medicine box is pumped out of the medicine box by a diaphragm pump and divided into two paths by a pressure regulating diverter valve, one path of liquid medicine enters the pipeline, and the other path of liquid medicine flows back to the medicine box; the liquid medicine in the pipeline is divided into two paths by a solenoid valve, and each path is connected to a three-way connector to form a six-path liquid medicine pipeline, and each liquid medicine pipeline is connected to a spray device; Each fan is connected to a three-phase brushless controller and a relay to achieve individual control of the wind speed of each fan.

2. The wolfberry tree plant protection spraying device based on a visual device and an ultrasonic sensor according to claim 1, characterized in that The visual device is a Dahua industrial camera.

3. The wolfberry tree plant protection spraying device based on a visual device and an ultrasonic sensor according to claim 1, characterized in that The spray module includes a circular tube and three nozzles; the circular tube is fixed at the edge of the platform and communicates with the pipeline; the three nozzles are evenly distributed on the outside of the circular tube, facing the wolfberry tree; the center points of the three nozzles are connected in sequence to form an equilateral triangle; the center of the circular tube and the center of the duct are on the same horizontal line; the second spray device and the visual device are at the same horizontal height.

4. A method for spraying wolfberry trees for plant protection based on a visual device and an ultrasonic sensor, using a wolfberry tree plant protection spraying device based on a visual device and an ultrasonic sensor as described in claims 1 to 3, characterized in that The density of wolfberry trees is obtained in real time through the visual device, and the spray volume of the nozzle in the spray device is adjusted through the valve; the distance between the visual device and the nozzle and the wolfberry tree is obtained in real time through the ultrasonic sensor to control the wind speed of the fan.

5. A method for spraying Chinese wolfberry trees for plant protection based on a visual device and an ultrasonic sensor according to claim 4, characterized in that The calculation method of wolfberry tree density is as follows: S1: Image acquisition, acquired through a visual device, assuming that the forward speed of the visual device is Vm / s, and a frame of image is captured every H / V seconds. After Ts, a color image with a fixed height and a width of Hm is obtained; S2: Image partitioning, partitioning the color image obtained in S1, and dividing the color image into three equal regions: an upper region, a middle region, and a lower region; the upper third of the color image is the upper region; the lower third is the lower region; and the middle is the middle region; S3: Grayscale conversion and edge detection: grayscale conversion and edge detection are performed on the three regions obtained in S2 to obtain binary images of the three regions of the wolfberry tree. The specific steps are as follows: According to the grayscale conversion formula, gray=0.3R+0.59G+0.11B, each area in S2 is converted into a grayscale image; R, G, B represent the red, green, and blue components respectively, and gray is the grayscale value of the pixel; Calculate the difference between the gray value of a pixel point P in each area and the gray value of its lower right adjacent pixel point, P(x,y)-P(x+1,y+1). If the difference exceeds the threshold, set P(x,y)=0. Otherwise, set P(x,y)=255. According to the above rules, all points in each area are traversed to obtain two types of point sets: pixel value 0 and pixel value 255; pixel value 0 is an edge point, and pixel value 255 is a non-edge point; S4: Calculate the density, calculate the ratio of the edge points obtained in step 3) of S3 to the total pixel points in the region, assume that the image pixel set of the edge points is A, and the total pixel point set of the region is W, then the density D1 of the region is: D1=(A / W)×%; A is related to the imaging distance. As the imaging distance increases, the image of the wolfberry tree in the visual device will become smaller, and the set of edge points A will become smaller. It is necessary to use the distance from the visual device to the edge point to correct it. D2=[ (A / W) ×%]×b, D2 is the corrected density, b is the correction ratio; The calibration method of b is as follows: a calibration object with a known area of ​​1 is used as the object, and the imaging pixel sets A1 and A2 of two measured pixel points are obtained at distances d1 and d2 respectively. d1 / d2=A1 / A2=b S5: Calculation of spraying amount, Q = Q1×D2+t, where: Q is the optimized spraying amount, Q1 is the known spraying amount of wolfberry trees at different growth stages, D2 is the corrected sparseness, and t is a constant; By calculating the corrected sparseness density D2 of each area respectively, the application amount of the upper area, middle area and lower area of ​​the wolfberry trees at different growth stages can be obtained.

6. The method for spraying Chinese wolfberry trees for protection based on a visual device and an ultrasonic sensor according to claim 4, characterized in that Through the ultrasonic sensor, the distance between the visual device and the nozzle and the wolfberry tree is obtained in real time, and the distance between each nozzle and the wolfberry tree is obtained, and the wind speed of the fan corresponding to each nozzle is controlled respectively: when the ventilation volume of the fan is constant, the wind pressure is proportional to the wind speed, and the change of wind pressure is achieved by adjusting the wind speed of the fan; wolfberry trees at different growth stages are set to obtain the average distance value L between the nozzle and the wolfberry tree; when the ultrasonic sensor obtains that the distance between the nozzle and the wolfberry tree is greater than L, the single-chip microcomputer transmits the information to the three-phase brushless controller, increases the wind speed of the fan, and the wind pressure increases, which can blow the liquid medicine sprayed by the nozzle farther into the wolfberry bush. When the ultrasonic sensor obtains that the distance between the nozzle and the wolfberry tree is less than or equal to L, there is no need to increase the wind speed of the fan.

7. The method for spraying Chinese wolfberry trees for protection based on a visual device and an ultrasonic sensor according to claim 4, characterized in that The method for controlling the wind speed of the fan is as follows: N = d×C+t, where: N is the wind speed of the fan; d is the distance between the nozzle and the wolfberry tree, measured by an ultrasonic sensor; C is the adjustment coefficient, and t is a constant.

8. The method for spraying Chinese wolfberry trees for protection based on a visual device and an ultrasonic sensor according to claim 5, characterized in that The horizontal height of the first ultrasonic sensor is not lower than the lowest edge of the first area; the horizontal height of the third ultrasonic sensor is not higher than the highest edge of the third area; and the horizontal height of the second ultrasonic sensor is within the second area.