Medical consumable supervision and distribution interconnection system based on industrial gateway

CN122889291APending Publication Date: 2026-10-09TIANJIN YUANXINCHENG TECHNOLOGY DEVELOPMENT CO LTD
View PDF 0 Cites 0 Cited by

Patent Information

Application Number
CN202610951263.3
Authority / Receiving Office
CN · China
Patent Type
Applications(China)
Current Assignee / Owner
Filing Date
2026-06-29
Publication Date
2026-10-09

AI Technical Summary

Technical Problem

[0004]本发明提供一种基于工业网关的医疗耗材监管配送互联互通系统,解决现有技术中缺乏有效数据互通机制导致监管链路存在信息断点、难以实现耗材从出库到患者使用全流程状态完整追溯及实时交通路况、车辆状态、库存等动态信息进行互联互通灵活调整的技术问题

Benefits of technology

[0015]本发明的有益效果在于:本发明通过工业网关的第一协议适配单元和第二协议适配单元分别解析院内智能库和院外配送终端采用的不同通信协议,实现跨域协议适配和数据互通,消除了监管链路中的信息断点;通过唯一追溯码将院内流通记录与院外流通记录进行关联绑定并按时间顺序拼接,构建覆盖耗材从出库到患者使用全流程状态的端到端追溯数据链,实现耗材全生命周期追溯;通过配送任务优先级评估模型对库存余量、耗材消耗速率、科室紧急程度和运输距离等多维特征进行综合评估,根据优先级结果生成包含配送顺序指令、路径重规划指令和时间调整指令的动态配送调度指令集,实现基于实时动态信息的灵活调度;通过指令间协调控制机制和执行状态反馈机制,建立从数据采集、决策生成、指令执行到结果反馈的医疗耗材监管配送互联互通体系,根据执行效果动态调整调度策略,实现持续优化。

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN122889291A_ABST
    Figure CN122889291A_ABST
Patent Text Reader

Abstract

The application relates to the technical field of material supervision and distribution, and discloses a medical consumable supervision and distribution interconnection system based on an industrial gateway, which comprises an industrial gateway protocol adaptation unit, which is used for analyzing consumable warehouse-out data and extracting logistics transportation data, realizing cross-domain protocol adaptation and data interconnection, and eliminating supervision link information breakpoints; in the application, in-hospital circulation records and out-of-hospital circulation records are associated and bound through unique traceability codes and are spliced in time sequence, an end-to-end traceability data chain covering the whole process state of consumables from warehouse-out to patient use is constructed, multi-dimensional features such as inventory reserves, consumable consumption rates, department emergency levels and transportation distances are comprehensively evaluated, dynamic distribution scheduling instruction sets containing distribution sequence instructions, path re-planning instructions and time adjustment instructions are generated according to priority results, and flexible scheduling based on real-time dynamic information is realized.
Need to check novelty before this filing date? Find Prior Art

Description

Technical Field

[0001] This invention relates to the field of material monitoring and distribution technology, and more specifically, to an interconnected system for monitoring and distributing medical consumables based on an industrial gateway. Background Technology

[0002] The supervision and distribution of medical consumables is a crucial aspect of the operation and management of medical institutions. It is widely used in hospital consumable inventory management and logistics traceability, ensuring the supply of surgical consumables, laboratory reagents, and disposable medical devices. With the improvement of medical informatization and the increase in consumable usage, the supervision and distribution of medical consumables face higher requirements and challenges. The lack of an effective data exchange mechanism between the hospital's SPD (Supply, Delivery, and Processing) system and the external logistics platform leads to information "breakpoints" in the supervision chain, making it difficult to achieve complete traceability of consumables from issuance to patient use. Simultaneously, existing distribution scheduling methods mainly rely on static rules to trigger alarms. Real-time traffic conditions, vehicle status, and inventory information are insufficient to meet the real-time interconnectivity planning needs of multi-variety, small-batch, and high-frequency distribution scenarios, easily leading to problems such as unreasonable distribution route planning and untimely scheduling, affecting the supply efficiency and the integrity of medical consumable supervision.

[0003] Therefore, how to achieve cross-domain protocol adaptation and end-to-end traceability, and possess dynamic delivery scheduling capabilities, in order to improve the intelligence and informatization level of medical consumable supervision, has become an urgent technical problem to be solved in the interconnection system for medical consumable supervision and distribution. Summary of the Invention

[0004] This invention provides a medical consumables supervision and distribution interconnection system based on an industrial gateway, which solves the technical problems in the prior art that the lack of an effective data interoperability mechanism leads to information breakpoints in the supervision link, makes it difficult to achieve complete traceability of the status of consumables from the time of leaving the warehouse to the time of patient use, and makes it difficult to flexibly adjust the interconnection of dynamic information such as real-time traffic conditions, vehicle status, and inventory.

[0005] This invention provides a medical consumables monitoring and distribution interconnection system based on an industrial gateway, comprising: Establish communication links between the industrial gateway and the intelligent warehouse within the institute and the delivery terminal outside the institute. Use the corresponding protocol adaptation unit to parse the communication protocols of each link and collect consumable outbound data and logistics transportation data from multiple sources. Standardize and preprocess consumable outbound data and logistics transportation data, convert heterogeneous data formats into a preset intermediate data format, and combine them with unique traceability codes to complete the association and binding of internal and external circulation records. By linking and binding the in-hospital circulation records with the out-of-hospital circulation records using a unique traceability code, an end-to-end traceability data chain covering the entire process of consumables from delivery to patient use is constructed. Real-time data collection of intelligent inventory balance, RFID access door consumable circulation data, and vehicle terminal delivery status data are collected. The standardized multi-source data is then input into the delivery task priority evaluation model, and the delivery task priority results are output. Based on the delivery task priority results, a structured dynamic delivery scheduling instruction set is generated, which includes delivery sequence instructions, route replanning instructions, and time adjustment instructions. A mechanism for issuing and executing instructions based on a dynamic delivery scheduling instruction set is established to send scheduling instructions to delivery terminals, in-hospital smart warehouses, and RFID access gates in real time, so as to coordinate the delivery of consumables through interconnection.

[0006] Furthermore, a first communication link is established between the industrial gateway and the intelligent warehouse within the facility, and a second communication link is established between the industrial gateway and the off-site distribution terminal; the first communication link adopts a first preset communication protocol, and the second communication link adopts a second preset communication protocol; The first protocol adaptation unit of the industrial gateway parses the first preset communication protocol and extracts the output consumables outbound data; the consumables outbound data includes consumables category identifier, outbound quantity, outbound time and target department information; The second protocol adaptation unit of the industrial gateway parses the second preset communication protocol and extracts the logistics transportation data output by the off-site logistics platform; the logistics transportation data includes the vehicle identification, transportation route information, current location coordinates and estimated arrival time.

[0007] Furthermore, the first protocol adaptation unit of the industrial gateway parses the first preset communication protocol and extracts the output consumable outbound data, including: When the first port of the first protocol adapter unit detects that data has arrived at a preset event, the first protocol adapter unit reads the original data stream from the data buffer. The data is the original message in HL7 format transmitted by the hospital's intelligent warehouse through the first communication link. The original message includes the consumable category identifier, the quantity issued, the issuance time, and the target department information. The preset events include a data frame arrival event triggered when the number of bytes accumulated in the receive buffer reaches a preset length threshold of the original message, a message boundary detection event triggered when the original message terminator is detected, and a timeout fallback event triggered when there is no new data in the buffer within a preset waiting time window. The first protocol adaptation unit performs protocol frame parsing on the original data stream to identify the message header, message body and message trailer of the original message; Extract the key fields of the MSH, PAT, and OBR segments from the parsed HL7 message body; The extracted key fields are mapped to a preset data structure template to generate a structured consumables outbound data object.

[0008] Furthermore, the first protocol adaptation unit performs protocol frame parsing on the original data stream, identifying the message header, message body, and message trailer of the original message, including: Detect the MLLP encapsulation flags in the data stream of the original message, using the start byte 0x0B as the message frame start delimiter and the end byte sequence 0x1C-0x0D as the message frame end delimiter; Extracting the byte sequence between the two delimiters completes the MLLP encapsulation layer stripping, yielding the original message byte stream; The message byte stream is segmented using the carriage return character 0x0D as the segment delimiter. The first segment starting with MSH is identified as the message header, and the field delimiter, component delimiter, and repetition delimiter are extracted from the Nth byte of the MSH segment as the basis rules for parsing. All segments from the MSH segment to the termination delimiter are identified as the message body, the last segment in the message body is identified as the message tail, and each segment of the message body is classified and labeled according to the segment name prefix.

[0009] Furthermore, the data structure of the unique traceability code is defined as a string encoding of a preset number of digits; the first a digits of the string encoding are the manufacturer code, the middle b digits are the batch number, the following c digits are the production date, and the last d digits are the serial number. When a new batch of consumables is received, the smart warehouse in the institute sends a consumables receipt request message to the industrial gateway. The industrial gateway's encoding generation unit receives consumable warehousing request messages and extracts manufacturer information, batch information, and production date information from the messages; The coding generation unit assigns an incrementing serial number to each smallest sales unit of the batch of consumables according to a preset serial number generation rule; The coding generation unit combines the manufacturer code, batch number, production date, and serial number according to a preset splicing format to generate a unique traceability code, and writes the unique traceability code into the tag chip.

