Sensor management method, system and apparatus, and medium

WO2025140745A3PCT designated stage expired Publication Date: 2025-08-14E SURFING IOT CO LTD
View PDF 7 Cites 0 Cited by

Patent Information

Application Number
PCT/CN2025/079014
Authority / Receiving Office
WO · WO
Patent Type
Applications
Current Assignee / Owner
Priority Date
2023-12-26
Filing Date
2025-02-25
Publication Date
2025-08-14

AI Technical Summary

Technical Problem

The sensors of existing IoT terminal devices are closely coupled to the main control module, resulting in poor flexibility and high modification costs, making it difficult to adapt to the needs of multiple scenarios.

Method used

By configuring the sensor abstract map and description files, periodically read flag bits and sensor data, update the mapping and determine the target sensor for writable attributes, the main control unit writes attribute values ​​to the real sensor, and decouples the terminal and sensor.

Benefits of technology

It improves the flexibility of terminal equipment, reduces the cost of transformation, and realizes flexible adaptation of sensors.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN2025079014_14082025_PF_FP_ABST
    Figure CN2025079014_14082025_PF_FP_ABST
Patent Text Reader

Abstract

Disclosed in the present application are a sensor management method, system and apparatus, and a storage medium. The method comprises: configuring a sensor abstraction mapping and a sensor description file, wherein the sensor description file comprises an emergency flag bit and a modification flag bit; periodically reading the modification flag bit and the emergency flag bit, and periodically reading sensor data of real sensors; on the basis of the sensor data, updating the sensor abstraction mapping; and on the basis of the emergency flag bit and the modification flag bit, determining, from the updated sensor abstraction mapping, all target abstract sensors having a writable attribute, and making a main control unit write attribute values into all real sensors corresponding to the target abstract sensors. The present application is widely applied to the technical field of Internet of Things.
Need to check novelty before this filing date? Find Prior Art

Description

Sensor management method, system, device and medium Technical Field

[0001] The present application relates to the field of Internet of Things technology, and in particular to a sensor management method, system, device and storage medium. Background Art

[0002] In current IoT scenarios, each sensor-equipped terminal has a well-defined usage scenario. The sensor and the terminal's main control module are often tightly coupled, both at the software and hardware levels. This means that a given type of terminal device is often targeted at a specific, fixed scenario. New scenarios often require more than partial modification and redesign, requiring a complete terminal-level modification or redesign. This results in limited flexibility for each terminal and unnecessary cost associated with terminal modification. Consequently, there are still technical challenges that need to be addressed in the related art. Summary of the Invention

[0003] The purpose of this application is to solve one of the technical problems existing in the prior art to at least a certain extent.

[0004] To this end, an object of embodiments of the present application is to provide a sensor management method, system, device, and storage medium, which can improve the flexibility of the terminal and save the cost of terminal modification.

[0005] In order to achieve the above-mentioned technical objectives, the technical solutions adopted in the embodiments of the present application include: a sensor management method, comprising: configuring a sensor abstract mapping and a sensor description file; the sensor description file includes an emergency flag and a modification flag; periodically reading the modification flag and the emergency flag, and periodically reading the sensor data of the real sensor; updating the sensor abstract mapping according to the sensor data; determining all target abstract sensors with writable attributes in the updated sensor abstract mapping according to the emergency flag and the modification flag, and enabling the main control unit to write attribute values ​​to the real sensors corresponding to all the target abstract sensors.

[0006] In addition, the sensor management method according to the above embodiment of the present invention may also have the following additional technical features:

[0007] Furthermore, in an embodiment of the present application, the emergency flag includes a first modification target item and a first modification comparison item, and the modification flag includes a second modification target item and a second modification comparison item. The step of determining all target abstract sensors having writable attributes in the sensor abstraction map based on the emergency flag and the modification flag specifically includes:

[0008] When the bytes of the first modification target item and the first modification comparison item are different, or the bytes of the second modification target item and the second modification comparison item are different, traversing and comparing the modification identifiers of all sensors in the sensor abstract map, the modification identifiers including the third modification target item and the third modification comparison item;

[0009] For any sensor, when the bytes of the modification target item are different from the bytes of the modification comparison item, querying the first attributes of all the abstract sensors in the sensor abstract map;

[0010] The abstract sensor whose first attribute is a writable attribute is determined as a target abstract sensor.

[0011] Furthermore, in an embodiment of the present application, when the bytes of the first modification target item and the first modification comparison item are different, or the bytes of the second modification target item and the second modification comparison item are different, the step of traversing and comparing the modification identifiers of all sensors in the sensor abstraction map includes:

[0012] When the bytes of the first modification target item are adjusted from the first initial byte to the first target byte, or the bytes of the second modification target item are adjusted from the second initial byte to the second target byte, modification identifiers of all sensors in the sensor abstract map are traversed and compared.

[0013] Furthermore, in the embodiment of the present application, the method further includes:

