| Dairy cow welfare is an important issue that must be considered in large-scale farming,and it is closely related to production efficiency and cow health.Among them,how to effectively alleviate heat stress in dairy cows is one of the core issues faced in dairy welfare farming.Heat stress leads to a decrease in cow feed intake,growth rate,and milk production,reduced fertility,and a lower conception rate,and can even cause death.Currently,the main method to alleviate heat stress in cows is spray cooling,but existing sprays are mainly applied during a fixed period before feeding and milking.Domestic and international research has tried to develop cow self-service spraying systems,but the water utilization rate is low.How to improve the efficiency of water utilization while ensuring the cooling effect of sprinklers is a key issue to be addressed in the application of self-help sprinklers for heat stress intervention.This thesis designs a distributed self-service spraying system for cow welfare that can automatically spray when cows are detected and adaptively adjusts the spraying duration during the spray cooling process according to the climate conditions at the time of spraying to ensure the water utilization rate.Based on the above research objectives,this study applied sensors and IoT wireless communication technology to develop a distributed self-service spraying system that can adaptively control the spraying duration according to environmental conditions.The main objective of this system is to improve the welfare and health of cows by mitigating their heat stress response in high-temperature environments through adaptive spray control.The main research work and results of the paper are as follows:(1)A cattle farm environment monitoring module based on STM32 embedded microprocessor and multiple sensors was designed.The microprocessor of this module connects the VMS-3000 temperature and humidity sensor,the VMS-3003 ultrasonic wind speed and direction sensor,and the RS-TEQ-N01-AL thermoelectric solar radiation intensity sensor through the RS485 bus and completes data transmission,parsing,and calibration through Modbus protocol.The RAK4203 chip,based on LoRa modulation and demodulation technology,is used to realize the wireless transmission of the collected data.The collected data is finally stored in a MySQL cloud database.After testing,the module’s temperature measurement error is±0.15℃,humidity measurement error is±0.35%RH,wind speed measurement error is±0.02 m/s,and radiation intensity measurement error is±11.09 W/m~2.(2)A cow self-service spraying module based on an STM32-embedded microprocessor and automatic control technology was designed.The module adopts a Q31 pair of photoelectric sensors to sense whether the cows enter the spray area,and the microprocessor controls the 2W-025-06 normally closed solenoid valve to realize the opening and closing of the spray.The module data requires wireless transmission and storage to achieve the same method as the environmental monitoring module.After testing,the measurement error of the spraying duration of the self-service spraying module is±1.5 s.(3)The user management and monitoring platform was designed based on the B/S architecture.The back end of this management platform was developed in Java based on the MVC design pattern.The front end was developed by JavaScript,HTML,and CSS based on the Layuimini framework.The real-time information display function of temperature and humidity,wind speed,radiation intensity,and heat stress degree is realized.LoRa gateway,environment monitoring module,and self-service spray module device management function.Heat stress index,cattle farm environment,spray duration history data query,and spray duration control model setting function.Postman test software was used to test the functions and found that all functions could meet the design requirements.(4)A spray duration control algorithm based on heat stress index was developed.A 85 d field experiment was conducted on a dairy farm,in which 12,240 sets of environmental data,387 spray duration data,and 3,374 cow respiration frequency data were collected during the period of heat stress.The correlation between the mean values of heat stress index(THI)and the length of voluntary spraying of cows from 0 to 48 h(2 h intervals each time)before the start of spraying was analyzed by IBM SPSS 22.0 software,and it was found that the correlation between the mean values of heat stress index and the logarithm of the length of voluntary spraying of cows in the hours before spraying was more significant than that of the heat stress index at the start of spraying(e.g.,the mean value of THI1 for 2 h before spraying:r=0.6,P<0.01;THI1 at the moment of spraying:r=0.44,P<0.01;Based on this result,the calculation interval for the mean values of different heat stress indices(e.g.,14 h for THI1)was selected,and the relationship between the logarithmic values of the voluntary spraying duration of cows and different heat stress indices was derived by simple linear regression.The mean relative error(MRE)of the spray duration control algorithm was verified to be a minimum of 13.45%.The algorithm was finally ported to the server of the user management platform to achieve adaptive regulation of the maximum spray duration in different environments.The distributed self-service spray cooling system designed for cow welfare in this study meets the design requirements and can automatically control the spraying when cows are monitored and adaptively adjust the spraying duration according to the historical environment at the time of spraying.The system can provide a reference for the design of new spray-cooling equipment in dairy farming. |