[0010] Furthermore, the consumable category identifier, quantity, time and target department information are extracted from the parsed consumable outbound data object. The corresponding traceability code record is retrieved in the unique traceability code database using the consumable category identifier as the primary key, thus completing the field-level primary key alignment. Using the unique traceability code as a foreign key, the aligned outbound data field is associated and bound with the traceability code record, and the current timestamp is written as the binding time to obtain the binding result; The binding result is encapsulated into a structured intra-hospital circulation record object containing a unique traceability code, consumable category identifier, outbound quantity, outbound time, target department information, and binding timestamp. The integrity of each required field is verified, and the record is written to the traceability database after the verification is successful.

[0011] Furthermore, using the unique traceability code as the index key, the in-hospital circulation record set and the out-of-hospital circulation record set are queried from the traceability database respectively. The traceability code field of the two types of records is compared for consistency, and records with mismatched traceability codes or abnormal formats are filtered out to obtain the valid in-hospital circulation record set and the valid out-of-hospital circulation record set. Based on the valid in-hospital circulation record set and the valid out-of-hospital circulation record set, the binding timestamp and transportation timestamp of each record are extracted. All record nodes are sorted in ascending order with a unified time base, and timestamp anomalies caused by clock deviation are corrected to obtain an ordered set of record nodes with monotonically increasing time sequence. Based on the ordered set of record nodes, the in-hospital circulation record nodes and the out-of-hospital circulation record nodes are merged into a unified traceability record item according to a preset splicing mode. The in-hospital circulation record nodes and the out-of-hospital circulation record nodes are sequentially spliced ​​together using a unique traceability code as a foreign key to obtain an ordered node sequence. Based on the ordered node sequence, coverage detection is performed on each key node of outbound, off-hospital transportation, in-hospital reception, departmental requisition, and patient use to verify whether each key node has a corresponding record. For missing nodes, a preset abnormal status code is written and an alarm is triggered to obtain a node sequence carrying the integrity detection result. Based on the node sequence carrying integrity detection results, the splicing result is encapsulated into an end-to-end traceability data chain object containing a unique traceability code, a set of records for each node, node integrity detection results, and chain generation timestamp.

[0012] Furthermore, by establishing real-time data acquisition channels with the smart warehouse, RFID access gate, and vehicle terminal through the industrial gateway, the remaining data of the smart warehouse, the consumable circulation data of the RFID access gate, and the delivery status data of the vehicle terminal are retrieved synchronously according to the preset acquisition cycle to obtain a multi-source raw dataset containing the acquisition timestamp. Based on the multi-source original dataset, preprocessing operations such as deduplication, missing value filling and format verification are performed on each data item, and the heterogeneous data format is uniformly converted into a preset intermediate data format to obtain a standardized multi-source dataset. Based on the standardized multi-source dataset, four types of feature parameters are extracted: inventory balance, consumable consumption rate, departmental urgency, and transportation distance, to construct a feature vector for the delivery task. The feature vectors of each delivery task are input into the delivery task priority evaluation model. The model calculates the priority score of each delivery task based on the weight coefficients of each feature parameter, thus obtaining the priority result of each delivery task.

[0013] Furthermore, based on the delivery task priority results, a structured dynamic delivery scheduling instruction set is generated, including delivery sequence instructions, route replanning instructions, and time adjustment instructions, including: Based on the priority ranking of each delivery task, the delivery tasks to be executed are sorted from high to low according to their priority scores to generate a delivery sequence instruction; the delivery sequence instruction includes the task number, priority level, and execution sequence number. Based on the delivery sequence instructions, combined with real-time traffic data and the vehicle's current location coordinates, the driving routes of each delivery task are dynamically replanned to generate route replanning instructions; the route replanning instructions include a starting node, a sequence of nodes along the route, an ending node, and an estimated driving distance. Based on the estimated mileage in the route replanning instruction, combined with the vehicle's average speed and dwell time at each node, the estimated arrival time and estimated completion time of each delivery task are calculated, and a time adjustment instruction is generated; the time adjustment instruction includes the estimated arrival timestamp of each node and the estimated completion timestamp of the task. According to the preset instruction encapsulation format, delivery sequence instructions, route replanning instructions, and time adjustment instructions are associated with the corresponding task numbers and encapsulated into a structured dynamic delivery scheduling instruction set, with an instruction generation timestamp and instruction version number attached.

[0014] A computer-readable storage medium is characterized in that it is used to store computer-readable instructions, which, when read by a computer, enable the operation of the aforementioned medical consumables supervision and distribution interconnection system based on an industrial gateway.

[0015] The beneficial effects of this invention are as follows: This invention uses the first and second protocol adaptation units of the industrial gateway to parse the different communication protocols used by the in-hospital intelligent warehouse and the out-of-hospital delivery terminal, respectively, to achieve cross-domain protocol adaptation and data interoperability, eliminating information breakpoints in the regulatory link; it uses a unique traceability code to associate and bind in-hospital circulation records with out-of-hospital circulation records and splice them in chronological order, constructing an end-to-end traceability data chain covering the entire process of consumables from warehousing to patient use, achieving full lifecycle traceability of consumables; it uses a delivery task priority evaluation model to comprehensively evaluate multi-dimensional characteristics such as inventory balance, consumable consumption rate, departmental urgency, and transportation distance, generating a dynamic delivery scheduling instruction set including delivery sequence instructions, route replanning instructions, and time adjustment instructions based on the priority results, achieving flexible scheduling based on real-time dynamic information; and it establishes an interconnected system for medical consumables supervision and delivery from data collection, decision generation, instruction execution to result feedback through an inter-instruction coordination and control mechanism and an execution status feedback mechanism, dynamically adjusting the scheduling strategy according to the execution effect to achieve continuous optimization. Attached Figure Description

[0016] Figure 1 This is a schematic diagram of a medical consumables supervision and distribution interconnection system based on an industrial gateway, provided in an embodiment of the present invention; Figure 2 This is a schematic diagram of the overall system architecture provided in an embodiment of the present invention; Figure 3 This is a schematic diagram of the internal structure of an industrial gateway provided in an embodiment of the present invention; Figure 4 This is a schematic diagram of the dynamic delivery scheduling module provided in an embodiment of the present invention. Detailed Implementation

[0017] The subject matter described herein will now be discussed with reference to exemplary embodiments. It should be understood that these embodiments are discussed only to enable those skilled in the art to better understand and implement the subject matter described herein, and changes may be made to the function and arrangement of the elements discussed without departing from the scope of this specification. Various processes or components may be omitted, substituted, or added as needed in the examples. Furthermore, some features described in the examples may be combined in other examples.

[0018] At least one embodiment of the present invention discloses a medical consumables monitoring and distribution interconnection system based on an industrial gateway, comprising: like Figures 1-2 As shown, a medical consumables monitoring and distribution interconnection system based on an industrial gateway includes: Step 1: Establish communication links between the industrial gateway and the intelligent warehouse within the facility and the delivery terminal outside the facility. Parse the communication protocols of each link through the corresponding protocol adaptation unit and collect consumable outbound data and logistics transportation data from multiple sources. Step 2: Standardize and preprocess the consumables outbound data and logistics transportation data, and convert the heterogeneous data formats into a preset intermediate data format, and complete the association and binding of internal and external circulation records with the unique traceability code; Step 3: Connect the associated and bound in-hospital circulation records with the out-of-hospital circulation records using a unique traceability code to build an end-to-end traceability data chain covering the entire process of consumables from delivery to patient use; Step 4: Collect in real time data on the hospital's intelligent inventory balance, RFID access gate consumable circulation data, and vehicle terminal delivery status data. Input the standardized multi-source data into the delivery task priority evaluation model and output the delivery task priority results. Step 5: Based on the delivery task priority results, generate a structured dynamic delivery scheduling instruction set containing delivery sequence instructions, route replanning instructions, and time adjustment instructions; Step 6: Establish an instruction issuance and execution status feedback mechanism based on the dynamic delivery scheduling instruction set, and issue scheduling instructions to delivery terminals, in-hospital smart warehouses and RFID access gates in real time to schedule consumables delivery through interconnection.

[0019] The schematic diagram of the overall architecture of the medical consumables supervision and distribution interconnection system based on an industrial gateway provided in this embodiment of the invention clearly shows the components of the entire system and the data flow relationships between them. The system uses the industrial gateway as the core data processing and communication hub, establishing communication connections with the hospital's intelligent warehouse, off-site delivery terminals, RFID access gates, and vehicle-mounted terminals, forming a complete data collection and transmission network covering both in-hospital and off-site logistics.

[0020] In the system architecture, the industrial gateway's first communication interface establishes a physical connection with the hospital's intelligent warehouse via a first communication link. This first communication link uses a first preset communication protocol for data transmission, typically the HL7 protocol commonly used in the medical field. The industrial gateway's second communication interface establishes a physical connection with the off-site delivery terminal via a second communication link. This second communication link uses a second preset communication protocol for data transmission, typically the JSON or XML format commonly used in the logistics field. A real-time data acquisition channel is established between the industrial gateway and the RFID access gate to collect consumable flow data. A real-time data acquisition channel is also established between the industrial gateway and the vehicle-mounted terminal to collect delivery status data.

[0021] The data flow of the entire system follows this logic: Consumable outbound data generated by the intelligent warehouse within the facility is transmitted to the industrial gateway via the first communication link, where the first protocol adaptation unit performs protocol parsing and data extraction; Logistics transportation data generated by the off-site delivery terminal is transmitted to the industrial gateway via the second communication link, where the second protocol adaptation unit performs protocol parsing and data extraction; Consumable circulation data collected by the RFID access gate is directly uploaded to the industrial gateway for data processing; Delivery status data collected by the vehicle terminal is also uploaded to the industrial gateway for comprehensive analysis.

