CN116800854A - Information processing method, device, equipment and storage medium - Google Patents

Information processing method, device, equipment and storage medium Download PDF

Info

Publication number
CN116800854A
CN116800854A CN202210247305.7A CN202210247305A CN116800854A CN 116800854 A CN116800854 A CN 116800854A CN 202210247305 A CN202210247305 A CN 202210247305A CN 116800854 A CN116800854 A CN 116800854A
Authority
CN
China
Prior art keywords
communication protocol
protocol type
message
platform
target
Prior art date
Legal status (The legal status is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the status listed.)
Pending
Application number
CN202210247305.7A
Other languages
Chinese (zh)
Inventor
谭云月
梁东
魏锋
吴必造
谢海泉
钟昌懿
杨亚军
Current Assignee (The listed assignees may be inaccurate. Google has not performed a legal analysis and makes no representation or warranty as to the accuracy of the list.)
China Mobile Communications Group Co Ltd
China Mobile IoT Co Ltd
Original Assignee
China Mobile Communications Group Co Ltd
China Mobile IoT Co Ltd
Priority date (The priority date is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the date listed.)
Filing date
Publication date
Application filed by China Mobile Communications Group Co Ltd, China Mobile IoT Co Ltd filed Critical China Mobile Communications Group Co Ltd
Priority to CN202210247305.7A priority Critical patent/CN116800854A/en
Publication of CN116800854A publication Critical patent/CN116800854A/en
Pending legal-status Critical Current

Links

Classifications

    • HELECTRICITY
    • H04ELECTRIC COMMUNICATION TECHNIQUE
    • H04LTRANSMISSION OF DIGITAL INFORMATION, e.g. TELEGRAPHIC COMMUNICATION
    • H04L69/00Network arrangements, protocols or services independent of the application payload and not provided for in the other groups of this subclass
    • H04L69/08Protocols for interworking; Protocol conversion

Landscapes

  • Engineering & Computer Science (AREA)
  • Computer Security & Cryptography (AREA)
  • Computer Networks & Wireless Communication (AREA)
  • Signal Processing (AREA)
  • Computer And Data Communications (AREA)
  • Communication Control (AREA)

Abstract

The application discloses an information processing method, which is applied to information processing equipment, and comprises the following steps: receiving a first message sent by a first platform; the first platform is any one of a service platform or an equipment access platform; the communication protocol type of the first message is a first communication protocol type; determining a target communication protocol type based on the first message; the target communication protocol type is a first communication protocol type or a second communication protocol type; based on a communication protocol conversion model corresponding to a target communication protocol type, carrying out protocol conversion on the first message to obtain a second message, wherein the communication protocol type of the second message is the second communication protocol type; the second message is sent to the second platform. In addition, the application also discloses an information processing device, equipment and a storage medium. The information processing method, the information processing device, the information processing equipment and the storage medium can avoid secondary development and reduce resource waste.

Description