[0014] After traversing all sensor attributes, the bytes of the first modification target item in the sensor description file are modified to the first initial bytes, or the bytes of the second modification target item in the sensor description file are modified to the second initial bytes.

[0015] Furthermore, in the embodiment of the present application, the step of updating the sensor abstract mapping according to the sensor data includes:

[0016] The sensor data of the real sensor is periodically read, and it is determined that the sensor data of the current cycle is different from the sensor data of the previous cycle, and the sensor abstract mapping is updated.

[0017] Furthermore, in an embodiment of the present application, the sensor data includes: sensor identity information, sensor name, and sensor mapping address. The step of periodically reading sensor data of a real sensor, determining that the sensor data of a current period is different from the sensor data of a previous period, and updating the sensor abstract mapping specifically includes:

[0018] Periodically reading sensor data of a real sensor, determining that the sensor name of a current period is different from the sensor name of a previous period, and updating the corresponding sensor name of the abstract sensor in the sensor abstraction map;

[0019] Alternatively, sensor data of a real sensor is periodically read, and it is determined that the sensor identity information of a current period is different from the sensor identity information of a previous period, and the corresponding sensor identity information of the abstract sensor in the sensor abstraction map is updated;

[0020] Alternatively, the sensor data of the real sensor is periodically read, and it is determined that the mapping address of the current cycle is different from the mapping address of the previous cycle, and the corresponding mapping address of the abstract sensor in the sensor abstract mapping is updated.

[0021] Furthermore, in an embodiment of the present application, the method also includes: periodically reading sensor data of a real sensor, determining that the sensor identity information, sensor name, and sensor mapping address of the current period are all different, and updating the corresponding mapping address, sensor name, and sensor identity information of the abstract sensor in the sensor abstract mapping.

[0022] On the other hand, an embodiment of the present application also provides a sensor management system, including: a configuration module for configuring a sensor abstract mapping and a sensor description file; the sensor description file includes an emergency flag and a modification flag; a reading unit for periodically reading the modification flag and the emergency flag, and periodically reading sensor data of real sensors; a first processing module for updating the sensor abstract mapping according to the sensor data; a second processing unit for determining all target abstract sensors with writable attributes in the updated sensor abstract mapping according to the emergency flag and the modification flag, and enabling the main control unit to write attribute values ​​to the real sensors corresponding to all the target abstract sensors.

[0023] On the other hand, the present application also provides a sensor management device, comprising:

[0024] at least one processor;

[0025] at least one memory for storing at least one program;

[0026] When the at least one program is executed by the at least one processor, the at least one processor implements a sensor management method as described in any one of the invention contents.

[0027] In addition, the present application also provides a computer-readable storage medium, which stores processor-executable instructions. When the processor executes the processor-executable instructions, the processor-executable instructions are used to perform a sensor management method as described in any one of the above items.

[0028] The advantages and benefits of this application will be partially given in the following description, and partially become apparent from the following description, or learned through practice of this application:

[0029] The present application can periodically read the sensor data of the real sensor and update the sensor abstract mapping according to the sensor data. After the update is completed, all target abstract sensors with writable attributes can be periodically determined in the sensor abstract mapping according to the emergency flag and the modification flag, and the main control unit can write attribute values ​​to the real sensors corresponding to all the target abstract sensors. The present application can decouple the terminal from the actual sensor and update the sensor abstract mapping. The main control unit can automatically write attribute values ​​to the real sensors corresponding to all the target abstract sensors according to the emergency flag and the modification flag to complete the adaptation of the new sensor. The present application can improve the flexibility of the terminal and save the cost of terminal modification. BRIEF DESCRIPTION OF THE DRAWINGS

[0030] FIG1 is a schematic diagram of the steps of a sensor management method according to a specific embodiment of the present invention;

[0031] FIG2 is a schematic diagram of steps for determining all target abstract sensors with writable attributes in a sensor abstraction map according to an emergency flag and a modification flag in a specific embodiment of the present invention;

[0032] FIG3 is a schematic diagram of the steps of traversing and comparing modification identifiers of all sensors in the sensor abstract map when the bytes of the first modification target item and the first modification comparison item are different, or the bytes of the second modification target item and the second modification comparison item are different, in a specific embodiment of the present invention;

[0033] FIG4 is a schematic diagram of steps of a sensor management method according to another specific embodiment of the present invention;

[0034] FIG5 is a schematic diagram illustrating the steps of periodically reading sensor data of a real sensor, determining that sensor data of a current cycle is different from sensor data of a previous cycle, and updating a sensor abstract mapping in a specific embodiment of the present invention;

[0035] FIG6 is a schematic diagram of steps of a sensor management method according to another specific embodiment of the present invention;

[0036] FIG7 is a schematic diagram of a data transmission process in a sensor management method according to a specific embodiment of the present invention;

[0037] FIG8 is a schematic diagram of the structure of a sensor management system according to a specific embodiment of the present invention;

[0038] FIG9 is a schematic structural diagram of a sensor management system in another specific embodiment of the present invention;