[0022] Internal structure and module layout of industrial gateway Reference Figure 3 The schematic diagram of the internal structure of the industrial gateway provided in this embodiment of the invention shows a detailed understanding of the layout and connection relationships of the various functional modules inside the industrial gateway. The industrial gateway mainly includes a first protocol adaptation unit, a second protocol adaptation unit, an encoding generation unit, a first communication interface, a second communication interface, and a data buffer, among other components.

[0023] The first protocol adaptation unit is located inside the industrial gateway near the first communication interface. Its main function is to parse the first preset communication protocol data transmitted through the first communication link. In this embodiment, the first preset communication protocol is HL7. Therefore, the first protocol adaptation unit integrates an HL7 protocol parser, which can identify the message header, message body, and message trailer in the HL7 message format and extract key fields of the MSH, PAT, and OBR segments. The first port of the first protocol adaptation unit establishes a connection with the data buffer. When a preset event is detected, the unit reads the original data stream from the data buffer for parsing and processing.

[0024] The second protocol adapter unit is located inside the industrial gateway, near the second communication interface. Its main function is to parse the second preset communication protocol data transmitted through the second communication link. In this embodiment, the second preset communication protocol is the JSON format protocol commonly used in the logistics field. The second protocol adapter unit integrates a JSON protocol parser, which can extract logistics and transportation-related data from JSON format messages. The second port of the second protocol adapter unit also establishes a connection with the data buffer to realize data reception and parsing.

[0025] The coding generation unit is located in the core area of ​​the industrial gateway. It establishes data connections with both the first and second protocol adaptation units to generate unique traceability codes when consumables are received into the warehouse. After receiving a consumable receipt request message from the intelligent warehouse within the institute, the coding generation unit extracts the manufacturer information, batch information, and production date information from the message. It then assigns an incrementing serial number to each smallest sales unit according to a preset serial number generation rule. Finally, it combines the manufacturer code, batch number, production date, and serial number according to a preset concatenation format to generate a unique traceability code. The preset concatenation format is a fixed-length, unseparated sequential concatenation, which consists of a 6-digit manufacturer code, an 8-digit batch number (the last 2 digits of the year + a 6-digit batch serial number), an 8-digit production date (in the format YYYYMMDD), and a 6-digit serial number (incrementing sequentially from 000001 within the same batch). If any segment is insufficient in length, it is padded with 0s on the left. The concatenated code generates a 28-digit unique traceability code string.

[0026] A data buffer is located inside the industrial gateway to temporarily store raw data received from the first and second communication links. The data buffer establishes data exchange connections with the first port of the first protocol adapter unit and the second port of the second protocol adapter unit, respectively, to realize the functions of data storage and forwarding.

[0027] The first communication interface is located on the external left side of the industrial gateway and is used to establish a physical connection with the intelligent warehouse within the facility. It establishes a signal transmission channel with the first protocol adapter unit via an internal bus. The second communication interface is located on the external right side of the industrial gateway and is used to establish a physical connection with the off-site delivery terminal. It establishes a signal transmission channel with the second protocol adapter unit via an internal bus.

[0028] Communication link establishment and data acquisition process During system operation, the first step is to establish a primary communication link between the industrial gateway and the intelligent warehouse within the facility, as well as a secondary communication link between the industrial gateway and the off-site delivery terminal. The communication link establishment module is responsible for coordinating the establishment of these two communication links.

[0029] The specific process of establishing a communication link by the communication link establishment module is as follows: First, the first communication interface of the industrial gateway is configured to establish a physical connection with the intelligent warehouse inside the facility. Electrical connection is achieved through physical transmission media such as network cables or optical fibers. After successful connection, the first communication link uses the first preset communication protocol for data transmission. Then, the second communication interface of the industrial gateway is configured to establish a physical connection with the delivery terminal outside the facility. Wireless connection is achieved through 4G / 5G mobile networks or satellite communication. After successful connection, the second communication link uses the second preset communication protocol for data transmission. Finally, the initialization configuration of the first protocol adaptation unit and the second protocol adaptation unit is completed inside the industrial gateway, enabling them to correctly process the corresponding communication protocol data.

[0030] After the first communication link is successfully established, the hospital's intelligent warehouse begins sending consumable outbound data to the industrial gateway. This data is transmitted in raw HL7 format, and the message contains key fields such as consumable category identifier, outbound quantity, outbound time, and target department information. The first protocol adaptation unit continuously monitors the reception status of the data buffer through the first port. When a preset event is detected, it reads the raw data stream from the data buffer for parsing and processing.

[0031] The first protocol adaptation unit detects three types of preset events: the first is a data frame arrival event triggered when the accumulated number of bytes in the receive buffer reaches the preset length threshold of the original message (the preset length threshold is set to 512 bytes); the second is a message boundary detection event triggered when the original message terminator is detected; and the third is a timeout fallback event triggered when there is no new data in the buffer within a preset waiting time window (the preset waiting time window is set to 500 milliseconds). When any preset event is triggered, the first protocol adaptation unit begins to execute the data parsing process.

[0032] The protocol frame parsing process of the first protocol adaptation unit for the original data stream includes the following specific steps: First, the MLLP encapsulation flag in the original message's data stream is detected, with the start byte as the message frame start delimiter and the end byte sequence as the message frame end delimiter; then, the byte sequence between the two delimiters is extracted to complete the MLLP encapsulation layer stripping, obtaining the message byte stream of the original message; next, the message byte stream is segmented using the carriage return as the segment separator, the first segment starting with MSH is identified as the message header, and the field separator, component separator, and repetition separator are extracted from the MSH segment as the baseline rules for subsequent parsing; then, all segment sequences after the MSH segment and before the end delimiter are identified as the message body, the last segment in the message body is identified as the message tail, and each segment of the message body is classified and labeled according to the segment name prefix; finally, the key fields of the MSH segment, PAT segment, and OBR segment are extracted from the parsed HL7 message body, and the extracted key fields are mapped to a preset data structure template to generate a structured consumable outbound data object; the preset data structure template contains eight fields: message unique control identifier (m The following are the data types: messageId (String, mapped from MSH.10), sending system identifier (sendingSystem, String, mapped from MSH.3), message generation timestamp (messageTimestamp, DateTime, format YYYYMMDDHHmmss, mapped from MSH.7), consumable category identifier (consumableCategoryId, String, mapped from OBR.4), outbound quantity (outboundQuantity, Integer, mapped from OBR.26), outbound time (outboundTime, DateTime, format YYYYMMDDHHmmss, mapped from OBR.7), target department code (targetDepartmentCode, String, mapped from PAT.3), and target department name (targetDepartmentName, String, mapped from PAT.5).

[0033] After the second communication link is successfully established, the off-site delivery terminal begins sending logistics transportation data to the industrial gateway. This data is transmitted in JSON format, containing key fields such as the logistics order number, vehicle information, current location coordinates, current time, and estimated arrival time. The second protocol adaptation unit reads the raw JSON message from the data buffer, first performs JSON format validation, and then extracts the logistics transportation data according to preset field mapping rules to generate a structured logistics transportation data object. The data structure template corresponding to the preset field mapping rules contains eight fields: logistics order number (orderId, String type, mapped from the JSON field order_id), vehicle identifier (vehicleId, String type, mapped from the JSON field vehicle.id), license plate number (vehiclePlate, String type, mapped from the JSON field vehicle.plate), and transportation route information (routeInfo, String type, mapped from the JSON field JSON). The N field contains route.description, current latitude coordinates (currentLatitude, Double type, mapped from the JSON field location.lat), current longitude coordinates (currentLongitude, Double type, mapped from the JSON field location.lng), current time (recordTimestamp, DateTime type, format YYYYMMDDHHmmss, mapped from the JSON field timestamp), and estimated arrival time (estimatedArrivalTime, DateTime type, format YYYYMMDDHHmmss, mapped from the JSON field eta).

[0034] Unique traceability code generation and data association binding When medical consumables enter the hospital's intelligent warehouse management system, the coding generation unit is responsible for generating a unique traceability code for each batch of consumables. The data structure of this unique traceability code is a 28-bit string encoding, where the first 6 bits are the manufacturer code, the middle 8 bits are the batch number, the next 8 bits are the production date (in the format YYYYMMDD), and the last 6 bits are the serial number.

