Search

CN-122004148-A - Intelligent weighing and feeding integrated control method and system based on livestock identity recognition

CN122004148ACN 122004148 ACN122004148 ACN 122004148ACN-122004148-A

Abstract

The invention discloses an intelligent weighing and feeding integrated control method and system based on livestock identity recognition, which relate to the technical field of Internet of things and intelligent livestock, and comprise the steps of carrying out structural analysis on an original data stream output by an RFID module, combining a preset standard tag ID length legal range, accumulating and checking results and a frame tail format to judge the validity of a data packet, extracting a tag ID when the data packet is valid, setting an RFID valid state mark, recording the recognition moment, inquiring a locally stored historical stable weight value according to the tag ID, setting a weight change threshold value, reading the current weight value output by a weighing sensor in a fixed period, comparing the current weight value with a last stable weight value, judging that the weight is in a stable state when the difference value of the preset times is smaller than the weight change threshold value continuously, recording the current weight as a final weight value, and recording the RFID valid state mark and the weight stable state mark as true at the same time on the premise that the corresponding tag ID is not processed on the current day.

Inventors

  • HAN FENG
  • DU LIN
  • ZHANG QIANXI
  • LI HUI
  • XU HUIYING

Assignees

  • 内蒙古智慧兴牧物联技术有限公司

Dates

Publication Date
20260512
Application Date
20260128