[0039] FIG10 is a schematic structural diagram of a sensor management device in a specific embodiment of the present invention. DETAILED DESCRIPTION

[0040] The following describes the embodiments of the present invention in detail with reference to the accompanying drawings to illustrate the principles and processes of the sensor management method, system, device, and storage medium in the embodiments of the present invention.

[0041] In today's IoT landscape, each sensor-equipped terminal has a well-defined usage scenario. The sensor and the terminal's main control module are often tightly coupled, both at the software and hardware levels. This means that a given type of terminal device is often designed for a specific scenario. New scenarios often require more than just partial modification and redesign, requiring a complete terminal-level modification or redesign. This results in limited flexibility for each terminal and unnecessary cost associated with terminal modification. Consequently, challenges remain in the relevant technologies that need to be addressed.

[0042] In view of the above-mentioned shortcomings of the related art, referring to Figure 1, which is a schematic diagram of the steps of a sensor management method provided by an embodiment of the present application, the sensor management method may include but is not limited to steps S101 to S104.

[0043] S101. Configure a sensor abstract mapping and a sensor description file; the sensor description file includes an emergency flag and a modification flag.

[0044] It is understandable that both the sensor abstract mapping and the sensor description file may be a file stored in the memory, and the content thereof may change according to different sensor connections.

[0045] In some feasible embodiments of the application, the processor may first configure the sensor abstraction mapping and the sensor description file; wherein the sensor description file may include an emergency flag bit and a modification flag bit.

[0046] S102: Periodically read the modification flag and the emergency flag, and periodically read the sensor data of the real sensor.

[0047] It's understood that sensor data from a real sensor can include the sensor ID (identification information), the sensor name (e.g., temperature sensor or humidity sensor), and the sensor's mapping address, which can correspond to the fixed mapping address for each sensor in the sensor abstraction mapping. A change in any of these three types of data is considered a change in the sensor.

[0048] In some embodiments of the present application, the processor may establish a wired or wireless connection with the acquisition module, periodically read the modification flag and the emergency flag, and periodically read the sensor data of the real sensor.

[0049] It should be noted that the aforementioned wired connection method may include a connection between a mobile device and a processing module, and may also include a connection between a processing module and a hardware device, and a wired connection between other currently known or future-developed devices and the processing module; and the aforementioned wireless connection method may include but is not limited to 3G / 4G / 5G connection, WiFi connection, Bluetooth connection, WiMAX connection, Zigbee connection, UWB (Ultra Wide Band) connection, and other currently known or future-developed wireless connection methods. The specific value of the first limit value of the built-in restriction policy, the specific value of the total number of releases configured by the user, and the specific value of the maximum limit value of the reported message can be configured and adjusted differently according to user needs.

[0050] S103: Update the sensor abstract mapping according to the sensor data.

[0051] It is understandable that the sensor abstract mapping may include identity information of the real sensor and the name of the sensor. The mapping address of the real sensor may correspond to the fixed mapping address of each sensor in the sensor abstract mapping.

[0052] In some feasible embodiments of the present application, the processor may periodically update the sensor abstraction map according to changes in sensor data.

[0053] S104 , determining all target abstract sensors with writable attributes in the updated sensor abstract map according to the emergency flag and the modification flag, and enabling the main control unit to write attribute values ​​to the real sensors corresponding to all target abstract sensors.

[0054] In some embodiments of the present application, after the updated sensor abstract mapping, the processor can determine all target abstract sensors with writable properties in the updated sensor abstract mapping based on the emergency flag and the modification flag in the sensor description file, and enable the main control unit to write property values ​​to the real sensors corresponding to all target abstract sensors.

[0055] It is understood that each abstract sensor can include either writable or readable attributes. For example, a temperature sensor and a humidity sensor are readable sensors, while a writable sensor is a sensor with a light, a fan, and a buzzer that can receive control commands.

[0056] In summary, this embodiment can periodically read the sensor data of the real sensor and update the sensor abstract mapping according to the sensor data. After the update is completed, it can periodically determine all target abstract sensors with writable attributes in the sensor abstract mapping according to the emergency flag and the modification flag, and enable the main control unit to write attribute values ​​to the real sensors corresponding to all target abstract sensors. This application can decouple the terminal from the actual sensor and update the sensor abstract mapping. It can automatically enable the main control unit to write attribute values ​​to the real sensors corresponding to all target abstract sensors according to the emergency flag and the modification flag to complete the adaptation of the new sensor. This application can improve the flexibility of the terminal and save the cost of terminal modification.

[0057] Further, referring to Figure 2, Figure 2 illustrates the steps for determining all target abstract sensors with writable attributes in the sensor abstraction map based on the emergency flag and the modification flag. In Figure 2, the emergency flag may include a first modification target item and a first modification comparison item, and the modification flag may include a second modification target item and a second modification comparison item. This step may specifically include steps S201 through S203.

