DEVELOPMENT OF THE SYSTEM TO CONTROL MILK ACIDITY IN THE MILK PIPELINE OF A MILKING ROBOT

means in order to optimize a contribution of each animal to the production process. The modern solution is precise control in animal husbandry that takes into consideration environmental factors, climatic conditions, the supply of feed and water. Continuous automated monitoring of livestock conditions is performed at the same time as their products’ quality is under control in real time. These measures generally provide the possibility of timely response, if necessary, to various factors. Precision livestock farming is a new direction in modern science and practice that separated from the precision farming, which already had an ideology and possessed technical means and technologies affordable for the implementation by commodity producers. The concept of the precision livestock farming has not completely formed yet, technical and technological requirements have not been substantiated, its potential has not been revealed, and the stages of implementation remain to be justified.


Introduction
One of the leading industries in the modern animal husbandry is dairy cattle breeding.The key driver for its successful development is considered to be the improvement of technology to store, prolong the term of consumption, and maintain high milk productivity of cows.That can be achieved under conditions of the implementation of highly technological milking equipment into technological process.
The technical systems that are in direct contact with the living organism must comply with enhanced structural requirements.Therefore, it is an important task to search for the new technical and technological solutions and effective modes of application under industrial conditions taking into consideration physiological characteristics of highly productive cows.
Successful and efficient dairy cattle breeding calls for the application of advanced technologies and technical the acidity is not determined in these systems.Since this indicator is very important in terms of the "starting readiness" of milk to primary processing there is an urgent need for the development of a technical means to measure the pH of milk in the flow under condition of its robotized production.
At present, solid-state converters based on semiconductor structures, such as pH-sensitive field transistors (pH-FT), are a real alternative to glass ion-sensitive electrodes for the response time, reliability, and durability [10].The pH-FT electrodes could be used both for regular pH-measurements [11] and for several specialized technical solutions, including biomedical [12], biochemical [13], and sensory analyses [14] into activity of ions of different types using ionophores [10].
Practical experience shows that the important benefits of pH-FT allow them to be used as primary sensors for chemical and biological sensory devices based on the biochemical methods of analysis using specific catalytic reactions.The possibility of employing the fabricated electrodes, including under a differential mode of measurement [15], has been extensively tested for environmental monitoring [14], to control quality of food products [16], biomedical research [17], enzyme analysis of toxic impurities in aqueous solutions [18].
Thus, one can argue that measuring such an important parameter as the acidity of milk at robotic milking has certain prospects when implemented at industrial dairy plants.Therefore, the development of the technical system for measuring the acidity of milk is of significant interest to the practical machine milking of highly productive cows and would enhance the efficiency of dairy cattle breeding in general.
Thus, there is a reason to believe that the improvement of the process of robotic milking should be complemented by the technical means for determining the acidity of milk in a flow; that necessitates our current research.

The aim and objectives of the study
The aim of present study is to design a technical system to improve the process of milking through control over the acidity of milk in a flow by installing an electrode based on the pH-sensitive field transistor into a milk pipeline.This would make it possible to quickly and reliably determine the quality of milk directly when it is received, and to timely separate milk of inappropriate acidity, thereby improving its starting readiness.
To accomplish the aim, the following tasks have been set: -to establish the correspondence of milk pH to the Turner degrees of acidity; -to improve the robotized system for measuring the quality parameters of milk during milking through the installation of an additional pH-FT electrode into a milk pipeline; -to design a block diagram of an electronic device for measuring the pH of milk using a high-speed pH-FT electrode.

1. The examined materials and equipment used in the experiment
The study was conducted using a pH meter of type I-150M (Republic of Belarus).A given device is widely used