[0035] The process of generating a unique traceability code is as follows: When a new batch of consumables is received, the intelligent warehouse within the facility sends a consumables receipt request message to the industrial gateway. This message contains information such as manufacturer information, batch information, production date information, and minimum sales unit quantity. The preset data structure template of the consumables receipt request message contains ten fields: unique identifier for receipt request (requestId, String type, format REQ+YYYYMMDDHHmmss+4-digit serial number), request initiation timestamp (requestTimestamp, DateTime type, format YYYYMMDDHHmmss), manufacturer code (manufacturerCode, String type, corresponding to the first 6 digits of the traceability code), manufacturer name (ma The serial number generation unit of the industrial gateway receives the consumable warehousing request message and extracts the manufacturer information, batch information, and production date information from the message as fixed components of the unique traceability code. Then, according to the preset serial number generation rules, the serial number generation unit assigns an incrementally increasing serial number to each minimum sales unit of the consumable in this batch, starting from 0001 and incrementing sequentially, ensuring that each minimum sales unit receives a unique serial number. (The serial numbers are: manufacturerName (String), batchNumber (String, format: last 2 digits of year + 6 digits of batch serial number), productionDate (String, format: YYYYMMDD), consumableCategoryId (String), consumableCategoryName (String), minimum sales unit count for this batch (minSalesUnitCount, Integer, determining the number of serial numbers generated), and storageLocation code (String). The coding generation unit combines the manufacturer code, batch number, production date, and serial number according to a preset splicing format to generate a unique traceability code, and writes the unique traceability code into the RFID tag chip associated with the corresponding consumable, thus completing the generation and binding of the unique traceability code.

[0036] The unique traceability code library stores all generated and assigned traceability code records. Each record includes fields such as traceability code number, manufacturer information, batch information, production date information, serial number information, tag chip number, and current status information. The unique traceability codes generated by the encoding generation unit are written to the unique traceability code library for storage management simultaneously with the tag chip.

[0037] The data preprocessing module is responsible for standardizing and preprocessing the collected consumable outbound data and logistics transportation data, converting various heterogeneous data formats into a preset intermediate data format, and combining it with a unique traceability code to complete the association and binding of internal and external circulation records. The preset intermediate data format includes two parts: a common header field and a type extension field. The common header field is shared by both types of data and includes the intermediate data unique identifier (dataId, String type, format DATA+YYYYMMDDHHmmss+6-digit serial number), data type identifier (dataType, enumeration type, value is OUTBOUND or LOGISTICS), source system identifier (sourceSystem, String type, SPD_WARD for internal intelligent warehouses, LOGISTICS for external distribution terminals), associated unique traceability code (traceCode, String type, 28-digit), intermediate data generation timestamp (createTimestamp, DateTime type, format YYYYMMDDHHmmss), and data format version number (dataVersion, current version is V1.0); OUTBOUND... The UND type extended fields include consumerCategoryId, outboundQuantity, outboundTime, targetDepartmentCode, and targetDepartmentName, which are mapped to OBR.4, OBR.26, OBR.7, PAT.3, and PAT.5 of the consumables outbound data structure template, respectively; the LOGISTICS type extended fields include orderId, vehicleId, currentLatitude, currentLongitude, recordTimestamp, and estimatedArrivalTime, which are mapped to order_id, vehicle.id, location.lat, location.lng, timestamp, and eta of the logistics transportation data structure template, respectively.

[0038] The detailed process of standardization and preprocessing is as follows: First, the consumable category identifier, quantity, time, and target department information are extracted from the parsed consumable outbound data object. Using the consumable category identifier as the primary key, the corresponding traceability code record is retrieved from the unique traceability code database, completing field-level primary key alignment. Then, the aligned outbound data fields are associated with the traceability code record using the unique traceability code as the foreign key, and the current timestamp is written as the binding time, yielding the binding result. Next, the binding result is encapsulated into a structured intra-hospital circulation record object containing the unique traceability code, consumable category identifier, quantity, time, target department information, and binding timestamp. Integrity checks are performed on each required field, and after successful verification, the data is written to the traceability database for storage.

[0039] For logistics and transportation data collected from off-site delivery terminals, the data preprocessing module follows a similar process. Using the logistics order number as the index key, it retrieves the corresponding traceability code record from the unique traceability code database. After aligning the primary keys at the field level, it associates and binds the transportation data fields with the traceability code record using the unique traceability code as the foreign key. This is then encapsulated into an off-site circulation record object containing fields such as unique traceability code, logistics order number, vehicle identifier, current location latitude and longitude coordinates, transportation timestamp (format: YYYYMMDDHHmmss), and estimated arrival time (format: YYYYMMDDHHmmss), and written to the traceability database for storage.

[0040] The data processing and traceability chain construction flowchart provided in this embodiment of the invention provides a detailed understanding of the traceability chain construction process. The traceability chain construction module is responsible for concatenating the associated and bound in-hospital circulation records and out-of-hospital circulation records using unique traceability codes to construct an end-to-end traceability data chain covering the entire process of consumables from warehousing to patient use.

[0041] The specific process of the traceability chain construction module in constructing the traceability data chain is as follows: The first step is to query the in-hospital circulation record set and the out-of-hospital circulation record set from the traceability database using the unique traceability code as the index key. The traceability code field of the two types of records is compared for consistency, and records with mismatched traceability codes or abnormal formats are filtered out to obtain the valid in-hospital circulation record set and the valid out-of-hospital circulation record set.

[0042] The second step involves extracting the binding timestamp and transportation timestamp of each record based on the valid in-hospital circulation record set and the valid out-of-hospital circulation record set. All record nodes are then sorted in ascending order using a unified time reference, and timestamp anomalies caused by clock deviations are corrected to obtain an ordered set of record nodes with monotonically increasing time sequence.

[0043] The third step involves merging the in-hospital circulation record nodes and the out-of-hospital circulation record nodes into a unified traceability record entry based on the ordered record node set and using a preset splicing pattern. The in-hospital circulation record nodes and the out-of-hospital circulation record nodes are then sequentially spliced ​​together using a unique traceability code as a foreign key to obtain an ordered node sequence.

[0044] The fourth step involves performing coverage checks on key nodes—outbound, outpatient transport, inpatient reception, departmental requisition, and patient use—based on an ordered node sequence. This verifies whether each key node has a corresponding record. For missing nodes, a preset abnormal status code is written and an alarm is triggered, resulting in a node sequence carrying the integrity check results. The preset abnormal status codes are categorized into seven types based on node type: missing outbound node records are written as ERR_NODE_001 (advanced alarm), missing outpatient transport node records are written as ERR_NODE_002 (advanced alarm), missing inpatient reception node records are written as ERR_NODE_003 (advanced alarm), and missing departmental requisition node records are written as ERR_NODE_004 (advanced alarm). 4 (Intermediate Alarm), missing patient usage node record written to ERR_NODE_005 (Intermediate Alarm), node timestamp does not meet monotonically increasing constraint written to ERR_NODE_006 (Advanced Alarm), node traceability code inconsistent with index traceability code written to ERR_NODE_007 (Advanced Alarm); the format of each abnormal status code includes five fields: node type identifier (nodeType), status code (statusCode), detection timestamp (detectedTimestamp, format YYYYMMDDHHmmss), alarm level (alertLevel), and abnormal description (description).

[0045] The fifth step involves encapsulating the splicing result into an end-to-end traceability data chain object based on the node sequence carrying the integrity detection result. This object contains a unique traceability code, a set of records for each node, the node integrity detection result, and a chain generation timestamp. The object is then written into the traceability database for storage and management.

[0046] Through the aforementioned traceability chain construction process, the system enables full-process tracking of each medical consumable from its issuance to patient use. Users can query the circulation status of consumables at any point in time using a unique traceability code, ensuring that the source and destination of consumables are traceable and effectively improving the level of supervision of medical consumables.

[0047] Dynamic delivery scheduling and real-time data collection Reference Figure 4 The flowchart of the dynamic delivery scheduling module provided in this embodiment of the invention illustrates the implementation process of dynamic delivery scheduling in detail. The dynamic scheduling module is responsible for collecting multi-source data in real time and evaluating the priority of delivery tasks, ultimately generating a dynamic delivery scheduling instruction set.

[0048] The dynamic scheduling module performs real-time data acquisition as follows: First, it establishes real-time data acquisition channels with the intelligent warehouse, RFID access gate, and vehicle-mounted terminal through the industrial gateway. It then synchronously retrieves data on the remaining inventory of the intelligent warehouse, the consumable circulation data from the RFID access gate, and the delivery status data from the vehicle-mounted terminal according to a preset acquisition cycle, obtaining a multi-source raw dataset containing acquisition timestamps. The preset acquisition cycle can be set to different durations such as 5 seconds, 10 seconds, or 30 seconds according to actual needs; the system default acquisition cycle is 10 seconds. The hospital's intelligent inventory balance data includes consumable category identifier (consumableCategoryId), current inventory balance (currentStock, Integer type, unit is piece), inventory alert threshold (stockAlertThreshold, Integer type, unit is piece), storage location code (storageLocation), and collection timestamp (collectTimestamp, format YYYYMMDDHHmmss); the RFID access gate consumable flow data includes RFID tag number (rfidTagId), associated unique traceability code (traceCode, 28 bits), and flow direction (flowDirection). The enumeration type has values ​​of IN or OUT, gate number (gateId), and flow timestamp (flowTimestamp, format YYYYMMDDHHmmss); the vehicle terminal delivery status data includes vehicleId, current latitude coordinates (currentLatitude, Double type), current longitude coordinates (currentLongitude, Double type), delivery status (deliveryStatus, enumeration type, values ​​of EN_ROUTE, ARRIVED, or ABNORMAL), and collection timestamp (collectTimestamp, format YYYYMMDDHHmmss).Then, based on the multi-source original dataset, preprocessing operations such as deduplication, missing value imputation, and format validation are performed on each data item, and the heterogeneous data formats are uniformly converted into a preset intermediate data format to obtain a standardized multi-source dataset. The deduplication operation deletes duplicate records using the combined unique key of the data source identifier, collection timestamp, and primary key field. The missing value imputation operation fills missing numeric fields with 0, fills missing enumeration fields with default values ​​(deliveryStatus is filled with EN_ROUTE by default), and fills missing DateTime fields with the current system timestamp. The format validation operation verifies the latitude and longitude coordinate range (latitude range is -90° to 90°, longitude range is -180° to 180°), the DateTime field format (YYYYMMDDHHmmss), and the length of the unique traceability code (28 bits). Records that do not conform to the rules are written with ERR_NODE_006 status code and are discarded after triggering an alarm.

[0049] The dynamic scheduling module performs delivery task priority evaluation as follows: First, based on a standardized multi-source dataset, four types of feature parameters are extracted: inventory balance, consumable consumption rate, departmental urgency, and transportation distance, to construct feature vectors for delivery tasks. The inventory balance feature parameter is extracted from real-time inventory data in the hospital's intelligent warehouse, reflecting the current inventory level of each type of consumable. The consumable consumption rate feature parameter is calculated from consumable flow data at RFID access gates, reflecting the consumption rate of various consumables in each department. The departmental urgency feature parameter is obtained from the hospital information system, reflecting the urgency level of each department. The transportation distance feature parameter is calculated from the location data of the vehicle terminal combined with the hospital's layout map, reflecting the driving distance from the delivery point to the target department. Then, the feature vectors of each delivery task are input into the delivery task priority evaluation model. The model calculates the priority score for each delivery task based on the weight coefficients of each feature parameter, obtaining the priority ranking results for each delivery task. The delivery task priority evaluation model can be implemented using various evaluation methods such as weighted scoring algorithms, analytic hierarchy process (AHP), or machine learning algorithms.

[0050] The process of generating a structured dynamic delivery scheduling instruction set by the dynamic scheduling module is as follows: Based on the priority ranking results of each delivery task, the delivery tasks to be executed are sorted from high to low according to their priority scores, and a delivery sequence instruction is generated. This delivery sequence instruction includes the task number (taskId, format: TASK+YYYYMMDDHHmmss+4-digit serial number), priority score (priorityScore, Double type, value range: 0.00 to 100.00), priority level (priorityLevel, enumeration type, value HIGH for scores ≥80, value MEDIUM for scores 50 to 79, value LOW for scores below 50), and execution sequence number (executeSequence, Integer type, incrementing from 1 according to the score from high to low). Based on delivery sequence instructions, combined with real-time traffic data and vehicle current location coordinates, the driving routes of each delivery task are dynamically replanned, generating a route replanning instruction. This instruction includes the associated task number (taskId), the start node code (startNode, delivery departure location code), the route node sequence (waypointSequence, an ordered array of transit node codes), the end node code (endNode, target department location code), and the estimated distance (estimatedMileage, a Double type, in meters). Based on the estimated distance in the route replanning instruction, combined with the vehicle's average speed and the dwell time at each node, the estimated arrival time and estimated completion time of each delivery task are calculated, generating a time adjustment instruction. This instruction includes the associated task number (taskId), an array of estimated arrival timestamps for each node (nodeArrivalTimes, each item containing the node code nodeId and the estimated arrival time eta, in the format YYYYMMDDHHmmss), and the estimated completion timestamp (taskCompletionTime, in the format YYYYMMDDHHmmss). According to the preset instruction encapsulation format, delivery sequence instructions, route replanning instructions, and time adjustment instructions are associated with the corresponding task numbers and encapsulated into a structured dynamic delivery scheduling instruction set. The instruction set is then appended with a unique identifier (instructionSetId, in the format INST+YYYYMMDDHHmmss+3-digit serial number), an instruction generation timestamp (generateTimestamp, in the format YYYYMMDDHHmmss), and an instruction version number (instructionVersion, the current version is V1.0).

[0051] Command issuance and execution status feedback mechanism The schematic diagram of the instruction issuance and execution status feedback mechanism provided in this embodiment of the invention can provide a detailed understanding of the implementation process of the entire closed-loop control system. The instruction execution module is responsible for establishing the instruction issuance and execution status feedback mechanism based on the dynamic delivery scheduling instruction set, and for issuing scheduling instructions to delivery terminals, in-hospital intelligent warehouses, and RFID access gates in real time.

[0052] The specific process by which the instruction execution module establishes an instruction issuance and execution status feedback mechanism is as follows: First, based on the control instruction set, the type, timestamp, and unique number information of each instruction are extracted. The order, dependencies, and conflicts between instructions are analyzed to obtain the analysis results.

[0053] Then, based on the analysis results, a timing constraint matrix for instruction execution is constructed to clarify the execution order and dependencies of each instruction. The timing constraint matrix is ​​a two-dimensional matrix used to describe the time constraint relationships between instructions, and the elements in the matrix represent the time interval requirements between corresponding instruction pairs.

[0054] Next, based on the timing constraint matrix, conflict detection is performed on the control instruction set. If conflicts exist, they are eliminated and the instruction execution order is optimized by adjusting the instruction execution time, modifying parameters, or reordering. Conflict detection mainly checks for issues such as overlapping time windows, resource contention, or logical contradictions.

[0055] Then, based on the optimized instruction sequence, a final control instruction set with timing dependencies is generated, and an instruction execution plan is formulated. The instruction execution plan details the execution timing, execution order, and execution conditions for each instruction.

[0056] Next, real-time data is collected on the equipment's operational status, changes in logistics parameters, and the system's operational performance during the execution of control commands, yielding feedback data. Equipment operational status includes the execution status of delivery terminals, the response status of the smart warehouse within the facility, and the opening and closing status of RFID access gates; changes in logistics parameters include changes in vehicle location, inventory, and transportation status; and system operational performance includes order completion rate, on-time delivery rate, and anomaly alarms.

[0057] Subsequently, the collected feedback data is processed and verified, abnormal data is filtered, and valid feedback information is generated. The filtering of abnormal data is mainly based on comparison with preset threshold ranges (vehicle position deviation exceeding 500 meters, change in inventory balance of a certain type of consumables exceeding 30% of the current inventory balance of that type within a single collection cycle, and command response delay exceeding 3 seconds) and historical data.

[0058] Next, the feedback information is compared with the expected control target to obtain the execution deviation and success rate of each control command. The comparison is carried out in three dimensions: In the time dimension, the actual arrival timestamps of each node reported by the vehicle terminal are compared with the eta of each node in the time adjustment command, and the actual task completion timestamps are compared with taskCompletionTime to calculate the arrival deviation and task completion deviation of each node; In the path dimension, the actual flow node sequence reported by the RFID channel gate is compared with the waypointSequence in the path replanning command to count the proportion of missing nodes to the total number of planned nodes, and the actual driving mileage calculated by GPS trajectory is compared with estimatedMileage; In the execution status dimension, it is verified whether the deliveryStatus reported by the vehicle terminal is ARRIVED and has no ERR_NODE abnormal status code, and the command response delay is counted to be within 3 seconds. A single instruction is considered successfully executed if it simultaneously meets three conditions: execution deviation not exceeding 15%, no missing nodes along the path, and instruction response delay not exceeding 3 seconds. If any one of these conditions is not met, it is considered a failed execution. Execution deviation reflects the degree of difference between the actual execution result and the expected control target, while success rate reflects the probability that the instruction is executed correctly.

[0059] Then, based on the degree of execution deviation and the success rate, the triggering conditions for the automatic error correction mechanism are obtained. When the execution deviation exceeds a preset threshold (15%) or the success rate is lower than a preset standard (95%), the automatic error correction mechanism will be triggered; the execution deviation is the percentage of the difference between the actual task completion time and the planned completion time to the total planned time of the task, that is, the deviation between the actual completion time and taskCompletionTime divided by the difference between taskCompletionTime and generateTimestamp and then multiplied by 100%; the success rate is the percentage of the number of instructions with no abnormal termination, no timeout, and no error response within the statistical period (1 hour) to the total number of instructions issued in the same period.

[0060] Finally, dynamic compensation is achieved by triggering an automatic error correction mechanism to regenerate control commands, forming a medical consumables supervision and distribution control system from state perception, decision generation, command execution to result feedback. The automatic error correction mechanism dynamically adjusts the scheduling strategy based on current execution deviations and success rate data, combined with the latest real-time data, regenerates optimized control commands, and then reissues them for execution through the command execution module.

[0061] Collaborative workflow between system modules An organic collaborative working relationship is established among the communication link establishment module, data acquisition module, data preprocessing module, traceability chain construction module, dynamic scheduling module, and instruction execution module to form a complete interconnected system for the supervision and distribution of medical consumables.

[0062] After the system starts up, the communication link establishment module first performs the initialization of communication links, establishing the first and second communication links with the in-hospital intelligent warehouse and the out-of-hospital delivery terminal, respectively. After the communication links are successfully established, the system enters the data acquisition phase.

[0063] The data acquisition module continuously collects raw data from the first and second communication links and stores the data in a data buffer for parsing by the protocol adaptation unit. The continuous acquisition adopts an event-driven approach. On the first communication link, when one of the following three preset events is detected—a complete data frame arrival event (the accumulated number of bytes in the buffer reaches 512 bytes), a message boundary detection event (the MLLP terminator 0x1C 0x0D is detected), or a timeout fallback event (no new data in the buffer within 500 milliseconds)—the raw data stream is written to the data buffer. Similarly, on the second communication link, the module listens for JSON message arrival events and writes the data to the data buffer. The data buffer maintains first-in-first-out read / write pointers to ensure that the protocol adaptation unit reads and parses the data in order. The data acquisition module simultaneously collects real-time status data from the hospital's intelligent warehouse, RFID access gates, and vehicle terminals in a timed polling manner according to a preset cycle (default 10 seconds). Specifically, the intelligent warehouse actively retrieves consumable category identifiers, current inventory balances, inventory warning thresholds, warehouse location codes, and collection timestamps via HTTP / REST interfaces. The RFID access gates passively receive TCP long-connection pushes to collect RFID tag numbers, associated unique traceability codes, flow direction, access gate numbers, and flow timestamps. The vehicle terminals actively retrieve vehicle identifiers, current location latitude and longitude coordinates, delivery status, and collection timestamps via 4G / 5G reporting interfaces. After each timed collection is completed, the data acquisition module appends a collection timestamp to each data record and summarizes and writes it into a multi-source raw dataset for subsequent processing by the data preprocessing module.

[0064] The data preprocessing module standardizes and associates the raw data collected by the data acquisition module, generating structured circulation records that are written into the traceability database.

[0065] The traceability chain construction module periodically scans the traceability database to check if there is a set of circulation records that meet the conditions for traceability chain construction. If so, it executes the traceability chain construction process to generate an end-to-end traceability data chain.

[0066] The dynamic scheduling module collects multi-source status data in real time, calculates priority scores through the delivery task priority evaluation model, generates a dynamic delivery scheduling instruction set, and outputs it to the instruction execution module.

[0067] After receiving the dynamic delivery scheduling instruction set, the instruction execution module executes the instruction issuance and execution status feedback process, sends the scheduling instructions to the target device and monitors the execution effect, and triggers an automatic error correction mechanism for dynamic compensation based on the execution deviation.

[0068] During operation, the various modules of the system maintain close collaboration through data transmission and message notification, forming a data-driven closed-loop control system to ensure the stable and efficient operation of medical consumables supervision and distribution.

[0069] In actual hospital operations, the system and method of this invention can effectively solve many problems in the supervision and distribution of medical consumables. The following explanation uses a real-world application scenario from a top-tier hospital as an example.

[0070] When a department submits a consumable requisition request, the hospital's intelligent warehouse receives the request information and generates a requisition task. It then sends an HL7-formatted requisition message to the industrial gateway via the first communication link. After the first protocol adaptation unit parses the message and extracts the requisition data, the data preprocessing module associates and binds the requisition data with traceability codes in the unique traceability code database, generating an internal circulation record and writing it into the traceability database.

[0071] After receiving the delivery task, the off-site delivery terminal begins the delivery operation, reporting logistics and transportation data to the industrial gateway in real time via the second communication link. After the second protocol adaptation unit parses the JSON-formatted transportation message, the data preprocessing module associates and binds the transportation data with the corresponding traceability code, generating an off-site circulation record and writing it into the traceability database.

[0072] The traceability chain construction module periodically checks the inbound and outbound circulation records, matching and splicing them through traceability codes to generate a complete end-to-end traceability data chain. The traceability data chain records the entire process status information of consumables from outbound, off-site transportation, in-hospital warehousing, departmental requisition, to patient use.

[0073] The dynamic scheduling module monitors in real time the inventory balance data of the hospital's smart warehouse, the consumable circulation data of RFID access gates, and the delivery status data of the vehicle terminal. It comprehensively analyzes the urgency level of each department and the priority of delivery tasks, and dynamically generates delivery scheduling instructions. The instruction execution module sends the scheduling instructions to the delivery terminal and the hospital's smart warehouse, and dynamically adjusts the scheduling strategy based on the execution feedback.

[0074] The system and method of this invention enable data interoperability between the hospital's SPD system and the off-site logistics platform, eliminating information gaps in the regulatory chain, achieving complete traceability of the entire process of consumables from warehousing to patient use, and realizing flexible delivery scheduling based on real-time dynamic information, significantly improving the efficiency and reliability of medical consumables supervision and delivery.

[0075] To enable those skilled in the art to fully understand and implement this invention, the specific implementation principles are further explained below in conjunction with a specific application scenario. Taking the complete monitoring and distribution process of a batch of urgently needed disposable surgical supplies in the operating room of a tertiary hospital as an example, the collaborative working principle of each module of the system is illustrated in detail.

[0076] Application Scenario 1: Emergency Delivery Process for Surgical Supplies When the hospital's intelligent warehouse receives a requisition request, the Cardiac Surgery Intensive Care Unit submits an urgent requisition request through the hospital information system, requesting a batch of disposable consumables needed for cardiac interventional surgery. Upon receiving this requisition request, the intelligent warehouse first sends a consumables requisition request message to the industrial gateway via the first communication interface. This message is encapsulated in HL7 protocol format and includes key fields such as the consumable category identifier "cardiac interventional consumables," the quantity to be requisitioned is "20 sets," the requisition time is the current system time, and the target department information is "cardiac surgery intensive care unit." Simultaneously, the industrial gateway's communication link establishment module has already completed the establishment of the first communication link in advance, ensuring real-time data transmission.

[0077] When the industrial gateway parses HL7 protocol data, the first protocol adaptation unit continuously monitors the reception status of the data buffer through the first port. When the number of bytes accumulated in the data buffer reaches the preset length threshold of the HL7 message, a data frame complete arrival event is triggered. After reading the raw data stream from the data buffer, the first protocol adaptation unit first detects the MLLP encapsulation flag, uses the start byte as the message frame start delimiter and the end byte sequence as the message frame end delimiter to complete the MLLP encapsulation layer stripping. Then, it segments the message byte stream using the carriage return as the segment separator, identifies the MSH segment as the message header and extracts the field separator as the subsequent parsing benchmark rule. Finally, it extracts the key fields of the MSH segment, PAT segment and OBR segment from the parsed HL7 message body, maps the extracted key fields to the preset data structure template, and generates a structured consumable outbound data object.

[0078] During the generation and binding of unique traceability codes, the coding generation unit extracts the outbound data from the consumable outbound data object and then retrieves the corresponding traceability code record in the unique traceability code database using the consumable category identifier as the primary key. After finding a matching traceability code record, the data preprocessing module associates and binds the outbound data with the corresponding traceability code, using the unique traceability code as a foreign key to associate and bind the outbound data fields with the traceability code record, and writes the current timestamp as the binding time. After obtaining the binding result, the encapsulated intra-hospital circulation record is written to the traceability database. This intra-hospital circulation record includes fields such as unique traceability code, consumable category identifier, outbound quantity, outbound time, target department information, and binding timestamp.

[0079] When an off-site delivery terminal receives a delivery task, its management backend receives a delivery task instruction from the industrial gateway. This instruction includes information about the target department, a list of consumables to be delivered, and the urgency level. The off-site delivery terminal immediately dispatches the nearest delivery vehicle to perform the delivery operation. The vehicle's onboard terminal collects delivery status data in real time, including the vehicle's current location coordinates, current time, speed, and estimated arrival time. The onboard terminal reports logistics and transportation data to the industrial gateway in real time via a second communication link. This data is transmitted in JSON format.

[0080] When the industrial gateway parses JSON protocol data, the second protocol adaptation unit reads the raw JSON-formatted message from the data buffer. First, it performs JSON format verification to ensure data integrity. Then, it extracts logistics transportation data according to preset field mapping rules, generating a structured logistics transportation data object. The data preprocessing module retrieves the corresponding traceability code record from the unique traceability code database using the logistics order number as the index key. After aligning the field-level primary keys, it associates and binds the transportation data fields with the traceability code record using the unique traceability code as the foreign key. This is encapsulated into an off-site circulation record object containing fields such as unique traceability code, logistics order number, transportation vehicle information, current location coordinates, transportation timestamp, and estimated arrival time, and then written to the traceability database for storage.

[0081] When the RFID access gate collects circulation data, consumables pass through the RFID access gate after leaving the warehouse. The RFID access gate automatically reads the RFID tag information on the consumable packaging, collects the consumable circulation data, and directly uploads it to the industrial gateway for data processing. This circulation data includes the consumable passage time, access gate location information, consumable status, etc. The data acquisition module of the industrial gateway also writes this data into the traceability database, forming a complete circulation trajectory record.

[0082] During traceability chain construction and full-process traceability, the traceability chain construction module periodically scans the traceability database to check for the existence of a set of circulation records that meet the conditions for traceability chain construction. When it is found that a batch of consumables has both in-hospital and out-of-hospital circulation records, the traceability chain construction module executes the traceability data chain construction process. First, using the unique traceability code as the index key, it queries the traceability database for the in-hospital and out-of-hospital circulation record sets respectively. The traceability code fields of the two types of records are compared and filtered for consistency to obtain the valid in-hospital and out-of-hospital circulation record sets. Then, it extracts the binding timestamp and transportation timestamp of each record, sorts all record nodes in ascending order using a unified time base, and corrects for timestamp anomalies caused by clock deviations, resulting in an ordered set of record nodes with monotonically increasing time sequence. Based on the ordered set of record nodes, the in-hospital and out-of-hospital circulation record nodes are merged into a unified traceability record entry according to a preset splicing mode. The two types of record nodes are then sequentially spliced ​​using the unique traceability code as the foreign key to obtain an ordered node sequence. Coverage checks were performed on key nodes at each stage: warehousing, off-site transportation, in-hospital receipt, departmental requisition, and patient use. After verifying that corresponding records existed at each key node, the splicing results were encapsulated into an end-to-end traceability data chain object and written to the traceability database. Through the above traceability chain construction process, the system achieved complete traceability of the entire process of this batch of cardiac interventional surgical consumables from warehousing to patient use.

[0083] Application Scenario 2: Dynamic Scheduling Process for Multi-Task Concurrent Delivery During real-time data acquisition, the dynamic scheduling module establishes real-time data acquisition channels with the intelligent warehouse, RFID access gate, and vehicle-mounted terminal through the industrial gateway, synchronously pulling multi-source data according to a preset acquisition cycle. The preset acquisition cycle is set to 10 seconds. Every 10 seconds, the system pulls real-time inventory balance data from the intelligent warehouse, consumable flow data from the RFID access gate, and delivery status data from the vehicle-mounted terminal, obtaining a multi-source raw dataset containing acquisition timestamps. Subsequently, preprocessing operations such as deduplication, missing value imputation, and format validation are performed on each data item to unify the heterogeneous data format into a preset intermediate data format, resulting in a standardized multi-source dataset.

[0084] During feature parameter extraction and priority evaluation, the dynamic scheduling module extracts four types of feature parameters—inventory balance, consumable consumption rate, departmental urgency level, and transportation distance—based on a standardized multi-source dataset to construct a feature vector for the delivery task. The inventory balance feature parameter is extracted from real-time inventory data in the hospital's intelligent warehouse, reflecting the current inventory level of each type of consumable. For example, the inventory balance of interventional cardiology consumables has dropped to 15 sets, below the safe inventory threshold of 20 sets. The consumable consumption rate feature parameter is calculated from consumable flow data at RFID access gates, reflecting the consumption rate of various consumables in each department. For example, the cardiac surgery ICU consumed 8 sets of interventional cardiology consumables in the past hour, indicating a high consumption rate. The departmental urgency feature parameter is obtained from the hospital information system, reflecting the urgency level of each department; the cardiac surgery ICU is set to the highest level, Level 1. The transportation distance feature parameter is calculated from the location data of the vehicle terminal combined with the hospital's layout map, reflecting the driving distance from the delivery point to the target department. For example, the delivery vehicle is approximately 150 meters from the cardiac surgery ICU.

[0085] When prioritizing delivery tasks, the feature vectors of the aforementioned delivery tasks are input into the delivery task priority evaluation model. The model calculates the priority score for each delivery task based on the weight coefficients of each feature parameter. The delivery task priority evaluation model uses a weighted scoring algorithm, with the weight coefficients for each feature parameter being: inventory balance weight 0.3, consumable consumption rate weight 0.25, departmental urgency weight 0.3, and transportation distance weight 0.15. The model calculates a priority score of 92 for this task, significantly higher than the scores of other delivery tasks. The system simultaneously performs similar feature extraction and priority scoring on other delivery tasks to obtain the priority ranking results for each delivery task.

[0086] When dynamic delivery scheduling instructions are generated, the dynamic scheduling module sorts the delivery tasks according to their priority ranking, from highest to lowest priority score, and generates a delivery sequence instruction. This delivery sequence instruction includes the task number, priority level, and execution sequence number. Based on the delivery sequence instruction, combined with real-time traffic data and the vehicle's current location coordinates, the driving route of the high-priority delivery task is dynamically replanned. Since the roads within the facility are clear and there is no traffic congestion, the original planned route remains unchanged, and the generated route replanning instruction includes the starting node, the sequence of nodes along the route, the ending node, and the estimated travel distance. Based on the estimated travel distance in the route replanning instruction, combined with the vehicle's average speed and the dwell time at each node, the estimated arrival time of the delivery task is calculated to be 15 minutes. A time adjustment instruction is then generated, including the estimated arrival timestamps of each node and the estimated completion timestamp of the task. The delivery sequence instruction, route replanning instruction, and time adjustment instruction are associated with the corresponding task numbers according to a preset instruction encapsulation format and encapsulated into a structured dynamic delivery scheduling instruction set. After attaching the instruction generation timestamp and instruction version number, the instruction is output to the instruction execution module.

[0087] When instructions are issued and executed, the instruction execution module receives the dynamic delivery scheduling instruction set and first extracts the type, timestamp, and unique number information of each instruction. It then analyzes the order, dependencies, and conflicts between the instructions. The analysis results show that there are no conflicts in this batch of delivery instructions. Subsequently, a timing constraint matrix for instruction execution is constructed to clarify the execution order and dependencies of each instruction. Based on the timing constraint matrix, conflict detection is performed on the control instruction set. After confirming that there are no overlapping time windows, resource contention, or logical contradictions, a final control instruction set with timing dependencies is generated, and an instruction execution plan is formulated.

[0088] During the execution status feedback and dynamic compensation process, the instruction execution module sends scheduling instructions to the off-site delivery terminal and the on-site intelligent warehouse in real time. Simultaneously, it collects real-time data on equipment action status, logistics parameter changes, and system operation results during the execution of control instructions. Equipment action status indicates that the delivery terminal has received the instruction and begun execution; logistics parameter changes indicate that the vehicle has started heading to the target department; and system operation results show that the order status is updated to "delivering". After processing and verifying the collected feedback data, the feedback information is compared with the expected control target to obtain the execution deviation and success rate of the control instruction. Execution deviation shows that the deviation between the estimated arrival time and the actual estimated arrival time is within the allowable range, and the success rate is 100%. Since the execution deviation does not exceed the preset threshold and the success rate is higher than the preset standard, the automatic error correction mechanism is not triggered, and the system continues to monitor the delivery execution process. When the delivery vehicle arrives at the target department, the on-board terminal updates the delivery status to "completed." This status information is uploaded to the industrial gateway in real time and written to the traceability database, updating the final status in the traceability data chain.

[0089] Application Scenario 3: Cross-protocol data interoperability implementation process When the hospital's SPD system uploads data, a batch of disposable high-pressure injectors is released from the hospital's smart warehouse, ready for delivery to the radiology department. The hospital's smart warehouse SPD system generates an HL7 format release message, which includes MSH header information, PAT patient-related information, and OBR laboratory order information. After receiving the HL7 message through the first communication interface, the first protocol adaptation unit extracts the release data according to the protocol parsing process. Information such as field separator "^" and component separator "-" is extracted from the MSH segment. Key fields such as consumable category identifier "disposable high-pressure injector", release quantity "50 units", release time "2024-01-15 10:30:00", and target department information "radiology department" are extracted from the OBR segment. The first protocol adaptation unit maps the extracted key fields to a preset data structure template, generating a structured consumable release data object, providing a unified data format for subsequent data processing.

[0090] When the data of the off-hospital logistics platform is uploaded, the logistics management system of the off-hospital distribution terminal generates a transport message in JSON format, which includes fields such as the order number "LOG20240115001", the transport vehicle information "Jing A 12345", the current position coordinates "116.397428, 39.90923", the current time "2024-01-15 10:35:00", the estimated arrival time "2024-01-15 11:00:00". After the second protocol adaptation unit reads the JSON message from the data buffer, it first performs JSON format check to ensure the message structure is complete, then extracts the logistics transport data according to the preset field mapping rules, and generates a structured logistics transport data object.

[0091] During standardization processing and association binding, the data preprocessing module performs standardization processing on two sets of heterogeneous data formats, and uniformly converts the HL7-format consumables outbound data and the JSON-format logistics transportation data into a preset intermediate data format. During the conversion process, the corresponding traceability code record is retrieved in the unique traceability code database by using the consumables category identifier as the primary key. Since the unique traceability code has been generated by the coding generation unit and written into the unique traceability code database for management when this batch of consumables is put into storage, the corresponding traceability code record can be retrieved. After the matching record is retrieved, the data preprocessing module uses the unique traceability code as a foreign key to perform association binding on the aligned outbound data fields and the traceability code record, writes the current timestamp as the binding time, and obtains the binding result, which is then encapsulated into in-hospital circulation records and off-hospital circulation records respectively and written into the traceability database.

[0092] When implementing cross-domain data connectivity, through the first protocol adaptation unit and the second protocol adaptation unit provided by the embodiments of the present invention, the system implements cross-domain protocol adaptation and data intercommunication between the in-hospital SPD system and the off-hospital logistics platform. After HL7 protocol data and JSON protocol data are parsed and processed by their respective protocol adaptation units, they are uniformly converted into a standardized intermediate data format, which eliminates the information "breakpoint" problem caused by the lack of an effective data intercommunication mechanism between the in-hospital SPD system and the off-hospital logistics platform in the prior art. The in-hospital circulation records and the off-hospital circulation records are associated and bound through the unique traceability code, which realizes the connectivity of the whole process data of consumables from in-hospital outbound to off-hospital transportation, and provides complete data support for the subsequent construction of the traceability chain and dynamic scheduling.

[0093] This clearly demonstrates the collaborative working principle of each module in the actual operation of the medical consumables supervision and distribution interconnection system based on an industrial gateway provided in this embodiment of the invention. The system achieves cross-domain protocol adaptation through a first protocol adaptation unit and a second protocol adaptation unit, end-to-end traceability through a traceability chain construction module, and flexible distribution scheduling based on real-time dynamic information through a dynamic scheduling module and an instruction execution module. This effectively solves the technical problems of "breakpoints" in the supervision link information and inflexible distribution scheduling existing in the prior art, significantly improving the efficiency and reliability of medical consumables supervision and distribution.

[0094] A computer-readable storage medium is characterized in that it is used to store computer-readable instructions, which, when read by a computer, enable the operation of the aforementioned medical consumables supervision and distribution interconnection system based on an industrial gateway.

[0095] The embodiments of the present invention have been described above. However, the embodiments are not limited to the specific implementation methods described above. The specific implementation methods described above are merely illustrative and not restrictive. Those skilled in the art can make more equivalent embodiments under the guidance of the present embodiments, and all of them are within the protection scope of the present embodiments.

Claims

1. A medical consumables monitoring and distribution interconnection system based on an industrial gateway, characterized in that, include: Establish communication links between the industrial gateway and the intelligent warehouse within the institute and the delivery terminal outside the institute. Use the corresponding protocol adaptation unit to parse the communication protocols of each link and collect consumable outbound data and logistics transportation data from multiple sources. Standardize and preprocess consumable outbound data and logistics transportation data, convert heterogeneous data formats into a preset intermediate data format, and combine them with unique traceability codes to complete the association and binding of internal and external circulation records. By linking and binding the in-hospital circulation records with the out-of-hospital circulation records using a unique traceability code, an end-to-end traceability data chain covering the entire process of consumables from delivery to patient use is constructed. Real-time data collection of intelligent inventory balance, RFID access door consumable circulation data, and vehicle terminal delivery status data are collected. The standardized multi-source data is then input into the delivery task priority evaluation model, and the delivery task priority results are output. Based on the delivery task priority results, a structured dynamic delivery scheduling instruction set is generated, which includes delivery sequence instructions, route replanning instructions, and time adjustment instructions. A mechanism for issuing and executing instructions based on a dynamic delivery scheduling instruction set is established to send scheduling instructions to delivery terminals, in-hospital smart warehouses, and RFID access gates in real time, so as to coordinate the delivery of consumables through interconnection.

2. The medical consumables monitoring and distribution interconnection system based on an industrial gateway according to claim 1, characterized in that, Establish a first communication link between the industrial gateway and the intelligent warehouse within the facility, and a second communication link between the industrial gateway and the off-site distribution terminal; the first communication link adopts a first preset communication protocol, and the second communication link adopts a second preset communication protocol; The first protocol adaptation unit of the industrial gateway parses the first preset communication protocol and extracts the output consumables outbound data; the consumables outbound data includes consumables category identifier, outbound quantity, outbound time and target department information; The second protocol adaptation unit of the industrial gateway parses the second preset communication protocol and extracts the logistics transportation data output by the off-site logistics platform; the logistics transportation data includes the vehicle identification, transportation route information, current location coordinates and estimated arrival time.

3. The medical consumables monitoring and distribution interconnection system based on an industrial gateway according to claim 2, characterized in that, The first protocol adaptation unit of the industrial gateway parses the first preset communication protocol and extracts the output consumable outbound data, including: When the first port of the first protocol adapter unit detects that data has arrived at a preset event, the first protocol adapter unit reads the original data stream from the data buffer. The data is the original message in HL7 format transmitted by the hospital's intelligent warehouse through the first communication link. The original message includes the consumable category identifier, the quantity issued, the issuance time, and the target department information. The preset events include a data frame arrival event triggered when the number of bytes accumulated in the receive buffer reaches a preset length threshold of the original message, a message boundary detection event triggered when the original message terminator is detected, and a timeout fallback event triggered when there is no new data in the buffer within a preset waiting time window. The first protocol adaptation unit performs protocol frame parsing on the original data stream to identify the message header, message body and message trailer of the original message; Extract the key fields of the MSH, PAT, and OBR segments from the parsed HL7 message body; The extracted key fields are mapped to a preset data structure template to generate a structured consumables outbound data object.

4. The medical consumables monitoring and distribution interconnection system based on an industrial gateway according to claim 3, characterized in that, The first protocol adaptation unit performs protocol frame parsing on the original data stream, identifying the message header, message body, and message trailer of the original message, including: Detect the MLLP encapsulation flags in the data stream of the original message, using the start byte 0x0B as the message frame start delimiter and the end byte sequence 0x1C-0x0D as the message frame end delimiter; Extracting the byte sequence between the two delimiters completes the MLLP encapsulation layer stripping, yielding the original message byte stream; The message byte stream is segmented using the carriage return character 0x0D as the segment delimiter. The first segment starting with MSH is identified as the message header, and the field delimiter, component delimiter, and repetition delimiter are extracted from the Nth byte of the MSH segment as the basis rules for parsing. All segments from the MSH segment to the termination delimiter are identified as the message body, the last segment in the message body is identified as the message tail, and each segment of the message body is classified and labeled according to the segment name prefix.

5. A medical consumables monitoring and distribution interconnection system based on an industrial gateway according to claim 4, characterized in that, The unique traceability code is defined as a string encoding of a preset number of digits; the first a digits of the string encoding are the manufacturer code, the middle b digits are the batch number, the following c digits are the production date, and the last d digits are the serial number. When a new batch of consumables is received, the smart warehouse in the institute sends a consumables receipt request message to the industrial gateway. The industrial gateway's encoding generation unit receives consumable warehousing request messages and extracts manufacturer information, batch information, and production date information from the messages; The coding generation unit assigns an incrementing serial number to each smallest sales unit of the batch of consumables according to a preset serial number generation rule; The coding generation unit combines the manufacturer code, batch number, production date, and serial number according to a preset splicing format to generate a unique traceability code, and writes the unique traceability code into the tag chip.

6. A medical consumables monitoring and distribution interconnection system based on an industrial gateway according to claim 5, characterized in that, Extract the consumable category identifier, outbound quantity, outbound time and target department information from the parsed consumable outbound data object. Use the consumable category identifier as the primary key to retrieve the corresponding traceability code record in the unique traceability code database to complete the field-level primary key alignment. Using the unique traceability code as a foreign key, the aligned outbound data field is associated and bound with the traceability code record, and the current timestamp is written as the binding time to obtain the binding result; The binding result is encapsulated into a structured intra-hospital circulation record object containing a unique traceability code, consumable category identifier, outbound quantity, outbound time, target department information, and binding timestamp. The integrity of each required field is verified, and the record is written to the traceability database after the verification is successful.

7. A medical consumables monitoring and distribution interconnection system based on an industrial gateway according to claim 6, characterized in that, Using the unique traceability code as the index key, query the set of intra-hospital circulation records and the set of extra-hospital circulation records from the traceability database respectively. Perform a consistency comparison on the traceability code field of the two types of records, filter out records with mismatched traceability codes or abnormal formats, and obtain the set of valid intra-hospital circulation records and the set of valid extra-hospital circulation records. Based on the valid in-hospital circulation record set and the valid out-of-hospital circulation record set, the binding timestamp and transportation timestamp of each record are extracted. All record nodes are sorted in ascending order with a unified time base, and timestamp anomalies caused by clock deviation are corrected to obtain an ordered set of record nodes with monotonically increasing time sequence. Based on the ordered set of record nodes, the in-hospital circulation record nodes and the out-of-hospital circulation record nodes are merged into a unified traceability record item according to a preset splicing mode. The in-hospital circulation record nodes and the out-of-hospital circulation record nodes are sequentially spliced ​​together using a unique traceability code as a foreign key to obtain an ordered node sequence. Based on the ordered node sequence, coverage detection is performed on each key node of outbound, off-hospital transportation, in-hospital reception, departmental requisition, and patient use to verify whether each key node has a corresponding record. For missing nodes, a preset abnormal status code is written and an alarm is triggered to obtain a node sequence carrying the integrity detection result. Based on the node sequence carrying integrity detection results, the splicing result is encapsulated into an end-to-end traceability data chain object containing a unique traceability code, a set of records for each node, node integrity detection results, and chain generation timestamp.

8. A medical consumables monitoring and distribution interconnection system based on an industrial gateway according to claim 1, characterized in that, Real-time data acquisition channels are established with the smart warehouse, RFID access gate and vehicle terminal in the hospital through the industrial gateway. The smart warehouse inventory data, RFID access gate consumable circulation data and vehicle terminal delivery status data are synchronously pulled according to the preset collection cycle to obtain multi-source raw datasets containing collection timestamps. Based on the multi-source original dataset, preprocessing operations such as deduplication, missing value filling and format verification are performed on each data item, and the heterogeneous data format is uniformly converted into a preset intermediate data format to obtain a standardized multi-source dataset. Based on the standardized multi-source dataset, four types of feature parameters are extracted: inventory balance, consumable consumption rate, departmental urgency, and transportation distance, to construct a feature vector for the delivery task. The feature vectors of each delivery task are input into the delivery task priority evaluation model. The model calculates the priority score of each delivery task based on the weight coefficients of each feature parameter, thus obtaining the priority result of each delivery task.

9. A medical consumables monitoring and distribution interconnection system based on an industrial gateway according to claim 8, characterized in that, Based on the delivery task priority results, a structured dynamic delivery scheduling instruction set is generated, which includes delivery sequence instructions, route replanning instructions, and time adjustment instructions, including: Based on the priority ranking of each delivery task, the delivery tasks to be executed are sorted from high to low according to their priority scores to generate a delivery sequence instruction; the delivery sequence instruction includes the task number, priority level, and execution sequence number. Based on the delivery sequence instructions, combined with real-time traffic data and the vehicle's current location coordinates, the driving routes of each delivery task are dynamically replanned to generate route replanning instructions; the route replanning instructions include a starting node, a sequence of nodes along the route, an ending node, and an estimated driving distance. Based on the estimated mileage in the route replanning instruction, combined with the vehicle's average speed and dwell time at each node, the estimated arrival time and estimated completion time of each delivery task are calculated, and a time adjustment instruction is generated; the time adjustment instruction includes the estimated arrival timestamp of each node and the estimated completion timestamp of the task. According to the preset instruction encapsulation format, delivery sequence instructions, route replanning instructions, and time adjustment instructions are associated with the corresponding task numbers and encapsulated into a structured dynamic delivery scheduling instruction set, with an instruction generation timestamp and instruction version number attached.

10. A computer-readable storage medium, characterized in that, Used to store computer-readable instructions, which, when read by a computer, enable the operation of a medical consumables monitoring and distribution interconnection system based on an industrial gateway as described in any one of claims 1-9.