[0058] S201: When the bytes of the first modification target item and the first modification comparison item are different, or the bytes of the second modification target item and the second modification comparison item are different, traverse and compare the modification identifiers of all sensors in the sensor abstract map, where the modification identifiers include the third modification target item and the third modification comparison item.

[0059] S202: For any sensor, when the bytes of the modified target item are different from the bytes of the modified comparison item, query the first attribute of all abstract sensors in the sensor abstract map;

[0060] S203: Determine an abstract sensor whose first attribute is a writable attribute as a target abstract sensor.

[0061] It is understood that the first modification target item and the first modification comparison item may be the modification target item and modification comparison item of the emergency flag in the sensor description file, and the second modification target item and the second modification comparison item may be the modification target item and modification comparison item of the modification flag in the sensor description file. The third modification target item and the third modification comparison item may be the modification identifier in the sensor abstract mapping. The first attribute may also be a readable or writable attribute corresponding to the abstract sensor.

[0062] In some feasible embodiments of the present application, when the bytes of the first modification target item are different from the bytes of the first modification control item, or the bytes of the second modification target item are different from the bytes of the second modification control item, the processor can traverse and compare the modification identifiers of all sensors in the sensor abstract mapping, and the modification identifiers include the third modification target item and the third modification control item; for any sensor, when the bytes of the modification target item are different from the bytes of the modification control item, the first attributes of all abstract sensors are queried in the sensor abstract mapping; and the abstract sensor whose first attribute is a writable attribute is determined as the target abstract sensor.

[0063] Further, referring to Figure 3 , Figure 3 illustrates the steps for traversing and comparing the modification identifiers of all sensors in the sensor abstract map when the bytes of the first modification target item and the first modification comparison item differ, or when the bytes of the second modification target item and the second modification comparison item differ. In Figure 3 , this step may include step S301 or step S302.

[0064] S301: When the byte of the first modification target item is adjusted from the first initial byte to the first target byte, traverse and compare the modification identifiers of all sensors in the sensor abstract map;

[0065] or

[0066] S302: When the byte of the second modification target item is adjusted from the second initial byte to the second target byte, traverse and compare the modification identifiers of all sensors in the sensor abstract map.

[0067] It can be understood that the first initial byte may be the byte of the first modification target item read in the previous cycle.

[0068] In some feasible embodiments of the present application, when the bytes of the first modification target item are adjusted from the first initial byte to the first target byte, or the bytes of the second modification target item are adjusted from the second initial byte to the second target byte, the processor can traverse and compare the modification identifiers of all sensors in the sensor abstract map.

[0069] Further, referring to Figure 4, which is a schematic diagram of steps of another sensor management method, the management method further includes step S105.

[0070] S105 . After traversing all sensor attributes, modify the bytes of the first modification target item in the sensor description file to the first initial bytes, or modify the bytes of the second modification target item in the sensor description file to the second initial bytes.

[0071] In some feasible embodiments of the present application, after completing the traversal of all sensor properties, the processor can modify the bytes of the first modification target item in the sensor description file to the first initial byte, or modify the bytes of the second modification target item in the sensor description file to the second initial byte.

[0072] Furthermore, the step of updating the sensor abstract mapping according to the sensor data includes step S301.

[0073] Step S301 : periodically read sensor data of real sensors, determine whether sensor data of a current period is different from sensor data of a previous period, and update the sensor abstract mapping.

[0074] In some feasible embodiments of the present application, the processor may periodically read sensor data of a real sensor, and when determining that the sensor data of a current cycle is different from the sensor data of a previous cycle, the processor may update the sensor abstraction map.

[0075] It can be understood that the sensor data may include sensor identification information, sensor name, and sensor mapping address.

[0076] Furthermore, the sensor data includes: sensor identity information, sensor name, and sensor mapping address. Referring to Figure 5, the sensor data of the real sensor is periodically read, and it is determined that the sensor data of the current cycle is different from the sensor data of the previous cycle. The step of updating the sensor abstract mapping specifically includes any one of steps S401-step S402, or steps S401-S403, or steps S401-S404.

[0077] S401, periodically reading sensor data of a real sensor;

[0078] S402, determining that the sensor name of the current cycle is different from the sensor name of the previous cycle, and updating the corresponding sensor name of the abstract sensor in the sensor abstraction map;

[0079] or,

[0080] S403: Determine that the sensor identity information of the current cycle is different from the sensor identity information of the previous cycle, and update the sensor identity information corresponding to the abstract sensor in the sensor abstraction mapping;

[0081] or,

[0082] S404 , periodically reading sensor data of the real sensor, determining that the mapping address of the current cycle is different from the mapping address of the previous cycle, and updating the corresponding mapping address of the abstract sensor in the sensor abstract mapping.

[0083] Furthermore, referring to FIG. 6 , the management method further includes step S405 .

[0084] S405: Determine that the sensor identity information, sensor name, and sensor mapping address of the current cycle are all different, and update the corresponding mapping address, sensor name, and sensor identity information of the abstract sensor in the sensor abstract mapping.

