CN110661692B - Network interconnection system and method - Google Patents

Network interconnection system and method Download PDF

Info

Publication number
CN110661692B
CN110661692B CN201911107824.8A CN201911107824A CN110661692B CN 110661692 B CN110661692 B CN 110661692B CN 201911107824 A CN201911107824 A CN 201911107824A CN 110661692 B CN110661692 B CN 110661692B
Authority
CN
China
Prior art keywords
network
interface
standardized
data
layer
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.)
Active
Application number
CN201911107824.8A
Other languages
Chinese (zh)
Other versions
CN110661692A (en
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.)
Lenovo Beijing Ltd
Original Assignee
Lenovo Beijing 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 Lenovo Beijing Ltd filed Critical Lenovo Beijing Ltd
Priority to CN201911107824.8A priority Critical patent/CN110661692B/en
Publication of CN110661692A publication Critical patent/CN110661692A/en
Application granted granted Critical
Publication of CN110661692B publication Critical patent/CN110661692B/en
Active legal-status Critical Current
Anticipated expiration legal-status Critical

Links

Images

Classifications

    • HELECTRICITY
    • H04ELECTRIC COMMUNICATION TECHNIQUE
    • H04LTRANSMISSION OF DIGITAL INFORMATION, e.g. TELEGRAPHIC COMMUNICATION
    • H04L12/00Data switching networks
    • H04L12/28Data switching networks characterised by path configuration, e.g. LAN [Local Area Networks] or WAN [Wide Area Networks]
    • H04L12/46Interconnection of networks
    • HELECTRICITY
    • H04ELECTRIC COMMUNICATION TECHNIQUE
    • H04LTRANSMISSION OF DIGITAL INFORMATION, e.g. TELEGRAPHIC COMMUNICATION
    • H04L12/00Data switching networks
    • H04L12/28Data switching networks characterised by path configuration, e.g. LAN [Local Area Networks] or WAN [Wide Area Networks]
    • H04L12/2854Wide area networks, e.g. public data networks
    • H04L12/2856Access arrangements, e.g. Internet access

Abstract

The application provides a network interconnection system and a method, an access layer in the network interconnection system provides a standardized interface which is adapted to a first type network and a second type network for an application layer, the access layer provides a communication interface which is adapted to the first type network and a communication interface which is adapted to the second type network for a driving layer, the communication interface which is adapted to the first type network enables the access layer to carry out data interaction with electronic equipment under the first type network, the communication interface which is adapted to the second type network enables the access layer to carry out data interaction with electronic equipment under the second type network, therefore, for the application layer, the access layer shields the network type for the application layer by providing the standardized interface which is adapted to different types of networks, the interface unification of different types of networks is realized, and the application layer can carry out data interaction on the electronic equipment under different types of networks by calling one standardized interface, the operation of the application layer on the electronic equipment under different types of networks is facilitated.

Description

