A sow intelligent disease early warning and breeding full life cycle digital management method based on an internet of things electronic ear tag
By using IoT electronic ear tags that are resistant to falling off, self-locking, and have built-in temperature measurement capabilities to communicate with the breeding management system in a standardized manner, the system enables automatic and continuous collection of sow body temperature and three-level disease early warning. This solves the problems of ear tags easily falling off, inflammation, and lack of body temperature monitoring in sows, and realizes the digitalization of the entire life cycle of breeding management.
Patent Information
- Application Number
- CN202611506684.1
- Authority / Receiving Office
- CN · China
- Patent Type
- Applications(China)
- Current Assignee / Owner
- Filing Date
- 2026-09-27
- Publication Date
- 2026-11-06
AI Technical Summary
Existing sow ear tags are prone to falling off, becoming inflamed, and have failed to be traced back to their source. Body temperature monitoring is also lacking. Furthermore, poor data communication between the hardware and the breeding management system leads to data gaps and insufficient early warnings.
It adopts IoT electronic ear tags that are anti-detachment, self-locking, and have built-in temperature measurement. It achieves standardized data communication with the breeding management system through the XLMJ-IoT protocol, automatically collects body temperature and conducts three-level disease early warning, realizing digital management of the entire life cycle.
It solved the problems of sow ear tag detachment, inflammation, traceability failure, and lack of body temperature monitoring, and achieved a data closed loop between hardware and system, reducing manual temperature measurement time and breeding costs, and improving the continuity and accuracy of breeding data.
Smart Images

