A door lock cooperative service guarantee method and system

CN122372510BActive Publication Date: 2026-08-28DESSMANN CHINA MACHINERY & ELECTRONICS
View PDF 2 Cites 0 Cited by

Patent Information

Application Number
CN202610831091.6
Authority / Receiving Office
CN · China
Patent Type
Patents(China)
Current Assignee / Owner
Filing Date
2026-06-10
Publication Date
2026-08-28
Estimated Expiration
2046-06-10

AI Technical Summary

Technical Problem

然而,此类方案存在明显不足:一方面,依靠中心服务器进行集中决策,不仅增加了网络传输延迟,且一旦服务器或网络链路出现故障,异常事件便无法得到及时响应;另一方面,传统方法缺乏多门锁之间的协同确认机制,单个门锁误报或漏报易引发错误处置,难以准确评估异常的严重程度

Benefits of technology

[0013]与现有技术相比,本发明提供的一种门锁协同的业务保障方法,能够实现异常事件的精准识别、网络资源的按需升级以及系统状态的自动恢复,提高安防响应的可靠性与网络资源利用率。

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN122372510B_ABST
    Figure CN122372510B_ABST
Patent Text Reader

Abstract

This invention discloses a service assurance method and system for door lock collaboration. The method includes: generating a protection request message and sending it to a router based on the first door lock detecting an abnormal state of a target object, and assigning it a medium-priority protection strategy; based on the protection request message, other door locks enter a waiting-to-respond state, and the router, by identifying data streams matching classification rules on different ingress interfaces, counts the number of active door locks to reach a preset threshold, and upgrades the priority of the data stream corresponding to the event from medium priority to high priority; any responding door lock detects that the target object's state has returned to normal, sends an exit-of-concern message to the router, and when the number of exit-of-concern messages reaches a preset exit threshold, notifies all door locks to stop detection and data stream transmission. Using this invention, accurate identification of abnormal events, on-demand upgrades of network resources, and automatic recovery of system state can be achieved, improving the reliability of security response and network resource utilization.
Need to check novelty before this filing date? Find Prior Art

Description

Technical Field

[0001] This invention belongs to the field of smart door lock technology, and in particular to a business security method and system for door lock collaboration. Background Technology

[0002] With the rapid development of smart security and IoT technologies, linkage monitoring and protection systems based on door lock devices have been widely applied in smart communities, financial security, and other scenarios. In existing technologies, when a single door lock detects abnormal events such as illegal intrusion or brute-force attacks, it typically handles the situation by either triggering a local alarm or reporting the event to a central server. However, this approach has significant shortcomings: firstly, relying on a central server for centralized decision-making increases network transmission latency, and if the server or network link fails, abnormal events cannot be responded to in a timely manner; secondly, traditional methods lack a collaborative confirmation mechanism between multiple door locks, making it easy for false alarms or missed alarms from a single door lock to lead to incorrect handling and difficulty in accurately assessing the severity of the anomaly. Furthermore, existing technologies typically employ a fixed priority strategy for data stream transmission of abnormal events, failing to dynamically adjust resource protection levels based on the number of door locks participating in the response. This increases the risk of network congestion during real-world group anomalies, potentially resulting in the loss of critical data. Simultaneously, system resources cannot be released promptly after anomaly recovery, causing unnecessary bandwidth consumption and device power consumption. Summary of the Invention

[0003] The purpose of this invention is to provide a business security method and system for door lock collaboration, in order to overcome the shortcomings of the prior art, and to achieve accurate identification of abnormal events, on-demand upgrade of network resources, and automatic recovery of system status, thereby improving the reliability of security response and network resource utilization.

[0004] One embodiment of this application provides a service assurance method for door lock collaboration, the method comprising: Abnormal event triggering and initial protection: Based on the abnormal state of the target object detected by the first door lock, a protection request message carrying an event feature identifier is generated and sent to the router in the network via multicast; the router dynamically generates data stream classification rules for the event based on the event feature identifier in the request message and assigns a medium-priority protection strategy to it; Collaborative confirmation and proactive reporting: Based on the protection request message forwarded by the router, other door locks enter a waiting response state, and when they simultaneously match the event feature identifier and detect the same abnormal state, they send a real-time data stream carrying the event feature identifier to the multicast address. The router identifies the data streams on different ingress interfaces that match the classification rules and counts the number of active door locks participating in the response. Dynamic policy upgrade and key monitoring: When the number of active door locks counted by the router reaches a preset threshold, the priority of the data stream corresponding to the event is upgraded from medium priority to high priority, and the first door lock is notified to enter the key monitoring state via multicast; the first door lock starts storing data when it first receives the data stream, and permanently marks the stored data after receiving the key monitoring notification; Recovery detection and resource release: If any responding door lock detects that the target object's status has returned to normal, it sends an exit attention message to the router; when the number of exit attention messages received reaches a preset exit threshold, the router clears the classification rules and priority policies associated with the event, and notifies all door locks to stop detection and data stream transmission via multicast.

[0005] Optionally, the abnormal event triggering and initial protection include: Anomaly detection and feature extraction: Based on the continuous monitoring of surrounding personnel by the first door lock, when the facial features of the target object match the pre-stored features and the emotion recognition result is abnormal, the feature hash value is calculated based on the facial feature vector of the target object, and this value is used to uniquely identify this event; Multicast Join and Interface Binding: Based on the first lock, an IGMPv3 join message carrying the lock identifier and the feature hash value of the face feature vector is sent to the router. After receiving the message, the router records the receiving interface in the multicast forwarding table and associates the lower 16 bits of the feature hash value of the face feature vector with that interface. Safeguarding the transmission of the request message: Construct a multicast message carrying the feature hash value of the face feature vector, the medium priority level and the request tag according to the first door lock, and send it to the preset multicast address; Classification rules are dynamically generated: After the router parses the protection request message and determines that it needs to be actively processed, it generates an ingress interface classification rule based on the feature hash value of the face feature vector. The classification rule matches the message in the data stream whose source port is equal to the lower 16 bits of the feature hash value of the face feature vector, and maps the successfully matched message to the medium priority queue.