[0085] The specific implementation principle of this application is described below with reference to the accompanying drawings:

[0086] 7 and 8, the hardware structure of this application may include a main control module, a sensor information storage module, a sensor management system, and various sensors. The sensor management module mainly functions as follows: managing sensors, managing sensor description files, and managing sensor abstract mappings.

[0087] Managing sensors: The management module manages subordinate sensors through sensor drivers, including reading, writing, and execution, such as data collection, parameter setting, and device switching.

[0088] Managing sensor description files: Generate sensor description file information according to the sensor description file requirements (see below) for the sensor information under the management module, and synchronize it to the designated address for storing the sensor description file in the storage module.

[0089] Managing sensor abstract mapping includes two directions. One direction is to periodically synchronize sensor-related information to the storage module according to the sensor abstract mapping requirements (see below); the other direction is to synchronize the contents of the sensor abstract mapping in the storage module to the sensor on demand.

[0090] Sensor information storage module: This module is a shared storage unit that can be accessed by the sensor management module and the main control module at the same time; this storage unit is used to store sensor description files and sensor abstract mapping files, and it is stipulated that the sensor description files are stored starting from the first address.

[0091] Sensor description file: The sensor description file is used to describe the information of all sensors managed by the sensor management module.

[0092] The sensor description file format is defined in Table 1:

[0093] Table 1

[0094] In Table 1, the validity identifier can be used to help the program distinguish whether the information in the storage unit can be used. The 4-byte fixed character (such as "ABCD") is used to identify that the content of the sensor description file is legal and usable.

[0095] The total length of the sensor description file is a 2-byte binary number, and the user identifies the total length (number of bytes) of the entire sensor description file.

[0096] The emergency flag is divided into a target byte and a reference byte, totaling two bytes. The target byte is controlled by the main control unit. By modifying the value of this bit, it notifies the sensor management module that there is an urgent modification to the sensor abstract mapping part and requires an immediate response. The reference byte is controlled by the sensor management module and allows it to determine whether the emergency flag has been responded to. If the target and reference values ​​are the same, it means that a response has been received. If they are different, the flag has not yet been responded to.

[0097] The modification flag is also divided into a target byte and a reference byte, totaling two bytes. Similar to the emergency flag, the target byte is controlled by the main control unit. By modifying the value of this bit, the sensor management module is notified that the sensor abstract mapping has been modified. The reference byte is controlled by the sensor management module to determine whether the modification flag has been responded to. If the target and reference values ​​are the same, it indicates that a response has been received. If they are different, the flag has not yet been responded to.

[0098] The sensor quantity is a 1-byte binary number used to identify the number of sensor descriptions.

[0099] For the sensor information list, please refer to Table 2 and Table 3.

[0100] The format of a single sensor description unit is defined as follows:

[0101] Table 2

[0102] The sensor information list format is defined in Table 3:

[0103] Table 3

[0104] The sensor information list may contain multiple sensor description units, each of which contains three fields: sensor ID, name, and abstract mapping address.

[0105] Sensor abstract mapping: Sensor abstract mapping maps all sensor capabilities into storage space.

[0106] The format of a single attribute description unit is defined in Table 4:

[0107] Table 4

[0108] For the above attribute ID: For each sensor, the attribute ID needs to be unique.

[0109] Attribute name: The name of each attribute, which cannot be repeated.

[0110] Supported operations: Read, write, and execute are each assigned a byte for identification. 1 indicates that the operation is supported, and 0 indicates that the operation is not supported.

[0111] Last updated role: This byte is used to identify the role that last updated this attribute. 0 means the sensor management module last updated this field, and 1 means the control module last updated this field.

[0112] Attribute value length: 1 byte to identify the total length of the attribute value.

[0113] Attribute value: When the attribute value length is less than 8 bytes, the attribute value field that follows is used to store the attribute value directly starting from the low address; when the length is greater than 8 bytes, the first 4 bits of the attribute value field represent the actual attribute length, and the last 4 bits represent the actual address of the attribute in the storage unit.

[0114] The format of a single sensor mapping unit is defined as shown in Table 5:

[0115] Table 5

[0116] Number of attributes: Use 2 bytes to identify the number of attributes a sensor has, that is, how many attributes are in the attribute list of a sensor mapping unit.

[0117] Modification flag: The modification flag is divided into a target byte and a reference byte. The target byte is controlled by the main control unit, and by modifying the value of the bit, it marks whether the byte has been modified; the reference byte is controlled by the sensor management module, which determines whether the modification of the attribute value has been processed.

[0118] The attribute list consists of multiple attribute description units.

[0119] The sensor abstract mapping format is defined in Table 6:

[0120] Table 6

[0121] The sensor abstract mapping is composed of multiple sensor mapping units.

[0122] The overall process of the program is as follows:

[0123] S1, initialization phase:

[0124] 1) The sensor management module manages all subordinate sensors through the driver module, abstracts and plans the sensor capabilities according to the sensor abstract mapping format definition, and generates a sensor abstract mapping.