Literature review and problem statement
Newly created machines, systems for the automation of production processes must provide such conditions at farms and agricultural plants that would effectively contribute to improving the quality of obtained primary products from livestock breeding, in particular milk [1].Given this, precise, computerized, or managed cattle breeding makes it possible to maximally effectively utilize material resources of an enterprise [2].That warrants not only a short-term effect in the form of better profit, for example, from milk production, but, in the long term, extending the productive use of cattle [3].
The main direction for the implementation of the concepts of precision livestock farming in modern dairy cattle breeding is the use of milking robots.Their use for milking cows is physiologically substantiated and almost eliminates the cost of an operator labor [4].However, despite a significant number of measured parameters of milk quality, such an important technological parameter as the acidity is not measured in the robotized milking [2].The importance of a given parameter is confirmed by that among the key indicators of milk quality that are regulated by DSTU 3662 [5], it ranks first.Acidity characterizes "starting readiness" of milk for primary processing and is one of the main parameters that are monitored when taking raw materials at a milk factory.When the milk fails to comply with the DSTU requirements, the grade of the milk supplied decreases with the farmers incurring significant losses.Therefore, it is important to timely separate milk with the lowered acidity directly during the robotized milking.However, we have not found any information about technical systems for the differentiation and separation of milk with reduced acidity in real time, in the available scientific literature.
The feasibility of designing effective techniques for robotized milking, as well as parameters and modes of operation of technical equipment, implies enabling maximum detection of the productive capacity of cows, further improvement in productivity and the attractiveness of labor to service staff, all of which are essential indicators for the efficient dairy cattle breeding [6].
It should be noted, however, that an increase in milk production has to be accompanied by the simultaneous growth in labor productivity and bringing down the cost of energy to perform the process of milking because it is the process energy consumption that is an important indicator for the profitability of production [7].That is predetermined by that under modern conditions the main and decisive factors are a technological and economic aspect, which create reliable and effective utilization of equipment, as well as serving dairy animals in terms of technology to fully meet their physiological needs [8].
Typically, in the systems of machine milking, upon completion of the operation of a milk pipe, part of the milk is fed to a measuring container where, following the milking, the scale of the container shows the value of milk yield.The milk is then fed to a separate cup for taking the samples to analyze quality at a lab.This operation requires significant time for carrying out appropriate measurements of physical-chemical indicators of milk; at the same time, it cannot provide for the prompt acquisition of reliable data and requires specialized skills for its implementation [9].That is why, in order to speed up the process of quality control of the received milk, robotized installations measure almost all basic indicators of milk quality directly in its flow.It should be noted, however, that The obtained measurement errors were plotted on the chart using the spreadsheet processor MS Excel with an embedded package for data statistical analysis.Typically, 3 to 5 measurements are performed; the obtained values are then averaged.Based on this dependence, we constructed a trend for the equation of linear regression: where y is the Turner degrees, x is the measured respective pH value.Fig. 1 shows that the dependence of pH on Turner degrees is linear.That confirms a determination coefficient R2=0.999, which is equal to the squared correlation coefficient with a confidence level of 0.001.In addition, it was established that the variation coefficient, which demonstrates the variability of an attribute, is, for pH, considerably less than for the Turner degrees of acidity, that is, 0.53 % versus 4.29 %, respectively.Therefore, the pH index is more accurate than the conventional Turner degrees.
To test the possibility of the pH-measurement method, we investigated pH of milk depending on the period after calving.These data are given in the form of a histogram shown in Fig. 2. The data were acquired in the following way: we took from a cow after calving the samples of milk for each day of lactation, from day 1 to day 5, and subsequently from day 10 in 10 days of lactation until day 30.We measured the pH of each sample of milk at the specified days over a given period of lactation; we built the histogram based on these data.The histogram shows that the pH of milk rapidly increases over the first 5 days, and then pH only gradually rises to the standard of 6.5-6.7.Thus, it did not make sense to measure pH daily following the fifth day of calving.for measuring the pH of food products, including milk and meat [19].Our research into measuring the pH of milk, as well as some basic indicators, involved two samples comprising 5 samples of each.
To examine quality, we used experimental samples of milk with a fat content of 2.5 % and 3.2 %.First of all, we estimated quality of the samples based on organoleptic indicators.The samples were taken directly from the milk pipeline in a milking installation of the "Fir Tree" type at DP DG "Kutuzivka", ISGPS of NAAN in the Kharkiv region of Kharkiv Oblast, Ukraine.
Organoleptic estimation of the smell and taste of drinking milk was carried out according to Table 1.Comparing the data acquired from investigating the milk samples for organoleptic indicators, we confirm that the experimental samples meet the requirements of DSTU 3662 [5].Thus, we can use them for further research into acidity.