[0006] Optionally, the collaborative confirmation and proactive reporting include: Activation of waiting state: Based on the guarantee request message forwarded by the router received by other door locks, the feature hash value of the face feature vector is parsed, and the waiting state is entered. Face detection and emotion recognition are continuously performed within the preset time window. Dual-condition determination: If the hash value of the face feature detected by any other door lock in the pending response state matches the hash value of the face feature vector, and the emotion recognition result is abnormal, it is determined that the reporting condition is met; Data stream multicast transmission: Based on the door locks that meet the reporting conditions, start sending real-time data streams to the preset multicast address, wherein the source port of the data stream packet is set to the lower 16 bits of the feature hash value of the face feature vector, and the destination port is fixed to the preset receiving port. Router identification and statistics: Based on the data streams received by the router through different ingress interfaces, the source port and destination port are matched using the classification rules. The traffic that is successfully matched is classified into the traffic category associated with the event. The router maintains an active lock statistics table, queries the pre-stored interface and lock identifier mapping relationship based on the ingress interface of the matched traffic, obtains the lock identifiers that participated in the response, and counts the number of active locks.

[0007] Optionally, the dynamic upgrading and key monitoring of the strategy includes: Threshold triggering and policy upgrade: Based on the number of active door locks counted by the router reaching a preset threshold, the priority of the traffic category corresponding to the event is dynamically changed from medium priority to high priority, and the global dynamic QoS policy is updated. Key monitoring notification: Based on the router, a specific group query message carrying the message type, facial feature vector feature hash value and the list of currently active door locks is constructed and sent via multicast so that all door locks can receive it; First Lock Storage Management: From the moment the first lock receives any data stream about the event, it continuously stores the data in a local circular buffer according to the lock identifier and time segmentation. When a key monitoring notification message is received, the feature hash value of the facial feature vector is parsed out, and all video segments corresponding to the event that have been stored locally are marked as permanently retained to prevent them from being overwritten by the circular buffer, and subsequent data streams are continued to be stored. Anomaly Reporting: Based on the first door lock start duration timer, an anomaly event report is sent to the school management system after the timer expires. The report includes the characteristics of the target object, the start time of the event, the key confirmation time, and the storage link.

[0008] Optionally, the recovery detection and resource release include: Single lock recovery detection: If any responding lock detects that the target object's emotional state has returned to normal during continuous monitoring, or detects that the target object's face matches but the emotion is normal, the lock sends an exit attention message to the router carrying the exit message type, the lock's identifier, and the feature hash value of the face feature vector. Router cumulative counting and decision-making: Based on the exit attention message received by the router, maintain the exit count associated with the event. When the cumulative number of exit messages received reaches the preset exit threshold, it is determined that the global exit condition is met. Policy and rule clearing: Based on the router's determination that the global exit conditions are met, delete the ingress interface classification rules, dynamic QoS policies, and priority queue configurations associated with the event; Network-wide exit notification: Based on the router's construction of a specific group query message carrying the end message type and the feature hash value of the face feature vector, it is sent via multicast to notify all door locks to stop sending data streams, face detection, and video storage for this event; First lock exit process: Upon receiving the end-of-attention message, the first lock stops video storage, sends an event end notification to the school management system, and clears the local state related to the event. Last resort timeout mechanism: If the router's duration timer starts after receiving the first protection request message expires and the exit mechanism is not triggered, it will automatically construct and send a termination of concern message and perform resource release.

[0009] Optionally, the method further includes: Door lock identifier mapping establishment: When each door lock starts up, it sends an IGMPv3 join message carrying its own door lock identifier to the router. The router establishes a mapping table between the receiving interface and the door lock identifier for subsequent identification of the data stream source. Video stream targeted forwarding: After the router matches the data stream according to the classification rules, it queries the multicast forwarding table for the interface that records the lower 16 bits of the feature hash value of the face feature vector, and forwards the data stream only from that interface to the first door lock, realizing precise targeted transmission in point-to-multipoint; The first lock uses a progressive storage strategy: When the first lock does not receive a notification of key monitoring, it adopts a circular buffer strategy to limit the storage time; after receiving a notification of key monitoring, all data of the corresponding event in the circular buffer will be converted to permanent storage, realizing a smooth transition from temporary records to permanent evidence.

[0010] Another embodiment of this application provides a door lock collaboration business assurance system, the system comprising: The triggering module is used for abnormal event triggering and initial protection: based on the abnormal state of the target object detected by the first door lock, a protection request message carrying the event feature identifier is generated and sent to the router in the network via multicast; the router dynamically generates data stream classification rules for the event based on the event feature identifier in the request message and assigns a medium-priority protection strategy to it; The confirmation module is used for coordinated confirmation and proactive reporting: based on the protection request message forwarded by the router, other door locks enter the waiting response state, and when they simultaneously match the event feature identifier and detect the same abnormal state, they send a real-time data stream carrying the event feature identifier to the multicast address. The router identifies the data streams on different ingress interfaces that match the classification rules and counts the number of active door locks participating in the response. The upgrade module is used for dynamic policy upgrades and key monitoring: based on the number of active door locks counted by the router reaching a preset threshold, the priority of the data stream corresponding to the event is upgraded from medium priority to high priority, and the first door lock is notified to enter the key monitoring state via multicast; the first door lock starts storing data when it first receives the data stream, and permanently marks the stored data after receiving the key monitoring notification; The detection module is used for recovery detection and resource release: if any responding door lock detects that the target object's status has returned to normal, it sends an exit attention message to the router; when the number of exit attention messages received reaches a preset exit threshold, the router clears the classification rules and priority policies associated with the event, and notifies all door locks to stop detection and data stream transmission via multicast.