Information processing method, device, equipment and storage medium
Technical Field
The present application relates to the field of information processing, and relates to, but is not limited to, an information processing method, apparatus, device, and storage medium.
Background
In the related art, for a service platform and a device access platform, the service platform is a platform for displaying an operation interface to a user, and the device access platform is a platform for accessing terminal devices (such as a mobile phone, a tablet computer, etc.). The service platform can send an instruction to the equipment access platform, and after receiving the instruction sent by the service platform, the equipment access platform sends the instruction to the terminal equipment accessed to the equipment access platform, so that the terminal equipment executes the instruction sent by the service platform.
Here, in the process that the device access platform sends the instruction to the terminal device, the instruction is sent through a protocol. Since the device access platform needs to send an instruction through a protocol, all terminal devices connected under the device access platform must be connected by adopting the same protocol type. When the manufacturers of the terminal devices connected to the device access platform are different, the terminal devices of different manufacturers need to modify the protocol type of each terminal device so that the modified protocol type is the same as the designated protocol type. In this way, since the terminal devices of different manufacturers need to modify the protocol type adopted by the terminal devices of each manufacturer according to the designated protocol type, namely, secondary development is performed, the problem of resource waste exists.
Disclosure of Invention
The application provides an information processing method, an information processing device, information processing equipment and a storage medium, which can avoid secondary development and reduce resource waste.
The technical scheme of the application is realized as follows:
in a first aspect, an embodiment of the present application provides an information processing method, applied to an information processing apparatus, including:
receiving a first message sent by a first platform; the first platform is any one of a service platform or a device access platform; the communication protocol type of the first message is a first communication protocol type;
determining a target communication protocol type based on the first message; the target communication protocol type is the first communication protocol type or the second communication protocol type; the first communication protocol type and the second communication protocol type are different;
based on a communication protocol conversion model corresponding to the target communication protocol type, carrying out protocol conversion on the first message to obtain a second message, wherein the communication protocol type of the second message is the second communication protocol type;
and sending the second message to a second platform, wherein the second platform is a platform except the first platform in the service platform and the equipment access platform.
In a second aspect, an embodiment of the present application provides an information processing apparatus including:
the receiving unit is used for receiving a first message sent by the first platform; the first platform is any one of a service platform or a device access platform; the communication protocol type of the first message is a first communication protocol type;
a determining unit configured to determine a target communication protocol type based on the first message; the target communication protocol type is the first communication protocol type or the second communication protocol type; the first communication protocol type and the second communication protocol type are different;
the conversion unit is used for carrying out protocol conversion on the first message based on a communication protocol conversion model corresponding to the target communication protocol type to obtain a second message, wherein the communication protocol type of the second message is the second communication protocol type;
and the sending unit is used for sending the second message to a second platform, wherein the second platform is a platform except the first platform in the service platform and the equipment access platform.
In a third aspect, an embodiment of the present application provides an electronic device, including a memory, a processor, and a computer program stored on the memory and executable on the processor, where the processor implements the above information processing method when executing the computer program.
In a fourth aspect, an embodiment of the present application provides a computer-readable storage medium having stored thereon a computer program which, when executed by a processor, implements the above-described information processing method.
The embodiment of the application provides an information processing method, an information processing device, information processing equipment and a storage medium, wherein the information processing device is used for receiving a first message sent by a first platform; the first platform is any one of a service platform or a device access platform; the communication protocol type adopted by the first message is a first communication protocol type; determining a target communication protocol type based on the first message; the target communication protocol type is the first communication protocol type or the second communication protocol type; based on a communication protocol conversion model corresponding to the target communication protocol type, carrying out protocol conversion on the first message to obtain a second message, wherein the communication protocol type of the second message is the second communication protocol type; and sending the second message to a second platform, wherein the second platform is a platform except the first platform in the service platform and the equipment access platform. Because the information processing equipment sends the second message after protocol conversion, when the manufacturers of the terminal equipment accessed to the equipment access platform are different, the first message of the first communication protocol type can be converted into the second message of the second communication protocol type through the communication protocol conversion model, and the converted second message is sent to the second platform, so that the problems of secondary development and resource waste of the terminal equipment of different manufacturers supporting different communication protocol types according to the appointed protocol type can be avoided.
Drawings
FIG. 1 is a schematic diagram of an alternative architecture of an information handling system according to an embodiment of the present application;
FIG. 2 is a schematic flow chart of an alternative information processing method according to an embodiment of the present application;
FIG. 3 is a schematic diagram of an alternative architecture of an information handling system according to an embodiment of the present application;
FIG. 4 is a schematic flow chart of an alternative information processing method according to an embodiment of the present application;
FIG. 5 is a schematic diagram of an alternative configuration of an information processing method according to an embodiment of the present application;
FIG. 6 is a schematic diagram of an alternative configuration of an information processing method according to an embodiment of the present application;
FIG. 7 is a schematic diagram showing an alternative configuration of an information processing apparatus according to an embodiment of the present application;
fig. 8 is an alternative structural schematic diagram of an electronic device according to an embodiment of the present application.
Detailed Description
In order to make the objects, technical solutions and advantages of the embodiments of the present application more apparent, the specific technical solutions of the present application will be described in further detail below with reference to the accompanying drawings in the embodiments of the present application. The following examples are illustrative of the application and are not intended to limit the scope of the application.
Embodiments of the present application may provide an information processing method and apparatus, a device (e.g., an electronic device), and a storage medium (e.g., a computer-readable storage medium). In practical applications, the information processing method may be implemented by an information processing apparatus.
Unless defined otherwise, all technical and scientific terms used herein have the same meaning as commonly understood by one of ordinary skill in the art to which this application belongs. The terminology used herein in the description of the application is for the purpose of describing particular embodiments only and is not intended to be limiting of the application. The term "and/or" as used herein includes any and all combinations of one or more of the associated listed items.
The information processing method of the embodiment of the present application is applicable to the information processing system 100 shown in fig. 1, and as shown in fig. 1, the information processing system 100 includes: a server 110 and a client 120. Communication between the server 110 and the client 120 is via a network 130.
Here, the client 120 is capable of interacting with a user based on input devices, wherein the input devices include: a display, mouse, keyboard, etc. capable of receiving user input information.
The client can be provided with a service platform, and the server is provided with a device access platform. In an example, the service platform may receive an instruction of a user, and send the instruction to the server, so that the server sends the received instruction to the accessed terminal device, and the terminal device performs an operation corresponding to the instruction. In an example, the terminal device sends the information to the device access platform of the server, and the device access platform of the server sends the received information to the service platform, so that the service platform manages and displays the information of the terminal device.
In the embodiment of the application, a terminal abstraction layer is arranged between a service platform and a device access platform, wherein the device provided with the terminal abstraction layer is called an information processing device, wherein the information processing device can be a client, a server or a third device independent of the client and the server. When the information processing equipment is a client, the service platform and the terminal abstraction layer are positioned in the same physical equipment; when the information processing equipment is a server, the equipment access platform and the terminal abstraction layer are positioned on the same physical equipment; when the information processing device is a third device independent of the client and the server, the service platform, the device access platform and the terminal abstraction layer are respectively located on different physical devices.
In the embodiment of the application, after the information processing device receives the first message sent by the first platform based on the abstract access platform, the information processing device can determine the target communication protocol type based on the first message, and perform protocol conversion on the first message based on the conversion model corresponding to the determined target communication protocol type to obtain the second message, and then send the second message to the second platform. The first platform is any one of a service platform and a device access platform, the target communication protocol type is a first communication protocol type or a second communication protocol type, the communication protocol type of the first message is the first communication protocol type, the communication protocol type of the second message is the second communication protocol type, and the second platform is a platform except the first platform in the service platform and the device access platform.
Embodiments of an information processing method, apparatus, device, and storage medium provided by the embodiments of the present application are described below.
Fig. 2 is a schematic flow chart of an implementation of an information processing method according to an embodiment of the present application, where the method is applied to an information processing device, and as shown in fig. 2, the method may include the following steps:
s201, the information processing device receives a first message sent by the first platform.
Here, the first platform is a service platform or a device access platform. The service platform is a platform for displaying an operation interface to a user, and the equipment access platform is a platform for accessing terminal equipment.
In an example, the first platform is a service platform, and when the service platform displays an operation interface to a user, the service platform receives the operation of the user, generates a first message based on the operation of the user, and sends the generated first message to the information processing device, so that the information processing device receives the first message sent by the service platform.
In another example, the first platform is a device access platform, the terminal device accessed to the device access platform sends a first message to the device access platform, and after receiving the first message, the device access platform sends the first message to the information processing device, so that the information processing device receives the first message sent by the device access platform.
The first message is a message related to the first function, for example, the first message is used for indicating the terminal device to execute the first function, and for example, the first message carries service data generated by the terminal device to execute the first function. The first function is a function supported by a terminal device accessed to the device access platform.
Here, the first function is any one of at least one function supported by a terminal device accessed by the device access platform.
In an example, in a case that a kind of a terminal device accessed to the device access platform is unopened, the first function is: closing, opening, current and voltage acquisition and the like.
In the embodiment of the present application, based on different sending directions of the first message, the types of the first message may include: upstream messages and downstream messages. The uplink message is a message reported by the equipment access platform to the service platform, and the downlink message is a message issued by the service platform to the equipment access platform.
In one example, the uplink message is current data and voltage data reported by the device access platform to the service platform.
In another example, the downlink message is a closing message issued by the service platform to the device access platform.
Here, the embodiment of the present application does not limit the number of uplink messages and downlink messages in any way.
In one example, the number of upstream messages is 1 and the number of downstream messages is 3.
In another example, the number of upstream messages is 3 and the number of downstream messages is 1.
In the embodiment of the application, different messages corresponding to terminal equipment supporting different communication protocol types are identical in protocol type adopted in transmission between a service platform and a terminal abstract layer, and different in protocol type adopted in transmission between the terminal abstract layer and a device access layer.
The communication protocol type of the first message is a first communication protocol type.
In an example, the first communication protocol type includes: transmission control communication protocol (Transmission Control Protocol, TCP), internet protocol (Internet Protocol, IP), etc.
S202, the information processing device determines a target communication protocol type based on the first message.
Here, the target communication protocol type is a first communication protocol type or a second communication protocol type, the first communication protocol type being different from the second communication protocol type.
In an example, the second communication protocol type includes: user data protocol (User Data Protocol, UDP), etc.
In an embodiment of the present application, the information processing apparatus determines a target communication protocol type based on the first message, including: and the information processing equipment determines equipment information of the terminal equipment corresponding to the first message, and determines the target communication protocol type based on the equipment information. The device information of the terminal device may include: the model of the terminal device, etc.
Here, determining, for the information processing device, device information of the terminal device corresponding to the first message may include the following two ways:
in mode 1, in the case that the first platform is a service platform, after receiving a first message sent by the service platform, the information processing device may determine a terminal device that executes a first function indicated by the first message, determine device information of the terminal device after determining the terminal device, and determine a target communication protocol type based on the device information.
In the mode 2, when the first platform is an equipment access platform and the terminal equipment is accessed to the equipment access platform, the equipment access platform receives the first message sent by the terminal equipment and then sends the received first message to the information processing equipment, and the information processing equipment can determine the equipment information of the terminal equipment sending the first message after receiving the first message sent by the equipment access platform and then determine the type of the target communication protocol based on the equipment information.
In the embodiment of the present application, for the above two modes, in the case of the above mode 1, the target communication protocol type may be the second communication protocol type, and in the case of the above mode 2, the target communication protocol type is the first communication protocol type.
S203, the information processing equipment performs protocol conversion on the first message based on a communication protocol conversion model corresponding to the target communication protocol type to obtain a second message.
Here, the communication protocol type of the second message is the second communication protocol type.
After receiving the first message of the first communication protocol type, the information processing device can determine the target passing protocol type based on the first message, and after determining the target communication protocol type, the information processing device can perform protocol conversion on the first message based on a communication protocol conversion model corresponding to the target communication protocol type, so as to convert the first message of the first communication protocol type into the second message of the second communication protocol type.
For the communication protocol conversion model, the communication protocol conversion model may correspond to a communication protocol type, the communication protocol type corresponds to at least one message, and different messages in the at least one message may correspond to different functions.
In an example, the communication protocol type corresponding to the communication protocol conversion model 1 is a type a, and the message corresponding to the communication protocol type a includes: message a1, message a2 and message a3, wherein message a1 corresponds to function f1, message a2 corresponds to function f2, and message a3 corresponds to function f3.
In the embodiment of the application, the information processing device can determine the message corresponding to the first function in the target communication protocol type by calling the communication protocol conversion model corresponding to the target communication protocol type, wherein the message corresponding to the first function in the target communication protocol type is the second message.
In an example, when the target communication protocol type is type a, the communication protocol conversion model corresponding to the target communication protocol type a is model 1, and the message corresponding to the target communication protocol type a includes: the message a1, the message a2 and the message a3, wherein, when the message a1 corresponds to the function f1, the message a2 corresponds to the function f2 and the message a3 corresponds to the function f3, if the first function is the function f1, the information processing device may determine that the message corresponding to the first function f1 in the target communication protocol type a is the message a1 by calling the communication protocol conversion model 1, and at this time, the message a1 is the second message.
S204, the information processing device sends the second message to a second platform.
Here, the second platform is a platform other than the first platform in the service platform and the device access platform.
In an example, if the first platform is a service platform, the second platform is a device access platform.
In another example, if the first platform is a device access platform, the second platform is a service platform.
In the embodiment of the application, when the first platform is a service platform and the second platform is a device access platform, after the information processing device sends the second message to the device access platform, the device access platform can send the second message to the terminal device accessed to the device access platform, so that the terminal device executes the first function issued by the service platform.
When the first platform is an equipment access platform and the second platform is a service platform, the information processing equipment can receive data reported by the equipment access platform after sending the second message to the service platform.
The information processing method provided by the embodiment of the application can be applied to the following scenes:
the terminal equipment accessed by the equipment access platform comprises: the terminal equipment 1 and the terminal equipment 2, the communication protocol type of the terminal equipment 1 is type A, the communication protocol type of the terminal equipment 2 is type B, and the communication protocol type between the service platform and the terminal abstract layer is protocol C. If the first platform is a service platform, the terminal abstraction layer receives the first message using the protocol C and converts the first message into the second message using the protocol a, and sends the second message using the protocol a to the device access platform, so that the device access platform sends the second message of the protocol a to the terminal device a, or if the first platform is a device access platform, the first message is a message sent by the terminal device a, and the terminal abstraction layer receives the first message using the protocol a and converts the first message into the second message using the protocol C and sends the second message using the protocol C to the service platform. If the first platform is a service platform, the terminal abstraction layer receives the first message using the protocol C and converts the first message into the second message using the protocol B, and sends the second message using the protocol B to the device access platform, so that the device access platform sends the second message of the protocol B to the terminal device B, or if the first platform is a device access platform, the first message is a message sent by the terminal device B, and the terminal abstraction layer receives the first message using the protocol B and converts the first message into the second message using the protocol C and sends the second message using the protocol C to the service platform.
The embodiment of the application provides an information processing method, which is used for receiving a first message sent by a first platform; the first platform is any one of a service platform or a device access platform; the communication protocol type adopted by the first message is a first communication protocol type; determining a target communication protocol type based on the first message; the target communication protocol type is a first communication protocol type or a second communication protocol type; based on a communication protocol conversion model corresponding to the target communication protocol type, carrying out protocol conversion on the first message to obtain a second message, wherein the communication protocol type of the second message is the second communication protocol type; and sending the second message to a second platform, wherein the second platform is a platform except the first platform in the service platform and the equipment access platform. Because the information processing equipment sends the second message after protocol conversion, when the manufacturers of the terminal equipment accessed to the equipment access platform are different, the first message of the first communication protocol type can be converted into the second message of the second communication protocol type through the communication protocol conversion model, and the converted second message is sent to the second platform, so that the problems of secondary development and resource waste of the terminal equipment of different manufacturers supporting different communication protocol types according to the appointed unique protocol can be avoided.
In the embodiment of the present application, for the case that the service platform sends the first message to the information processing device, the first message may include the following two cases:
case 1, a first message is used to indicate a first function, the first message being applicable to all terminal devices performing the first function.
Case 2, the first message is used to instruct the target terminal device to execute the first function. That is, the first message is applicable only to the target terminal device performing the first function.
The specific steps of the information processing apparatus determining the target communication protocol type based on the first message are different for the above case 1 and case 2.
The specific steps of the information processing apparatus to determine the target communication protocol type based on the first message will be described in detail below with respect to the above case 1.
In some embodiments, in a case where the first platform is the service platform, the first message is at least used to indicate a first function, and the determining the target communication protocol type based on the first message includes: determining at least two communication protocol types corresponding to the first function, wherein the at least two communication protocol types comprise the target communication protocol type, and the target communication protocol type is the second communication protocol type.
Here, among the at least two communication protocol types, communication protocol conversion models corresponding to different communication protocol types are different.
In an example, the at least two communication protocol types include: the communication protocol type is 101 and the communication protocol type is 102, wherein a communication protocol conversion model corresponding to the communication protocol type 101 is a model 1, a communication protocol conversion model corresponding to the communication protocol type 102 is a model 2, and the communication protocol conversion model 1 and the communication protocol conversion model 2 are two different communication protocol conversion models.
In the embodiment of the present application, when an information processing device receives a first message sent by a service platform, the information processing device determines at least two communication protocol conversion types corresponding to the first function, including: the information processing device determines terminal devices supporting the first function, determines device information of the terminal devices, and determines a communication protocol type corresponding to the device information of the terminal devices.
In an example, a terminal device supporting a first function f1 includes: the information processing device may determine that, in the case where the device information of the terminal device 10 is 10a, the device information of the terminal device 20 is 20a, the device information of the terminal device 30 is 30a, the communication protocol type corresponding to the device information 10a is 101, the communication protocol type corresponding to the device information 20a is 101, and the communication protocol type corresponding to the device information 30a is 102, if the first function is the function f1, the communication protocol types corresponding to the first function f1 are 101 and 102.
In the embodiment of the present application, after the information processing device determines at least two communication protocol types, the information processing device may further determine at least two communication protocol conversion models corresponding to the at least two communication protocol types, where each communication protocol type in the at least two communication protocol types corresponds to a communication protocol conversion model.
In an example, when the communication protocol conversion model corresponding to the communication protocol type 101 is the model 1, the communication protocol conversion model corresponding to the communication protocol type 102 is the model 2, and the communication protocol conversion model corresponding to the communication protocol type 103 is the model 3, if the communication protocol type 101 is the model 1, the communication protocol conversion model corresponding to the communication protocol type 101 may be determined.
The specific steps of the information processing apparatus to determine the target communication protocol type based on the first message will be described in detail below with respect to the above case 2.
In some embodiments, in a case where the first platform is the service platform, the first message is configured to instruct a target terminal device to perform a first function, and determining the target communication protocol type based on the first message includes: and determining the target communication protocol type corresponding to the target terminal equipment in at least two communication protocol types corresponding to the first function.
Here, among the at least two communication protocol types, the communication protocol conversion models corresponding to different communication protocol types are different, the communication protocol type of the first communication protocol conversion model is the first communication protocol type, and the target communication protocol type is the second communication protocol type.
In the embodiment of the application, after receiving the first message sent by the service platform and indicating the target terminal device to execute the first function, the information processing device can determine the target communication protocol type corresponding to the target terminal device in at least two communication protocol types corresponding to the first function.
In one example, the at least two communication protocol types include: in the case where the communication protocol type 101 corresponds to the target terminal device, the information processing device may determine, in the communication protocol type 101 and the communication protocol conversion model 102, that the target communication protocol type corresponding to the target terminal device is the type 101.
The specific steps of the information processing apparatus to determine the target communication protocol type based on the first message in the case where the apparatus access platform transmits the first message to the information processing apparatus will be described in detail below.
In some embodiments, where the first platform is the device access platform, the first message is a message related to a target terminal device performing a first function, the determining a target communication protocol type based on the first message includes: and determining the target communication protocol type corresponding to the target terminal equipment in at least two communication protocol types corresponding to the first function.
Here, among the at least two communication protocol types, communication protocol conversion models corresponding to different communication protocol types are different. The communication protocol type of the first communication protocol conversion model is the first communication protocol type, and the target communication protocol type is the first communication protocol type.
In the embodiment of the present application, in the case that the device access platform sends, to the information processing device, a first message related to the target terminal device executing the first function, the information processing device may determine, from at least two communication protocol types corresponding to the first function, a target communication protocol type corresponding to the target terminal device.
In one example, the at least two communication protocol types include: in the case where the communication protocol type 101 and the communication protocol type 102 correspond to the target terminal device, the information processing device may determine, in the communication protocol type 101 and the communication protocol conversion model 102, that the target communication protocol type corresponding to the target terminal device is the type 102.
In some embodiments, the method further comprises: the information processing equipment determines at least two communication protocol types corresponding to at least two terminal equipment; the information processing device determines a communication protocol conversion model corresponding to each communication protocol in the at least two communication protocol types.
Here, each of the at least two terminal devices corresponds to a communication protocol type;
in an example, at least two terminal devices include: the communication protocol type corresponding to the terminal device 10 is type 101, the communication protocol type corresponding to the terminal device 20 is type 102, the communication protocol conversion model corresponding to the communication protocol type 101 is model 1, and the communication protocol conversion model corresponding to the communication protocol type 102 is model 2. At this time, for the terminal device 10, the information processing device may determine that the communication protocol conversion model corresponding to the communication protocol type 101 is model 1; for the terminal device 20, the information processing device may determine that the communication protocol conversion model corresponding to the communication protocol type 102 is model 2.
In some embodiments, the determining a target communication protocol type based on the first message includes: in at least two abstract classes, the information processing device determines a target abstract class based on a first function indicated by the first message; and in at least two communication protocol types corresponding to the target abstract class, the information processing equipment determines a target communication protocol type based on the first message.
Here, in at least two abstract classes, functions corresponding to different abstract classes are different.
In an example, the at least two abstract classes include: abstract class a and abstract class b, wherein the function corresponding to abstract class a is function a1, the function corresponding to abstract class b is function b1, and the function a1 and the function b1 are two different functions.
In the embodiment of the application, at least two abstract classes correspond to at least two functions, each abstract class in the at least two abstract classes corresponds to a function, and the at least two functions comprise a first function. Since one abstract class may correspond to one function, the information processing apparatus may determine, from a first function indicated by the first message, a target abstract class corresponding to the first function among at least two functions corresponding to at least two abstract classes.
After determining the target abstract class, the information processing device may determine a target communication protocol type based on the first message from at least two communication protocol types corresponding to the target abstract class.
Here, the target abstract class may include: at least two terminal devices executing the first function, the information processing device can instantiate the target abstract class after determining the target abstract class, so that at least two communication protocol conversion models can be obtained. For the communication protocol conversion model, the communication protocol conversion model may correspond to a communication protocol type, and the information processing device may determine the communication protocol conversion model corresponding to the communication protocol type after determining the communication protocol type corresponding to the terminal device.
In an example, the target abstract class includes: the terminal device 10 and the target terminal device 20, wherein the communication protocol type corresponding to the terminal device 10 is 101, the communication protocol type corresponding to the terminal device 20 is 102, the communication protocol conversion model corresponding to the communication protocol type 101 is model 1, the communication protocol conversion model corresponding to the communication protocol type 102 is model 2, and at this time, the information processing device can instantiate the target abstract class to obtain the communication protocol conversion model 1 and the communication protocol conversion model 2.
In some embodiments, the method further comprises: the information processing device determines at least two functions supported by at least two terminal devices; the information processing device divides the at least two terminal devices into the at least two abstract classes according to the at least two functions.
Here, each of the at least two abstract classes includes at least one terminal device supporting the same function.
In an example, at least two terminal devices include: terminal device 10, terminal device 20, and terminal device 30, wherein terminal device 10 and terminal device 20 support function a1, and terminal device 30 supports function a2, at which time, the information processing device may divide terminal device 10 and terminal device 20 into abstract class a and terminal device 30 into abstract class b according to function a1 and function a2, wherein abstract class a includes: terminal device 10 and terminal device 20 supporting function a1, abstract class b includes: terminal device 30 supporting function a 2.
The hardware abstraction layer is an interface layer between the operating system kernel and the hardware circuitry, which aims at abstracting the hardware. The hardware abstraction layer conceals the hardware interface details of a specific platform, provides a virtual hardware platform for an operating system, has hardware independence, and can be transplanted on various platforms. From the perspective of software and hardware testing, the software and hardware testing work can be completed based on the hardware abstraction layer respectively, so that the parallelism of the software and hardware testing work is possible.
The embedded system is composed of hardware and software, and is a device capable of operating independently. The software content of the embedded system only comprises a software running environment and an operating system thereof. The hardware content of the embedded system comprises: various aspects including signal processors, memories, communication modules, etc. Compared with a general computer processing system, the embedded system has large variability, and has no large-capacity medium matched with the embedded system, so the embedded system cannot realize the large-capacity storage function. Most embedded systems employ storage media that include: erasable programmable read-Only Memory (Erasable Programmable Read-Only Memory, E-PROM), charged erasable programmable read-Only Memory (Electrically Erasable Programmable read Only Memory, EEPRO), etc., the software portion uses an application programming interface (Application Programming Interface, API) as the core of the development platform.
Along with the continuous progress and development of the internet of things technology, schemes such as a smart park, a smart energy-saving intelligent factory and the like based on a platform and hardware are mature, data of various internet of things terminals and internet of things terminals for operating an access platform can be conveniently checked by the platform, but along with the expansion and landing of project scale, terminal sources in the scheme tend to be complex, the same type of access terminals can be accessed by adopting terminals produced by different factories, and the cost of equipment access platform is greatly increased due to non-uniform protocols caused by different factories.
The traditional communication protocol interaction between the equipment access platform and the terminal is similar to a process-oriented mode, the equipment access platform directly analyzes the reported data through protocol analysis and issues control commands, and the mode requires that all terminals of the same type connected under the equipment access platform are connected by adopting the same protocol. This will result in the following two access methods for accessing the device to the platform for the same type of terminal (e.g., smart switch), as shown in fig. 3:
the first mode, the device access platform 301 performs individual adaptation according to the communication protocol of the terminal device of each manufacturer;
And secondly, developing different types of terminal equipment of all access manufacturers secondarily according to a unique designated protocol.
When the first and second modes are adopted for access, a large amount of resources are required to be input, and thus, the problem of resource waste is caused.
The embodiment of the application provides an information processing method, which adds a terminal abstraction layer between a cloud device access platform and a service platform by means of an object-oriented thought, so as to solve the problem of adapting a terminal to the device access platform. The access terminal (i.e. the terminal equipment described in the above embodiment) is well defined by the access platform, the access terminal abstract class is generated at the terminal abstract layer, the code adaptation is performed according to the attribute of the access terminal abstract class and the terminal communication protocol provided by the terminal manufacturer, so as to form a terminal abstract model corresponding to the terminal equipment one by one, and finally when the terminal accesses the platform through the network access equipment, when the communication data up reaches the terminal abstract layer, the terminal can interact with the service platform at the upper layer of the access platform according to the terminal abstract model to which the terminal belongs.
An information processing method provided by an embodiment of the present application will be described in detail below.
As shown in fig. 4, the information processing method includes the steps of:
s401, the information processing equipment classifies the accessed terminal equipment according to the function of the accessed terminal equipment.
S402, the information processing equipment abstracts and refines the functions of the terminal equipment of each type to form a terminal abstract class.
Here, for the terminal abstract class, at least one attribute may be included in the terminal abstract class, wherein each attribute of the at least one attribute is for a function of a terminal device.
S403, the information processing device instantiates each terminal abstract class to obtain a terminal device abstract model included in each terminal abstract class.
S404, when the terminal equipment accesses the equipment access platform through the network, the terminal equipment sends data to the equipment access platform, the data can be sent to the terminal abstraction layer first, and then interaction is carried out with the equipment access platform according to the terminal abstraction model to which the terminal equipment belongs.
In the embodiment of the application, for the information processing device, the information processing device can firstly create a terminal abstraction layer, the terminal abstraction layer is composed of a plurality of terminal abstraction classes, the accessed terminal device is classified according to the functions of the terminal device, and the terminal abstraction classes are added in the terminal abstraction layer.
For each of the plurality of terminal abstract classes, the terminal abstract class comprises a plurality of attributes, wherein for each of the plurality of attributes, each attribute corresponds to a function of the terminal device.
As shown in fig. 5, the terminal abstraction layer 500 includes a terminal abstraction class 510 and a terminal abstraction class 520, wherein the terminal abstraction class 510 includes: attributes 511, 512, and 513, terminal abstraction class 520 includes: attributes 521, 522, and 523. After the terminal abstract class 510 is instantiated, a terminal device abstract model 510a of the vendor a and a terminal device abstract model 520b of the vendor b can be obtained, where the terminal device abstract model 510a includes: the terminal device abstraction model 520b includes: function 520b1, function 520b2, and function 520b3.
In addition, according to the communication protocol of the manufacturer terminal, the adaptation is performed according to the attribute in the corresponding terminal abstract class. The terminal uses the original communication protocol and communication mode, such as: message queue telemetry transport (Message Queuing Telemetry Transport, MQTT), limited application protocol (Constrained Application Protocol, COAP), TCP/UDP, etc. are connected to the device access platform. In order to ensure effective control and access guarantee of the device access platform to the terminal, the lower layer of the device access platform adopts a privately-owned deployment platform, namely a service (Platform as a Service, paaS) layer for docking, such as privately-owned OneNET and the like, fully utilizes the device access and management advantages of the PaaS layer, and performs standardized management on all access devices. The PaaS layer is the device access platform, that is, the PaaS layer is the second platform described in the above embodiment.
Finally, the terminal abstract class corresponding to the access device is instantiated according to the access device, the instantiated terminal abstract model and the corresponding device are in one-to-one correspondence, and the service flow is shown in the following figure 6. The service platform 601 issues a command (i.e., the first message described in the above embodiment) to the device management and control layer 602, after the device management and control layer 602 receives the command issued by the service platform 601, the device management and control layer 602 invokes the corresponding instantiated terminal device abstract model in the terminal abstract layer 500 through an interface manner such as an API, and then issues the command to the terminal device 604, the terminal device 605 and the terminal device 606 through the platform as a service (PaaS) layer 603. The terminal device 604, the terminal device 605 and the terminal device 606 are terminal devices of different manufacturers. Here, for terminal devices of different manufacturers, the types of communication protocols for the terminal devices of different manufacturers are different.
Specifically, the service platform can issue instructions to the device management and control layer through means such as a network (Web) or an Application (App), the device management and control layer manages service states and functions of the terminal device, and after receiving the instructions issued by the service platform, the device management and control layer invokes a corresponding instantiated terminal device abstract model in the terminal abstract layer through an interface mode such as an API, and finally invokes commands with corresponding attributes according to the commands, and finally issues the commands to the terminal device through the PaaS layer. The PaaS layer can be used for managing the access of the terminal equipment, managing the online and offline states of the terminal equipment, storing data and managing the connection log of the terminal equipment.
Fig. 7 is a schematic diagram of an information processing apparatus according to an embodiment of the present application, and as shown in fig. 7, the information processing apparatus 700 includes:
a receiving unit 701, configured to receive a first message sent by a first platform; the first platform is any one of a service platform or a device access platform; the communication protocol type of the first message is a first communication protocol type;
a determining unit 702, configured to determine a target communication protocol type based on the first message; the target communication protocol type is the first communication protocol type or the second communication protocol type; the first communication protocol type and the second communication protocol type are different;
a conversion unit 703, configured to perform protocol conversion on the first message based on a communication protocol conversion model corresponding to the target communication protocol type, to obtain a second message, where the communication protocol type of the second message is the second communication protocol type;
and a sending unit 704, configured to send the second message to a second platform, where the second platform is a platform other than the first platform in the service platform and the device access platform.
In some embodiments, in a case where the first platform is the service platform, the first message is at least used to indicate a first function, and the determining unit 702 is further configured to:
Determining at least two communication protocol types corresponding to the first function, wherein the at least two communication protocol types comprise the target communication protocol type, the target communication protocol type is the second communication protocol type, and communication protocol conversion models corresponding to different communication protocol types in the at least two communication protocol types are different.
In some embodiments, in a case where the first platform is the service platform, the first message is configured to instruct the target terminal device to perform a first function; the determining unit 702 is further configured to:
determining a target communication protocol type corresponding to the target terminal equipment in at least two communication protocol types corresponding to the first function; and in the at least two communication protocol types, communication protocol conversion models corresponding to different communication protocol types are different, and the target communication protocol type is the second communication protocol type.
In some embodiments, in a case where the first platform is the device access platform, the first message is a message related to the target terminal device performing the first function, the determining unit 702 is further configured to:
determining a target communication protocol type corresponding to the target terminal equipment in at least two communication protocol types corresponding to the first function; and in the at least two communication protocol types, communication protocol conversion models corresponding to different communication protocol types are different, and the target communication protocol type is the first communication protocol type.
In some embodiments, the determining unit 702 is further configured to:
determining at least two communication protocol types corresponding to at least two terminal devices; each of the at least two terminal devices corresponds to a communication protocol type;
and determining a communication protocol conversion model corresponding to each communication protocol type in the at least two communication protocol types.
In some embodiments, the determining unit 702 is further configured to:
determining a target abstract class based on a first function indicated by the first message in at least two abstract classes, wherein functions corresponding to different abstract classes in the at least two abstract classes are different;
and determining a target communication protocol type based on the first message in at least two communication protocol types corresponding to the target abstract class.
In some embodiments, the determining unit 702 is further configured to:
determining at least two functions supported by at least two terminal devices;
dividing the at least two terminal devices into the at least two abstract classes according to the at least two functions, wherein each abstract class in the at least two abstract classes comprises at least one terminal device supporting the same function.
The embodiment of the application also provides an electronic device, which comprises a memory and a processor, wherein the memory stores a computer program capable of running on the processor, and the processor realizes the information processing method provided in the embodiment when executing the program.
The embodiment of the present application also provides a storage medium, that is, a computer-readable storage medium, on which a computer program is stored, which when executed by a processor, implements the information processing method provided in the above embodiment.
It should be noted here that: the description of the storage medium and apparatus embodiments above is similar to that of the method embodiments described above, with similar benefits as the method embodiments. For technical details not disclosed in the embodiments of the storage medium and the apparatus of the present application, please refer to the description of the method embodiments of the present application.
It should be noted that fig. 8 is a schematic diagram of a hardware entity of an electronic device according to an embodiment of the present application, as shown in fig. 8, the electronic device 800 includes: a processor 801, at least one communication bus 802, at least one external communication interface 804, and memory 805. Wherein the communication bus 802 is configured to enable connected communication between these components. In an example, the electronic device 800 further includes: user interface 803, wherein user interface 803 may comprise a display screen, and external communication interface 804 may comprise a standard wired interface and a wireless interface.
The memory 805 is configured to store instructions and applications executable by the processor 801, and may also cache data (e.g., image data, audio data, voice communication data, and video communication data) to be processed or processed by each module in the processor 801 and the electronic device, which may be implemented by a FLASH memory (FLASH) or a random access memory (Random Access Memory, RAM).
It should be appreciated that reference throughout this specification to "one embodiment" or "an embodiment" means that a particular feature, structure or characteristic described in connection with the embodiment is included in at least one embodiment of the present application. Thus, the appearances of the phrases "in one embodiment" or "in some embodiments" in various places throughout this specification are not necessarily all referring to the same embodiment. Furthermore, the particular features, structures, or characteristics may be combined in any suitable manner in one or more embodiments. It should be understood that, in various embodiments of the present application, the sequence numbers of the foregoing processes do not mean the order of execution, and the order of execution of the processes should be determined by the functions and internal logic thereof, and should not constitute any limitation on the implementation process of the embodiments of the present application. The foregoing embodiment numbers of the present application are merely for the purpose of description, and do not represent the advantages or disadvantages of the embodiments.
It should be noted that, in this document, the terms "comprises," "comprising," or any other variation thereof, are intended to cover a non-exclusive inclusion, such that a process, method, article, or apparatus that comprises a list of elements does not include only those elements but may include other elements not expressly listed or inherent to such process, method, article, or apparatus. Without further limitation, an element defined by the phrase "comprising one … …" does not exclude the presence of other like elements in a process, method, article, or apparatus that comprises the element.
In the several embodiments provided by the present application, it should be understood that the disclosed apparatus and method may be implemented in other ways. The above described device embodiments are only illustrative, e.g. the division of the units is only one logical function division, and there may be other divisions in practice, such as: multiple units or components may be combined or may be integrated into another system, or some features may be omitted, or not performed. In addition, the various components shown or discussed may be coupled or directly coupled or communicatively coupled to each other via some interface, whether indirectly coupled or communicatively coupled to devices or units, whether electrically, mechanically, or otherwise.
The units described above as separate components may or may not be physically separate, and components shown as units may or may not be physical units; can be located in one place or distributed to a plurality of network units; some or all of the units may be selected according to actual needs to achieve the purpose of the solution of this embodiment.
In addition, each functional unit in each embodiment of the present application may be integrated in one processing unit, or each unit may be separately used as one unit, or two or more units may be integrated in one unit; the integrated units may be implemented in hardware or in hardware plus software functional units.
Those of ordinary skill in the art will appreciate that: all or part of the steps for implementing the above method embodiments may be implemented by hardware related to program instructions, and the foregoing program may be stored in a computer readable storage medium, where the program, when executed, performs steps including the above method embodiments; and the aforementioned storage medium includes: a mobile storage device, a Read Only Memory (ROM), a magnetic disk or an optical disk, or the like, which can store program codes.
Alternatively, the above-described integrated units of the present application may be stored in a computer-readable storage medium if implemented in the form of software functional modules and sold or used as separate products. Based on such understanding, the technical solution of the embodiments of the present application may be embodied essentially or in a part contributing to the related art in the form of a software product stored in a storage medium, including several instructions for causing a computer device (which may be a personal computer, a server, or a network device, etc.) to perform all or part of the methods described in the embodiments of the present application. And the aforementioned storage medium includes: various media capable of storing program codes, such as a removable storage device, a ROM, a magnetic disk, or an optical disk.
The foregoing is merely an embodiment of the present application, but the scope of the present application is not limited thereto, and any person skilled in the art can easily think about changes or substitutions within the technical scope of the present application, and the changes and substitutions are intended to be covered by the scope of the present application. Therefore, the protection scope of the present application shall be subject to the protection scope of the claims.