2. Procedure for determining the consistency and acidity of milk
We determined consistency by slowly pouring the milk in a thin trickle along the wall of the cylinder.Based on the stream and trace left on the glass, we determined consistency, the presence of flakes, contaminants, colostrum, etc.
At the next stage, once the basic organoleptic parameters were determined, we applied a titrimetric method, using an indicator of phenolphthalein in accordance with GOST 3624 [20], in order to identify the acidity of milk.

Results of studying the acidity of milk with the development of a project to control it in the milk pipeline of a milking robot
By comparing data acquired from the study into the milk samples for organoleptic indicators, we obtain the result: both samples meet the requirements of DSTU 3662 [5].
We have statistically processed data related to acidity from all samples of milk in the Turner degrees of acidity and in the units of pH.The experimental data derived were used to construct a calibration chart of dependence of the Turner degrees on the pH of milk using the spreadsheet processor MS Excel.The chart is shown in Fig. 1.
When calculating the parameters of a milk pipeline it is necessary to take into consideration that quality should be maintained constant when moving the product.This is achieved by a proper choice of the motion mode and by the appropriate, assigned technologically, speed of the product motion.Taking into consideration the volume of the moved product, we calculated the required diameter of the pipeline.A milk pipeline diameter is derived from formula [22]:

4
, 3600 where M is the productivity, m 3 /h, V is the speed of milk motion, m/s.Robotic milking becomes profitable when the annual milk yield exceeds 7,000 liters per cow [2].If we accept the annual milk yield to make uo 9,000 liters over a lactation period of 300 days, the daily yield per a cow will equal 30 l. Duration of milking a cow using a milking robot is 6 minutes on average [4].It follows that the performance efficiency of a milk pipeline when a cow is milked by a robot should equal (at two-time milking) 150 l/h or 0.15 m 3 /h.The milk flow rate must not exceed 0.5 m/s under condition of a laminar flow.We accept it preliminary to be 0.3 m/s.Based on these data, the diameter of a milk pipeline, derived from formula (2), will equal 0.0135 m, that is, 13.5 mm.The tolerance accepted is 0.02 m, that is 20 mm.At a given diameter the speed drops to 0.13 m/s, providing for a sufficient laminar mode of the flow.The mode of the flow is estimated using the Reynolds criterion, which is calculated from formula: where µ is the kinematic viscosity of milk, 1.65•10 -6 m 2 /s, V is the motion speed, m/s, d is the diameter of a milk pipeline, m.Calculation using a given formula (3) produces Re=1,575.A steady laminar regime is ensured at Re<1,200...1,600.If Re>2,320, the motion mode is turbulent.Based on the calculation, we can conclude that the flow is clearly laminar.Therefore, we can argue that there will be neither air jams nor turbulence, and the pH-FT electrode, located in a milk pipeline, will be exposed to optimum conditions, that is, in milk.
Since the diameter of a milk pipeline is a function of two variables, that is productivity and speed, it is advisable to construct this function in the form of a graphical 3D model, which is shown in Fig. 4.