[0011] Another embodiment of this application provides a storage medium storing a computer program, wherein the computer program is configured to execute the method described in any of the preceding claims when running.

[0012] Another embodiment of this application provides an electronic device including a memory and a processor, wherein the memory stores a computer program and the processor is configured to run the computer program to perform the method described in any of the preceding claims.

[0013] Compared with existing technologies, the door lock collaboration service assurance method provided by this invention can achieve accurate identification of abnormal events, on-demand upgrade of network resources, and automatic recovery of system status, thereby improving the reliability of security response and the utilization rate of network resources. Attached Figure Description

[0014] Figure 1 A hardware structure block diagram of a computer terminal for a door lock collaboration service assurance method provided in an embodiment of the present invention; Figure 2 A flowchart illustrating a business assurance method for door lock collaboration provided in an embodiment of the present invention; Figure 3 This is a schematic diagram of the structure of a door lock collaborative business assurance system provided in an embodiment of the present invention. Detailed Implementation

[0015] The embodiments described below with reference to the accompanying drawings are exemplary and are only used to explain the present invention, and should not be construed as limiting the present invention.

[0016] In settings such as schools and homes, smart door locks and camera devices have been widely deployed, capable of simultaneously monitoring students' emotional states (such as depression and anxiety) and providing timely psychological intervention. However, existing technologies have the following shortcomings: 1. Individual door locks rely on facial emotion recognition to determine students' emotional abnormalities. This is susceptible to factors such as lighting, angle, and instantaneous changes in facial expressions, resulting in a high false alarm rate and easily triggering unnecessary alarms and video transmissions, leading to a waste of network and storage resources. When a door lock detects a student with abnormal emotions, it cannot coordinate with other door locks for cross-verification of that student. If all door locks continuously transmit video streams, it will consume a large amount of network resources; while relying solely on a single door lock to trigger an alarm cannot confirm its authenticity, resulting in a large amount of irrelevant video being transmitted and stored. 2. Abnormal emotional states of students can potentially lead to serious safety incidents in severe cases. However, the large amount of traffic on the network can cause network congestion, resulting in packet loss and delays in the transmission of critical video streams (such as tracking footage of students with abnormal emotions), affecting the timeliness of intervention. Traditional network QoS policies are mostly based on static configuration or priority scheduling for a specific application. They cannot manage specific traffic of the same application with finer granularity, or dynamically adjust policies based on terminal requests and real-time events.

[0017] This invention first provides a business security method for door lock collaboration, which can be applied to electronic devices, such as computer terminals, specifically ordinary computers.

[0018] The following detailed explanation uses a computer terminal as an example. Figure 1 This is a hardware structure block diagram of a computer terminal for a door lock collaboration service assurance method provided in an embodiment of the present invention. Figure 1 As shown, the computer device includes a processor, memory, and network interface connected via a system bus, wherein the memory may include non-volatile storage media and internal memory.

[0019] See Figure 2 The present invention provides a service assurance method for door lock collaboration, which may include the following steps: S201, Abnormal Event Triggering and Initial Protection: Based on the abnormal state of the target object detected by the first door lock, a protection request message carrying an event feature identifier is generated and sent to the router in the network via multicast; the router dynamically generates data stream classification rules for the event based on the event feature identifier in the request message, and assigns a medium-priority protection policy to it; specifically, the abnormal event triggering and initial protection includes: Anomaly detection and feature extraction: Based on the continuous monitoring of surrounding personnel by the first door lock, when the facial features of the target object match the pre-stored features and the emotion recognition result is abnormal, the feature hash value is calculated based on the facial feature vector of the target object, and this value is used to uniquely identify this event; Multicast Join and Interface Binding: Based on the first lock, an IGMPv3 join message carrying the lock identifier and the feature hash value of the face feature vector is sent to the router. After receiving the message, the router records the receiving interface in the multicast forwarding table and associates the lower 16 bits of the feature hash value of the face feature vector with that interface. Safeguarding the transmission of the request message: Construct a multicast message carrying the feature hash value of the face feature vector, the medium priority level and the request tag according to the first door lock, and send it to the preset multicast address; Classification rules are dynamically generated: After the router parses the protection request message and determines that it needs to be actively processed, it generates an ingress interface classification rule based on the feature hash value of the face feature vector. The classification rule matches the message in the data stream whose source port is equal to the lower 16 bits of the feature hash value of the face feature vector, and maps the successfully matched message to the medium priority queue.

[0020] S202, Cooperative Confirmation and Active Reporting: Based on the protection request message forwarded by the router, other door locks enter a waiting-to-respond state, and when they simultaneously match the event feature identifier and detect the same abnormal state, they send a real-time data stream carrying the event feature identifier to the multicast address. The router identifies the data streams matching the classification rules on different ingress interfaces and counts the number of active door locks participating in the response; specifically, the cooperative confirmation and active reporting includes: Activation of waiting state: Based on the guarantee request message forwarded by the router received by other door locks, the feature hash value of the face feature vector is parsed, and the waiting state is entered. Face detection and emotion recognition are continuously performed within the preset time window. Dual-condition determination: If the hash value of the face feature detected by any other door lock in the pending response state matches the hash value of the face feature vector, and the emotion recognition result is abnormal, it is determined that the reporting condition is met; Data stream multicast transmission: Based on the door locks that meet the reporting conditions, start sending real-time data streams to the preset multicast address, wherein the source port of the data stream packet is set to the lower 16 bits of the feature hash value of the face feature vector, and the destination port is fixed to the preset receiving port. Router identification and statistics: Based on the data streams received by the router through different ingress interfaces, the source port and destination port are matched using the classification rules. The traffic that is successfully matched is classified into the traffic category associated with the event. The router maintains an active lock statistics table, queries the pre-stored interface and lock identifier mapping relationship based on the ingress interface of the matched traffic, obtains the lock identifiers that participated in the response, and counts the number of active locks.