[0125] 2) After summarizing the generated sensor abstract mapping information, a sensor description file is generated according to the sensor description file format definition.

[0126] 3) The generated sensor description file and sensor abstract mapping are stored in a shared storage unit.

[0127] 4) After the main control unit detects the shared memory, it starts to read the sensor description file and further reads the sensor abstract mapping according to the content of the sensor description file.

[0128] S2. The main control unit reads the properties of the sensor:

[0129] 1) The sensor management module will periodically read sensor data without conditions, in order to maintain real-time, and update the various attributes of the sensor abstract map at the same time.

[0130] 2) The main control unit obtains the sensor data by reading the relevant attribute values ​​in the sensor abstract map.

[0131] S3. Write (or execute) sensor properties:

[0132] 1) The main control unit needs to write data to the sensor (or execute) to write the sensor attributes to be written into the abstract map. The sensor management module will periodically read the sensor description file. First, it will modify the attribute value corresponding to the sensor in the sensor abstract map; then modify the modification flag of the sensor abstract map attribute so that the target byte is inconsistent with the reference byte; finally, modify the modification flag bit of the sensor description file so that the target byte is inconsistent with the reference byte; if an emergency response is required, it is also necessary to modify the emergency flag bit so that the target byte is inconsistent with the reference byte.

[0133] Specifically, the sensor management module will periodically read the modification flag and the emergency flag of the sensor description file (the reading cycle of the emergency flag is shorter, and the cycle of the modification flag is slightly longer). In the current cycle, when it is found that the emergency flag or the modification flag of the sensor description file has changed from the initial byte to the target byte, this means that a new sensor has been connected, and the target byte is inconsistent with the reference byte, then the target byte in the sensor description file of the current cycle will be recorded (if both flags are different, both will be recorded) and the modification identification field of all abstract sensors in the sensor abstract map will be further traversed. When it is found that the target byte in the modification identification field is inconsistent with the reference byte, the properties of all abstract sensors in the sensor abstract map will be traversed to determine the abstract sensor with a writable property as the target abstract sensor that needs to be modified, and the corresponding property item will be modified (or executed) in the actual sensor corresponding to the target abstract sensor, and the traversal will continue. After completing the traversal of the property items of all sensor properties, the modification flag and the emergency flag of the sensor description file will be modified to the initial byte.

[0134] In addition, referring to FIG9 , corresponding to the method of FIG1 , a sensor management system is further provided in an embodiment of the present application. The system may include: a configuration unit 1001, a reading unit 1002, a first processing unit 1003, and a second processing unit 1004. The configuration unit 1001 may be used to configure a sensor abstract mapping and a sensor description file; the sensor description file includes an emergency flag and a modification flag; the reading unit 1002 may be used to periodically read the modification flag and the emergency flag, and periodically read sensor data of real sensors; the first processing unit 1003 may be used to update the sensor abstract mapping based on the sensor data; the second processing unit 1004 may be used to determine all target abstract sensors with writable attributes in the updated sensor abstract mapping based on the emergency flag and the modification flag, and enable the main control unit to write attribute values ​​to the real sensors corresponding to all target abstract sensors.

[0135] It should be noted that the acquisition unit can be any integrated circuit unit or microprocessor unit obtained by integrating a chip having processing functions and its peripheral circuits using existing integration technology. The first processing unit and the second processing unit can also be any integrated circuit module or microprocessor module obtained by integrating a chip having processing functions and its peripheral circuits using existing integration technology. The first processing unit and the second processing unit can also include one or more memories. One or more memories can be used to store the specific algorithm used for compression adjustment processing in this application.

[0136] In some embodiments of the present application, the acquisition unit 1001 and the processing unit 1002 may be provided in the same gateway or device having a processor. The specific device connection method and device configuration of the acquisition unit 1001 and the first processing unit 1002, and the first processing unit 1002 and the second processing unit 1003 are not limited.

[0137] It should be noted that the contents of the above-mentioned sensor management method embodiment are applicable to the present sensor management system embodiment. The functions specifically implemented by the present sensor management system embodiment are the same as those of the above-mentioned sensor management method embodiment, and the beneficial effects achieved are also the same as those achieved by the above-mentioned sensor management method embodiment.

[0138] Corresponding to the method of FIG1 , an embodiment of the present application further provides a sensor management device, the specific structure of which can be referred to FIG10 , including:

[0139] at least one processor 1011;

[0140] at least one memory 1012, configured to store at least one program;

[0141] When the at least one program is executed by the at least one processor, the at least one processor implements the sensor management method.

[0142] The contents of the above method embodiments are all applicable to the present device embodiments. The functions specifically implemented by the present device embodiments are the same as those of the above method embodiments, and the beneficial effects achieved are also the same as those achieved by the above method embodiments.

[0143] Corresponding to the method of FIG. 1 , an embodiment of the present application further provides a computer-readable storage medium storing processor-executable instructions, which are used to execute the sensor management method when executed by the processor.