Fig. 4. Dependence of milk pipeline diameter on the flow rate and productivity in the form of a 3D-graphical model
The histogram in Fig. 2 shows that the pH of milk is reduced over the first 1-3 days after calving.This is due to the large content of proteins, salts, lactose, and the products of their transformation, as well as other biochemical compounds; thereafter, in a certain period, pH increases to the physiological norm, that is, it approaches 6.5 units.The data obtained correlate well with similar data obtained using the conventional Turner method.Thus, based on the established empirical dependence (1), it can be argued that the method of pH-measurement could completely replace the traditional method, outperforming the latter by simplicity, accuracy, and rate of analysis.To this end it is possible to apply a microprocessor that is commonly used in an industrial pH meter.It must be provided with a subprogram according to the derived equation ( 1), as well as with a high-speed pH-FT electrode based on the ionic-selective field transistors fabricated using the MDS technology [18].
To compare the response time of the pH-FT electrode and a regular glass electrode, we measured two aqueous solutions of substances with a known pH value.Solutions were prepared from such substances as tris-(oxymethyl)-aminomethane, pH 7.65, and acetic acid, pH 4.64 [21].Initially, both electrodes were in turn dipped in the first solution, then, upon determining the value of pH, in the second one, with a lower pH.The data in millivolts from the output of the pH-meter entered a digital oscilloscope, then, from it, through the USB connector, arrived to the Acer computer eMachines E727-442G32mi (made in China) for processing.Using the spreadsheet processor MS Excel, we constructed, based on the data acquired, a dependence of the response time for two types of electrodes: high-speed pH-FT and a standard glass electrode, shown in Fig. 3.The measurement errors obtained were plotted on the chart using the spreadsheet processor MS Excel.