[0021] S203, Dynamic Policy Upgrade and Key Monitoring: Based on the number of active locks counted by the router reaching a preset threshold, the priority of the data stream corresponding to the event is upgraded from medium priority to high priority, and the first lock is notified to enter key monitoring status via multicast; the first lock starts storing data from the first time it receives the data stream, and permanently marks the stored data after receiving the key monitoring notification; specifically, the dynamic policy upgrade and key monitoring include: Threshold triggering and policy upgrade: Based on the number of active door locks counted by the router reaching a preset threshold, the priority of the traffic category corresponding to the event is dynamically changed from medium priority to high priority, and the global dynamic QoS policy is updated. Key monitoring notification: Based on the router, a specific group query message carrying the message type, facial feature vector feature hash value and the list of currently active door locks is constructed and sent via multicast so that all door locks can receive it; First Lock Storage Management: From the moment the first lock receives any data stream about the event, it continuously stores the data in a local circular buffer according to the lock identifier and time segmentation. When a key monitoring notification message is received, the feature hash value of the facial feature vector is parsed out, and all video segments corresponding to the event that have been stored locally are marked as permanently retained to prevent them from being overwritten by the circular buffer, and subsequent data streams are continued to be stored. Anomaly Reporting: Based on the first door lock start duration timer, an anomaly event report is sent to the school management system after the timer expires. The report includes the characteristics of the target object, the start time of the event, the key confirmation time, and the storage link.

[0022] S204, Recovery Detection and Resource Release: Upon detecting that the target object's state has returned to normal, any responding door lock sends an exit-of-concern message to the router. When the number of received exit-of-concern messages reaches a preset exit threshold, the router clears the classification rules and priority policies associated with that event and notifies all door locks to stop detection and data stream transmission via multicast. Specifically, the recovery detection and resource release includes: Single lock recovery detection: If any responding lock detects that the target object's emotional state has returned to normal during continuous monitoring, or detects that the target object's face matches but the emotion is normal, the lock sends an exit attention message to the router carrying the exit message type, the lock's identifier, and the feature hash value of the face feature vector. Router cumulative counting and decision-making: Based on the exit attention message received by the router, maintain the exit count associated with the event. When the cumulative number of exit messages received reaches the preset exit threshold, it is determined that the global exit condition is met. Policy and rule clearing: Based on the router's determination that the global exit conditions are met, delete the ingress interface classification rules, dynamic QoS policies, and priority queue configurations associated with the event; Network-wide exit notification: Based on the router's construction of a specific group query message carrying the end message type and the feature hash value of the face feature vector, it is sent via multicast to notify all door locks to stop sending data streams, face detection, and video storage for this event; First lock exit process: Upon receiving the end-of-attention message, the first lock stops video storage, sends an event end notification to the school management system, and clears the local state related to the event. Last resort timeout mechanism: If the router's duration timer starts after receiving the first protection request message expires and the exit mechanism is not triggered, it will automatically construct and send a termination of concern message and perform resource release.

[0023] Furthermore, the method also includes: Door lock identifier mapping establishment: When each door lock starts up, it sends an IGMPv3 join message carrying its own door lock identifier to the router. The router establishes a mapping table between the receiving interface and the door lock identifier for subsequent identification of the data stream source. Video stream targeted forwarding: After the router matches the data stream according to the classification rules, it queries the multicast forwarding table for the interface that records the lower 16 bits of the feature hash value of the face feature vector, and forwards the data stream only from that interface to the first door lock, realizing precise targeted transmission in point-to-multipoint; The first lock uses a progressive storage strategy: When the first lock does not receive a notification of key monitoring, it adopts a circular buffer strategy to limit the storage time; after receiving a notification of key monitoring, all data of the corresponding event in the circular buffer will be converted to permanent storage, realizing a smooth transition from temporary records to permanent evidence.

[0024] This invention provides a method and system for monitoring and protecting student emotional abnormalities based on door lock collaborative detection and dynamic QoS. When the first door lock detects a student exhibiting low mood, it immediately requests the router to provide medium-priority QoS protection for the video stream carrying the student's face, and notifies all other door locks to pay attention to the student's face via multicast. Other door locks, when simultaneously meeting both the "face matching" and "low mood" conditions, send real-time video streams to the first door lock via multicast. The router uses an ingress interface classification strategy to match the UDP source port (lower 16 bits of the face feature hash) and ingress interface of the video stream, directly identifying different source door locks and counting their numbers. When the number of active door locks reaches a preset threshold, the router proactively upgrades the QoS priority to high and notifies the first door lock to enter a state of focused monitoring for that student. The first door lock begins storing the video upon first receiving it, and upon receiving the focused notification, marks the event and notifies the school management system. When the student's mood recovers, the door lock observing this phenomenon sends an exit message to the router. After receiving a preset number of exit messages, the router triggers a full network exit, clears the QoS policy, and notifies all door locks to stop. Throughout the process, the door locks communicate via multicast, and the router proactively adjusts QoS based on counts to achieve bidirectional collaboration between the terminal and the network, avoiding single points of failure, ensuring the transmission quality of critical video streams, and automatically releasing resources. Solution: I. Prerequisites Smart door lock terminals (hereinafter referred to as "locks") are deployed at key locations throughout the campus (classroom entrances, corridors, dormitories, etc.). Each lock integrates a camera, a face detection module, an emotion recognition module (capable of recognizing two basic states: "depressed" and "normal"), and a Bluetooth / WiFi communication module. The locks have local computing capabilities, enabling real-time analysis of facial features and emotional states in video streams. All locks are pre-registered on the school's management platform and possess a unique device ID. The student facial feature database is pre-entered into the school's management platform and distributed to all registered locks, which can locally cache these facial features for rapid comparison. The router supports PIM and IGMPv3 multicast protocols (locks communicate using a specific multicast address, preset to 228.15.15.1) and QoS priority queue scheduling based on the DSCP field.

