Protocol fusion method and device, equipment and storage medium
By mapping the application layer services of the DL/T698.45 protocol and setting object identifiers in the DLMS/COSEM protocol, and integrating security mechanisms, the compatibility issues between the DLMS/COSEM protocol and the DL/T698.45 protocol are resolved, improving interoperability and communication efficiency between devices, and reducing system complexity and maintenance costs.
Patent Information
- Application Number
- CN202511245883.7
- Authority / Receiving Office
- CN · China
- Patent Type
- Applications(China)
- Current Assignee / Owner
- Filing Date
- 2025-09-02
- Publication Date
- 2025-11-21
AI Technical Summary
When power grid systems in different countries and regions are interconnected, the differences between the DLMS/COSEM protocol and the DL/T698.45 protocol become obstacles to system interoperability. Furthermore, the DLMS/COSEM protocol is highly complex and difficult to adapt to the flexible data acquisition needs in China.
By mapping the application layer service set of the DL/T698.45 protocol to the DLMS/COSEM protocol, and setting consistent object identifiers and integrating its security mechanisms in the DLMS/COSEM protocol, interoperability and communication efficiency between protocols are improved.
It achieves compatibility between the DLMS/COSEM protocol and the DL/T698.45 protocol, improves interoperability and communication efficiency between devices, reduces system complexity and maintenance costs, and ensures communication security.
Smart Images

