Abstract:A set of pest and disease detection and precise variable spraying system, based on visual recognition, was designed for maize, addressing traditional issues of pesticide waste and spraying inefficiency. Utilizing image processing and machine vision, this system automatically and accurately identified pests and diseases in maize fields, adjusting spraying doses accordingly. It was then integrated into a computer control system, with its performance verified. The system surpassed the benchmark model YOLO v5s, improving P, R, and mAP by 1.6,1.3 and 0.7 percentage points,respectively. The high precision rate reduced false detection of pests and diseases to avoid false spraying of non-pest areas. The high recall rate reduces missed detection to ensure timely and effective treatment of pest and disease areas. The improvement of mAP value comprehensively reflected the overall identification ability of the system in different pest and disease categories. It stably identified maize stem borer, slime molds, grey spot, leaf spot, and rust diseases with over 60% accuracy, and red spider and aphid with over 40% accuracy. Field tests evaluated droplet deposition, drift, and pesticide saving rates. The system achieved a minimum droplet coverage of 52% and deposition density of 71.3 drops/cm2, satisfying pest control needs. Pesticide saving and ground wastage rates reached lows of 32.1% and 22%, respectively, significantly reducing overall pesticide consumption and waste. This maize pest and disease detection and precision variable spraying system significantly enhanced identification accuracy, improved pesticide utilization, and reduced environmental pollution, offering a scientific and efficient approach to pest and disease management.