[0025] II. Solution Steps 1. The first door lock detected an abnormal student's emotional state and requested the router to set a medium-priority QoS policy for the video stream containing the student's face. (1) Each door lock (e.g., door lock A, B, C, etc.) sends an IGMPv3 join message with a destination address of 228.15.15.1 to the gateway router upon startup. The message carries the door lock ID of the door lock. After receiving the IGMPv3 message, the router records the door lock ID corresponding to each receiving interface, forming a mapping table: {interface → door lock ID}. This mapping table is used to identify the source of the video stream later.

[0026] (2) When the camera of the first door lock (denoted as door lock A) detects a pedestrian in the vicinity, it continuously performs face detection and emotion recognition. When it detects that the face feature vector of student S matches the pre-stored face features of students, and the emotion state is identified as "depressed", it extracts the face feature vector F of the student and calculates its feature hash value H (used to uniquely identify this event). Door lock A also sends an IGMPv3 message with a destination address of 228.15.15.1 to the gateway router. The message additionally carries the hash value H of the face feature vector of student S (used to guide the forwarding when other door locks reply to door lock A about the video stream of student S via multicast). After receiving the message, the router creates a multicast forwarding table (*, 228.15.15.1) and records the lower 16 bits of the hash value H of the face feature vector (used to match the source port number of the video stream sent by other door locks) on the interface (such as interface G0 / 1) that received the IGMPv3 message.

[0027] (3) Door lock A simultaneously sends a "student attention request" multicast message to the gateway router. The destination address of the message is 228.15.15.1. The message content carries: message type (0x01: student attention request), face feature vector hash value H (feature hash value, used for subsequent matching), QoS policy adjustment tag (and tag is set to 1), QoS adjustment priority level (medium priority, corresponding to DSCP=AF41), door lock A's device ID, and trigger timestamp.

[0028] (4) After receiving the “Student Attention Request” message, the router adjusts the tag field to 1 according to the QoS policy in the message and determines that it needs to process the message itself: ① The router generates the corresponding ingress interface classification rule policy based on the face feature vector hash value H, which is used to identify the video stream carrying the feature hash. The router dynamically issues the classification rule policy on each IGMP interface (i.e. the interface connected to the door lock) in the forwarding table of (*, 228.15.15.1). The policy matches: UDP source port = the lower 16 bits of H, and the UDP destination port is fixed as the video stream receiving port (e.g., 5004). Subsequent successfully matched messages are classified into a traffic category related to event H (e.g., video_H). ② The traffic category Video_H is also dynamically issued and mapped to a global QoS dynamic policy - key: lower 16 bits of face feature vector hash value H; value: priority level (AF41), creation time. When the router receives a data packet with UDP source port equal to the lower 16 bits of H, it rewrites its DSCP field to AF41 and sends it to the medium priority queue. ③ The router simultaneously configures a DSCP-based priority queue on the interface connected to the first door lock to achieve priority scheduling when multiple other door locks forward the video stream of student S to door lock A.

[0029] (5) The router forwards the “Student Attention Request” multicast message in the forwarding table (*, 228.15.15.1). After receiving the “Student Attention Request” message, other door locks (such as door locks B, C, D, etc.) parse out the face feature vector hash value H, enter the “waiting for response state”, start to activate the camera and perform face detection and emotion recognition on the real-time image.

[0030] 2: Other door locks undergo dual verification and video stream is sent via multicast.

[0031] (1) Each door lock in the "waiting to respond" state (e.g., door lock B) continuously analyzes the screen within a preset time window (e.g., 300 seconds). Door lock B calculates the hash value of the currently detected facial feature. If it matches H (similarity > threshold), it performs emotion recognition on the facial region. If the emotion recognition result is "depressed", door lock B determines that video reporting is required.

[0032] (2) Door lock B immediately starts sending a real-time video stream (encoding format H.264 / H.265) to the multicast address 228.15.15.1. The video stream data packet encapsulation requirements are: the UDP source port number P is set to the lower 16 bits of the face feature hash value H (value range 0-65535), the destination port is fixed to the video stream receiving port (e.g. 5004), and the DSCP field in the IP header is rewritten by the router according to the policy. Door lock can fill in 0 first.

[0033] (3) The video stream is sent via multicast. The router matches the characteristic video stream (the source port is the lower 16 bits of the hash value H of the face feature vector) according to the classification rules of the incoming interface. The router queries the multicast forwarding table (*, 228.15.15.1) to find the interface that records the lower 16 bits of the hash value H of the face feature vector (i.e., the interface connected to door lock A), and forwards the traffic to that interface. Door lock A, as a multicast receiver, starts storing the video stream in local storage media (SSD / TF card) according to the source door lock ID and time fragments from the moment it receives the first video stream data packet. The storage adopts a circular buffer strategy, retaining at most the most recent 1 hour of data to avoid unlimited space occupation.

[0034] (4) By identifying traffic matching this category on different inbound interfaces, the router can distinguish different source locks (by comparing the {interface→lock ID} mapping table). The router maintains an active lock statistics table, with the event identifier H as the key and the set of lock IDs of the detected traffic (lock IDs corresponding to the traffic inbound interface) as the value. When the number of active locks counted (excluding lock A) reaches a preset threshold (e.g., 3), the router triggers step 3.

[0035] 3: The router proactively upgrades the QoS policy priority and notifies door lock A to focus on monitoring student S.

[0036] (1) When the router counts that the number of active door locks has reached a threshold (e.g., 3), the router actively upgrades the priority of the corresponding event H in the dynamic QoS policy table from medium priority (AF41) to high priority (EF, i.e., accelerated forwarding). Specifically, the router maps the traffic category belonging to event H (e.g., video_H) to a high priority DSCP value (EF), so that subsequent packets of this type will be forwarded with high priority.