Claims (10)

  1. 1. An intelligent weighing and feeding integrated control method based on livestock identity recognition is characterized by comprising the following steps: Carrying out structural analysis on the original data stream output by the RFID module, combining a preset standard tag ID length legal range, accumulating and checking results and a frame tail format to judge the validity of the data packet, extracting the tag ID when the data packet is valid, setting an RFID valid state mark, and recording the identification time; Inquiring a locally stored historical stable weight value according to the ear tag ID, setting a weight change threshold, reading a current weight value output by a weighing sensor in a fixed period, comparing the current weight value with a last stable weight value, judging that the weight is in a stable state when the difference value continuously reaching the preset times is smaller than the weight change threshold, and recording the current weight as a final weight value; When the RFID valid state mark and the weight stable state mark are true at the same time and the corresponding tag ID is not processed on the premise of not being processed on the same day, calculating the time difference between the identification time and the stable time, and when the time difference does not exceed a preset synchronization window threshold value, binding the tag ID with a final weight value to form a pairing data record; Based on the paired data records, invoking a feeding strategy corresponding to the tag ID, and executing a feeding decision by combining the final weight value to generate a feeding instruction; driving a feeding executing mechanism to complete feeding operation according to feeding instructions, and associating feeding executing results to paired data records; and packaging the ID of the earmark, the final weight value, the feeding execution result and the processing time into a structured data packet, uploading the structured data packet to a remote cloud platform through a wireless communication module, and clearing an RFID valid state mark, a weight stable state mark and a daily processing mark after uploading is completed.
  2. 2. The intelligent weighing and feeding integrated control method based on livestock identification of claim 1, wherein the method is characterized by structurally analyzing an original data stream output by an RFID module, and comprises the following specific steps: The system continuously receives the byte stream output by the RFID reader-writer through the serial communication interface, and temporarily stores the received data in the annular receiving buffer area; Scanning byte by byte in the annular receiving buffer area, searching for a preset frame header mark, and reading a data length field following the frame header mark after the frame header is detected The data length field indicates the number of valid data bytes from the beginning of the type field to the end of the data field; According to Calculating the theoretical end position of the data content area, verifying whether one byte after the theoretical end position is equal to the preset frame end mark, and if the frame ends are matched, accumulating and calculating all bytes from the type field to the data field to obtain a verification result ; Will be And check bytes carried in data packet Comparing and judging Whether it belongs to the legal set of the preset standard tag ID length Only when the end of the frame is correct, And (2) and When the current data packet is judged to be effective identification data; Extracting complete tag ID from data content area, setting RFID valid state flag, and recording time stamp of the identification event as identification time 。
  3. 3. The intelligent weighing and feeding integrated control method based on livestock identification according to claim 2, wherein the method is characterized by inquiring a locally stored historical stable weight value according to an ear tag ID and setting a weight change threshold value, and comprises the following specific steps: After the RFID valid status flag is set, based on the extracted tag ID, the historical stable weight value associated with the ID is retrieved from nonvolatile memory If the tag ID is first identified and no corresponding record exists in the memory, adopting a default initial weight value corresponding to the livestock variety as the initial weight value ; The system is based on Dynamically calculating weight change threshold used in the weighing process The formula is as follows: ; Wherein, the A minimum weight change threshold value preset for the system, for ensuring the weighing sensitivity of the small animal, Is a proportionality coefficient.
  4. 4. The intelligent weighing and feeding integrated control method based on livestock identification according to claim 3, wherein the method is characterized in that the current weight value output by the weighing sensor is read in a fixed period and compared with the last stable weight value, and comprises the following specific steps: the system sends a reading instruction to the weighing sensor in a fixed sampling period to acquire the current weight value ; Initializing the last stable weight value For first reading ; At each acquisition After that, calculate its and Absolute difference of (2) ; If it is Then the internal stable counter Add 1, otherwise, will Zero clearing and putting Updated to current ; When (when) The accumulation reaches a preset threshold value of the stable times When the system judges that the current weight is in a stable state, the system records the current weight As the final weight value of the current measurement Setting weight steady state flag, and recording time stamp of occurrence of steady event as steady time 。
  5. 5. The intelligent weighing and feeding integrated control method based on livestock identity recognition as set forth in claim 4, wherein the steps of calculating the time difference between the recognition time and the stabilization time and judging whether binding is performed are as follows: On the premise that the RFID valid state mark and the weight stable state mark are true at the same time, checking whether the tag ID is processed on the same day, and if not, reading the identification time And the moment of stabilization ; Calculating the time difference between the two, wherein the formula is as follows: ; Will be With a preset synchronization window threshold Comparing; When meeting the requirements When the RFID identification event and the weight stabilization event are judged to belong to the same livestock individual, the tag ID and the final weight value are allowed to be combined Binding is carried out to form a pairing data record, otherwise, a cross-individual interference event is judged, the current pairing attempt is discarded, and the relevant state flag is reset.
  6. 6. The intelligent weighing and feeding integrated control method based on livestock identity recognition according to claim 5, wherein the feeding decision is executed by combining the final weight value, and the method comprises the following specific steps: The system invokes a feeding strategy corresponding to the ID from a local nonvolatile memory according to the ID of the ear tag in the pairing data record; the feeding strategy comprises a target lower body weight limit Upper limit of target body weight Maximum daily feeding times A feed type parameter; The system inquires the feeding times of the tag ID executed on the same day If the final weight value is Below is lower than And (2) and Entering a feeding priority evaluation stage; wherein the priority score The method is calculated according to the following formula: ; Wherein, the And (3) with Is a preset weight coefficient, meets the following conditions The method is used for adjusting the influence degree of weight deviation and feeding frequency on decision making; Is the target lower weight limit; Is the upper limit of the target body weight; Maximum daily feeding times; Is the final weight value; The number of feeds that have been performed on the same day; When (when) Greater than a decision threshold preset by the system When the feeding device is used, a feeding instruction is generated, and then, a feeding executing mechanism is driven to release quantitative feed, and a feeding executing result is related to a pairing data record; if the wireless communication module returns to a failure state when uploading the structured data packet, writing the structured data packet into an annular buffer area in the nonvolatile memory, and marking the structured data packet as to-be-retransmitted; the main controller scans the annular buffer area periodically in an idle period, and uploads all the items to be retransmitted in sequence, after the uploading is successful, the mark to be retransmitted is cleared, and when the buffer area is full, the earliest written data to be retransmitted is covered according to the first-in first-out principle.
  7. 7. The intelligent weighing and feeding integrated control method based on livestock identity recognition as set forth in claim 6, wherein the steps of packaging and uploading the ear tag ID, the final weight value, the feeding execution result and the processing time into a structured data packet are as follows: earmark ID, final weight value Feeding an execution result, constructing a standardized data structure as processing time, serializing the standardized data structure into a character string in a JSON format to form a structured data packet, and transmitting the structured data packet to a remote cloud platform through a wireless communication module; after the transmission is completed, waiting for the communication module to return to a transmission state, if the state is successful, executing a state resetting flow, and if the state is failed, triggering a local buffer and retransmission mechanism; In the state resetting flow, the system clears the RFID valid state mark and the weight stable state mark, and marks the processing of the tag ID on the same day as processed; and (3) emptying the RFID receiving buffer zone and the weighing temporary variable to restore the system to an initial state to be identified, and preparing to respond to the weighing action of the next livestock individuals.
  8. 8. An intelligent weighing and feeding integrated control system based on livestock identity recognition, which is based on the intelligent weighing and feeding integrated control method based on livestock identity recognition as set forth in any one of claims 1 to 7, is characterized by comprising the following steps: The system comprises an RFID read-write module, a weighing platform, a main controller, a feeding executing mechanism, a wireless communication module and a power management unit; The RFID read-write module is arranged at the inlet side of the weighing platform, and is used for non-contact reading of electronic ear tags worn by livestock and outputting an original serial data stream comprising a frame header, a length field, data content, check bytes and a frame tail; the weighing platform consists of a high-rigidity metal frame and four high-precision weighing sensors and is used for bearing livestock and outputting an electric signal proportional to the weight of the livestock in real time; The main controller adopts an embedded micro control unit, is respectively connected with an RFID read-write module through a UART interface and is connected with a weighing platform through an ADC or a digital interface, and is used for controlling a system, and specifically comprises RFID data packet analysis, dynamic threshold calculation, weight stability judgment, time synchronization verification, feeding decision generation, data package uploading and state resetting; the feeding executing mechanism is arranged at the outlet side of the weighing platform and comprises a feed storage bin, a spiral feeder driven by a stepping motor and an electromagnetic control valve, and is controlled by a feeding instruction of the main controller and used for releasing precisely metered feed as required; The wireless communication module is integrated in the main controller or externally connected with the main controller, supports a 4G, wi-Fi or LoRa wireless communication protocol and is used for uploading the structured data packet to a remote livestock management cloud platform in real time to realize data centralized storage and analysis; The power management unit is connected with a commercial power or solar power supply system, and provides a stable direct current power supply for the RFID read-write module, the weighing platform, the main controller, the feeding executing mechanism and the wireless communication module after AC-DC conversion and voltage stabilization.
  9. 9. The computer equipment comprises a memory and a processor, wherein the memory stores a computer program, and the computer program is characterized in that the processor realizes the steps of the intelligent weighing and feeding integrated control method based on livestock identification according to any one of claims 1-8 when executing the computer program.
  10. 10. A computer readable storage medium is provided with a computer program, and is characterized in that the computer program is executed by a processor to realize the steps of the intelligent weighing and feeding integrated control method and system based on livestock identification as set forth in any one of claims 1-8.