[0144] The contents of the above-mentioned sensor management method embodiment are all applicable to the present storage medium embodiment. The functions specifically implemented by the present storage medium embodiment are the same as those of the above-mentioned sensor management method embodiment, and the beneficial effects achieved are also the same as those achieved by the above-mentioned sensor management method embodiment.

[0145] In some optional embodiments, the function / operation mentioned in the block diagram may not occur in the order mentioned in the operation diagram. For example, depending on the function / operation involved, the two boxes shown in succession can actually be executed substantially simultaneously or the boxes can sometimes be executed in reverse order. In addition, the embodiments presented and described in the flow chart of the present application are provided in an exemplary manner for the purpose of providing a more comprehensive understanding of the technology. The disclosed method is not limited to the operations and logical flows presented herein. Optional embodiments are contemplated in which the order of the various operations is changed and the sub-operations described as a part of a larger operation are performed independently.

[0146] In addition, although the present application is described in the context of functional modules, it should be understood that, unless otherwise stated, one or more of the functions and / or features may be integrated into a single physical device and / or software module, or one or more functions and / or features may be implemented in separate physical devices or software modules. It is also understood that a detailed discussion of the actual implementation of each module is not necessary for understanding the present application. More specifically, given the properties, functions, and internal relationships of the various functional modules in the devices disclosed herein, the actual implementation of the module will be understood within the routine skills of an engineer. Therefore, a person skilled in the art can implement the present application as set forth in the claims using ordinary techniques without undue experimentation. It is also understood that the specific concepts disclosed are merely illustrative and are not intended to limit the scope of the present application, which is determined by the full scope of the appended claims and their equivalents.

[0147] If the functions are implemented in the form of software functional units and sold or used as independent products, they can be stored in a computer-readable storage medium. Based on this understanding, the technical solution of the present application, or the part that contributes to the prior art, or the part of the technical solution, can be embodied in the form of a software product. The computer software product is stored in a storage medium and includes several programs for enabling a computer device (which can be a personal computer, a server, or a network device, etc.) to execute all or part of the steps of the method described in each embodiment of the present application. The aforementioned storage medium includes various media that can store program codes, such as a USB flash drive, a mobile hard disk, a read-only memory (ROM), a random access memory (RAM), a magnetic disk or an optical disk.

[0148] The logic and / or steps represented in a flowchart or otherwise described herein, for example, may be considered as an ordered list of executable programs for implementing the logical functions, and may be embodied in any computer-readable medium for use by, or in conjunction with, a program execution system, apparatus, or device (e.g., a computer-based system, a system including a processor, or other system that can retrieve and execute a program from a program execution system, apparatus, or device). For purposes of this specification, a "computer-readable medium" may be any device that can contain, store, communicate, propagate, or transport a program for use by, or in conjunction with, a program execution system, apparatus, or device.

[0149] More specific examples (a non-exhaustive list) of computer-readable media include the following: an electrical connection with one or more wires (electronic devices), a portable computer disk cartridge (magnetic devices), a random access memory (RAM), a read-only memory (ROM), an erasable and programmable read-only memory (EPROM or flash memory), a fiber optic device, and a portable compact disc read-only memory (CDROM). In addition, the computer-readable medium may even be paper or other suitable medium on which the program is printed, since the program may be obtained electronically, for example, by optically scanning the paper or other medium, followed by editing, deciphering, or processing in another suitable manner as necessary, and then stored in a computer memory.

[0150] It should be understood that various parts of the present application can be implemented using hardware, software, firmware, or a combination thereof. In the above embodiments, multiple steps or methods can be implemented using software or firmware stored in a memory and executed by a suitable program execution system. For example, if implemented using hardware, as in another embodiment, any one of the following technologies known in the art or a combination thereof can be used to implement: a discrete logic circuit having a logic gate circuit for implementing a logic function on a data signal, an application-specific integrated circuit having a suitable combination of logic gate circuits, a programmable gate array (PGA), a field programmable gate array (FPGA), etc.

[0151] In the above description of this specification, reference to the terms "one embodiment / example," "another embodiment / example," or "certain embodiments / examples" means that the specific features, structures, materials, or characteristics described in conjunction with the embodiment or example are included in at least one embodiment or example of the present application. In this specification, the schematic representation of the above terms does not necessarily refer to the same embodiment or example. Moreover, the specific features, structures, materials, or characteristics described can be combined in any appropriate manner in any one or more embodiments or examples.

[0152] Although the embodiments of the present application have been shown and described, those skilled in the art will appreciate that various changes, modifications, substitutions, and variations may be made to the embodiments without departing from the principles and intent of the present application, and that the scope of the present application is defined by the claims and their equivalents.

[0153] The above is a specific description of the preferred implementation of the present application, but the present application is not limited to the embodiments. Those skilled in the art may make various equivalent modifications or substitutions without violating the spirit of the present application. These equivalent modifications or substitutions are all included in the scope defined by the claims of the present application.