[0037] (2) The router constructs an IGMPv3 specific group query message with a destination address of 228.15.15.1, that is, the IGMPv3 specific group query message carries the following additional contents: message type (0x02: focus notification), event identifier H, current active door lock list (e.g. [B,C]), and trigger timestamp.

[0038] (3) Since “Personnel Focus” is an IGMP query message, all door locks can receive it. After receiving the message, the first door lock A marks the focus of the event H as “focus”. At the same time, it permanently retains the video segments of all door locks corresponding to the event H that are already stored locally (starting from the first reception) to prevent them from being overwritten by the circular buffer, and continues to store subsequent video streams.

[0039] (4) The first door lock A starts a timer for a duration of 30 minutes. After the timer expires, door lock A sends an abnormal event report to the school management system. The report includes: student facial features F, bound student ID, event start time, key confirmation time, video storage link, and a list of door locks participating in the response. The platform can arrange manual intervention based on this information.

[0040] 4: Student emotional recovery and exit mechanisms for door locks and routers (1) During continuous monitoring, a responding door lock (e.g., door lock B) detects that the target student S's emotional state changes from depressed to normal. Door lock B sends an exit watch message (an IGMPv3 join message with a destination address of 228.15.15.1) to the router. The message carries the message type (0x03: exit watch), the door lock ID, the event identifier H, the door lock ID, and the exit reason (emotional recovery). Door lock B continues to send a video stream about student S to door lock A (Note: When student S leaves the camera range of door lock B, door lock B can stop sending the video stream, but continue to monitor student S. The next time student S is detected, the video stream will be resumed). It is worth noting that when a new door lock (e.g., door lock D, where student S has never appeared nearby, so door lock D has never sent a video stream) receives the "student requests watch" message in step 1, it continues to monitor the screen. At some point, door lock D detects that the hash value of the facial feature vector matches H, but the emotion recognition result is "normal emotion". Then door lock D also sends an unfollow message to the router, but at the same time, door lock D still needs to report the video (fully record the emotional state changes of student S).

[0041] (2) After the router receives the “Exit Attention” message from door lock B, in order to avoid insufficient confidence of a single camera, the router can set a threshold (configurable, such as 2). After receiving the threshold number of “Exit Attention” messages sent by door locks, the router officially enters the “Exit Attention” state of the corresponding event H.

[0042] (3) The router clears the entries corresponding to the ingress interface classification rule policy, global dynamic QoS policy, and priority queue of the first lock interface (i.e., deletes all rules related to event H and stops QoS guarantee). The router constructs and sends an "End Attention" message (IGMPv3 specific group query) in the (*, 228.15.15.1) multicast group, carrying the message type (0x04: End Attention) and event H. The message requests all locks to stop sending, storing, and detecting video streams for event H.

[0043] (4) After receiving the "End Follow" message from the router, door lock A: stops video storage. Optional: Send an event end notification to the school management system. Clear the local state related to this event.

[0044] (5) After other door locks receive the “End of attention” message, they stop face and emotion detection and video transmission for event H, clear the temporary cache, and return to standby mode.

[0045] (6) If the router receives the “Student Attention Request” message and the duration timer (30 minutes) expires without triggering any exit mechanism, the router will automatically construct and send the “End Attention” message in the (*, 228.15.15.1) multicast group as a fallback mechanism.

[0046] Beneficial effects: 1. Multi-lock cross-verification: A lock is only upgraded to priority monitoring after multiple other locks simultaneously confirm a depressed mood and send a video stream, avoiding resource waste caused by single-point false alarms. 2. Upon triggering, the first lock immediately requests priority protection from the router. Subsequent routers proactively upgrade it to high priority once the number of multi-source video streams reaches a threshold, ensuring the quality of critical video transmission. 3. Utilizing inbound interface classification and matching of UDP source ports (lower 16 bits of facial feature hash), combined with an interface-lock ID mapping table to count the number of active locks, lightweight identification is achieved without DPI. 4. Other locks send video streams when they detect a target of interest. The first lock progressively stores the data (temporarily then permanently), significantly saving bandwidth and storage space. 5. Response locks send an exit message when they detect a recovered target of interest. The router clears the QoS policy after accumulating a certain number of responses or when the number of active locks falls below a threshold. New locks also send exit messages when they detect a normal target of interest, with a fallback timer ensuring resource release.

[0047] Protection Points: 1. The first door lock that detects a student's low mood initiates a collaborative request, stores the video streams reported by all other door locks, and determines whether to escalate to key monitoring based on the number of confirmations from the router, achieving distributed video recording and event management centered on the first door lock. 2. The router uses an ingress interface classification strategy to match the UDP source port (lower 16 bits of the face feature hash value) and destination port of the video stream; it distinguishes different door locks using a mapping table and counts the number of active door locks. Based on a preset threshold, it proactively upgrades the QoS priority of the corresponding video stream from medium to high level, achieving dynamic network resource protection based on terminal collaborative results. 3. The first door lock sends a "student attention request" message carrying the face feature hash value via multicast. The router forwards this message and triggers other door locks to enter a waiting state, starting to monitor the target student. Meanwhile, the router establishes an interface mapping table and forwarding rules based on the ID and facial feature hash value carried by the first lock in the IGMP message, so that subsequent video streams are only forwarded to the interface where the first lock is located; at the same time, the router uses IGMP specific group query messages to carry "focus" and "end focus" notifications to achieve precise notification only to relevant locks and avoid interference to irrelevant locks.