Network interconnection system and method
Technical Field
The present application relates to the field of communications technologies, and in particular, to a network interconnection system and method.
Background
At present, a network interconnection system can provide various types of communication modes, and when data interaction is performed with electronic equipment with different types of communication modes, the network interconnection system needs to acquire an equipment name of the electronic equipment, an address of the electronic equipment and a network type of a network connected with the electronic equipment, so that the network interconnection system can perform data interaction with the electronic equipment.
Disclosure of Invention
In view of the above, the present application is directed to a network interconnection system and method. The technical scheme is as follows:
the application provides a network interconnection system, including:
an application layer;
a drive layer;
the access layer is positioned between the application layer and the driving layer and provides a standardized interface which is adaptive to a first type network and a second type network for the application layer, the first type network is different from the second type network, and the standardized interface enables the application layer to perform data interaction with electronic equipment under different types of networks through the same interface;
the access layer provides a communication interface which is adapted to the first type network and a communication interface which is adapted to the second type network for the driving layer, the communication interface which is adapted to the first type network enables the access layer to carry out data interaction with the electronic equipment under the first type network, and the communication interface which is adapted to the second type network enables the access layer to carry out data interaction with the electronic equipment under the second type network.
Optionally, the standardized interface includes: a standardized transmission interface and a standardized reception interface, the communication interface comprising: a transmitting interface and a receiving interface;
the application layer is used for respectively sending instruction data to the electronic equipment under different types of networks based on the standardized sending interface and respectively receiving feedback data sent by the electronic equipment under different types of networks based on the standardized receiving interface;
the access layer is used for converting the instruction data sent to the electronic equipment into the transmission interface which is suitable for the network where the electronic equipment is located to send, and converting the feedback data of the electronic equipment received by the receiving interface into the feedback data which is sent by the standardized receiving interface.
Optionally, the access layer is configured to extract the identity of the electronic device and the control data for the electronic device from the instruction data, obtain a network address of the electronic device corresponding to the identity of the electronic device, and send the network address of the electronic device and the control data for the electronic device as interface parameters in a sending interface of a network where the electronic device is located.
Optionally, the access layer is configured to extract the network address of the electronic device and response data of the electronic device for the instruction data from the feedback data, obtain an identity of the electronic device corresponding to the network address of the electronic device, and send the identity of the electronic device and the response data of the electronic device as interface parameters of the standardized receiving interface.
Optionally, the access layer is further configured to provide, to the application layer, an identity of an electronic device in a different type of network and in networking, where the identity of the electronic device is used as an interface parameter in the standardized interface, and is used for enabling the application layer to perform data interaction with the electronic device.
Optionally, the identity of the electronic device includes a standardized address of the electronic device in the access layer, and standardized addresses of electronic devices in different types of networks are different, but the number of bits of the standardized addresses of electronic devices in different types of networks is the same.
The application also provides a network interconnection method, which comprises the following steps:
performing data interaction with an application layer through a standardized interface provided by an access layer, wherein the standardized interface is adapted to a first type network and a second type network;
determining the type of the network of the electronic equipment involved in the data interaction with the application layer;
determining a communication interface adapted to the network type of the electronic device from the communication interface adapted to the first type network and the communication interface adapted to the second type network provided by the access stratum;
and performing data interaction with the driving layer through a communication interface adaptive to the type of the network where the electronic equipment is located.
Optionally, the data interaction with the application layer through a standardized interface provided by the access layer includes:
receiving instruction data sent by the application layer through a standardized sending interface in standardized interfaces, and sending feedback data to the application layer through a standardized receiving interface in the standardized interfaces;
the data interaction with the driving layer through the communication interface adaptive to the type of the network where the electronic device is located comprises:
and converting the instruction data into a transmission interface in a communication interface adaptive to the network type of the electronic equipment to transmit the instruction data to the driving layer, and receiving the feedback data transmitted by the driving layer through a receiving interface in the communication interface adaptive to the network type of the electronic equipment.
Optionally, the converting the instruction data into sending the instruction data to the driver layer by using a sending interface in a communication interface adapted to a type of a network where the electronic device is located includes:
extracting the identity of the electronic equipment and control data aiming at the electronic equipment from the instruction data;
acquiring a network address of the electronic equipment corresponding to the identity of the electronic equipment;
and sending the network address of the electronic equipment and the control data aiming at the electronic equipment as interface parameters in a sending interface adaptive to the type of the network where the electronic equipment is located.
Optionally, the sending feedback data to the application layer through a standardized receiving interface in the standardized interfaces includes:
extracting a network address of the electronic device and response data of the electronic device for the instruction data from the feedback data;
acquiring an identity of the electronic equipment corresponding to the network address of the electronic equipment;
and sending the identity of the electronic equipment and the response data of the electronic equipment as interface parameters of the standardized receiving interface.
By means of the network interconnection system, an access layer in the network interconnection system provides a standardized interface which is adapted to a first type network and a second type network to an application layer, the access layer provides a communication interface which is adapted to the first type network and a communication interface which is adapted to the second type network to a driver layer, wherein the first type network and the second type network are not communicated, the standardized interface enables the application layer to carry out data interaction with electronic equipment under different types of networks through the same interface, the communication interface which is adapted to the first type network enables the access layer to carry out data interaction with electronic equipment under the first type network, the communication interface which is adapted to the second type network enables the access layer to carry out data interaction with electronic equipment under the second type network, and therefore, for the application layer, the access layer shields the network types for the application layer by providing the standardized interface which is adapted to the different types of networks, the unified interfaces of different types of networks are realized, so that the application layer can carry out data interaction on the electronic equipment under different types of networks by calling a standardized interface, and the application layer can conveniently operate the electronic equipment under different types of networks. And the network type factor can be ignored during the application layer development, so that the complexity of the application layer development is reduced.
Drawings
In order to more clearly illustrate the embodiments of the present application or the technical solutions in the prior art, the drawings needed to be used in the description of the embodiments or the prior art will be briefly introduced below, and it is obvious that the drawings in the following description are some embodiments of the present application, and it is obvious for those skilled in the art to obtain other drawings based on these drawings without creative efforts.
FIG. 1 is a system architecture diagram of a prior art network interconnection system;
fig. 2 is a system architecture diagram of a network interconnection system provided in an embodiment of the present application;
fig. 3 is a flowchart of a network interconnection method provided in an embodiment of the present application;
fig. 4 is a schematic structural diagram of a network interconnection device according to an embodiment of the present application.
Detailed Description
At present, the Network interconnection system CAN provide various types of communication modes, such as providing at least one wired communication mode and/or wireless communication mode, such as providing RS485, CAN (Controller Area Network), Zigbee (Zigbee Network), BLE (bluetooth), lora (long range), and Z-wave, so that the Network interconnection system CAN perform data interaction with electronic devices in different types of networks, and implement communication with electronic devices in different types of networks. The system architecture of the current network interconnection system is shown in fig. 1, and includes: the system comprises an application layer, a driver layer, a communication protocol layer, an operating system layer, a hardware abstraction layer and a hardware layer, wherein the driver layer comprises drivers for various networks, such as a CAN driver, an RS485 driver and a LORAdriver in FIG. 1, and data interaction between the electronic devices under different networks is realized through interaction between the application layer and the driver layer, but when the application layer and the driver layer perform data interaction, which electronic device needs to be determined, and the following three conditions are required:
1. the type of network the electronic device is in;
2. a network address of the electronic device;
3. and interacting with the electronic equipment through a communication interface of the network type where the electronic equipment is located.
Namely, the steps of determining the electronic device are as follows in sequence: looking for the device type- > network type- > address- > interface call, taking the water Meter as an example, referring to table 1, firstly, finding the water Meter Meter _ water from the device type, determining that the water Meter is in the RS485 network, then, the address of the water Meter in the RS485 network is 0x01, then, calling the RS485_ TX () through the communication interface of the RS485 network, and controlling the water Meter by taking the address 0x01 as an interface parameter, or calling the RS485_ RX () through the communication interface of the RS485 network, and receiving the feedback data of the water Meter by taking the address 0x01 as an interface parameter.
TABLE 1 statistical table of device information
Network type Communication interface Network address Type of device
Zigbee Zigbee_TX();Zigbee_RX() 0x0010(2Bytes) Environment
LORA LORA_TX();LORA_RX() 0x0011(2Bytes) Access_control
CAN CAN_TX();CAN_RX() 0x00000001(29bits) Device_status
BLE BLE_TX();BLE_RX() AA:BB:CC:DD Location
RS485 RS485_TX();RS485_RX() Self-defining Meter_water
In the column of the communication interface, interface functions corresponding to the communication interface are set forth, for example, Zigbee _ TX () and Zigbee _ RX () respectively represent a sending function and a receiving function used when data interaction is performed with an electronic device in a Zigbee network; however, a network interconnection system sometimes has a scene of hundreds of electronic devices (e.g. industries, smart cities, etc.), and the more electronic devices, the more troublesome the process of data interaction between the application layer and the electronic devices.
The application provides a network interconnection system and a network interconnection method, which shield the factor of the network type for an application layer, so that the application layer can perform data interaction with electronic equipment under different types of networks through a standardized interface.
In order to make the objects, technical solutions and advantages of the embodiments of the present application clearer, the technical solutions in the embodiments of the present application will be clearly and completely described below with reference to the drawings in the embodiments of the present application, and it is obvious that the described embodiments are some embodiments of the present application, but not all embodiments. All other embodiments, which can be derived by a person skilled in the art from the embodiments given herein without making any creative effort, shall fall within the protection scope of the present application.
Referring to fig. 2, a network interconnection system provided in an embodiment of the present application is shown, which may include: an application layer 10, a driver layer 20, and an access layer 30 located between the application layer 10 and the driver layer 20.
The driving layer 20 includes a driver for the above various types of networks, such as CAN driver, RS485 driver, and LORA driver in fig. 2. The access layer 30 provides the application layer 10 with a standardized interface adapted to a first type of network and a second type of network, the first type of network and the second type of network being different, wherein the standardized interface enables the application layer 10 to interact data with electronic devices under different types of networks through the same interface.
The first type network is any one of the RS485, CAN, Zigbee, BLE, LORA, and Z-wave, the second type network is a network different from the first type network among the RS485, CAN, Zigbee, BLE, LORA, and Z-wave, in an actual service scenario, the standardized interface provided by the access layer 30 may be further adapted to a network other than the first type network and the second type network, so that the application layer 10 CAN perform data interaction with electronic devices under different types of networks through one standardized interface, for example, the application layer 10 CAN perform data interaction with electronic devices under at least one of the RS485, CAN, BLE, LORA, and Z-wave through the standardized interface provided by the access layer 30, so that for the application layer 10, the standardized interface provided by the access layer 30 enables the application layer 10 to shield the network type, so that the application layer 10 CAN ignore the electronic devices under different types of networks when performing data interaction with the electronic devices under different types of networks The type of network in which the device is located.
Because the application layer 10 can ignore the type of the network where the electronic device is located, the manner of the application layer 10 performing data interaction through the standardized interface may also be correspondingly adjusted, for example, the application layer 10 obtains the identity of the electronic device performing data interaction, such as the device type mentioned above, and may perform data interaction with the electronic device by using the identity of the electronic device as the interface parameter of the standardized interface.
For example, the standardized interface may provide two interface functions, namely, a standardized sending function Gateway _ network _ TX () and a standardized receiving function Gateway _ network _ RX (), and the identity of the electronic device (such as the device type mentioned above) is used as an interface parameter, so that data interaction can be performed with the electronic device.
The access layer 30 provides the driver layer 20 with a communication interface adapted to the first type network and a communication interface adapted to the second type network, wherein the communication interface adapted to the first type network enables the access layer 30 to perform data interaction with the electronic devices under the first type network, and the communication interface adapted to the second type network enables the access layer 30 to perform data interaction with the electronic devices under the second type network.
That is, for the access layer 30, the access layer 30 has no shielding network type, the access layer 30 needs to perform data interaction with the electronic device by using the communication interface of the network where the electronic device is located when performing data interaction with the electronic device, for example, for the electronic device under RS485, the RS485_ TX () and RS485_ RX () are used for performing data interaction, and for the electronic device under CAN, the CAN _ TX () and CAN _ RX () are used for performing data interaction, so for the access layer 30, the access layer 30 CAN shield the network type (in other words, ignore the factor of the network type) when performing data interaction with the application layer 10 to adapt to the standardized sending function Gateway _ network _ TX () and the standardized receiving function Gateway _ network _ RX () corresponding to the standardized interfaces of different networks for performing data interaction, while the access layer 30 needs to consider the network where the electronic device is located when performing data interaction with the driver layer 20, and interacting through a communication interface under the network where the communication interface is positioned.
Based on this, on the basis of the network interconnection system shown in fig. 2, the device information statistical table corresponding to the access stratum 30 is changed to some extent on the basis of the above table 1, as shown in the following table 2.
TABLE 2 statistical table of device information
Figure BDA0002271851530000071
The access layer 30 only needs to refer to the device type (a form of identification) and the standardized interface when performing data interaction with the application layer 10, and the access layer 30 needs to refer to the device type, the network address, the communication interface and the network type when performing data interaction with the driver layer 20.
When the access layer 30 is accessed to the internet system, the access layer 30 scans any electronic device connected to the internet system to obtain device information of the electronic device in networking, such as the network type, the network address, the communication interface, the device type, and the like, so that the interaction between the application layer 10 and the driver layer 20 is realized through the access layer 30, and data interaction between the application layer 10 and the electronic devices in different types of networks is realized.
In this embodiment, the manner in which the access layer 30 obtains the device information of the electronic devices under networking includes, but is not limited to: the access stratum 30 periodically or aperiodically scans device information of electronic devices connected to the internet or device information uploaded by electronic devices connected to the internet, and the internet stores the device information in the above manner.
It can be known from the above technical solution that an access layer in a network interconnection system provides a standardized interface adapted to a first type network and a second type network to an application layer, the access layer provides a communication interface adapted to the first type network and a communication interface adapted to the second type network to a driver layer, wherein the first type network and the second type network are not connected, the standardized interface enables the application layer to perform data interaction with electronic devices under different types of networks through the same interface, the communication interface adapted to the first type network enables the access layer to perform data interaction with electronic devices under the first type network, the communication interface adapted to the second type network enables the access layer to perform data interaction with electronic devices under the second type network, so that for the application layer, the access layer shields the network type for the application layer by providing the standardized interface adapted to the different types of networks, the unified interfaces of different types of networks are realized, so that the application layer can carry out data interaction on the electronic equipment under different types of networks by calling a standardized interface, and the application layer can conveniently operate the electronic equipment under different types of networks. And the network type factor can be ignored during the application layer development, so that the complexity of the application layer development is reduced.
The network interconnection system can be applied to network interconnection devices capable of connecting electronic devices, such as gateways, which provide various wired and/or wireless communications to perform data interaction with electronic devices in various types of networks, and the network interconnection devices acquire the device information in the table 2 when being connected to electronic devices in different types of networks. When the network interconnection equipment performs data interaction with electronic equipment under any type of network, the application layer 10 of the network interconnection equipment uses the standardized interfaces which are provided by the access layer 30 and are adapted to different types of networks, and the driver layer 20 uses each communication interface which is provided by the access layer 30 and is adapted to a single network to realize data interaction with the electronic equipment under different types of networks through the standardized interfaces and each communication interface.
In the present embodiment, one way of data interaction among the application layer 10, the access layer 30 and the driver layer 20 is as follows:
the standardized interface includes: a standardized transmission interface and a standardized reception interface, the communication interface comprising: a transmitting interface and a receiving interface. And the corresponding application layer 10 is used for respectively sending instruction data to the electronic equipment in different types of networks based on the standardized sending interface and respectively receiving feedback data sent by the electronic equipment in different types of networks based on the standardized receiving interface, so that the instruction data is sent through the standardized sending interface, the feedback data is received through the standardized receiving interface, and the sending and receiving are distinguished.
And the access layer 30 is used for converting the instruction data sent to the electronic equipment into the transmission interface of the network where the electronic equipment is adapted to send, and converting the feedback data of the electronic equipment received by the receiving interface into the feedback data sent by the standardized receiving interface.
For example, the instruction data is transmitted from the application layer 10 to the electronic device in the first type network, the access layer 30 may convert the instruction data to be transmitted by the transmission interface of the first type network, and after the electronic device responds based on the instruction data, the access layer 30 may receive the feedback data through the receiving interface of the first type network, so that for the electronic device in the first type network, the data may be interacted through the transmission interface and the receiving interface in the communication interface of the network, thereby realizing the distinction of transmission and reception. Similarly, for electronic devices in other types of networks, data interaction with the application layer 10 may also be performed through the sending interface and the receiving interface of the communication interface of the network.
In this embodiment, the purpose of the conversion between the instruction data and the feedback data is to enable the instruction data to be sent to the corresponding electronic device and the application layer to receive the feedback data, so one way of the conversion in this embodiment is as follows:
the process of converting the instruction data includes: the access layer 30 extracts the id of the electronic device and the control data for the electronic device (e.g., a control command for the electronic device) from the command data, obtains the network address of the electronic device corresponding to the id of the electronic device, and sends the network address of the electronic device and the control data for the electronic device as interface parameters in a sending interface of a network where the electronic device is located, so that the control data can be sent to the electronic device pointed by the network address in the interface parameters through the sending interface, so that the control data can be accurately sent to the corresponding electronic device.
For example, the command data is transmitted by a standardized transmission function corresponding to a standardized transmission interface, and the standardized transmission function transmits the command data in the form of: gateway _ network _ TX (identity, data1), data1 is control data, and obtains a network address corresponding to the identity, and in the above device information statistics table, the corresponding network address can be found by the device type as the identity, and then the network address is converted into a sending function corresponding to the sending interface of the network where the network is located, and the sending function is in the form: and corresponding to the network _ TX (network address, data1), the conversion of the instruction data is realized and the instruction data can be accurately transmitted to the corresponding electronic equipment.
Taking the example that the instruction data is used for controlling the water meter, the instruction data sent by the standardized sending function is as follows: the Gateway _ network _ TX (Meter _ water, data1) can know that the application layer 10 only needs to know the identity of the water Meter, and then the access layer 30 recognizes that the water Meter belongs to the RS485 network and sends the water Meter by using the RS485_ TX () sending function. Before sending through the RS485_ TX () sending function, the network address of the water meter in the RS485 network is obtained as 0x01, so that the corresponding RS485_ TX () sending form is: RS485_ TX (0x01, data 1).
The conversion process of the feedback data is similar to that of the instruction data, except that the feedback data is from the network address to the identity, and the corresponding conversion process of the feedback data comprises the following steps: the access layer 30 extracts the network address of the electronic device and response data of the electronic device for the instruction data from the feedback data, obtains an identity of the electronic device corresponding to the network address of the electronic device, and sends the identity of the electronic device and the response data of the electronic device as interface parameters of the standardized receiving interface.
For example, the feedback data is sent by a receiving function corresponding to a receiving interface of a network where the electronic device is located, and the form of the feedback data sent by the receiving function is as follows: corresponding to network _ TX (network address, data2), data2 is response data to obtain the id corresponding to the network address, and as in the above device information statistics table, the corresponding device type as the id can be found through the network address, and then converted into a standardized receiving function corresponding to the standardized receiving interface for transmission, where the form of the standardized receiving function is: gateway _ network _ RX (Meter _ water, data2), which enables conversion of feedback data and ensures that the feedback data can be accurately transmitted from the electronic device to the application layer.
Still taking the example that the instruction data is used for controlling the water Meter, after receiving the instruction data, the electronic device obtains the response data, the access layer receives the response data through RS485_ RX (), for example, RS485_ RX (0x01, data), and then the access layer 30 recognizes that the identity of the water Meter is Meter _ water, and sends the response data to the application layer through Gateway _ network _ RX (Meter _ water, data 2).
According to the technical scheme, the access layer 30 converts the instruction data and the feedback data, so that the application layer 10 can perform data interaction through electronic devices of different types of networks under the driving layer 20.
In order to facilitate the data interaction between the application layer 10 and the electronic devices in the network, the access layer 30 is further configured to provide the application layer 10 with the identities of the electronic devices in different types of networks and in the network, where the identities of the electronic devices serve as interface parameters in the standardized interface for the data interaction between the application layer 10 and the electronic devices. For example, after the access layer 30 acquires the identity of the electronic device, the identity acquired by the access layer 30 is uploaded to the application layer 10, or the application layer 10 periodically/uninterruptedly acquires the identity from the access layer 30, so that the application layer 10 determines which electronic devices are currently in networking through the identity to perform data interaction with the electronic devices in networking, thereby reducing sending of instruction data to the electronic devices in offline (i.e., not in networking) and ensuring success of data interaction.
In this embodiment, one manner of the identity of the electronic device is the above-mentioned device type, but the device types of the electronic devices in different types of networks may be different, and therefore, this embodiment may also adopt other manners to represent the identity of the electronic device, for example, the identity of the electronic device includes a standardized address of the electronic device in an access layer, the standardized addresses of the electronic devices in different types of networks are different, but the number of bits of the standardized addresses of the electronic devices in different types of networks is the same, so as to unify the identities of the electronic devices in different types of networks.
For example, the standardized address of the electronic device in the access layer is a 32-bit int or long type, for example, expressed by 0xaabbcc d, and the corresponding device information statistical table is changed into the form of table 3. With respect to table 2 above, a standardized address column is added, which records standardized addresses of the respective electronic devices in the access layer, and the standardized addresses can be regarded as virtual addresses, and are allocated to the electronic devices by the access layer 30, and the recording and calling are facilitated by a standardized address with a uniform form and a uniform number of bits.
Table 3 device information statistics table
Figure BDA0002271851530000111
Through the technical scheme, the access layer 30 realizes the standardization and unification of the interface and the address, so that the data interaction between the application layer 10 and the electronic equipment in different types of networks is simplified, and the development complexity of the application layer is reduced.
Corresponding to the above system embodiment, an embodiment of the present application further provides a network interconnection method, a flowchart of which is shown in fig. 3, and the method may include the following steps:
101: and the standardized interface is adapted to the first type network and the second type network, so that the application layer can perform data interaction with electronic equipment under different types of networks through the standardized interface.
In this embodiment, the standardized interface enables the application layer to perform data interaction with the electronic devices in different types of networks, so that the application layer can ignore the type of the network where the electronic device is located when performing data interaction with the electronic devices in different types of networks.
Because the application layer can ignore the type of the network where the electronic device is located, the mode of the application layer when performing data interaction through the standardized interface can also be correspondingly adjusted, for example, the application layer obtains the identity of the electronic device performing data interaction, as for the device type, for example, the identity of the electronic device can be used as the interface parameter of the standardized interface to perform data interaction with the electronic device.
102: the network type of the electronic device involved in the data interaction with the application layer is determined, where the purpose of determining the network type of the electronic device is to determine a communication interface used in the data interaction with the electronic device, and one way of determining the network type of the electronic device may be to determine the network type of the electronic device based on an identity of the electronic device, for example, determine the network type of the electronic device by referring to the device information statistical table, which is not described in detail in this embodiment.
103: the communication interface adapted to the type of the network where the electronic device is located is determined from the communication interface adapted to the first type network and the communication interface adapted to the second type network provided by the access layer. If the network type of the electronic equipment is indicated as a first type network, determining the adaptive communication interface as the communication interface of the first type network; and if the network type of the electronic equipment is indicated as a second type network, determining that the adapted communication interface is the communication interface of the second type network. E.g., RS485, the type of network is located, then the adapted communication interface is determined.
104: and performing data interaction with the driving layer through a communication interface adaptive to the type of the network where the electronic equipment is located.
In this embodiment, the data interaction with the application layer through a standardized interface provided by the access layer includes: the method comprises the steps of receiving instruction data sent by an application layer through a standardized sending interface in a standardized interface, and sending feedback data to the application layer through a standardized receiving interface in the standardized interface.
For example, the command data is transmitted through a standardized transmission function corresponding to the standardized transmission interface, and the feedback data is transmitted to the application layer through a standardized receiving function corresponding to the standardized receiving interface.
One way in which feedback data is sent to the application layer through a standardized receiving interface in the standardized interfaces is: extracting a network address of the electronic equipment and response data of the electronic equipment for the instruction data from the feedback data; acquiring an identity of the electronic equipment corresponding to the network address of the electronic equipment; and sending the identity of the electronic equipment and the response data of the electronic equipment as interface parameters of the standardized receiving interface.
In this embodiment, the performing data interaction with the driver layer through the communication interface adapted to the type of the network where the electronic device is located includes: and converting the instruction data into a transmission interface in the communication interface adaptive to the type of the network where the electronic equipment is located to transmit the instruction data to the driving layer, and receiving feedback data transmitted by the driving layer through a receiving interface in the communication interface adaptive to the type of the network where the electronic equipment is located.
For example, the command data is transmitted through a transmission function corresponding to the transmission interface, and the feedback data is received through a reception function corresponding to the reception interface.
One way to convert the instruction data into a transmission interface in the communication interface adapted to the type of the network where the electronic device is located to transmit the instruction data to the driver layer is: extracting the identity of the electronic equipment and the control data aiming at the electronic equipment from the instruction data; acquiring a network address of the electronic equipment corresponding to the identity of the electronic equipment; and sending the network address of the electronic equipment and the control data aiming at the electronic equipment as interface parameters in a sending interface adapted to the type of the network where the electronic equipment is located.
For the processing procedure of the instruction data and the feedback data, please refer to the related description in the above system embodiment, which is not further described in this embodiment.
In addition, the network interconnection method provided by this embodiment further includes: and providing the identity of the electronic equipment under different types of networks and in networking to the application layer, wherein the identity of the electronic equipment is used as an interface parameter in a standardized interface and is used for enabling the application layer to perform data interaction with the electronic equipment.
One form of identification of the electronic device is: the specific description refers to the relevant description in the above system embodiment, and this embodiment is not described again.
It can be known from the above technical solution that an access layer in a network interconnection system provides a standardized interface adapted to a first type network and a second type network to an application layer, the access layer provides a communication interface adapted to the first type network and a communication interface adapted to the second type network to a driver layer, wherein the first type network and the second type network are not connected, the standardized interface enables the application layer to perform data interaction with electronic devices under different types of networks through the same interface, the communication interface adapted to the first type network enables the access layer to perform data interaction with electronic devices under the first type network, the communication interface adapted to the second type network enables the access layer to perform data interaction with electronic devices under the second type network, so that for the application layer, the access layer shields the network type for the application layer by providing the standardized interface adapted to the different types of networks, the unified interfaces of different types of networks are realized, so that the application layer can carry out data interaction on the electronic equipment under different types of networks by calling a standardized interface, and the application layer can conveniently operate the electronic equipment under different types of networks. And the network type factor can be ignored during the application layer development, so that the complexity of the application layer development is reduced.
Referring to fig. 4, a structure of a network interconnection apparatus provided in an embodiment of the present application is shown, which may include: a first interaction unit 10, a determination unit 20, a selection unit 30 and a second interaction unit 40.
And the first interaction unit 10 is used for performing data interaction with the application layer through a standardized interface provided by the access layer, wherein the standardized interface is adapted to the first type network and the second type network, so that the application layer performs data interaction with electronic equipment under different types of networks through the standardized interface.
In this embodiment, the data interaction between the first interaction unit 10 and the application layer through a standardized interface provided by the access layer includes: the method comprises the steps of receiving instruction data sent by an application layer through a standardized sending interface in a standardized interface, and sending feedback data to the application layer through a standardized receiving interface in the standardized interface.
For example, the command data is transmitted through a standardized transmission function corresponding to the standardized transmission interface, and the feedback data is transmitted to the application layer through a standardized receiving function corresponding to the standardized receiving interface.
One way in which feedback data is sent to the application layer through a standardized receiving interface in the standardized interfaces is: extracting a network address of the electronic equipment and response data of the electronic equipment for the instruction data from the feedback data; acquiring an identity of the electronic equipment corresponding to the network address of the electronic equipment; and sending the identity of the electronic equipment and the response data of the electronic equipment as interface parameters of the standardized receiving interface.
The determining unit 20 is configured to determine a network type of the electronic device involved in data interaction with the application layer, where the purpose of determining the network type of the electronic device is to determine a communication interface used in data interaction with the electronic device, and one way of determining the network type of the electronic device may be to determine the network type of the electronic device based on an identity of the electronic device, for example, determine the network type of the electronic device by referring to the device information statistics table, which is not described in detail in this embodiment.
The selection unit 30 is configured to determine a communication interface adapted to the network type of the electronic device from the communication interface adapted to the first type network and the communication interface adapted to the second type network provided by the access stratum. If the network type of the electronic equipment is indicated as a first type network, determining the adaptive communication interface as the communication interface of the first type network; and if the network type of the electronic equipment is indicated as a second type network, determining that the adapted communication interface is the communication interface of the second type network. E.g., RS485, the type of network is located, then the adapted communication interface is determined.
And the second interaction unit 40 is used for performing data interaction with the driving layer through a communication interface adaptive to the type of the network where the electronic equipment is located.
In this embodiment, the data interaction between the second interaction unit 40 and the driver layer through the communication interface adapted to the type of the network where the electronic device is located includes: and converting the instruction data into a transmission interface in the communication interface adaptive to the type of the network where the electronic equipment is located to transmit the instruction data to the driving layer, and receiving feedback data transmitted by the driving layer through a receiving interface in the communication interface adaptive to the type of the network where the electronic equipment is located.
For example, the command data is transmitted through a transmission function corresponding to the transmission interface, and the feedback data is received through a reception function corresponding to the reception interface.
One way to convert the instruction data into a transmission interface in the communication interface adapted to the type of the network where the electronic device is located to transmit the instruction data to the driver layer is: extracting the identity of the electronic equipment and the control data aiming at the electronic equipment from the instruction data; acquiring a network address of the electronic equipment corresponding to the identity of the electronic equipment; and sending the network address of the electronic equipment and the control data aiming at the electronic equipment as interface parameters in a sending interface adapted to the type of the network where the electronic equipment is located.
For the processing procedure of the instruction data and the feedback data, please refer to the related description in the above system embodiment, which is not further described in this embodiment.
In addition, the network interconnection apparatus provided in this embodiment further includes: and the identity identification providing unit is used for providing the identity identification of the electronic equipment under different types of networks and in networking to the application layer, and the identity identification of the electronic equipment is used as an interface parameter in the standardized interface and is used for enabling the application layer to perform data interaction with the electronic equipment.
One form of identification of the electronic device is: the specific description refers to the relevant description in the above system embodiment, and this embodiment is not described again.
The embodiment also provides a storage medium, in which computer program codes are stored, and when the computer program codes are executed, the network interconnection method is realized.
It should be noted that, in the present specification, the embodiments are all described in a progressive manner, each embodiment focuses on differences from other embodiments, and the same and similar parts among the embodiments may be referred to each other. For the method class embodiment and the apparatus class embodiment, since they are basically similar to the system embodiment, the description is simple, and the relevant points can be referred to the partial description of the system embodiment.
Finally, it should also be noted that, herein, relational terms such as first and second, and the like may be used solely to distinguish one entity or action from another entity or action without necessarily requiring or implying any actual such relationship or order between such entities or actions. Also, 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 an … …" does not exclude the presence of other identical elements in a process, method, article, or apparatus that comprises the element.
The previous description of the disclosed embodiments is provided to enable any person skilled in the art to make or use the present application. Various modifications to these embodiments will be readily apparent to those skilled in the art, and the generic principles defined herein may be applied to other embodiments without departing from the spirit or scope of the application. Thus, the present application is not intended to be limited to the embodiments shown herein but is to be accorded the widest scope consistent with the principles and novel features disclosed herein.
The foregoing is only a preferred embodiment of the present application and it should be noted that those skilled in the art can make several improvements and modifications without departing from the principle of the present application, and these improvements and modifications should also be considered as the protection scope of the present application.