Claims (10)

1. An information processing method, characterized by being applied to an information processing apparatus, comprising:
receiving a first message sent by a first platform; the first platform is any one of a service platform or a device access platform; the communication protocol type of the first message is a first communication protocol type;
determining a target communication protocol type based on the first message; the target communication protocol type is the first communication protocol type or the second communication protocol type; the first communication protocol type and the second communication protocol type are different;
based on a communication protocol conversion model corresponding to the target communication protocol type, carrying out protocol conversion on the first message to obtain a second message, wherein the communication protocol type of the second message is the second communication protocol type;
And sending the second message to a second platform, wherein the second platform is a platform except the first platform in the service platform and the equipment access platform.
2. The method according to claim 1, wherein, in the case that the first platform is the service platform, the first message is at least used to indicate a first function, and the determining the target communication protocol type based on the first message includes:
determining at least two communication protocol types corresponding to the first function, wherein the at least two communication protocol types comprise the target communication protocol type, the target communication protocol type is the second communication protocol type, and communication protocol conversion models corresponding to different communication protocol types in the at least two communication protocol types are different.
3. The method according to claim 1, wherein, in the case that the first platform is the service platform, the first message is used to instruct the target terminal device to perform the first function, and the determining the target communication protocol type based on the first message includes:
determining a target communication protocol type corresponding to the target terminal equipment in at least two communication protocol types corresponding to the first function; and in the at least two communication protocol types, communication protocol conversion models corresponding to different communication protocol types are different, and the target communication protocol type is the second communication protocol type.
4. The method according to claim 1, wherein the first message is a message related to a target terminal device performing a first function in case the first platform is the device access platform, the determining a target communication protocol type based on the first message comprising:
determining a target communication protocol type corresponding to the target terminal equipment in at least two communication protocol types corresponding to the first function; and in the at least two communication protocol types, communication protocol conversion models corresponding to different communication protocol types are different, and the target communication protocol type is the first communication protocol type.
5. The method according to any one of claims 1 to 4, further comprising:
determining at least two communication protocol types corresponding to at least two terminal devices; each of the at least two terminal devices corresponds to a communication protocol type;
and determining a communication protocol conversion model corresponding to each communication protocol type in the at least two communication protocol types.
6. The method according to any one of claims 1 to 4, wherein said determining a target communication protocol type based on said first message comprises:
Determining a target abstract class based on a first function indicated by the first message in at least two abstract classes, wherein functions corresponding to different abstract classes in the at least two abstract classes are different;
and determining a target communication protocol type based on the first message in at least two communication protocol types corresponding to the target abstract class.
7. The method of claim 6, wherein the method further comprises:
determining at least two functions supported by at least two terminal devices;
dividing the at least two terminal devices into the at least two abstract classes according to the at least two functions, wherein each abstract class in the at least two abstract classes comprises at least one terminal device supporting the same function.
8. An information processing apparatus, characterized in that the apparatus comprises:
the receiving unit is used for receiving a first message sent by the first platform; the first platform is any one of a service platform or a device access platform; the communication protocol type of the first message is a first communication protocol type;
a determining unit configured to determine a target communication protocol type based on the first message; the target communication protocol type is the first communication protocol type or the second communication protocol type; the first communication protocol type and the second communication protocol type are different;
The conversion unit is used for carrying out protocol conversion on the first message based on a communication protocol conversion model corresponding to the target communication protocol type to obtain a second message, wherein the communication protocol type of the second message is the second communication protocol type;
and the sending unit is used for sending the second message to a second platform, wherein the second platform is a platform except the first platform in the service platform and the equipment access platform.
9. An electronic device comprising a memory and a processor, the memory storing a computer program executable on the processor, the processor implementing the information processing method of any one of claims 1 to 7 when the program is executed.
10. A storage medium storing a computer program which, when executed by a processor, performs the information processing method of any one of the preceding claims 1 to 7.
CN202210247305.7A 2022-03-14 2022-03-14 Information processing method, device, equipment and storage medium Pending CN116800854A (en)