Description

Intelligent weighing and feeding integrated control method and system based on livestock identity recognition Technical Field The invention relates to the technical field of Internet of things and intelligent livestock raising, in particular to an intelligent weighing and feeding integrated control method and system based on livestock identity recognition. Background In modern intensive livestock breeding systems, personalized accurate management has become a core technical path for improving production efficiency, optimizing feed conversion rate and guaranteeing animal welfare. In recent years, with the maturity of radio frequency identification technology, high-precision weighing sensing technology and embedded control systems, the industry gradually explores an automatic solution for combining automatic identification of livestock identity and dynamic monitoring of weight. Such systems typically attempt to achieve "one animal at one file" data acquisition by deploying RFID readers and electronic scales in the tunnel or weigh station, and some studies have further attempted to introduce simple threshold decisions to filter out weigh fluctuations and trigger basal feeding actions based on recognition results. The prior art scheme has a plurality of key defects, and severely restricts the practical application efficiency. Under a dynamic weighing scene, time asynchronism often exists between an RFID identification event and a weight stable state, but an effective time sequence constraint mechanism is generally lacking in the conventional system, so that the conventional system cannot adapt to individual fluctuation characteristics of livestock of different varieties, body types or behavior characteristics, the RFID reading process is easily influenced by multi-tag collision, metal environment reflection and electromagnetic interference, a forward verification mechanism for legal tag coding formats is lacking, the anti-interference capability is insufficient, a weighing result cannot be deeply coupled with a feeding strategy, health evaluation and cloud management, a dynamic feeding decision model based on the individual growth state and a data uploading mechanism for fault tolerance of broken networks are lacking, the closed loop of a process is poor, and real intelligent and accurate cultivation is difficult to support. Disclosure of Invention The present invention has been made in view of the above-described problems occurring in the prior art. Therefore, the intelligent weighing and feeding integrated control method based on livestock identity recognition provided by the invention solves the problem of lack of an effective time sequence constraint mechanism, cannot adapt to the individual fluctuation characteristics of livestock of different varieties, body types or behavior characteristics, is susceptible to multi-tag collision, metal environment reflection and electromagnetic interference in the RFID reading process, lacks a forward verification mechanism for legal tag coding formats, lacks anti-interference capability, fails to deeply couple weighing results with feeding strategies, health assessment and cloud management, lacks a dynamic feeding decision model based on individual growth states and a data uploading mechanism for network breaking fault tolerance, and solves the problem of poor closed loop of the process. In order to solve the technical problems, the invention provides the following technical scheme: in a first aspect, the invention provides an intelligent weighing and feeding integrated control method based on livestock identity recognition, which comprises the following steps: Carrying out structural analysis on the original data stream output by the RFID module, combining a preset standard tag ID length legal range, accumulating and checking results and a frame tail format to judge the validity of the data packet, extracting the tag ID when the data packet is valid, setting an RFID valid state mark, and recording the identification time; Inquiring a locally stored historical stable weight value according to the ear tag ID, setting a weight change threshold, reading a current weight value output by a weighing sensor in a fixed period, comparing the current weight value with a last stable weight value, judging that the weight is in a stable state when the difference value continuously reaching the preset times is smaller than the weight change threshold, and recording the current weight as a final weight value; When the RFID valid state mark and the weight stable state mark are true at the same time and the corresponding tag ID is not processed on the premise of not being processed on the same day, calculating the time difference between the identification time and the stable time, and when the time difference does not exceed a preset synchronization window threshold value, binding the tag ID with a final weight value to form a pairing data record; Based on the paired data records, invo