Claims (10)

1. A network interconnection system comprising:
an application layer;
a drive layer;
the access layer is positioned between the application layer and the driving layer and provides a standardized interface which is adaptive to a first type network and a second type network for the application layer, the first type network is different from the second type network, and the standardized interface enables the application layer to perform data interaction with electronic equipment under different types of networks through the same interface;
the access layer provides a communication interface which is adapted to the first type network and a communication interface which is adapted to the second type network for the driving layer, the communication interface which is adapted to the first type network enables the access layer to carry out data interaction with the electronic equipment under the first type network, and the communication interface which is adapted to the second type network enables the access layer to carry out data interaction with the electronic equipment under the second type network;
in the process of sending instruction data of an application layer through an access layer, the access layer acquires a network address corresponding to an identity identifier in the instruction data, and sends the network address corresponding to the identity identifier and control data in the instruction data through the access layer; or, in the process of sending feedback data to the application layer through the access layer, the access layer acquires an identity corresponding to a network address in the feedback data, and sends the identity corresponding to the network address and control data in the feedback data to the application layer.
2. The system of claim 1, the standardized interface comprising: a standardized transmission interface and a standardized reception interface, the communication interface comprising: a transmitting interface and a receiving interface;
the application layer is used for respectively sending instruction data to the electronic equipment under different types of networks based on the standardized sending interface and respectively receiving feedback data sent by the electronic equipment under different types of networks based on the standardized receiving interface;
the access layer is used for converting the instruction data sent to the electronic equipment into the transmission interface which is suitable for the network where the electronic equipment is located to send, and converting the feedback data of the electronic equipment received by the receiving interface into the feedback data which is sent by the standardized receiving interface.
3. The system according to claim 2, wherein the access stratum is configured to extract the identification of the electronic device and the control data for the electronic device from the instruction data, obtain a network address of the electronic device corresponding to the identification of the electronic device, and send the network address of the electronic device and the control data for the electronic device as interface parameters in a sending interface of a network where the electronic device is located.
4. The system according to claim 2, wherein the access layer is configured to extract, from the feedback data, a network address of the electronic device and response data of the electronic device for the instruction data, obtain an identity of the electronic device corresponding to the network address of the electronic device, and send the identity of the electronic device and the response data of the electronic device as interface parameters of the standardized receiving interface.
5. The system of claim 1, wherein the access layer is further configured to provide, to the application layer, identities of electronic devices in different types of networks and in networking, and the identities of the electronic devices serve as interface parameters in the standardized interface, so that the application layer and the electronic devices perform data interaction.
6. The system of claim 5, wherein the identity of the electronic device comprises a standardized address of the electronic device in the access layer, wherein standardized addresses of electronic devices in different types of networks are different, but the standardized addresses of electronic devices in different types of networks have the same number of bits.
7. A method of internetworking, the method comprising:
performing data interaction with an application layer through a standardized interface provided by an access layer, wherein the standardized interface is adapted to a first type network and a second type network;
determining the type of the network of the electronic equipment involved in the data interaction with the application layer;
determining a communication interface adapted to the network type of the electronic device from the communication interface adapted to the first type network and the communication interface adapted to the second type network provided by the access stratum;
performing data interaction with a driving layer through a communication interface adaptive to the type of the network where the electronic equipment is located;
in the process of sending instruction data of an application layer through an access layer, the access layer acquires a network address corresponding to an identity identifier in the instruction data, and sends the network address corresponding to the identity identifier and control data in the instruction data through the access layer; or, in the process of sending feedback data to the application layer through the access layer, the access layer acquires an identity corresponding to a network address in the feedback data, and sends the identity corresponding to the network address and control data in the feedback data to the application layer.
8. The method of claim 7, wherein interacting data with the application layer through a standardized interface provided by the access layer comprises:
receiving instruction data sent by the application layer through a standardized sending interface in standardized interfaces, and sending feedback data to the application layer through a standardized receiving interface in the standardized interfaces;
the data interaction with the driving layer through the communication interface adaptive to the type of the network where the electronic device is located comprises:
and converting the instruction data into a transmission interface in a communication interface adaptive to the network type of the electronic equipment to transmit the instruction data to the driving layer, and receiving the feedback data transmitted by the driving layer through a receiving interface in the communication interface adaptive to the network type of the electronic equipment.
9. The method of claim 8, wherein the converting the instruction data into sending the instruction data to the driver layer through a sending interface in a communication interface adapted to a type of a network in which the electronic device is located comprises:
extracting the identity of the electronic equipment and control data aiming at the electronic equipment from the instruction data;
acquiring a network address of the electronic equipment corresponding to the identity of the electronic equipment;
and sending the network address of the electronic equipment and the control data aiming at the electronic equipment as interface parameters in a sending interface adaptive to the type of the network where the electronic equipment is located.
10. The method of claim 8, the sending feedback data to the application layer through a standardized receiving interface of the standardized interfaces comprising:
extracting a network address of the electronic device and response data of the electronic device for the instruction data from the feedback data;
acquiring an identity of the electronic equipment corresponding to the network address of the electronic equipment;
and sending the identity of the electronic equipment and the response data of the electronic equipment as interface parameters of the standardized receiving interface.
CN201911107824.8A 2019-11-13 2019-11-13 Network interconnection system and method Active CN110661692B (en)