Figure CN121000802A_ABST
Abstract
Description
Technical Field
[0001] This application belongs to the field of smart grid energy management technology, and more specifically, relates to a protocol fusion method, apparatus, device and storage medium. Background Technology
[0002] DLMS / COSEM (Device Language Message Specification / Companion Specification for Energy Metering) is an international standard communication protocol widely used in smart meters and energy management systems. It has high flexibility and interoperability, is suitable for a variety of energy metering devices, and is widely used internationally.
[0003] DL / T 698.45 is a standard communication protocol for China's power industry, primarily used for electricity metering and data acquisition. Optimized for the characteristics of China's power grid, this protocol boasts efficient data transmission and security, and is widely used in domestic smart meters and concentrators, holding a dominant position in the Chinese market.
[0004] With the globalization of smart grids, the demand for interconnection and interoperability of power grid systems in different countries and regions is constantly increasing, but differences in communication protocols have become an obstacle to system interoperability. Although DLMS / COSEM supports unified modeling of multiple energy types (e.g., electricity / water / gas / heat), its protocol complexity is high and it is difficult to adapt to the flexible data acquisition needs in China.
[0005] Therefore, integrating these two protocols is of great significance for achieving interconnection and data sharing between devices with different protocols. Summary of the Invention
[0006] One of the objectives of this application is to provide a protocol fusion method, apparatus, device, and storage medium to achieve the fusion of the DLMS / COSEM protocol with the DL / T698.45 protocol, thereby improving interoperability and communication efficiency between different devices.
[0007] A first aspect of this application provides a protocol fusion method for fusing a first protocol with a second protocol, the method comprising:
[0008] The application layer service set of the second protocol is mapped to the application layer service set of the first protocol; the first protocol includes: DLMS / COSEM protocol, and the second protocol includes: DL / T698.45 protocol;
[0009] In the first protocol, an object identifier is set for the second protocol that is consistent with the first protocol;
[0010] Integrate the security mechanisms of the second protocol into the first protocol.
[0011] A second aspect of this application provides a protocol fusion apparatus, comprising:
[0012] The first fusion module is used to map the application layer service set of the second protocol to the application layer service set of the first protocol; the first protocol includes: DLMS / COSEM protocol, and the second protocol includes: DL / T698.45 protocol;
[0013] The second fusion module is used to set an object identifier for the second protocol that is consistent with the first protocol in the first protocol;
[0014] The third fusion module is used to integrate the security mechanism of the second protocol into the first protocol.
[0015] A third aspect of this application provides an electronic device, including a memory, a processor, and a computer program stored in the memory and running on the processor, wherein the processor executes the computer program to implement the steps of the above-described protocol fusion method.
[0016] A fourth aspect of this application provides a computer-readable storage medium storing a computer program that, when executed by a processor, implements the steps of the protocol fusion method described above.
[0017] A fifth aspect of this application provides a computer program product, including a computer program or computer executable instructions, wherein when the computer program or computer executable instructions are executed by a processor, the steps of the above-described protocol fusion method are implemented.
[0018] The protocol fusion method, apparatus, device, and storage medium provided in this application embodiment have at least the following effects:
[0019] The first protocol of this application includes the DLMS / COSEM protocol, and the second protocol includes the DL / T698.45 protocol. This is achieved by mapping the application layer service set of the second protocol to the application layer service set of the first protocol; setting an object identifier for the second protocol that is consistent with the first protocol in the first protocol; and integrating the security mechanism of the second protocol into the first protocol. This realizes the integration of the DLMS / COSEM protocol and the DL / T698.45 protocol at the application layer, solves the compatibility problem of the DLMS / COSEM protocol with the DL / T698.45 protocol, improves the interoperability and communication efficiency between devices using the two protocols, and reduces system complexity and maintenance costs. Attached Figure Description
[0020] To more clearly illustrate the technical solutions in the embodiments of this application, the drawings used in the description of the embodiments or the prior art will be briefly introduced below. Obviously, the drawings described below are only some embodiments of this application. For those skilled in the art, other drawings can be obtained based on these drawings without creative effort.
[0021] Figure 1 A schematic flowchart illustrating a protocol fusion method provided in an embodiment of this application;
[0022] Figure 2 A structural block diagram of a protocol fusion device provided in an embodiment of this application;
[0023] Figure 3 This is a schematic block diagram of an electronic device provided in an embodiment of this application. Detailed Implementation
[0024] In the following description, specific details such as particular system architectures and techniques are set forth for illustrative purposes and not for limitation, in order to provide a thorough understanding of the embodiments of this application. However, those skilled in the art will understand that this application may also be implemented in other embodiments without these specific details. In other instances, detailed descriptions of well-known systems, apparatuses, circuits, and methods have been omitted so as not to obscure the description of this application with unnecessary detail.
[0025] To make the objectives, technical solutions, and advantages of this application clearer, the following description will be provided in conjunction with the accompanying drawings and specific embodiments.
[0026] Please refer to Figure 1 , Figure 1 The flowchart illustrates a protocol fusion method provided in an embodiment of this application, which can be executed by the protocol fusion device of this application. This device can be configured in an electronic device. The method includes:
[0027] S1: Map the application layer service set of the second protocol to the application layer service set of the first protocol. The first protocol includes the DLMS / COSEM protocol, and the second protocol includes the DL / T698.45 protocol.
[0028] Application layer services include connection, reading, setting, and operation. The application layer service set of the second protocol includes various services of the DL / T698.45 protocol application layer. After mapping the application layer service set of the second protocol to the application layer service set of the first protocol, the DLMS / COSEM protocol can be compatible with the application layer services of the DL / T698.45 protocol, realizing the integration of service function level.
[0029] S2: Set an object identifier for the second protocol in the first protocol that is consistent with the first protocol;
[0030] Object identifiers are used to identify managed objects. After setting object identifiers for the second protocol, the first protocol can manage the managed objects of the second protocol when performing application layer services of the second protocol, realizing services such as checking balances and calculating electricity bills. Moreover, the object identifiers of the second protocol are set in the first protocol in the same way as those of the first protocol, so the first protocol can also manage these managed objects when performing application layer services of the original first protocol, thus better realizing the integration of the first and second protocols.
[0031] S3: Integrate the security mechanisms of the second protocol into the first protocol.
[0032] The security mechanism of the second protocol is used to protect the security of power communication, ensuring that information cannot be tampered with during transmission through data encryption and authentication mechanisms. By integrating the security mechanism of the second protocol into the first protocol, the first protocol can use the same security mechanism to ensure the security of power communication, reducing the security risks caused by the difference in security mechanisms between the two protocols when devices based on the first protocol communicate with devices based on the second protocol.
[0033] In this embodiment, the protocol fusion method maps the application layer set of the second protocol to the application layer set of the first protocol, and sets an object identifier for the second protocol in the first protocol. This achieves the fusion of the DLMS / COSEM protocol and the DL / T698.45 protocol at the application layer, solving the compatibility problem between the DLMS / COSEM protocol and the DL / T698.45 protocol, improving the interoperability and communication efficiency between devices using the two protocols, and reducing system complexity and maintenance costs. Furthermore, the first protocol also incorporates the security mechanisms of the second protocol, ensuring the security of devices using the first protocol when receiving, processing, and managing data based on the second protocol. Thus, devices using the DL / T698.45 protocol can interoperate with devices using the DLMS / COSEM protocol, reducing system complexity and management costs.
[0034] It should be noted that there is no strict order restriction for the execution of steps S1, S2, and S3 in this application; they can be executed in other orders or simultaneously. Figure 1 The execution method described is merely an example and is not intended to be limiting.
[0035] In this embodiment, the application layer service set of the first protocol may include application layer connection service, GET (get) service, SET (set) service and ACTION (operation) service, and the application layer service set of the second protocol may include application layer connection service, GET service, SET service, ACTION service, SetThenGetRequestNormalList (retrieves several object properties after requesting to set) service and ActionThenGetRequestNormalList (retrieves several object properties after requesting to operate on several object methods) service.
[0036] In one embodiment, step S1, mapping the application layer service set of the second protocol to the application layer service set of the first protocol, includes:
[0037] S11. Map the application layer connection service in the second protocol to the application layer connection service of the first protocol.
[0038] The application layer connection service of the second protocol may include pre-connection and application connection. During the mapping process, both pre-connection and application connection can be mapped to the application layer connection service of the first protocol.
[0039] S12. Map the Get service in the second protocol to the Get service in the first protocol;
[0040] Optionally, the Get services of the second protocol include GetRequestNormal (request to read an object property), GetRequestNormalList (request to read several object properties), GetRequestRecord (request to read a record-type object property), GetRequestRecordList (request to read several record-type object properties), GetRequestNext (request to read the next frame of the framed transmission), GetRequestMD5 (request to read the MD5 value of an object property), GetRequestWithParaList (read request service with a parameter list), GetRequestConsistentRecord (request to read consistent records service), and GetRequestSimplifyRecord (request to read simplified records service).
[0041] GetRequestNormal in the second protocol can be mapped to GetRequestNormal in the first protocol;
[0042] The GetRequestNormalList in the second protocol can be mapped to the GetRequestWithList (retrieving requests with a list) in the first protocol;
[0043] GetRequestRecord in the second protocol can be mapped to GetRequestNormal in the first protocol, allowing users to selectively access GetRequestRecord in the second protocol;
[0044] The GetRequestRecordList in the second protocol can be mapped to the GetRequestWithList in the first protocol. Users can selectively access the GetRequestRecordList in the second protocol.
[0045] The GetRequestNext function in the second protocol can be mapped to the Get Request NextBlock function in the first protocol (request the next data block).
[0046] GetRequestMD5, GetRequestWithParaList, GetRequestConsistentRecord, and GetRequestSimplifyRecord in the second protocol can be mapped to GetRequestNormal in the first protocol. Users can selectively access the above four services in the second protocol.
[0047] After the Get service of the second protocol is mapped to the Get service of the first protocol, the device using the first protocol can read data from the second protocol.
[0048] S13. Map the Set service in the second protocol to the Set service in the first protocol;
[0049] The second protocol's Set service includes SetRequestNormal (which requests to set several object properties) and SetRequestNormalList (which requests to set several object properties).
[0050] The SetRequestNormal in the second protocol can be mapped to the SetRequestNormal in the first protocol;
[0051] The SetRequestNormalList in the second protocol can be mapped to the SetRequestWithList (Set Request with List) in the first protocol.
[0052] After the Set service of the second protocol is mapped to the Set service of the first protocol, the device using the first protocol can set the data of the second protocol.
[0053] S14. Map the Action service in the second protocol to the Action service in the first protocol;
[0054] The Action service of the second protocol includes ActionRequestNormal (requesting to operate on one object method) and ActionRequestNormalList (requesting to operate on several object methods);
[0055] The ActionRequestNormal in the second protocol can be mapped to the ActionRequestNormal in the first protocol;
[0056] The ActionRequestNormalList in the second protocol can be mapped to the ActionRequestWithList in the first protocol.
[0057] After the Action service of the second protocol is mapped to the Action service of the first protocol, the device using the first protocol can operate on the data of the second protocol.
[0058] S15. Map the SetThenGetRequestNormalList (retrieves several object properties after requesting to set) and ActionThenGetRequestNormalList (retrieves several object properties after requesting to operate on several object methods) services in the second protocol to the Access service in the first protocol.
[0059] After the mapping in step S15 is completed, the device using the first protocol can perform the service of setting before reading and the service of operating before reading on the data of the second protocol.
[0060] In this embodiment, the application layer connection service, GET service, SET service, ACTION service, SetThenGetRequestNormalList service, and ActionThenGetRequestNormalList service in the second protocol are all mapped to the first protocol. Therefore, devices using the first protocol can interoperate with devices using the second protocol and perform reading, setting, operation, setting-then-reading, and operation-then-reading services on the data of the second protocol.
[0061] In one implementation, mapping the application layer connection service in the second protocol to the application layer connection service of the first protocol includes:
[0062] S111. Add a preset special service of the second protocol to the protocol consistency block in the application layer connection service of the first protocol. The preset special service is a service other than the Get service, Set service and Action service.
[0063] The DLMS / COSEM protocol has a consistency block, which ensures that various real-world environments can communicate with different performance levels based on the same DLMS protocol. This application adds a pre-defined special service of a second protocol to the consistency block, enabling functional extensions to the DLMS / COSEM protocol. This allows devices using the DLMS / COSEM protocol to communicate with devices using the DL / T698.45 protocol.
[0064] S112. Add the authentication request of the second protocol to the authentication request object in the first protocol application layer connection service.
[0065] When a device using the first protocol, which has completed authentication request fusion, receives a communication request from a device using the original second protocol's authentication request, the first protocol can authenticate the communication request using the authentication request method corresponding to the second protocol, and then communication can proceed after successful authentication. This embodiment allows the first protocol to add the second protocol's authentication request method, which can prevent illegal communication requests and improve the security of inter-system interoperability.
[0066] In this embodiment, the protocol fusion method extends communication functionality through the consistency block of the DLMS / COSEM protocol, reducing the difficulty of communication fusion between the DL / T698.45 protocol and the DLMS / COSEM protocol. Furthermore, the protocol fusion method adds an authentication request for the second protocol to the authentication request object in the application layer connection service of the first protocol. Devices using the first protocol can communicate with devices based on the second protocol upon successful authentication, preventing unauthorized communication and ensuring communication security.
[0067] In one implementation, setting an object identifier for the second protocol that is consistent with the first protocol in the first protocol includes:
[0068] S20. Set up a utility-specific class for the second protocol so that the interface corresponding to the utility table of the first protocol can recognize data from the second protocol.
[0069] The DLMS / COSEM protocol enables the "Utility Table" interface class to accept DL / T 698.45 data. Specifically, class 36 of the DLMS / COSEM protocol can be defined as a dedicated class for the DL / T 698.45 protocol. This class includes 3 attributes and 0 methods. The 3 attributes include OBIS (Object Identification System), OAD (Object Attribute Designator), and Buffer. OBIS is 6 bytes and represents a field from the DLMS / COSEM protocol; OAD is 2 bytes and stores the OI (Object Identifier) of the DL / T 698.45 protocol, such as OIA and OIB. Attribute and index information from the second protocol, as well as other data items not included in the application layer service set (such as curve time information, entry count, time stamp fields, etc.), are mapped to the Buffer.
[0070] In one implementation, setting an object identifier for the second protocol that is consistent with the first protocol in the first protocol includes:
[0071] Define a class mapping object for the second protocol, mapping the identifier of the class mapping object to the OBIS of the first protocol. Specifically, this includes:
[0072] 1) Map the custom flag bit to OBIS-A; in one implementation, the value of the custom flag bit can be set to a specific value, such as 1, to indicate that the OBIS code is user-defined and not a standard definition.
[0073] 2) Map the measured channel number to OBIS-B; currently, this information is not available in the data frames of the DL / T698.45 protocol, and this value can be set to 0.
[0074] 3) Map the protocol identifier of the second protocol to OBIS-C; you can select one of the unused fields of the DLMS / COSEM protocol as the DL / T698.45 protocol identifier, for example, select an unused identifier from 0-89 as the DL / T698.45 protocol identifier.
[0075] 4) Map the OIA of the second protocol to OBIS-D; and
[0076] 5) Map the OIB of the second protocol to OBIS-E.
[0077] In addition, the OBIS-F byte is not used and can be set to a fixed value of 0xFF.
[0078] Taking OBIS-C as defined as 0x59H as an example, the original DL / T698.45 object OI is mapped to the DLMS / COSEM protocol OBIS as shown in the table below:
[0079]
[0080] In this embodiment, the DLMS / COSEM protocol defines an object identifier corresponding to the object in the DL / T 698.45 protocol, which enables the DLMS / COSEM protocol to accurately identify the object in the DL / T 698.45 protocol, ensuring that the fused DLMS / COSEM protocol can communicate with the DL / T 698.45 protocol.
[0081] In one implementation, integrating the security mechanism of the second protocol into the first protocol includes:
[0082] S31. Add a second authentication method to the existing authentication method of the first protocol, and identify the required authentication method by combining the connection service source language with the authentication mechanism name;
[0083] This embodiment adds DL / T698.45 authentication methods 0x10-0x13 to the existing DLMS / COSEM protocol authentication methods 0x00-0x07. During the application of the merged protocol, the server or application can determine which authentication method to use by establishing a connection service source term followed by the authentication mechanism name. For example, if the authentication mechanism name is 0x12, the DL / T698.45 authentication method is used; if the authentication mechanism name is 0x05, the existing DLMS / COSEM protocol authentication method is used.
[0084] The integration of access mechanisms ensures the security of the interoperability process between the two protocols.
[0085] S32. Add security services of the second protocol to the existing security services of the first protocol, while retaining the original format of the security services of the second protocol;
[0086] In one implementation, the original security service identifier of the DLMS / COSEM protocol is security service 219-221. This application can add security service 240 on the basis of the original security service of the DLMS / COSEM protocol. The SECURITY-Request
[16] and SECURITY-Response
[144] of the DL / T698.45 protocol are both mapped to security service 240. The format of the APDU (Application Protocol Data Unit) of security service 240 is consistent with the original DL / T698.45 protocol security service. Of course, this application can also use other reserved service identifiers in the DLMS / COSEM protocol as DL / T698.45 security service mappings, which is not limited here.
[0087] S33. Add a security suite for the second protocol to the existing security suite of the first protocol.
[0088] In one implementation, the original security suites of the DLMS / COSEM protocol are 0x00, 0x01, and 0x02. This application adds the DL / T698.45 protocol security suite 0x10 to these. During the application of the integrated protocol, when security suite 0x10 is used, the access authentication method should adopt 0x10-0x13 in the integrated protocol, and the security service should adopt security service 240 in the integrated protocol.
[0089] The protocol fusion method in this embodiment integrates the security services and security suites of the DL / T698.45 protocol into the DLMS / COSEM protocol, enabling the fused DLMS / COSEM protocol to provide more secure protection and ensuring the security of the fused DLMS / COSEM protocol when interoperating with the DL / T698.45 protocol.
[0090] Corresponding to the protocol fusion method in the above embodiments, Figure 2 This is a structural block diagram of a protocol fusion apparatus provided according to an embodiment of this application. For ease of explanation, only the parts relevant to the embodiment of this application are shown. References Figure 2 This application also provides a protocol fusion apparatus, comprising:
[0091] The first fusion module 21 is used to map the application layer service set of the second protocol to the application layer service set of the first protocol; the first protocol includes: DLMS / COSEM protocol, and the second protocol includes: DL / T698.45 protocol;
[0092] The second fusion module 22 is used to set an object identifier for the second protocol that is consistent with the first protocol in the first protocol;
[0093] The third fusion module 23 is used to integrate the security mechanism of the second protocol into the first protocol.
[0094] The first fusion module 21 includes:
[0095] The connection fusion module is used to map the application layer connection service in the second protocol to the application layer connection service of the first protocol.
[0096] The fusion module is used to map the Get service in the second protocol to the Get service in the first protocol.
[0097] Set up a fusion module to map the Set service in the second protocol to the Set service in the first protocol;
[0098] The operation fusion module is used to map Action services in the second protocol to Action services in the first protocol; and
[0099] The composite fusion module is used to map the SetThenGetRequestNormalList and ActionThenGetRequestNormalList services in the second protocol to the Access service in the first protocol.
[0100] The connectivity and fusion module includes:
[0101] The connection protocol fusion module is used to add a second protocol to the protocol consistency block in the application layer connection service of the first protocol; and
[0102] The connection authentication fusion module is used to add authentication requests for the second protocol to the authentication request object in the first protocol application layer connection service.
[0103] The second fusion module 22 includes:
[0104] The identification and fusion module is used to set a public utility-specific class for the second protocol, so that the interface corresponding to the public utility table of the first protocol can identify the data from the second protocol.
[0105] Optionally, the utility-specific class includes a buffer attribute, and the second fusion module 22 further includes:
[0106] The cache fusion module is used to map the attribute and index information in the second protocol, as well as other data items not included in the application layer service set, into the Buffer.
[0107] Optionally, the public utility-specific class includes Object Identification System (OBIS) attributes, and the identification fusion module includes:
[0108] An identifier fusion module is used to define class mapping objects for the second protocol and map the identifiers of the class mapping objects to the OBIS of the first protocol. Specifically, the identifier fusion module includes:
[0109] A custom flag fusion module is used to map custom flags to OBIS-A;
[0110] The channel number fusion module is used to map the measured channel number to OBIS-B;
[0111] The protocol identifier fusion module is used to map the protocol identifier of the second protocol to OBIS-C;
[0112] The OIA fusion module is used to map the OIA of the second protocol to OBIS-D; and
[0113] The OIB fusion module is used to map the OIB of the second protocol into OBIS-E.
[0114] The third fusion module 23 includes:
[0115] The access mechanism fusion module is used to add a second protocol authentication method to the original authentication method of the first protocol. It identifies the authentication method to be used by combining the connection service source language with the authentication mechanism name.
[0116] The security service fusion module is used to add security services of the second protocol to the existing security services of the first protocol, while retaining the original format of the security services of the second protocol; and
[0117] The security suite fusion module is used to add a security suite for a second protocol to the existing security suite of the first protocol.
[0118] See Figure 3 , Figure 3 This is a schematic block diagram of an electronic device provided according to an embodiment of this application. Figure 3 The electronic device 300 in this embodiment may include one or more processors 301, one or more input devices 302, one or more output devices 303, and one or more memories 304. The processors 301, input devices 302, output devices 303, and memories 304 communicate with each other via a communication bus 305. The memories 304 store computer programs, including program instructions. The processors 301 execute the program instructions stored in the memories 304. Specifically, the processors 301 are configured to invoke the program instructions to perform the functions of each module / unit in the above-described device embodiments, for example... Figure 2 The functions of the first fusion module 21, the second fusion module 22, and the third fusion module 23 shown are illustrated.
[0119] It should be understood that, in the embodiments of this application, the processor 301 may be a central processing unit (CPU), but it may also be other general-purpose processors, digital signal processors (DSPs), application-specific integrated circuits (ASICs), field-programmable gate arrays (FPGAs), or other programmable logic devices, discrete gate or transistor logic devices, discrete hardware components, etc. The general-purpose processor may be a microprocessor or any conventional processor.
[0120] In one embodiment, the input device 302 and the output device 303 may include RS485, RS232, fiber optic communication interface, public network communication module, point-to-point communication module, etc.
[0121] The memory 304 may include read-only memory and random access memory, and provides instructions and data to the processor 301. A portion of the memory 304 may also include non-volatile random access memory. For example, the memory 304 may also store device type information.
[0122] In specific implementations, the processor 301, input device 302, and output device 303 described in the embodiments of this application can execute the implementation methods described in the protocol fusion method provided in the embodiments of this application, or they can execute the implementation methods of the electronic devices described in the embodiments of this application, which will not be repeated here.
[0123] In another embodiment of this application, a computer-readable storage medium is provided. This computer-readable storage medium stores a computer program, which includes program instructions. When executed by a processor, the program instructions implement all or part of the processes in the methods described above. Alternatively, the computer program can instruct related hardware to complete the process. The computer program can be stored in a computer-readable storage medium, and when executed by a processor, it can implement the steps of the various method embodiments described above. The computer program includes computer program code, which can be in the form of source code, object code, executable files, or certain intermediate forms. The computer-readable medium can include any entity or device capable of carrying computer program code, a recording medium, a USB flash drive, a portable hard drive, a magnetic disk, an optical disk, a computer memory, a read-only memory (ROM), a random access memory (RAM), an electrical carrier signal, a telecommunication signal, and a software distribution medium, etc.
[0124] The computer-readable storage medium can be an internal storage unit of the electronic device in any of the foregoing embodiments, such as a hard disk or memory of the electronic device. The computer-readable storage medium can also be an external storage device of the electronic device, such as a plug-in hard disk, smart media card (SMC), secure digital card (SD), flash card, etc., equipped on the electronic device. Furthermore, the computer-readable storage medium can include both internal and external storage units of the electronic device. The computer-readable storage medium is used to store computer programs and other programs and data required by the electronic device. The computer-readable storage medium can also be used to temporarily store data that has been output or will be output.
[0125] This application provides a computer program product, which includes computer-executable instructions or a computer program. The computer-executable instructions or computer program are stored in a computer-readable storage medium. The processor of an electronic device reads the computer-executable instructions from the computer-readable storage medium and executes the computer-executable instructions, causing the electronic device to execute the protocol fusion method described above in this application.
[0126] Those skilled in the art will recognize that the modules / units and algorithm steps of the various examples described in conjunction with the embodiments disclosed herein can be implemented in electronic hardware, computer software, or a combination of both. To clearly illustrate the interchangeability of hardware and software, the components and steps of the various examples have been generally described in terms of functionality in the foregoing description. Whether these functions are implemented in hardware or software depends on the specific application and design constraints of the technical solution. Those skilled in the art can use different methods to implement the described functions for each specific application, but such implementations should not be considered beyond the scope of this application.
[0127] Those skilled in the art will clearly understand that, for the sake of convenience and brevity, the specific working process of the electronic devices and units described above can be referred to the corresponding process in the foregoing method embodiments, and will not be repeated here.
[0128] In the several embodiments provided in this application, it should be understood that the disclosed electronic devices and methods can be implemented in other ways. For example, the device embodiments described above are merely illustrative. For instance, the division of modules / units is only a logical functional division, and in actual implementation, there may be other division methods. For example, multiple modules, units, or components may be combined or integrated into another system, or some features may be ignored or not executed. In addition, the mutual coupling or direct coupling or communication connection shown or discussed may be indirect coupling or communication connection through some interfaces or modules / units, or it may be an electrical, mechanical, or other form of connection.
[0129] The modules / units described as separate components may or may not be physically separate. Similarly, the components shown as modules / units may or may not be physical modules / units; they may be located in one place or distributed across multiple network modules / units. Some or all of the modules / units can be selected to achieve the purpose of the embodiments of this application, depending on actual needs.
[0130] Furthermore, the functional modules / units in the various embodiments of this application can be integrated into one processing module / unit, or each module / unit can exist physically separately, or two or more modules / units can be integrated into one module / unit. The integrated modules / units described above can be implemented in hardware or in the form of software functional modules / units.
[0131] The above are merely specific embodiments of this application, but the scope of protection of this application is not limited thereto. Any person skilled in the art can easily conceive of various equivalent modifications or substitutions within the technical scope disclosed in this application, and these modifications or substitutions should all be covered within the scope of protection of this application. Therefore, the scope of protection of this application should be determined by the scope of the claims.
Claims
1. A protocol fusion method characterized by, A method for fusing a second protocol into a first protocol, the method comprising: mapping a set of application layer services of the second protocol into a set of application layer services of the first protocol; the first protocol comprising a DLMS / COSEM protocol, and the second protocol comprising a DL / T 698.45 protocol; setting object identities for the second protocol in the first protocol consistent with the first protocol; fusing security mechanisms of the second protocol into the first protocol.
2. The method of claim 1, wherein, The mapping a set of application layer services of the second protocol into a set of application layer services of the first protocol comprises: mapping an application layer connection service in the second protocol onto an application layer connection service in the first protocol; mapping a Get service in the second protocol onto a Get service in the first protocol; mapping a Set service in the second protocol onto a Set service in the first protocol; mapping an Action service in the second protocol onto an Action service in the first protocol; and mapping a request setting followed by reading object attributes SetThenGetRequestNormalList and a request operation followed by reading object attributes ActionThenGetRequestNormalList service in the second protocol onto an Access service in the first protocol.
3. The method of claim 2, wherein, The mapping an application layer connection service in the second protocol onto an application layer connection service in the first protocol comprises: adding a pre-defined special service of the second protocol in a protocol consistency block in the application layer connection service in the first protocol, the pre-defined special service being a service other than the Get service, the Set service, and the Action service; and adding an authentication request of the second protocol in an authentication request object in the application layer connection service in the first protocol.
4. The method according to any one of claims 1 to 3, characterized in that, The setting object identities for the second protocol in the first protocol consistent with the first protocol comprises: setting a utility-specific class for the second protocol, such that an interface of a utility table of the first protocol is identifiable for data from the second protocol.
5. The method of claim 4, wherein, The utility-specific class comprises a Buffer attribute, and the method further comprises: mapping attribute and index information in the second protocol, and other data items not contained in the set of application layer services, into the Buffer.
6. The method of claim 4, wherein, The utility-specific class comprises an object identification system (OBIS) attribute, and the setting object identities for the second protocol in the first protocol consistent with the first protocol comprises: defining a class mapping object for the second protocol, mapping an identifier of the class mapping object into the OBIS of the first protocol, comprising: mapping a custom flag into OBIS-A; mapping a channel number of a measurement into OBIS-B; mapping a protocol identifier of the second protocol into OBIS-C; mapping an OIA of the second protocol into OBIS-D; and mapping an OIB of the second protocol into OBIS-E.
7. The method of claim 1, wherein, The fusing security mechanisms of the second protocol into the first protocol comprises: Adding an authentication mode of a second protocol on the basis of an original authentication mode of a first protocol, identifying the authentication mode to be used by connecting a service source language with a name of an authentication mechanism; Adding a security service of a second protocol on the basis of an original security service of a first protocol, retaining an original format of the security service of the second protocol; and Adding a security suite of a second protocol on the basis of an original security suite of a first protocol.
8. A protocol convergence device, characterized by, Comprise: A first fusion module for mapping a second protocol application layer service set into a first protocol application layer service set; The first protocol comprises: a DLMS / COSEM protocol, and the second protocol comprises: a DL / T698.45 protocol; A second fusion module for setting an object identification consistent with the first protocol for the second protocol in the first protocol; A third fusion module for fusing a security mechanism of a second protocol into the first protocol.
9. An electronic device comprising a memory, a processor, and a computer program stored in the memory and running on the processor, characterized in that, The processor executes the computer program to realize the steps of the method of any one of claims 1 to 7.
10. A computer-readable storage medium storing a computer program, the computer program comprising instructions that, when executed by a computer, cause the computer to perform the method of any one of claims 1 to 9. The computer program is executed by the processor to realize the steps of the method of any one of claims 1 to 7.