[0048] Another embodiment of the present invention provides a door lock collaborative business assurance system, see [link to relevant documentation]. Figure 3 The system may include: Triggering module 301 is used for abnormal event triggering and initial protection: based on the abnormal state of the target object detected by the first door lock, a protection request message carrying an event feature identifier is generated and sent to the router in the network via multicast; the router dynamically generates a data stream classification rule for the event based on the event feature identifier in the request message and assigns a medium-priority protection strategy to it; The confirmation module 302 is used for coordinated confirmation and active reporting: based on the protection request message forwarded by the router, other door locks enter the waiting response state, and when they match the event feature identifier and detect the same abnormal state at the same time, they send a real-time data stream carrying the event feature identifier to the multicast address. The router identifies the data streams on different ingress interfaces that match the classification rules and counts the number of active door locks participating in the response. Upgrade module 303 is used for dynamic policy upgrade and key monitoring: based on the number of active door locks counted by the router reaching a preset threshold, the priority of the data stream corresponding to the event is upgraded from medium priority to high priority, and the first door lock is notified to enter the key monitoring state via multicast; the first door lock starts storing data when it first receives the data stream, and permanently marks the stored data after receiving the key monitoring notification; The detection module 304 is used for recovery detection and resource release: if any responding door lock detects that the target object's state has returned to normal, it sends an exit attention message to the router; when the number of exit attention messages received reaches a preset exit threshold, the router clears the classification rules and priority policies associated with the event, and notifies all door locks to stop detection and data stream transmission via multicast.

[0049] This invention also provides a storage medium storing a computer program, wherein the computer program is configured to execute the steps in any of the above method embodiments when running.

[0050] This invention also provides an electronic device, including a memory and a processor, wherein the memory stores a computer program, and the processor is configured to run the computer program to perform the steps in any of the above method embodiments.

[0051] Specifically, the aforementioned electronic device may further include a transmission device and an input / output device, wherein the transmission device is connected to the aforementioned processor, and the input / output device is connected to the aforementioned processor.

[0052] The above description, based on the embodiments shown in the figures, details the structure, features, and effects of the present invention. The above description is only a preferred embodiment of the present invention, but the present invention is not limited to the scope of implementation shown in the figures. Any changes made in accordance with the concept of the present invention, or equivalent embodiments modified to have equivalent changes, that do not exceed the spirit covered by the specification and figures, should be within the protection scope of the present invention.

Claims

1. A method for ensuring business operations through door lock collaboration, characterized in that, The method includes: Abnormal event triggering and initial protection: Based on the abnormal state of the target object detected by the first door lock, a protection request message carrying an event feature identifier is generated and sent to the router in the network via multicast; the router dynamically generates data stream classification rules for the event based on the event feature identifier in the request message and assigns a medium-priority protection strategy to it; Collaborative confirmation and proactive reporting: Based on the protection request message forwarded by the router, other door locks enter a waiting response state, and when they simultaneously match the event feature identifier and detect the same abnormal state, they send a real-time data stream carrying the event feature identifier to the multicast address. The router identifies the data streams on different ingress interfaces that match the classification rules and counts the number of active door locks participating in the response. Dynamic policy upgrade and key monitoring: When the number of active door locks counted by the router reaches a preset threshold, the priority of the data stream corresponding to the event is upgraded from medium priority to high priority, and the first door lock is notified to enter the key monitoring state via multicast; the first door lock starts storing data when it first receives the data stream, and permanently marks the stored data after receiving the key monitoring notification; Recovery detection and resource release: If any responding door lock detects that the target object's status has returned to normal, it sends an exit attention message to the router; when the number of exit attention messages received reaches a preset exit threshold, the router clears the classification rules and priority policies associated with the event, and notifies all door locks to stop detection and data stream transmission via multicast.

2. The method according to claim 1, characterized in that, The abnormal event triggering and initial protection include: Anomaly detection and feature extraction: Based on the continuous monitoring of surrounding personnel by the first door lock, when the facial features of the target object match the pre-stored features and the emotion recognition result is abnormal, the feature hash value is calculated based on the facial feature vector of the target object, and this value is used to uniquely identify this event; Multicast Join and Interface Binding: Based on the first lock, an IGMPv3 join message carrying the lock identifier and the feature hash value of the face feature vector is sent to the router. After receiving the message, the router records the receiving interface in the multicast forwarding table and associates the lower 16 bits of the feature hash value of the face feature vector with that interface. Safeguarding the transmission of the request message: Construct a multicast message carrying the feature hash value of the face feature vector, the medium priority level and the request tag according to the first door lock, and send it to the preset multicast address; Classification rules are dynamically generated: After the router parses the protection request message and determines that it needs to be actively processed, it generates an ingress interface classification rule based on the feature hash value of the face feature vector. The classification rule matches the message in the data stream whose source port is equal to the lower 16 bits of the feature hash value of the face feature vector, and maps the successfully matched message to the medium priority queue.

3. The method according to claim 2, characterized in that, The collaborative confirmation and proactive reporting include: Activation of waiting state: Based on the guarantee request message forwarded by the router received by other door locks, the feature hash value of the face feature vector is parsed, and the waiting state is entered. Face detection and emotion recognition are continuously performed within the preset time window. Dual-condition determination: If the hash value of the face feature detected by any other door lock in the pending response state matches the hash value of the face feature vector, and the emotion recognition result is abnormal, it is determined that the reporting condition is met; Data stream multicast transmission: Based on the door locks that meet the reporting conditions, start sending real-time data streams to the preset multicast address, wherein the source port of the data stream packet is set to the lower 16 bits of the feature hash value of the face feature vector, and the destination port is fixed to the preset receiving port. Router identification and statistics: Based on the data streams received by the router through different ingress interfaces, the source port and destination port are matched using the classification rules. The traffic that is successfully matched is classified into the traffic category associated with the event. The router maintains an active lock statistics table, queries the pre-stored interface and lock identifier mapping relationship based on the ingress interface of the matched traffic, obtains the lock identifiers that participated in the response, and counts the number of active locks.