Priority Applications (1)

Application Number Priority Date Filing Date Title
CN202210247305.7A CN116800854A (en) 2022-03-14 2022-03-14 Information processing method, device, equipment and storage medium

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
CN202210247305.7A CN116800854A (en) 2022-03-14 2022-03-14 Information processing method, device, equipment and storage medium

Publications (1)

Publication Number Publication Date
CN116800854A true CN116800854A (en) 2023-09-22

Family

ID=88044331

Family Applications (1)

Application Number Title Priority Date Filing Date
CN202210247305.7A Pending CN116800854A (en) 2022-03-14 2022-03-14 Information processing method, device, equipment and storage medium

Country Status (1)

Country Link
CN (1) CN116800854A (en)

Similar Documents

Publication Publication Date Title
CN110851237B (en) Container cross-isomerism cluster reconstruction method for domestic platform
CN113312037B (en) Data processing method, device, equipment and storage medium applied to micro-service
CN111708702A (en) Simulation test method, client, server, system and readable storage medium
CN113641413B (en) Target model loading updating method and device, readable medium and electronic equipment
CN114721719B (en) Method and system for containerized deployment of heterogeneous applications in cluster
CN109933381A (en) A kind of loading method and device of kernel
WO2023065707A1 (en) Method and apparatus for page display
CN109343970B (en) Application program-based operation method and device, electronic equipment and computer medium
CN113806097A (en) Data processing method and device, electronic equipment and storage medium
CN116721007B (en) Task control method, system and device, electronic equipment and storage medium
CN112987936A (en) Interactive processing method, system, device, equipment and medium
CN113204425A (en) Method and device for process management internal thread, electronic equipment and storage medium
CN115509531A (en) Micro front end implementation method, device, terminal and storage medium based on front end technology
US20220326939A1 (en) Mobile service upgrade method and apparatus, and terminal
CN116800854A (en) Information processing method, device, equipment and storage medium
CN113742716B (en) Code running method, device, electronic equipment, storage medium and program product
CN107301089A (en) A kind of APP deployment and call method and terminal
CN113835846B (en) Method and device for creating k8s cluster and computer-readable storage medium
CN116760881B (en) System configuration method and device of power distribution terminal, storage medium and electronic equipment
CN117170738B (en) Method, system, equipment and storage medium for interaction of Python and Fortran
CN113590166B (en) Application program updating method and device and computer readable storage medium
CN111225054B (en) Method and system for designing automatic operation program of cloud mobile phone
CN112667348B (en) MySQL containerization method and system and computer equipment
CN112882709A (en) Rendering method, device and equipment based on container engine system and storage medium
CN115469887A (en) Method and device for issuing cloud native application, electronic equipment and storage medium

Legal Events

Date Code Title Description
PB01 Publication
PB01 Publication
SE01 Entry into force of request for substantive examination
SE01 Entry into force of request for substantive examination