Priority Applications (1)

Application Number Priority Date Filing Date Title
CN201911107824.8A CN110661692B (en) 2019-11-13 2019-11-13 Network interconnection system and method

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
CN201911107824.8A CN110661692B (en) 2019-11-13 2019-11-13 Network interconnection system and method

Publications (2)

Publication Number Publication Date
CN110661692A CN110661692A (en) 2020-01-07
CN110661692B true CN110661692B (en) 2021-01-15

Family

ID=69043529

Family Applications (1)

Application Number Title Priority Date Filing Date
CN201911107824.8A Active CN110661692B (en) 2019-11-13 2019-11-13 Network interconnection system and method

Country Status (1)

Country Link
CN (1) CN110661692B (en)

Families Citing this family (1)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN111787431B (en) * 2020-06-30 2022-06-14 深圳市北电仪表有限公司 Centralized meter reading system of dual-mode networking communication technology and implementation method thereof

Citations (1)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN101989960A (en) * 2010-11-09 2011-03-23 中国电信股份有限公司 Home gateway and access adaption method

Family Cites Families (6)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
US20030217182A1 (en) * 2002-05-15 2003-11-20 Xiaodong Liu Interface architecture
CN1787653A (en) * 2004-12-10 2006-06-14 华为技术有限公司 Communication system
CN104679694B (en) * 2013-11-28 2017-11-14 英业达科技有限公司 The selection initialization system and microserver of peripheral interconnection standard
CN109995720A (en) * 2017-12-30 2019-07-09 中国移动通信集团贵州有限公司 Heterogeneous device manages method, apparatus, system, equipment and medium concentratedly
CN109189718B (en) * 2018-09-04 2020-07-10 上海睿赛德电子科技有限公司 Socket assembly and method for supporting multiple network interfaces
CN109885341A (en) * 2019-02-20 2019-06-14 无锡宝威电子有限公司 A kind of common apparatus driving model, system and application