4. The method according to claim 3, characterized in that, The strategy includes dynamic upgrades and key monitoring, including: Threshold triggering and policy upgrade: Based on the number of active door locks counted by the router reaching a preset threshold, the priority of the traffic category corresponding to the event is dynamically changed from medium priority to high priority, and the global dynamic QoS policy is updated. Key monitoring notification: Based on the router, a specific group query message carrying the message type, facial feature vector feature hash value and the list of currently active door locks is constructed and sent via multicast so that all door locks can receive it; First Lock Storage Management: From the moment the first lock receives any data stream about the event, it continuously stores the data in a local circular buffer according to the lock identifier and time segmentation. When a key monitoring notification message is received, the feature hash value of the facial feature vector is parsed out, and all video segments corresponding to the event that have been stored locally are marked as permanently retained to prevent them from being overwritten by the circular buffer, and subsequent data streams are continued to be stored. Anomaly Reporting: Based on the first door lock start duration timer, an anomaly event report is sent to the school management system after the timer expires. The report includes the characteristics of the target object, the start time of the event, the key confirmation time, and the storage link.

5. The method according to claim 4, characterized in that, The recovery detection and resource release include: Single lock recovery detection: If any responding lock detects that the target object's emotional state has returned to normal during continuous monitoring, or detects that the target object's face matches but the emotion is normal, the lock sends an exit attention message to the router carrying the exit message type, the lock's identifier, and the feature hash value of the face feature vector. Router cumulative counting and decision-making: Based on the exit attention message received by the router, maintain the exit count associated with the event. When the cumulative number of exit messages received reaches the preset exit threshold, it is determined that the global exit condition is met. Policy and rule clearing: Based on the router's determination that the global exit conditions are met, delete the ingress interface classification rules, dynamic QoS policies, and priority queue configurations associated with the event; Network-wide exit notification: Based on the router's construction of a specific group query message carrying the end message type and the feature hash value of the face feature vector, it is sent via multicast to notify all door locks to stop sending data streams, face detection, and video storage for this event; First lock exit process: Upon receiving the end-of-attention message, the first lock stops video storage, sends an event end notification to the school management system, and clears the local state related to the event. Last resort timeout mechanism: If the router's duration timer starts after receiving the first protection request message expires and the exit mechanism is not triggered, it will automatically construct and send a termination of concern message and perform resource release.

6. The method according to claim 5, characterized in that, The method further includes: Door lock identifier mapping establishment: When each door lock starts up, it sends an IGMPv3 join message carrying its own door lock identifier to the router. The router establishes a mapping table between the receiving interface and the door lock identifier for subsequent identification of the data stream source. Video stream targeted forwarding: After the router matches the data stream according to the classification rules, it queries the multicast forwarding table for the interface that records the lower 16 bits of the feature hash value of the face feature vector, and forwards the data stream only from that interface to the first door lock, realizing precise targeted transmission in point-to-multipoint; The first lock uses a progressive storage strategy: When the first lock does not receive a notification of key monitoring, it adopts a circular buffer strategy to limit the storage time; after receiving a notification of key monitoring, all data of the corresponding event in the circular buffer will be converted to permanent storage, realizing a smooth transition from temporary records to permanent evidence.

7. A door lock collaborative business security system, characterized in that, The system includes: The triggering module is used for abnormal event triggering and initial protection: based on the abnormal state of the target object detected by the first door lock, a protection request message carrying the event feature identifier is generated and sent to the router in the network via multicast; the router dynamically generates data stream classification rules for the event based on the event feature identifier in the request message and assigns a medium-priority protection strategy to it; The confirmation module is used for coordinated confirmation and proactive reporting: based on the protection request message forwarded by the router, other door locks enter the waiting response state, and when they simultaneously match the event feature identifier and detect the same abnormal state, they send a real-time data stream carrying the event feature identifier to the multicast address. The router identifies the data streams on different ingress interfaces that match the classification rules and counts the number of active door locks participating in the response. The upgrade module is used for dynamic policy upgrades and key monitoring: based on the number of active door locks counted by the router reaching a preset threshold, the priority of the data stream corresponding to the event is upgraded from medium priority to high priority, and the first door lock is notified to enter the key monitoring state via multicast; the first door lock starts storing data when it first receives the data stream, and permanently marks the stored data after receiving the key monitoring notification; The detection module is used for recovery detection and resource release: if any responding door lock detects that the target object's status has returned to normal, it sends an exit attention message to the router; when the number of exit attention messages received reaches a preset exit threshold, the router clears the classification rules and priority policies associated with the event, and notifies all door locks to stop detection and data stream transmission via multicast.

8. The system according to claim 7, characterized in that, The triggering module is specifically used for: Anomaly detection and feature extraction: Based on the continuous monitoring of surrounding personnel by the first door lock, when the facial features of the target object match the pre-stored features and the emotion recognition result is abnormal, the feature hash value is calculated based on the facial feature vector of the target object, and this value is used to uniquely identify this event; Multicast Join and Interface Binding: Based on the first lock, an IGMPv3 join message carrying the lock identifier and the feature hash value of the face feature vector is sent to the router. After receiving the message, the router records the receiving interface in the multicast forwarding table and associates the lower 16 bits of the feature hash value of the face feature vector with that interface. Request message transmission is guaranteed: Construct a multicast message carrying the feature hash value of the face feature vector, the medium priority level and the request tag according to the first door lock, and send it to the preset multicast address; Classification rules are dynamically generated: After the router parses the protection request message and determines that it needs to be actively processed, it generates an ingress interface classification rule based on the feature hash value of the face feature vector. The classification rule matches the message in the data stream whose source port is equal to the lower 16 bits of the feature hash value of the face feature vector, and maps the successfully matched message to the medium priority queue.

9. A storage medium, characterized in that, The storage medium stores a computer program, wherein the computer program is configured to execute the method of any one of claims 1-6 when it is run.

10. An electronic device comprising a memory and a processor, characterized in that, The memory stores a computer program, and the processor is configured to run the computer program to perform the method of any one of claims 1-6.

Citation Information

Patent Citations

  • Service quality control method and network appliance

    CN101272324A

  • Intelligent door lock gateway access system and method for campus dormitory

    CN122090532A