Figure CN123053522A_ABST
Abstract
Description
Technical Field
[0001] This invention belongs to the field of digital management and intelligent disease early warning technology in animal husbandry, specifically involving a method for intelligent disease early warning of sows based on IoT electronic ear tags, a standardized data communication method between ear tag devices and breeding management systems, and a digital management method for the entire life cycle of sow breeding based on IoT electronic ear tags. Background Technology
[0002] The applicant has developed the "Xingluomeijia Eight-Eyebrow Berkshire Crossbreeding and Brand Licensing Management System V1.0" (hereinafter referred to as the "Breeding Management System"). This system adopts a front-end single-page application architecture and includes 17 functional modules, covering subsystems such as breeding pig file management, mating record management, pregnancy tracking management, piglet file management, genetic pedigree management, trademark file management, brand licensing contract management, licensor management, trademark monitoring and early warning, statistical reports, user permission management, and system settings. The system's core data model defines 13 attribute fields for the breeding pig file (breedStock), including ear tag number, file ID, name, breed, sex, birth date, weight, status, source, bloodline, litters, and remark. It also establishes associated data tables for mating records, pregnancy management, and piglet files. The system has achieved full-chain data traceability based on ear tags: from individual breeding pig files → mating records → pregnancy tracking → piglet birth → weaning → genetic lineage management throughout the entire life cycle.However, there are the following key technical bottlenecks in the connection between the hardware perception layer and the software application layer: (1) The traditional ear tag buckle structure is loose, and sows fighting and rubbing against the pen are very easy to lose the tag, drop the tag, or replace the tag, which causes the data chain of the entire link indexed by earTag in the breeding management system to be broken, the data chain of mating records, pregnancy tracking, and piglet files to be broken, and the genetic lineage is unreliable; (2) The existing ear tags only have passive RFID identification function and no active temperature measurement sensor. Pig farms rely entirely on manual temperature measurement and cannot realize the automatic collection of body temperature data and trigger disease warning. The pregnancy management module in the breeding management system only has static gestDays (gestation days) and checkResult (check results) fields, lacking continuous and quantitative body temperature monitoring data support; (3) Ordinary ear tags only support single RFID identification and have no QR code redundancy. (3) When the RFID chip ages or the radio frequency identification equipment fails, the system file associated with the earTag cannot be read through the backup method, and the traceability chain is interrupted; (4) The hardness of ordinary plastic ear tags is too high. The ears of the eight-browed sows are thin and the skin is tender. After wearing them, they become red, swollen, ulcerated and inflamed. The rate of falling off is extremely high, which seriously affects the continuity and accuracy of breeding data; (5) The existing ear tags are not moisture-proof, not resistant to manure corrosion, and not resistant to the diurnal temperature difference of -20℃ to 40℃ in Northwest China. The circuit module has a short lifespan, which leads to intermittent temperature data collection and cannot support the continuous monitoring needs of the system; (6) There is a lack of standardized data communication protocol and API interface between the existing ear tags and the breeding management system. The RFID chip ID and temperature data collected by the hardware cannot be automatically written into the system's breedStock, pregnancy and other data tables, forming an information island of "hardware has data, but the system does not recognize the data". Summary of the Invention
[0003] (a) Technical problems to be solved The technical problem to be solved by the present invention is to overcome the above-mentioned shortcomings of the prior art and provide a method for intelligent disease early warning and digital management of the entire breeding life cycle of sows based on Internet of Things electronic ear tags. Through standardized data communication between the electronic ear tag device with anti-detachment, self-locking, built-in temperature measurement and dual recognition and the breeding management system, the method realizes automatic and continuous collection of sow body temperature, three-level disease early warning based on adaptive baseline of gestation stage, and digital closed-loop management of the entire life cycle from individual breeding pig files to genetic lineage.
[0004] To address the aforementioned technical problems, the first aspect of this invention provides a method for intelligent disease early warning in sows based on Internet of Things (IoT) electronic ear tags, comprising the following steps: (a) receiving temperature sampling data uploaded by the ear tag device, wherein the temperature sampling data includes an RFID chip ID (chipId), body surface temperature value (temperature), and sampling time (sampleTime); (b) using chipId as an index to obtain the corresponding sow's gestation stage information (pregnancy.stage) from the breeding management system, wherein the gestation stage includes early pregnancy, mid-pregnancy, and late pregnancy; (c) automatically loading the corresponding normal body temperature baseline range according to the gestation stage: early pregnancy baseline 38.2℃±0.3℃, mid-pregnancy baseline 38.5℃±0.3℃, late pregnancy baseline 38.8℃±0.4℃, and non-pregnant sows... (d) Calculate the deviation of the current temperature from the baseline of the corresponding gestation stage, and the rate of temperature change in the last 24 hours; (e) When the temperature deviates from the baseline by more than 0.8℃ for three consecutive samplings and the rate of temperature increase exceeds 0.5℃ / h, it is judged as a high fever warning, and the warning level is high; when the temperature deviates from the baseline by more than 0.5℃ for three consecutive samplings, it is judged as a medium temperature warning, and the warning level is medium; when the temperature of the sow in late gestation is more than 1.0℃ below the corresponding baseline, it is judged as a low body temperature warning, and the warning level is high; (f) After the warning is triggered, the warning record is automatically inserted into the warning data table (tmMonitor) of the breeding management system. The warning type is abnormal body temperature warning, the priority corresponds to the warning level, and it is displayed in real time on the system console (Dashboard) and a notification is pushed to the relevant technical personnel.
[0005] Further, in step (b), when it is determined that the corresponding sow is pregnant, the sow's mating date (mating.mateDate), expected delivery date (pregnancy.expectDate), gestation days (pregnancy.gestDays), and data on the previous litter of piglets (piglet) are simultaneously retrieved from the breeding management system for comprehensive assessment of disease risk and treatment priority. Further, in step (d), the temperature change rate is calculated as follows: a linear regression is performed on the temperature sampling sequence over the most recent 24 hours, and the slope of the regression line is taken as the temperature change rate. The calculation formula is: trendRate = Σ((ti-t_avg)×(Ti-T_avg)) / Σ(ti-t_avg)², where ti is the sampling time point, Ti is the corresponding temperature value, and t_avg and T_avg are the mean values of time and temperature, respectively. Furthermore, the judgment logic for three consecutive samples in step (e) is as follows: maintain an abnormality counter with an initial value of 0; increment the counter by 1 each time the sampled temperature deviates from the corresponding baseline by more than the threshold, and reset the counter to 0 when the temperature returns to the normal range; trigger the corresponding warning level when the counter accumulates to 3 consecutively.
[0006] Furthermore, before the judgment in step (e), the original temperature data is first subjected to sliding window filtering. The window size is 5 samples, and the median value within the window is taken as the current valid temperature value to participate in the deviation calculation, so as to eliminate the instantaneous abnormal temperature readings caused by sows rubbing against the pen or lying down and being compressed.
[0007] Furthermore, after step (f) triggers the warning, the following linkage operations are further performed: (i) the pregnancy check result field (pregnancy.checkResult) of the corresponding sow in the breeding management system is updated to abnormal body temperature, and the last abnormal sampling time is marked; (ii) the pending warning count in the system console is automatically incremented by 1, and the latest warning list is refreshed in real time; (iii) according to the list of users whose department field in the user data table (users) of the breeding management system is the breeding center, SMS or in-app notifications are automatically pushed.
[0008] To address the aforementioned technical problems, a second aspect of this invention provides a standardized data communication method for an IoT-based electronic ear tag and breeding management system. This method defines an XLMJ-IoT data communication protocol between the ear tag device and the breeding management system, comprising the following three layers: (a) Physical layer communication: Supports handheld RFID readers to communicate with the breeding management system terminal via USB or Bluetooth BLE 5.0. The RFID reader operates in the UHF band at 920-925MHz, with an adjustable reading distance of 0-5m. Simultaneously, it supports fixed channel gate antennas to communicate with the system server via WiFi or Ethernet. The channel gate antenna is a dual-band antenna consisting of a 134.2kHz low-frequency LF and a 920MHz ultra-high-frequency UHF antenna; (b) Data layer communication: Defines a JSON-formatted data message structure. The uplink message, from the ear tag to the system, includes the fields {chipId, earTag, temperature, sampleTime, batteryLevel, signalStrength}; the downlink message, from the system to the ear tag, includes the fields {chipId, pregnancyStage, baselineTempLo, baselineTempHi, ...}. sampleInterval}; The message is encrypted and transmitted using the AES-128 symmetric encryption algorithm, and a CRC-16 cyclic redundancy check code is added to ensure data integrity; (c) Application layer communication: After receiving the uplink message, the system uses chipId as the index to look up the corresponding earTag record in the breeding pig file data table (breedStock), writes temperature and sampleTime into the temperature time series data table (temperatureLog), and then calls the early warning algorithm to make a judgment and writes it into the early warning data table (tmMonitor) when the early warning is triggered.
[0009] Furthermore, when RFID radio frequency communication fails due to chip aging, antenna damage, or environmental electromagnetic interference, the system automatically switches to the backup identification channel: by scanning the DataMatrix QR code on the outer surface of the ear tag with a mobile terminal, the earTag number is decoded and obtained. Then, the complete breeding file and temperature history data of the corresponding sow are directly retrieved from the breeding management system using the earTag as an index, realizing automatic switching of redundant communication between radio frequency identification and optical identification channels.
[0010] Furthermore, the breeding management system adopts a front-end single-page application (SPA) architecture, which includes six core data modules: breedstock, mating record management, pregnancy tracking management, piglet record management, genetic pedigree management, and tmMonitor. Each module uses ear tag or RFID chip ID as the main index to achieve data association, forming a closed loop of data for the entire life cycle from individual breeder records → mating records → pregnancy tracking → piglet birth → weaning → genetic pedigree.
[0011] To address the aforementioned technical problems, the third aspect of this invention provides a digital management method for the entire lifecycle of sow breeding based on IoT electronic ear tags, comprising: (a) Wearing stage: wearing an anti-detachment electronic ear tag with a globally unique RFID chip ID on the sow's ear, establishing a one-to-one mapping and binding relationship between chipId and earTag in the breeding stock data table of the breeding management system; (b) Continuous temperature measurement stage: the microcontroller built into the ear tag wakes up the temperature sensor at a preset sampling interval to collect the body surface temperature at the base of the ear, filters it through a sliding window, and locally caches the temperature sequence of the most recent 48 hours. The microcontroller simultaneously calculates the 24-hour temperature mean and standard deviation, and the rate of temperature change offline; (c) Data synchronization stage: when a handheld RFID reader or the channel gate antenna enters the effective communication range, the ear tag device is automatically woken up, and data is synchronized via XLMJ-IoT data communication. (d) Intelligent early warning stage: The system uses chipId as an index to obtain the gestation stage information of the corresponding sow, loads the normal body temperature baseline range of the corresponding stage, calculates the temperature deviation value and 24-hour temperature change rate, and automatically triggers graded early warning when the deviation exceeds the corresponding threshold for 3 consecutive times, and writes the early warning record to the early warning data table (tmMonitor) of the breeding management system; (e) Full life cycle traceability stage: The system uses earTag or chipId as an index to link all breeding files of an individual sow: pedigree → mating record → gestation stage → litter of piglets → genetic lineage → body temperature history curve, to realize digital breeding management of the entire life cycle under one standard.
[0012] (III) Beneficial Effects Compared with existing technologies, this invention has the following beneficial effects: 1. Solving industry pain points: It completely solves the five major problems of ear tag removal, tag replacement, inflammation, traceability failure, and lack of body temperature monitoring in Bamei sows, adapting to the characteristics of the Bamei pig breed and the cold breeding environment in Northwest China; 2. Software and hardware closed loop: For the first time, it realizes a complete data closed loop from ear tag hardware → XLMJ-IoT protocol → breeding management system V1.0. The chipId and body temperature data collected by the sensing layer are automatically associated with four data tables: breedStock, pregnancy, temperatureLog, and tmMonitor. The dashboard console displays the data in real time, forming a five-in-one software and hardware technology system of "hardware acquisition - data storage - intelligent analysis - early warning push - file association"; 3. Reducing breeding costs: It reduces manual temperature measurement time by more than 80%, reduces re-labeling and rework costs (the removal rate is reduced from the industry average of 15% to below 2%), and reduces the culling rate of sows and the mortality rate of piglets by early detection and treatment of abnormal body temperature; 4. High breeding value: Ensures that the ear tags of breeding pigs are irreplaceable for life, the earTag→chipId binding is tamper-proof, the pedigree records are authentic and reliable, and the genetic lineage calculation is accurate and reliable; 5. Strong scalability: The XLMJ-IoT protocol and temperatureLog table architecture support the future expansion to access more sensor types, laying the foundation for the comprehensive digitalization of pig farms. Attached Figure Description
[0013] Figure 1 This is a schematic diagram of the overall structure of the electronic ear tag device involved in the present invention, showing the public tag puncture component, the female tag body, the RFID radio frequency identification chip, the digital temperature sensor, the MCU microcontroller, the silicone ear pad layer, the QR code layer, and the sealing layer.
[0014] Figure 2 The circuit system connection block diagram of the electronic ear tag device according to the present invention shows the electrical connection relationship between RFID chip → MCU microcontroller → temperature sensor → NFC communication module → battery → antenna.
[0015] Figure 3 This is a system integration architecture diagram of the present invention and the breeding management system V1.0, showing the three-layer architecture of perception layer → transmission layer → application layer and the data flow.
[0016] Figure 4 The flowchart of the intelligent disease early warning algorithm of the present invention shows the complete processing flow of temperature sampling → data filtering → baseline matching during pregnancy → deviation judgment → early warning triggering → tmMonitor database entry → Dashboard display.
[0017] Figure 5This is an extended diagram of the data table relationships in the Breed Management System V1.0, showing the extended relationships between the four tables: breedStock, temperatureLog, pregnancy, and tmMonitor. Detailed Implementation
[0018] The specific embodiments of the present invention will be described in further detail below with reference to the accompanying drawings and examples. It should be noted that the following examples are only for illustrating the present invention and are not intended to limit the scope of protection of the present invention.
[0019] The electronic ear tag device upon which the method of this invention relies is, for example... Figure 1 As shown, it consists of a male standard component (1) and a female standard component (2). The puncture needle body (11) of the male standard component (1) is made of tapered, thickened, high-strength medical-grade nylon 66 material. The needle body is provided with 3-5 levels of asymmetrical unidirectional barbed self-locking teeth (12) along the axial direction. The face angle of each level of barbed teeth is 45°±5° (needle insertion side) and 90°±2° (anti-retraction side), forming an irreversible self-locking mechanical mechanism. The female standard component (2) is provided with a locking hole groove (21) inside. After matching and connecting with the barbed self-locking teeth, it can only be pushed in one direction, cannot be pulled out in reverse, and cannot be disassembled manually. The bottom surface of the female standard component is provided with an arc-shaped curved ear pad layer (25) made of food-grade liquid silicone (LSR) material, with a contact area ≥4.5cm² and a Shore hardness of A20-A30, which effectively buffers the shearing force generated when the sow's ear moves. The outer surface of the mother label component is provided with a laser-engraved DataMatrix QR code anti-counterfeiting and traceability label layer (26). The QR code encoding content includes an encrypted summary of RFID chip ID (chipId), ear tag number (earTag), variety code, date of birth, and gender identification information, which corresponds one-to-one with the internal RFID chip ID, forming a dual traceability redundancy structure of radio frequency identification + optical identification.
[0020] like Figure 2As shown, the motherboard component internally encapsulates a 134.2KHz livestock-specific low-frequency RFID radio frequency identification chip (22), a miniature digital temperature sensing module (23), and a microcontroller MCU (24). The RFID chip has a globally unique 64-bit ID code (chipId). The temperature sensor has an accuracy of ±0.1℃ and a resolution of 0.01℃. It is coupled to the inner surface of the silicone layer at the bottom of the motherboard through thermally conductive silicone grease, adhering to the skin of the pig's ear to achieve continuous acquisition of the body surface temperature at the base of the ear. The MCU has built-in edge computing firmware, supporting sliding window filtering (window size 5 times), calculation of 24-hour temperature mean and standard deviation, calculation of temperature change rate, local caching of the temperature sequence of the most recent 48 hours (approximately 576 records), offline storage when the network is disconnected, and batch uploading after the connection is restored. The motherboard employs a two-stage injection molding encapsulation: the first layer of circuit modules is vacuum-encapsulated with epoxy resin (thickness ≥ 1.5 mm), and the second outer layer is injection-molded with TPU thermoplastic polyurethane (thickness ≥ 2 mm). The overall protection level reaches IP68, with an operating temperature range of -30℃ to 60℃, and it is resistant to corrosion from fecal matter and peracetic acid / glutaraldehyde disinfectant solutions within a pH range of 5-9. It is powered by a built-in CR2032 button battery, and the MCU uses a deep sleep-timed wake-up mode, with an average power consumption ≤ 15 μA and a designed lifespan ≥ 3 years.
[0021] like Figure 3 As shown, the ear tag device interacts with the breeding management system through the standardized XLMJ-IoT data communication protocol. The complete system architecture is divided into three layers: (1) Perception layer: The ear tag device collects data such as chipId, temperature, sampleTime, and batteryLevel; (2) Transmission layer: A handheld RFID reader (UHF 920-925MHz, USB / Bluetooth BLE 5.0 connection) or channel gate antenna (134.2KHz LF + 920MHz UHF dual frequency, WiFi / Ethernet connection) transmits data through AES-128 encrypted JSON messages; (3) Application layer: After receiving the data, the breeding management system V1.0 automatically writes it into the temperatureLog time series table, calls the early warning algorithm to judge, and if an early warning is triggered, it writes it into the tmMonitor table and displays it on the Dashboard. At the same time, it associates with the breedStock, pregnancy, mating, piglet, and genetics tables to achieve full life cycle traceability. When the RFID radio frequency communication fails, it automatically switches to the DataMatrix QR code optical recognition backup channel to ensure that the traceability chain is not interrupted.
[0022] like Figure 4As shown, the early warning algorithm process is as follows: receive temperature data → filter the midpoint of the sliding window (5 windows) → obtain the sow's gestation stage using the chipId index → load the corresponding baselines according to early gestation (38.2℃±0.3℃), mid-gestation (38.5℃±0.3℃), and late gestation (38.8℃±0.4℃) → calculate the 24-hour temperature change rate using linear regression → calculate the deviation value → if there are 3 consecutive deviations > 0.8℃ and the rate of increase is > 0.5℃ / h, a high fever warning (level = high) is triggered → if there are 3 consecutive deviations > 0.5℃, a medium temperature warning (level = medium) is triggered → if the body temperature in late gestation is < baseline - 1.0℃, a low body temperature warning (level = high) is triggered → after triggering, the data is automatically written to the tmMonitor table, the Dashboard is refreshed, pregnancy.checkResult is updated, and a notification is pushed to the breeding center technician.
[0023] like Figure 5 As shown, to ensure seamless integration between ear tag hardware data and the breeding management system, five extended fields—chipId (unique RFID ID), qrCode (QR code), lastTemp (latest body temperature), tempStatus (body temperature status), and deviceBattery (battery power)—were added to the original breedStock table. A new temperature time-series data table, temperatureLog, was also added (containing fields such as chipId, earTag, temperature, sampleTime, ambientTemp, batteryLevel, and signalStrength). The pregnancy table was further expanded with three extended fields: avgTemp7d (7-day average temperature), tempTrend (body temperature trend), and tempAlertCount (number of abnormalities). Through the mapping relationship between chipId and earTag, a four-table linkage was established—breedStock, temperatureLog, pregnancy, and tmMonitor—to achieve a complete closed loop from ear tag binding, continuous temperature monitoring, data synchronization, intelligent early warning, to full lifecycle traceability.
[0024] The above description is merely a preferred embodiment of the present invention and is not intended to limit the present invention in any way. Any modifications, equivalent substitutions, and improvements made within the spirit and principles of the present invention should be included within the scope of protection of the present invention.
Claims
1. A method for intelligent early warning of diseases in sows based on Internet of Things (IoT) electronic ear tags, characterized in that, Includes the following steps: (a) Receive temperature sampling data uploaded by the ear tag device, the temperature sampling data including RFID chip ID (chipId), body surface temperature value (temperature), and sampling time (sampleTime); (b) Using chipId as an index, retrieve the pregnancy stage information (pregnancy.stage) of the corresponding sow from the breeding management system, the pregnancy stage including early pregnancy, mid pregnancy, and late pregnancy; (c) Automatically load the corresponding normal body temperature baseline range according to the pregnancy stage: early pregnancy baseline 38.2℃±0.3℃, mid pregnancy baseline 38.5℃±0.3℃, late pregnancy baseline 38.8℃±0.4℃, and non-pregnant sows use the general baseline 38.5℃±0.5℃; (d) Calculate the deviation of the current temperature from the baseline of the corresponding pregnancy stage, and the temperature change rate in the last 24 hours; (e) When the temperature deviation from the baseline exceeds 0.8℃ for 3 consecutive samplings and the temperature rise rate exceeds 0.5℃ / h, it is determined to be a high heat warning, and the warning level is high; When the temperature deviates from the baseline by more than 0.5℃ in three consecutive samplings, it is determined to be a medium temperature warning, and the warning level is medium. When the temperature of a sow in late pregnancy is more than 1.0°C below the corresponding baseline, it is determined as a low body temperature warning, and the warning level is high; (f) After the warning is triggered, the warning record is automatically inserted into the warning data table (tmMonitor) of the breeding management system. The warning type is abnormal body temperature warning, the priority corresponds to the warning level, and it is displayed in real time on the system console (Dashboard) and a notification is pushed to the relevant technical personnel.
2. The intelligent disease early warning method according to claim 1, characterized in that: Step (b) further includes: when it is determined that the corresponding sow is pregnant, the breeding management system is used to retrieve the sow's mating date (mating.mateDate), expected delivery date (pregnancy.expectDate), gestation days (pregnancy.gestDays), and data of the previous litter of piglets (piglet) to comprehensively assess the disease risk and treatment priority.
3. The intelligent disease early warning method according to claim 1, characterized in that: The method for calculating the temperature change rate in step (d) is as follows: perform linear regression fitting on the temperature sampling sequence within the most recent 24 hours, and take the slope of the regression line as the temperature change rate. The calculation formula is: trendRate = Σ((ti-t_avg)×(Ti-T_avg)) / Σ(ti-t_avg)², where ti is the sampling time point, Ti is the corresponding temperature value, and t_avg and T_avg are the mean values of time and temperature, respectively.
4. The intelligent disease early warning method according to claim 1, characterized in that: The judgment logic for the three consecutive samples in step (e) is as follows: maintain an exception counter with an initial value of 0; Each time the sampled temperature deviates from the corresponding baseline by more than the threshold, the counter is incremented by 1, and the counter is reset to 0 when the temperature returns to the normal range; when the counter accumulates to 3 consecutively, the corresponding warning level is triggered.
5. The intelligent disease early warning method according to claim 1, characterized in that: Before the judgment in step (e), the original temperature data is first subjected to sliding window filtering. The window size is 5 samples, and the median value within the window is taken as the current valid temperature value to participate in the deviation calculation, so as to eliminate the instantaneous abnormal temperature readings caused by sows rubbing against the pen or lying down and being compressed.
6. The intelligent disease early warning method according to claim 1, characterized in that: After step (f) triggers the warning, the following linkage operations are further performed: (i) the pregnancy check result field (pregnancy.checkResult) of the corresponding sow in the breeding management system is updated to abnormal body temperature, and the last abnormal sampling time is marked; (ii) the pending warning count in the system console is automatically incremented by 1, and the latest warning list is refreshed in real time; (iii) according to the list of users whose department field in the user data table (users) of the breeding management system is the breeding center, SMS or in-app notifications are automatically pushed.
7. A standardized data communication method based on an Internet of Things (IoT) electronic ear tag and breeding management system, characterized in that: An XLMJ-IoT data communication protocol is defined between the ear tag device and the breeding management system. This protocol comprises three layers: (a) Physical layer communication: Supports handheld RFID readers to communicate with the breeding management system terminal via USB or Bluetooth BLE 5.
0. The RFID readers operate in the UHF band (920-925MHz) with an adjustable reading distance of 0-5m. Simultaneously, it supports fixed channel gate antennas to communicate with the system server via WiFi or Ethernet. The channel gate antenna is a dual-band antenna consisting of a 134.2kHz low-frequency LF and a 920MHz ultra-high-frequency UHF antenna. (b) Data layer communication: Defines a JSON-formatted data message structure. The uplink message (ear tag to system direction) includes the fields {chipId, earTag, temperature, sampleTime, batteryLevel, signalStrength}. The downlink message (system to ear tag direction) includes the fields {chipId, pregnancyStage, baselineTempLo, baselineTempHi, ...}. sampleInterval}; The message is encrypted and transmitted using the AES-128 symmetric encryption algorithm, and a CRC-16 cyclic redundancy check code is added to ensure data integrity; (c) Application layer communication: After receiving the uplink message, the system uses chipId as the index to look up the corresponding earTag record in the breeding pig file data table (breedStock), writes temperature and sampleTime into the temperature time series data table (temperatureLog), and then calls the early warning algorithm to make a judgment and writes it into the early warning data table (tmMonitor) when the early warning is triggered.
8. The standardized data communication method according to claim 7, characterized in that: When RFID radio frequency communication fails due to chip aging, antenna damage, or environmental electromagnetic interference, the system automatically switches to the backup identification channel: by scanning the DataMatrix QR code on the outer surface of the ear tag with a mobile terminal, the earTag number is decoded and obtained. Then, the complete breeding file and temperature history data of the corresponding sow are directly retrieved from the breeding management system using the earTag as an index, realizing automatic switching redundancy notification between radio frequency identification and optical identification channels.
9. The method according to claim 1 or 7, characterized in that: The breeding management system adopts a front-end single-page application (SPA) architecture, which includes six core data modules: breedstock, mating record management, pregnancy tracking management, piglet record management, genetic pedigree management, and tmMonitor. Each module uses ear tag or RFID chip ID as the main index to achieve data association, forming a closed loop of data for the entire life cycle from individual breeder records to mating records, pregnancy tracking, piglet birth, weaning, and genetic pedigree.
10. A method for digital management of the entire life cycle of sow breeding based on Internet of Things electronic ear tags, characterized in that, include: (a) Wearing Stage: A globally unique RFID chip ID-protected electronic ear tag is worn on the sow's ear. A one-to-one mapping between chipId and earTag is established in the breeding stock data table of the breeding management system. (b) Continuous Temperature Measurement Stage: The microcontroller built into the ear tag wakes up the temperature sensor at preset sampling intervals to collect the body surface temperature at the base of the ear. After filtering by a sliding window, the temperature sequence of the most recent 48 hours is locally cached. The microcontroller simultaneously calculates the 24-hour temperature mean and standard deviation, and the rate of temperature change offline. (c) Data Synchronization Stage: When a handheld RFID reader or the channel gate antenna enters the effective communication range, the ear tag device is automatically woken up. The temperature cache sequence is read in batches via the XLMJ-IoT data communication protocol, decrypted by AES-128, and... After CRC-16 verification, the data is written to the temperature time series data table (temperatureLog) of the breeding management system; (d) Intelligent early warning stage: The system uses chipId as the index to obtain the gestation stage information of the corresponding sow, loads the normal body temperature baseline range of the corresponding stage, calculates the temperature deviation value and the 24-hour temperature change rate, and automatically triggers graded early warning when the deviation exceeds the corresponding threshold for 3 consecutive times, and writes the early warning record to the early warning data table (tmMonitor) of the breeding management system; (e) Full life cycle traceability stage: The system uses earTag or chipId as the index to link all the breeding files of the sow: pedigree → mating record → gestation stage → litter of piglets → genetic lineage → body temperature history curve, so as to realize digital breeding management of the entire life cycle under one standard.