Patent Citations (1)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN101989960A (en) * 2010-11-09 2011-03-23 中国电信股份有限公司 Home gateway and access adaption method

Also Published As

Publication number Publication date
CN110661692A (en) 2020-01-07

Similar Documents

Publication Publication Date Title
CN110235456A (en) Smart machine method of network entry, mobile terminal, Cloud Server, equipment and system
US8334755B2 (en) Method for recognizing radio frequency identification tag reader and apparatus thereof
CN105763619B (en) The method and device that client and server-side are communicated
CN109981668A (en) Common apparatus Internet of Things communication means based on the extensive agreement of MQTT
CN104796969A (en) Network accessing method and system for equipment of internet of things on basis of recognition codes of internet of things
US20170085392A1 (en) System, method and apparatus for data communication
CN105163364A (en) Intelligent device WiFi connection system and intelligent device WiFi connection method based on intelligent gateway
CN104980322A (en) Method and device for linking network access equipment
WO2018176244A1 (en) Data collection method, device, and dynamic environment network management system
KR20220084075A (en) Systems and methods for communication between incompatible wireless devices and virtual baseband units
CN103716189A (en) Configuration management method for local area network terminal gateway equipment
CN108012305A (en) Smart machine matches somebody with somebody network method, system and smart machine
CN110661692B (en) Network interconnection system and method
KR20170124055A (en) APPARATUS FOR COMPATIBILITY BETWEEN ZIGBEE AND CoAP
CN105577717A (en) Control method and system having compatibility with various electric appliances
CN102006192A (en) Control system and control method for digital family network equipment
US9325814B2 (en) Wireless SNMP agent gateway
CN106790282A (en) A kind of method of protocol conversion, device and air-conditioning system
US9762445B2 (en) Device and method for automatic switching of communication protocol of network devices based on user action
CN105530151A (en) GPRS module and information transmission method for the GPRS module
CN109639554B (en) Remote VLAN implementation method
CN107071921A (en) A kind of terminal equipment control method and system based on wireless management frame
CN101312412B (en) Ethernet transmission system based on embedded technique
CN105404253A (en) Control instruction sending method, response method and device
US20210306030A1 (en) Apparatus and methods for g3-plc bootstrap in a hybrid network

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
GR01 Patent grant
GR01 Patent grant