Fig. 3. Response time dependence for two types of electrodes: pH-FT and a standard glass electrode
It follows from Fig. 3 that the response time of a highspeed pH-FT electrode is several times lower than that of the glass one, namely, 2 s versus 12 s.In other words, in order to develop a design for measuring the pH of milk in the milk pipeline of a milking robot, it is advisable to use the pH-FT electrode.If this is implemented, only a small part of the milk would pass through the milk pipeline, which, in case the acidity deviates from the standard, can be swiftly discharged into a separate container.
In order to develop a system to control milk acidity in a flow, we established basic parameters for the milk pipeline of a milking robot and for additional elements that complement it, as demonstrated by the projected control system shown below.
Control system operates as follows: a pH-FT electrode produces potential continuously from the start of milking, proportional to the pH of milk; the amplifier increases the potential for the normal operation of ADC.The algorithm for processing is regular, similar to that used in digital pH meters, which convert the potential, measured in millivolts, into pH indices according to the Nernst equation.
In addition, the microprocessor converts, using the empiric formula (1), the pH indices into the Turner degrees of acidity according to the equation of linear regression.In case the measured value of pH leaves the specified range, the microprocessor triggers a signal to the controlling element, which opens an electromagnetic valve with a tee.
Modern MP and regulators have several outputs that can be programmed to control external devices depending on the values of the signal arriving to MP.In other words, one can programmatically set the range of the input signal, leaving which triggers different responses from the controlling element, managed by MP.In this case, controlling element is a powerful transistor key.Depending on the request received from the microprocessor, the electromagnetic valve opens an additional milk pipeline, shutting off the main one, and discharges milk with nonstandard pH into a separate container.The radio module is used for transmitting the measured data on milk pH related to current milking to the host computer of a dairy farm, as well as to a computer of the milking robot in order to store data in a cow calendar [2].
Functional circuit of the pH measuring and radio-transmitting part of the designed control system is shown in Fig. 6.
Fig. 6 shows main components of the circuit -pH-FT electrode with a circuit for temperature compensation and preliminary amplification (D1), a microprocessor (D3), a radio module of the transmitter NM-T (D5), and power stabilizers (D2, D4).
The specialized radio modules of HM-series, a range of 433 MHz (receivers and transmitters) are typically used for building the systems of wireless data transmission.HM-R and HM-T are the modules of FM receiver and FM transmitter.They provide for the rate of data transmission-reception in the range of 600-9,600 bit/s (or 300-100 kbit/s).The HM-R receivers are able to provide reliable communication with the HM-T transmitters at distances from 160 up to 370 m at direct visibility.Fig. 7 shows functional circuit of radio-receiving part of the designed technical system.
It follows from the model that the diameter of a milk pipeline cannot be less than 20 mm in accordance with the above calculations, and in case of choosing a larger diameter, for example, 30 mm, this chart makes it possible to find the appropriate productivity of 0.27 m 3 /h at a preset milk flow rate of 0.3 m/s.Hence, a given chart can be regarded as reference when choosing parameters for a milk pipeline and the milk flow rate.
The parameters of containers for storing milk of standard acidity and separately for storing milk with non-standard acidity, specified by DSTU, are calculated using formula [22]: where a is the coefficient of milk yield instability (2...2.5), M is the annual milk yield per cow, 9,000 kg, m is the number of cows (we accept it to be 200).
According to formula (4), we obtain 9,863 kg.The closest standard container tank is 10 t.As reported in the scientific literature, milk of non-standard acidity makes up 5-10 % depending on the season, composition of feed, lactation period.Most of these factors are not relevant at robotic milking, namely: a robot controls the quality of nutrition, condition of an animal, and other parameters; it sends a timely signal to the specialist about a deviation of milk from quality standards.Therefore, a possible deviation in the milk quality at robotic milking is minimized, including its acidity.Thus, it is logical to assume the maximum deviation in quality to be close to the lower bound, that is, 5 % for acidity.Hence we calculate capacity of the tank for storing milk with non-standard acidity, in order to dispose of it subsequently.Thus, the additional container for the non-standard milk has the capacity of 500 l (0.5 tons).
As regards the loss of head at pumping milk along a milk pipeline, one can note that loss of head in modern milking plants typically reaches 10-15 kPa.However, in robotized installations, the length of a milk pipeline does not usually exceed 5-7 m.So, a loss of head can be neglected.
The calculation of other components of a milk pipeline system makes no sense because they are embedded in robotic installations and their modernization is beyond the scope of our work.
Upon obtaining experimental and calculated data, we designed a project of the structure for a technical system that would measure pH of milk in the flow of a milk pipeline in a milking robot.Fig. 5 shows block diagram of the device for the automated measurement of milk pH, fragment of a milk pipeline, and containers for storing milk based on its acidity (standard and non-standard).
The distance L is calculated based on data from a 3D-graphical model, Fig. 4. Accepting the estimated flow rate of 0.13 m/s and the response time from a high-speed pH-FT electrode of 2 s, the resulting distance L=0.26 m.
Thus, at an estimated milk pipeline diameter of 20 mm and at a given flow rate, the insert for an electromagnetic valve should be at a distance not exceeding 26 cm from the pH sensor.That is necessary to ensure the timely discharge of milk, refused for acidity, into a separate container triggered by a signal from the processor of pH meter, taking into consideration the response time of the pH-FT electrode.on measuring the samples selected from milk containers and are conducted at a laboratory using specialized devices [23].Such an indicator as acidity is typically measured in the pH units applying a special device, the pH-meter, with subsequent conversion of the value obtained into conventional Turner degrees.This process, however, does not make it possible to determine the Turner acidity in a flow, which is badly needed at automated milking and is an important task for modern science and practice.
The index of pH, as noted by researchers [24], affects the colloidal state of milk proteins, the growth of beneficial and harmful microorganisms, heat resistance of milk, the activity of enzymes.Milk possesses buffer properties due to the presence of proteins, hydrophosphates, citrates and carbon dioxide.This is confirmed by the fact that despite an increase in the titrated acidity the pH of milk also varies to a certain limit [16].
At the same time, researchers [25] point out that existing laboratory methods for determining the indicators of milk quality can fully and reliably estimate a given food product in terms of suitability for processing.However, the parameter that is of top importance, acidity, is not measured directly a flow.That could lead to losses in the quality of milk during transportation, as noted in [26], to refusal while supplying it to a milk-processing enterprise [27].Data provided by the cited researchers confirm the relevance of our work.The developed control system over the acidity of milk in the milk pipeline of a milking robot eliminates the indicated shortcomings in existing robotized equipment, forms prerequisites for obtaining milk of high quality by preventing obtaining milk of low quality based on the indicator of acidity.
It should be emphasized that the reported system to control acidity of milk in the milk pipeline of a milking robot makes it possible, in real time, and reliably, to determine the quality of milk.A radio module is used for the transmission of measured data on milk pH from current milking to the host computer at a dairy farm, as well as to a computer of the milking robot.The remaining elements of the robotized system of milking remain unchanged.
Prospects for the further research include the substantiation, development, and implementation of innovative technical and technological solutions to service high productivity cows at all stages of the process of robotic milking.