Claims

1. A sensor management method, characterized in that, It includes the following steps: Configure a sensor abstraction mapping and a sensor description file; The sensor description file includes an emergency flag bit and a modification flag bit; Periodically read the modification flag bit and the emergency flag bit, and periodically read the sensor data of the real sensor; Update the sensor abstraction mapping according to the sensor data; According to the emergency flag bit and the modification flag bit, determine all target abstract sensors with writable attributes in the updated sensor abstraction mapping, and enable the main control unit to write attribute values to the real sensors corresponding to all the target abstract sensors.

2. The sensor management method according to claim 1, wherein The emergency flag includes a first modification target item and a first modification comparison item, and the modification flag bit includes a second modification target item and a second modification comparison item. The step of determining all target abstract sensors with writable attributes in the sensor abstraction mapping according to the emergency flag bit and the modification flag bit specifically includes: When the bytes of the first modification target item and the first modification comparison item are different, or the bytes of the second modification target item and the second modification comparison item are different, traverse and compare the modification identifiers of all sensors in the sensor abstraction mapping. The modification identifier includes a third modification target item and a third modification comparison item; For any sensor, when the bytes of the modification target item are different from the bytes of the modification comparison item, query the first attribute of all the abstract sensors in the sensor abstraction mapping; Determine the abstract sensors with the first attribute being a writable attribute as the target abstract sensors.

3. The sensor management method according to claim 2, wherein The step of when the bytes of the first modification target item and the first modification comparison item are different, or the bytes of the second modification target item and the second modification comparison item are different, traverse and compare the modification identifiers of all sensors in the sensor abstraction mapping includes: When the byte of the first modification target item is adjusted from a first initial byte to a first target byte, or the byte of the second modification target item is adjusted from a second initial byte to a second target byte, traverse and compare the modification identifiers of all sensors in the sensor abstraction mapping.

4. The sensor management method according to claim 3, wherein The method further includes: After completing the traversal of all sensor attributes, modify the byte of the first modification target item in the sensor description file to the first initial byte, or modify the byte of the second modification target item in the sensor description file to the second initial byte.

5. The sensor management method according to claim 1, characterized in that The step of updating the sensor abstraction mapping according to the sensor data includes: Periodically read the sensor data of the real sensor, determine that the sensor data in the current period is different from the sensor data in the previous period, and update the sensor abstraction mapping.

6. The sensor management method according to claim 5, characterized in that The sensor data includes: sensor identity information, sensor name, and the mapping address of the sensor. The step of periodically reading the sensor data of the real sensor, determining that the sensor data in the current period is different from the sensor data in the previous period, and updating the sensor abstraction mapping specifically includes: Periodically read the sensor data of the real sensor. If it is determined that the sensor name in the current period is different from that in the previous period, update the corresponding sensor name of the abstract sensor in the sensor abstraction mapping; Alternatively, periodically read the sensor data of the real sensor. If it is determined that the sensor identity information in the current period is different from that in the previous period, update the corresponding sensor identity information of the abstract sensor in the sensor abstraction mapping; Alternatively, periodically read the sensor data of the real sensor. If it is determined that the mapping address in the current period is different from that in the previous period, update the corresponding mapping address of the abstract sensor in the sensor abstraction mapping.

7. The sensor management method according to claim 6, wherein The method further includes: Periodically read the sensor data of the real sensor. If it is determined that the sensor identity information, sensor name, and mapping address of the sensor in the current period are all different, update the corresponding mapping address, sensor name, and sensor identity information of the abstract sensor in the sensor abstraction mapping simultaneously.

8. A sensor management system, characterized in that, It includes: A configuration unit for configuring the sensor abstraction mapping and the sensor description file; The sensor description file includes an emergency flag bit and a modification flag bit; A reading unit for periodically reading the modification flag bit and the emergency flag bit, and periodically reading the sensor data of the real sensor; A first processing unit for updating the sensor abstraction mapping according to the sensor data; A second processing unit for determining all target abstract sensors with writable attributes in the updated sensor abstraction mapping according to the emergency flag bit and the modification flag bit, and causing the main control unit to write attribute values to the real sensors corresponding to all the target abstract sensors.

9. A sensor management device, characterized in that, It includes: At least one processor; At least one memory for storing at least one program; When the at least one program is executed by the at least one processor, the at least one processor implements a sensor management method according to any one of claims 1-7.

10. A computer-readable storage medium storing instructions executable by a processor, characterized in that, The instructions executable by the processor are used to execute a sensor management method according to any one of claims 1-7 when executed by the processor.

Citation Information

Patent Citations

  • Data integration method and device, storage medium and processor

    CN114138745A

  • Method for remotely upgrading embedded software of automatic weather station

    CN114721694A

  • Data processing method, data processing system and computer readable storage medium

    CN114780037A

  • Firmware program updating method and device of slave station equipment, equipment and storage medium

    CN115048129A

  • Software programming method and device and computer readable storage medium

    CN115599406A