Conclusions
1.In order to implement more efficiently the possibilities of precision livestock breeding, the robotized system should be complemented with technical means to operatively determine the acidity of milk, that is directly in the milk pipeline of a milking robot.It was established that it is most expedi-Output signals from a radio module, corresponding to the UART interface, are sent to the R×D input of microcontroller D2, which has an embedded hardware USB interface.The interface UART (Universal Asynchronous Receiver-Transmitter) is aboard the radio module and controller, that is, it is integrated directly into their composition.
All the signals received by a radio module are converted into signals to the USB port and transmitted to a computer.It is possible, instead of a microcontroller, to apply the specialized FT232R chip in which the specified functions of converting the UART interface signals into signals to the USB port are implemented at the hardware level.
The pH-FT electrode and an electromagnetic valve (at a distance of 26 cm) are inserted into a main milk pipeline immediately after the inlet system of four hoses of milk pipes of the robot from the udder quarters.The valve and the electrode are connected to an electronic measuring device with a radio module.Thus, the designed control system includes: a pH-FT-electrode, a measuring device (Fig. 5), a tee with electromagnetic valve, and an additional container.The remaining elements of the robotized system remain unchanged.

Discussion of results of studying and designing a technical system for the improvement of milking process
There are various methodological approaches to determining the indicators of milk quality.All of them are based calibration dependence chart of diameter of a milk pipeline on its productivity and the milk flow rate.4. Based on the obtained experimental and calculated data, we developed a system to control the acidity of milk in a flow in the milk pipeline of a milking robot.This system includes an electronic circuit for measuring pH and converting its value into Turner degrees, a controlling element, a tee with an electromagnetic valve, and a pH-FT electrode.The valve and electrode are inserted into the main milk pipeline of a milking robot, and there is an additional container for the separation of milk with lowered acidity.ent, in order to control the acidity of milk in a flow, to use a high-speed MDS-transistor pH-electrode.
2. The result of experimental research is the measured acidity of milk using a conventional Turner method and applying the method of pH-measurement, with their linear correlation dependence Р>0.999) having been established, thereby confirming the reliability of the values for milk pH obtained employing the indicated methods.
3. We have calculated values for the required diameter of a milk pipeline, which is 20 mm, and the milk flow rate, which is 0.13 m/s.We have constructed a 3-dimensional

Fig. 1 .
Fig. 1.Dependence chart of the Turner degrees of acidity on the pH of milk

Fig. 2 .
Fig. 2. Histogram of change in the pH of milk depending on the period after calving

Fig. 5 .
Fig. 5. Principal block diagram of technical system for continuous measurement of milk pH in a flow, with an automated discharge of milk with a non-standard pH into a separate container: L -distance between the inserts of pH-FT electrode and a tee into a milk pipeline; AS -amplifier of primary signal from the electrode; ADC -analog-to-digital converter; MP -microprocessor; CE -controlling element; Ind -indicator; RM -radio module

Fig. 6 .Fig. 7 .
Fig. 6.Functional circuit of the measuring and radio-transmitting part of the system for the automated measurement of milk pH in a flow

Table 1
Organoleptic estimation of smell and taste of drinking milk Slight smack of feed, weakly oxidized, weakly lipolysis-like, weakly unclean fair 3 Intensive smack of feed, including onion, garlic, wormwood, and other herbs, which render milk a bitter taste; salty, oxidized, lipolysis-like, musty poor 2 Bitter, rancid, moldy, putrid smell and taste of petroleum products, medicines, detergents, disinfectants, other chemicals poor 1