CN114449059A - Communication control method and device - Google Patents
Communication control method and device Download PDFInfo
- Publication number
- CN114449059A CN114449059A CN202210055636.0A CN202210055636A CN114449059A CN 114449059 A CN114449059 A CN 114449059A CN 202210055636 A CN202210055636 A CN 202210055636A CN 114449059 A CN114449059 A CN 114449059A
- Authority
- CN
- China
- Prior art keywords
- communication
- communication protocol
- target
- network
- service server
- 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.)
- Granted
Links
- 230000006854 communication Effects 0.000 title claims abstract description 422
- 238000004891 communication Methods 0.000 title claims abstract description 420
- 238000000034 method Methods 0.000 title claims abstract description 79
- 230000005540 biological transmission Effects 0.000 claims abstract description 83
- 238000004590 computer program Methods 0.000 claims description 11
- 238000012545 processing Methods 0.000 claims description 4
- 238000012549 training Methods 0.000 description 11
- 238000010586 diagram Methods 0.000 description 10
- 230000003068 static effect Effects 0.000 description 9
- 230000006870 function Effects 0.000 description 8
- 230000004044 response Effects 0.000 description 4
- 235000012054 meals Nutrition 0.000 description 3
- 238000010295 mobile communication Methods 0.000 description 3
- 230000008569 process Effects 0.000 description 3
- 230000004048 modification Effects 0.000 description 2
- 238000012986 modification Methods 0.000 description 2
- 238000012546 transfer Methods 0.000 description 2
- 230000009286 beneficial effect Effects 0.000 description 1
- 238000004364 calculation method Methods 0.000 description 1
- 230000006872 improvement Effects 0.000 description 1
- 230000000977 initiatory effect Effects 0.000 description 1
- 230000003287 optical effect Effects 0.000 description 1
- 238000000060 site-specific infrared dichroism spectroscopy Methods 0.000 description 1
- 239000007787 solid Substances 0.000 description 1
Images
Classifications
-
- H—ELECTRICITY
- H04—ELECTRIC COMMUNICATION TECHNIQUE
- H04L—TRANSMISSION OF DIGITAL INFORMATION, e.g. TELEGRAPHIC COMMUNICATION
- H04L69/00—Network arrangements, protocols or services independent of the application payload and not provided for in the other groups of this subclass
- H04L69/18—Multiprotocol handlers, e.g. single devices capable of handling multiple protocols
-
- H—ELECTRICITY
- H04—ELECTRIC COMMUNICATION TECHNIQUE
- H04L—TRANSMISSION OF DIGITAL INFORMATION, e.g. TELEGRAPHIC COMMUNICATION
- H04L41/00—Arrangements for maintenance, administration or management of data switching networks, e.g. of packet switching networks
- H04L41/14—Network analysis or design
- H04L41/145—Network analysis or design involving simulating, designing, planning or modelling of a network
Landscapes
- Engineering & Computer Science (AREA)
- Computer Networks & Wireless Communication (AREA)
- Signal Processing (AREA)
- Computer Security & Cryptography (AREA)
- Communication Control (AREA)
Abstract
The embodiment of the invention discloses a communication control method and a communication control device. After acquiring the device information of the target device and the communication related data between the target device and the service server, the method determines a target communication protocol based on a pre-trained communication protocol decision model by taking the device information and the communication related data as input, and then informs the target device and the service server of the target communication protocol, so that the target device and the service server adopt the target communication protocol for data transmission. The communication protocol decision model is used for determining a communication protocol meeting network transmission requirements of the target equipment, and the communication protocol is used for indicating a data transmission rule between the target equipment and the service server. The communication quality can be improved by the method.
Description
Technical Field
The present invention relates to the field of communications, and in particular, to a communication control method and apparatus.
Background
The remote intelligent device, such as an intelligent express cabinet, an intelligent vending cabinet or an intelligent meal fetching cabinet, generally needs to establish a communication connection with the service server, so that data transmission can be performed between the remote intelligent device and the service server, and thus, related functions of the remote intelligent device are realized.
In the prior art, the remote intelligent device usually communicates with the service server through a mobile communication system (3G/4G/5G). However, in a state of poor network condition, the key information issued by the service server to the remote intelligent device is often inaccessible, so that communication obstacles are easily caused to cause loss, and communication quality is difficult to guarantee.
Disclosure of Invention
In view of this, embodiments of the present invention provide a communication control method and apparatus to improve communication quality.
In a first aspect, an embodiment of the present invention provides a communication control method, where the method includes:
acquiring device information of target equipment and communication related data between the target equipment and a service server;
determining a target communication protocol based on a pre-trained communication protocol decision model by taking the equipment information and the communication related data as input;
informing the target device and a service server of the target communication protocol so as to transmit data between the target device and the service server by adopting the target communication protocol;
the communication protocol decision model is used for determining a communication protocol meeting the network transmission requirement of the target equipment, and the communication protocol is used for indicating a data transmission rule between the target equipment and a service server.
In a second aspect, an embodiment of the present invention provides a communication control apparatus, where the apparatus includes:
the device comprises an acquisition unit, a service server and a service processing unit, wherein the acquisition unit is used for acquiring device information of target equipment and communication related data between the target equipment and the service server;
the determining unit is used for determining a target communication protocol based on a pre-trained communication protocol decision model by taking the equipment information and the communication related data as input;
a notification unit, configured to notify the target device and the service server of the target communication protocol, so that data transmission is performed between the target device and the service server by using the target communication protocol;
the communication protocol decision model is used for determining a communication protocol meeting the network transmission requirement of the target equipment, and the communication protocol is used for indicating a data transmission rule between the target equipment and a service server.
In a third aspect, an embodiment of the present invention provides a computer-readable storage medium on which computer program instructions are stored, which when executed by a processor implement the method according to any one of the first aspect.
In a fourth aspect, an embodiment of the present invention provides an electronic device, where the electronic device includes:
a memory for storing one or more computer program instructions;
a processor, the one or more computer program instructions being executable by the processor to implement the method of any of the first aspects.
After acquiring the device information of the target device and the communication related data between the target device and the service server, the communication control method of the embodiment of the invention determines the target communication protocol based on the pre-trained communication protocol decision model by taking the device information and the communication related data as input, and then informs the target device and the service server of the target communication protocol, so that the target device and the service server adopt the target communication protocol for data transmission. The communication protocol decision model is used for determining a communication protocol meeting network transmission requirements of the target equipment, and the communication protocol is used for indicating a data transmission rule between the target equipment and the service server. The communication quality can be improved by the method.
Drawings
The above and other objects, features and advantages of the present invention will become more apparent from the following description of the embodiments of the present invention with reference to the accompanying drawings, in which:
FIG. 1 is a schematic diagram of an application system of an embodiment of the present invention;
fig. 2 is a flowchart of a communication control method according to an embodiment of the present invention;
fig. 3 is a flowchart of a method for determining network status parameters according to an embodiment of the present invention;
FIG. 4 is a flow chart of a target communication protocol determination method according to an embodiment of the present invention;
FIG. 5 is a flow chart of a communication protocol decision model training method according to an embodiment of the present invention;
FIG. 6 is a flow chart of a dynamic data acquisition method according to an embodiment of the present invention;
FIG. 7 is a diagram of a communication protocol decision model training system according to an embodiment of the present invention;
FIG. 8 is a diagram of a communication protocol decision model application system according to an embodiment of the present invention;
fig. 9 is a schematic diagram of a communication control apparatus of an embodiment of the present invention;
fig. 10 is a schematic diagram of an electronic device of an embodiment of the invention.
Detailed Description
The present invention will be described below based on examples, but the present invention is not limited to only these examples. In the following detailed description of the present invention, certain specific details are set forth. It will be apparent to one skilled in the art that the present invention may be practiced without these specific details. Well-known methods, procedures, components and circuits have not been described in detail so as not to obscure the present invention.
Furthermore, those of ordinary skill in the art will appreciate that the drawings provided herein are for illustrative purposes and are not necessarily drawn to scale.
Unless the context clearly requires otherwise, throughout this application, the words "comprise", "comprising", and the like are to be construed in an inclusive sense as opposed to an exclusive or exhaustive sense; that is, what is meant is "including, but not limited to".
In the description of the present application, it is to be understood that the terms "first," "second," and the like are used for descriptive purposes only and are not to be construed as indicating or implying relative importance. In addition, in the description of the present invention, "a plurality" means two or more unless otherwise specified.
The remote intelligent device, such as an intelligent express cabinet, an intelligent vending cabinet or an intelligent meal fetching cabinet, generally needs to establish a communication connection with the service server, so that data transmission can be performed between the remote intelligent device and the service server, and thus, related functions of the remote intelligent device are realized.
Taking the intelligent express cabinet as an example, when a user needs to store or take goods out, a door opening request is sent to the service server. And after receiving the door opening request, the service server sends a related instruction to the intelligent express cabinet to open the corresponding cabinet door.
In this process, the intelligent express delivery cabinet needs to upload the state data of the intelligent express delivery cabinet, for example, the current cabinet lattice is occupied to the business server, so that the business server can allocate available cabinet lattices for the user according to the cabinet lattice occupied condition when receiving a door opening request. Meanwhile, the service server also needs to transmit a related instruction to the intelligent express cabinet when receiving a door opening request of a user, so that the intelligent express cabinet is controlled to open a corresponding cabinet door in time, and the user can store or take goods conveniently.
In the prior art, the remote intelligent device usually communicates with the service server through a mobile communication system (3G/4G/5G). However, in a state of poor network condition, the key information issued by the service server to the remote intelligent device is often inaccessible, so that communication obstacles are easily caused to cause loss, and communication quality is difficult to guarantee.
In view of the above, embodiments of the present invention provide a communication control method and apparatus, so as to improve communication quality between a remote intelligent device and a service server.
Fig. 1 is a schematic diagram of an application system according to an embodiment of the present invention. As shown in fig. 1, the application system includes a service server 11, a decision server 12, and a remote intelligent device.
The remote intelligent device in this embodiment is described by taking the intelligent express delivery cabinet 13 as an example. The service server 11 is a server that performs data transmission with the intelligent express delivery cabinet 13, and the service server 11 needs to implement the related service functions of the intelligent express delivery cabinet 13 through data transmission, such as opening a cabinet door, uploading data, and distributing cabinet grids. The decision server 12 is configured to determine a communication protocol used by the service server 11 and the intelligent express delivery cabinet 13.
It should be understood that the relevant service function may be specifically determined according to the device type of the smart device. Different types of devices have different associated service functions. For example: for a smart vending machine, the relevant service functions should also include a settlement function.
Specifically, the service server 11 and the intelligent express delivery cabinet 13 establish a communication connection and transmit data by using a preset communication protocol. In the process of data transmission, the decision server 12 acquires the device information of the intelligent express delivery cabinet 13 and the communication related data between the intelligent express delivery cabinet 13 and the service server 11, determines a target communication protocol meeting the network transmission requirement of the current communication scene according to the acquired device information and the communication related data by using a pre-trained communication protocol decision model, and notifies the service server 11 and the intelligent express delivery cabinet 13 of the target communication protocol, so that the service server 11 and the intelligent express delivery cabinet 13 transmit data by using the target communication protocol.
Wherein the communication protocol is used for indicating a data transmission rule between the target device and a service server.
Specifically, in a seven-layer network protocol of the OSI Model (Open System Interconnection Reference Model), there are many kinds of protocols for each layer. For example, 4G, Wi-Fi of the physical layer and the data link layer, UDP (User Datagram Protocol) of the Transport layer, TCP (Transmission Control Protocol), HTTP (hypertext Transfer Protocol) of the application layer, MQTT (Message queue Telemetry Transport) of the application layer, and the like. Each communication protocol has different hierarchy, reliability and effectiveness, and the size of the data packet required for transmitting the same effective data content is different. Different communication protocols should be selected for different communication scenarios. For example, communication using HTTP is more reliable than using MQTT, but less efficient. Communication using TCP is more reliable than using UDP, but less efficient.
In this embodiment, the decision server 12 may select a better communication protocol between the current service server 11 and the intelligent express cabinet 13 according to the communication scenario between the two.
For example: when the communication scenario between the service server 11 and the intelligent express delivery cabinet 13 has a high requirement for stability, the decision server 12 may select a relatively stable and reliable communication protocol. However, in a communication scenario with a poor network condition, the decision server 12 may relatively select a communication protocol with higher effectiveness.
It should be understood that the communication scenario in this embodiment should comprehensively consider the data type of the currently transmitted data, the network status, and other factors that may have an influence. Such as how well the network quality of the environment in which the device is located, how important the transmitted data is, how important the target device is, etc. And the selected communication protocol is a relatively preferred communication protocol over the communication scenario.
Fig. 2 is a flowchart of a communication control method according to an embodiment of the present invention. As shown in fig. 2, the communication control method specifically includes the following steps:
s100, acquiring device information of target equipment and communication related data between the target equipment and a service server.
The target equipment is remote intelligent equipment which performs data transmission with the service server. In this embodiment, the target device may specifically be an intelligent express delivery cabinet.
Specifically, the target device may first establish a communication connection with the service server according to a predetermined communication protocol. The predetermined communication protocol may be a communication protocol that can be applied in a plurality of scenarios and has a wide applicability. After the communication connection is established, normal data transmission can be performed between the target device and the service server, and the decision server can obtain the device information of the target device and the communication related data between the target device and the service server.
Optionally, the device information may include hardware parameters supported by the target device and network service parameters.
Specifically, the hardware parameters include a device interface type, a device ID, and a device type. The network Service parameters include one or more of network operator information, a network type, Domain name resolution (DNS), a router Address, a wireless local area network Service Set Identifier (WIFI SSID), a wireless local area network physical Address (WIFI MAC), an Internet Protocol (IP) Address, signal strength, and a Dynamic Host Configuration Protocol (DHCP) corresponding to the target device.
And the interface type is a data transmission interface type supported by the target equipment. The device ID is a unique identification of the target device. The device type is the device type of the target device, such as an express intelligent cabinet, an intelligent meal taking cabinet or an intelligent sales counter.
The network operator information is a network operator to which the target device currently uses a network. The network type is an available network type supported by the target device, such as 2G, 3G, 4G or wireless local area network. The domain name resolution, the router address, the wireless local area network service set identifier, the wireless local area network physical address, the internet protocol address and the dynamic host configuration protocol are all related addresses corresponding to the target equipment or related protocols supported by the target equipment. The signal strength is the strength of the signal transmitted by the target device.
Optionally, the communication-related data may include a data type and a network status parameter of data transmitted between the target device and a service server. Wherein, the network state parameter can be used for characterizing the network state of the current transmission process.
Specifically, the data type may be determined according to a related identifier in the transmitted data, for example, for the intelligent express delivery cabinet, the identifier of the cabinet door opening instruction sent by the service server to the intelligent express delivery cabinet may be a, the identifier of the feedback information returned by the intelligent cabinet after the door opening operation is performed may be B, and the identifier of the cabinet state data uploaded by the intelligent express delivery cabinet may be C. The decision server may determine the type of data transmitted based on the identification in the transmitted data.
The network state parameter may be determined according to historical communication records of the target device and the service server during a statistical period. The historical communication record is generated by the target device and the service server in a statistical period, and the communication record comprises communication time and communication result of each communication.
Fig. 3 is a flowchart of a method for determining network status parameters according to an embodiment of the present invention. As shown in fig. 3, the method for determining network status parameters specifically includes the following steps:
and S110, acquiring the communication time and the corresponding communication result in the historical communication record.
Specifically, the communication time recorded by the historical communication record and the corresponding communication result are obtained.
And S120, determining the network state parameter according to the communication time and the communication result.
Wherein the network state parameter includes at least one of a communication reach rate, a communication speed, and a number of consecutive failures of communication. The communication reach rate is used for representing the probability of communication success, and the value of the communication reach rate may specifically be the ratio of the number of communication success times to the total number of communication times in a statistical period. The communication speed is used for characterizing a communication transfer rate, and the value of the communication speed may specifically be an average time taken by the service server from initiating communication to receiving communication feedback. The number of continuous communication failures may specifically be the maximum number of continuous communications that the service server initiates communication but does not receive communication feedback within a preset time period.
It should be understood that the network status parameter may be determined according to actual conditions. The network state parameters should reflect the network state in the current communication process to the maximum extent.
S200, determining a target communication protocol based on a pre-trained communication protocol decision model by taking the equipment information and the communication related data as input.
Wherein the communication protocol decision model is used for determining a communication protocol meeting the network transmission requirement of the target device.
Specifically, after obtaining the device information and the communication-related data, the decision server inputs the device information and the communication-related data into a communication protocol decision model to obtain a target communication protocol. The target communication protocol is determined by the communication protocol decision model and can meet the current network transmission requirements of the target equipment and the service server.
Optionally, The communication Protocol involved in this embodiment includes, but is not limited to, UDP Protocol, COAP Protocol (The managed Application Protocol), TCP Protocol, IP Protocol (Internet Protocol), HTTP Protocol, RPC Protocol (Remote Procedure Call), and MQTT Protocol. The communication protocol decision model can select a better communication protocol which meets the network transmission requirement from the communication protocols.
It should be understood that, after the preferred communication protocol is selected, both the target device and the service server may invoke a protocol interface corresponding to the preferred communication protocol for data transmission.
Fig. 4 is a flowchart of a target communication protocol determining method according to an embodiment of the present invention. As shown in fig. 4, the target communication protocol determining method includes the following steps:
s210, determining the network transmission requirement conforming to the data type.
The network transmission requirement is determined by a communication protocol decision model and is used for representing network conditions to be met by the target equipment and the service server in the current communication scene. The network transmission requirement may specifically be a parameter range within which each parameter in the network state parameters obtained by the communication protocol decision model through calculation should be located.
For example: when the data type of the data transmitted by the target device and the service server is a door opening instruction, and the communication scenario has a high requirement on the communication reach rate, it is determined that the communication reach rate in the network transmission requirement should be in a high range, for example, 95% -100%.
Another example is: when the data type of the data currently transmitted by the target device and the service server is the grid state data, and the communication scenario does not need to have an excessively high requirement on the communication reach rate, it is determined that the communication reach rate in the network transmission requirement can be in a relatively low range, for example, 80% -100%.
That is, the range of each parameter in the network transmission requirement should be specifically consistent with the communication scenario to ensure the device use experience of the user. And the data type can reflect the current communication scene to a certain extent.
Specifically, after the device information and the communication related data are input into the communication protocol decision model, the communication protocol decision model determines that the network transmission requirements of the current communication scene are met according to the data type.
It should be appreciated that the factors referenced by the communication protocol decision model in determining network transmission requirements are not limited to only the data type of the transmitted data. That is, the network transmission requirement may also be determined according to other related information, such as the network quality in the environment where the device is located, the importance degree of the transmitted data, the communication frequency, the device type, and the like, so that the determined network transmission requirement is as consistent as possible with the current communication scenario.
For example: when the target device is placed in an environment with poor network quality, such as a metropolitan area, the network transmission requirements may be reduced appropriately. When the target device is placed in an environment with better network quality, such as a suburban area, the network transmission requirement can be increased appropriately.
Another example is: when the importance of the transmitted data is low, the network transmission requirement can be reduced appropriately. When the importance of the transmitted data is high, the network transmission requirements can be increased appropriately.
S220, responding to the situation that the network state parameters meet the network communication mode switching triggering conditions, and determining the target communication protocol according to the equipment information, the data type and the network state parameters.
The network state parameter satisfies the network communication mode switching triggering condition and is used for representing that the network state parameter does not satisfy the network transmission requirement.
Specifically, after determining the network transmission requirement that matches the current communication scenario, the current network state parameter may be compared with the determined network transmission requirement, and if the network state parameter satisfies the network communication mode switching trigger condition, it indicates that the current network state cannot satisfy the network transmission requirement required for data transmission. And the communication protocol decision model determines a target communication protocol according to the equipment information, the data type and the network state parameter. The target communication protocol is a better communication protocol capable of meeting the current network transmission requirements of the target equipment and the service server.
Optionally, the specific determination condition that the network status parameter satisfies the network communication mode switching trigger condition may be that any one of the network status parameters exceeds a corresponding parameter range set in the network transmission requirement.
For example: the communication reaching rate in the network state parameters is 80%, and the range of the communication reaching rate set in the network transmission requirement is 90% -100%, then the network state parameters meet the network communication mode switching triggering conditions.
It should be understood that in practical applications, the output of the communication protocol decision model should be specifically the scores for different communication protocols. The communication protocol with the highest score is the target communication protocol.
S300, the target communication protocol is notified to the target device and the service server, so that the target device and the service server adopt the target communication protocol for data transmission.
Specifically, after the communication protocol decision model determines the target communication protocol, the decision server notifies the target communication protocol to the target device and the service server, so that the target device and the service server perform data transmission by using the target communication protocol.
After acquiring the device information of the target device and the communication related data between the target device and the service server, the communication control method of the embodiment of the invention determines the target communication protocol based on the pre-trained communication protocol decision model by taking the device information and the communication related data as input, and then informs the target device and the service server of the target communication protocol, so that the target communication protocol is adopted between the target device and the service server for data transmission. The communication protocol decision model is used for determining a communication protocol meeting network transmission requirements of the target equipment, and the communication protocol is used for indicating a data transmission rule between the target equipment and the service server. The communication quality can be improved by the method.
Fig. 5 is a flowchart of a communication protocol decision model training method according to an embodiment of the present invention. As shown in fig. 5, the communication protocol decision model training method includes the following steps:
and S410, acquiring static data.
Wherein the static data is used for characterizing hardware parameters and network service parameters supported by the target device.
The hardware parameters and the network service parameters are similar to the hardware parameters and the network service parameters obtained in step S100, and are not described herein again.
And S420, acquiring dynamic data.
The dynamic data is related data generated by the target device and the service server in a data transmission process, and the dynamic data comprises positive dynamic data and negative dynamic data. And the positive dynamic data and the negative dynamic data are respectively used for generating positive sample data and negative sample data.
It should be understood that, in the process of acquiring the dynamic data in this embodiment, normal operation of the target device may be maintained, that is, the dynamic data may be acquired on the basis that normal operation of the target device is not affected.
Specifically, fig. 6 is a flowchart of a dynamic data acquisition method according to an embodiment of the present invention. As shown in fig. 6, the dynamic data acquisition method includes the following steps:
s421, notifying the target device and the service server of a first communication protocol in the communication protocol set, so that the target device and the service server perform data transmission by using the first communication protocol.
Wherein the set of communication protocols comprises a plurality of communication protocols having a predetermined priority order. The communication protocol in the communication protocol set is determined according to the communication protocol type supported by the target device. The priority of each communication protocol in the communication protocol set may be determined according to the applicability of the communication protocol. For example: the communication protocol with wider adaptability has higher priority, and the communication protocol with smaller adaptability has lower priority.
Specifically, the communication protocols in the communication protocol set are determined according to the communication protocol types supported by the target device. And informing the target device and the service server of a first communication protocol in the communication protocol set, namely the communication protocol with the highest priority, so that the target device and the service server adopt the first communication protocol to carry out data transmission.
S422, acquiring the sample data type and the sample network parameters of the data transmitted between the target equipment and the service server under the first communication protocol.
Specifically, a sample data type and sample network parameters of data transmitted between the target device and the service server under a first communication protocol are obtained. The sample data type is the data type of data transmitted between the target device and the service server, and the sample network parameters are used for representing the network state in the current communication scene.
And S423, determining corresponding network connection conditions according to the sample data types.
The network connection condition is used for representing a network condition which needs to be met when the data of the corresponding data type is transmitted. The network connection condition may specifically be a parameter range in which each of the network state parameters manually input by the tester should be located.
S424, in response to any one of the sample network parameters exceeding the corresponding parameter range set in the network connection condition, switching the communication protocol between the target device and the service server to the communication protocol of the next priority in the communication protocol set until the target sample network parameter is determined.
Wherein none of the target sample network parameters exceeds a corresponding parameter range set in the network connection condition.
Specifically, after the network connection condition is determined, if any one of the sample network parameters exceeds the corresponding parameter range set in the network connection condition, the communication protocol adopted between the target device and the service server is switched to the communication protocol of the next priority in the communication protocol set until the target sample network parameter is determined. Each parameter in the target sample network parameters does not exceed the corresponding parameter range set in the network connection condition.
S425, determining the sample data type, the target sample network parameter and the corresponding target communication protocol as the forward dynamic data.
Specifically, after the target sample network parameters are found, the sample data type, the target sample network parameters and the target communication protocol at the moment are determined as forward dynamic data.
It should be appreciated that the target device and the service server may communicate using a target communication protocol. Until the communication scenario changes, so that the target sample network parameters cannot meet the network connection condition corresponding to the changed communication scenario, step S424 is executed again to determine a new target communication protocol and record the forward dynamic data corresponding thereto. When step S424 is executed again, the switching is resumed from the communication protocol with the highest priority in the communication protocol set.
For example: the currently determined target communication protocol is a fourth priority communication protocol of the set of communication protocols. When the fourth priority communication protocol does not meet the network connection condition corresponding to the changed communication scenario, switching needs to be started again from the first priority communication protocol in the communication protocol set.
S426, determining the sample data type, the switched communication protocol and the corresponding sample network parameter before the target communication protocol as the negative dynamic data.
Specifically, the type of the sample data and the network parameters of the switched communication protocol and the corresponding sample before the target communication protocol are determined as negative dynamic data.
Optionally, if the target communication protocol is not found after all communication protocols in the communication protocol set are switched, in order to meet normal use of the target device, the communication protocol corresponding to the sample network parameter that meets the maximum number of network connection condition items may be selected as the target communication protocol.
Specifically, in response to that the target sample network parameter is not determined, the communication protocol corresponding to the sample network parameter that satisfies the maximum number of items of the network connection condition is determined as the target communication protocol.
Through steps S421-S426, the communication quality between the target device and the service server can be improved without affecting the normal operation of the target device, and dynamic data can be collected.
And S430, generating positive sample data and negative sample data according to the static data and the dynamic data.
Specifically, after the static data and the dynamic data are collected, positive sample data and negative sample data are generated.
Wherein the positive sample data is generated from positive dynamic data and static data. The negative sample data is generated by negative dynamic data and static data.
S440, training the communication protocol decision model according to the positive sample data and the negative sample data.
Specifically, the positive sample data and the negative sample data are input into a preset model to be trained, the preset model is trained according to the input positive sample data and the input negative sample data, and the trained preset model can be used as a communication protocol decision model.
The preset Model may be a Model built based on PMML (Predictive Model Markup Language). In practical application, the trained PMML model can output scoring results for different communication protocols according to the input data.
Fig. 7 is a schematic diagram of a communication protocol decision model training system according to an embodiment of the present invention. As shown in fig. 7, 72 is a dynamic data acquiring portion, and the dynamic data acquiring portion 72 includes network connection conditions and communication protocol sets corresponding to each data type input by a tester in advance. The set of communication protocols includes a plurality of communication protocols determined according to the type of communication protocol supported by the target device 74.
The dynamic data acquisition section 72 notifies the target device 74 and the service server 73 of a communication protocol having a first priority in the communication protocol set, so that the target device 74 and the service server 73 communicate using the communication protocol of the first priority. The dynamic data acquiring section 72 compares the network connection condition corresponding to the type of the data transmitted with the sample network state parameter at this time. When the sample network state parameters satisfy the network connection condition, a communication protocol between the target device 74 and the traffic server 73 is maintained. When the sample network state parameter does not satisfy the network connection condition, the communication protocol used between the target device 74 and the service server 73 is switched to the next-level communication protocol in the communication protocol set, so as to keep the network state parameter at each time satisfying the network connection condition.
The types of data transmitted during the communication process, the network status parameters, and the communication protocols corresponding to the network status parameters are collected by the collecting part 75 and transmitted to the communication protocol decision model for training.
The communication control system can train a communication protocol decision model on the premise of not influencing the normal operation of the target equipment.
Fig. 8 is a schematic diagram of a communication protocol decision model application system according to an embodiment of the present invention. As shown in fig. 8, the communication protocol decision model in fig. 8 is a model that has been trained.
When data transmission is required, the target device 74 and the service server 73 communicate with each other by using a predetermined communication protocol. The collecting section 75 acquires communication-related data generated during communication and device information of the target device, and inputs the acquired communication-related data and device information into the communication protocol decision model 71. The communication protocol decision model 71 continuously detects the current network state after receiving the communication related data and the device information. In the case of detecting that the network status is poor, the communication protocol decision model 71 outputs the target communication protocol and notifies the target device 74 and the service server 73, so that the target device 74 and the service server 73 perform data transmission using the target communication protocol. While the relevant data generated by the target device 74 and the service server 73 during communication using the target communication protocol is still collected by the collecting part 75 for optimizing the communication protocol decision model 71.
Fig. 9 is a schematic diagram of a communication control apparatus according to an embodiment of the present invention. As shown in fig. 9, the communication control apparatus of the embodiment of the present invention includes an acquisition unit 91, a determination unit 92, and a notification unit 93.
Specifically, the obtaining unit 91 is configured to obtain device information of a target device and communication related data between the target device and a service server;
the determining unit 92 is configured to determine a target communication protocol based on a pre-trained communication protocol decision model by using the device information and the communication related data as inputs;
the notifying unit 93 is configured to notify the target device and the service server of the target communication protocol, so that data transmission is performed between the target device and the service server by using the target communication protocol;
the communication protocol decision model is used for determining a communication protocol meeting the network transmission requirement of the target equipment, and the communication protocol is used for indicating a data transmission rule between the target equipment and a service server.
After acquiring the device information of the target device and the communication related data between the target device and the service server, the communication control device of the embodiment of the invention determines the target communication protocol based on a pre-trained communication protocol decision model by taking the device information and the communication related data as input, and then informs the target device and the service server of the target communication protocol, so that the target device and the service server adopt the target communication protocol for data transmission. The communication protocol decision model is used for determining a communication protocol meeting network transmission requirements of the target equipment, and the communication protocol is used for indicating a data transmission rule between the target equipment and the service server. The communication quality can be improved by the device.
Fig. 10 is a schematic diagram of an electronic device of an embodiment of the invention. In this embodiment, the electronic device includes a server, a terminal, and the like. As shown in fig. 10, the electronic device: at least one processor 101; and a memory 102 communicatively coupled to the at least one processor 101; and a communication component 103 communicatively coupled to the scanning device, the communication component 103 receiving and transmitting data under control of the processor 101; the memory 102 stores instructions executable by the at least one processor 101, and the instructions are executed by the at least one processor 101 to implement the communication control method.
Specifically, the electronic device includes: one or more processors 101 and a memory 102, with one processor 101 being illustrated in fig. 10. The processor 101 and the memory 102 may be connected by a bus or other means, and fig. 10 illustrates the connection by the bus as an example. Memory 102, which is a non-volatile computer-readable storage medium, may be used to store non-volatile software programs, non-volatile computer-executable programs, and modules. The processor 101 executes various functional applications of the device and data processing by executing nonvolatile software programs, instructions, and modules stored in the memory 102, that is, implements the communication control method described above.
The memory 102 may include a storage program area and a storage data area, wherein the storage program area may store an operating system, an application program required for at least one function; the storage data area may store a list of options, etc. Further, the memory 102 may include high speed random access memory, and may also include non-volatile memory, such as at least one magnetic disk storage device, flash memory device, or other non-volatile solid state storage device. In some embodiments, the memory 102 may optionally include memory located remotely from the processor 101, which may be connected to an external device via a network. Examples of such networks include, but are not limited to, the internet, intranets, local area networks, mobile communication networks, and combinations thereof.
One or more modules are stored in the memory 102, and when executed by the one or more processors 101, perform the communication control method in any of the method embodiments described above.
The product can execute the method provided by the embodiment of the application, has corresponding functional modules and beneficial effects of the execution method, and can refer to the method provided by the embodiment of the application without detailed technical details in the embodiment.
Another embodiment of the invention is directed to a non-transitory storage medium storing a computer-readable program for causing a computer to perform some or all of the above-described method embodiments.
That is, as can be understood by those skilled in the art, all or part of the steps in the method for implementing the embodiments described above may be implemented by a program instructing related hardware, where the program is stored in a storage medium and includes several instructions to enable a device (which may be a single chip, a chip, or the like) or a processor (processor) to execute all or part of the steps of the method described in the embodiments of the present application. And the aforementioned storage medium includes: a U-disk, a removable hard disk, a Read-Only Memory (ROM), a Random Access Memory (RAM), a magnetic disk or an optical disk, and other various media capable of storing program codes.
The embodiment of the invention discloses A1 and a communication control method, wherein the method comprises the following steps:
acquiring device information of target equipment and communication related data between the target equipment and a service server;
determining a target communication protocol based on a pre-trained communication protocol decision model by taking the equipment information and the communication related data as input;
informing the target device and a service server of the target communication protocol so as to transmit data between the target device and the service server by adopting the target communication protocol;
the communication protocol decision model is used for determining a communication protocol meeting the network transmission requirement of the target equipment, and the communication protocol is used for indicating a data transmission rule between the target equipment and a service server.
A2, the method according to A1, the communication related data including data type and network status parameters of the data transmitted between the target device and the traffic server.
A3, according to the method of A2, the determining a target communication protocol based on a pre-trained communication protocol decision model with the device information and the communication related data as inputs comprises:
determining network transmission requirements in accordance with the data type;
responding to the network state parameter meeting a network communication mode switching triggering condition, and determining the target communication protocol according to the equipment information, the data type and the network state parameter;
the network state parameter satisfies the network communication mode switching triggering condition and is used for representing that the network state parameter does not satisfy the network transmission requirement.
A4, the method of A3, the method further comprising:
and determining the network state parameters according to the historical communication records of the target equipment and the service server in the statistical period.
A5, according to the method of A4, the determining the network state parameters according to the historical communication records of the target device and the traffic server in the statistical period includes:
acquiring communication time and a corresponding communication result in the historical communication record;
and determining the network state parameter according to the communication time and the communication result.
A6, the method of A5, wherein the network state parameters include at least one of communication reach rate, communication speed and communication continuous failure times.
A7, according to the method in A6, the network state parameter meeting the triggering condition of network communication mode switching includes:
any one of the network state parameters is out of the corresponding parameter range set in the network transmission requirements.
A8, according to the method in A6, the communication protocol decision model is obtained by training as follows:
acquiring static data, wherein the static data is used for representing hardware parameters and network service parameters supported by the target equipment;
acquiring dynamic data, wherein the dynamic data is related data generated by the target device and a service server in a data transmission process, and the dynamic data comprises positive dynamic data and negative dynamic data;
generating positive sample data and negative sample data according to the static data and the dynamic data;
and training the communication protocol decision model according to the positive sample data and the negative sample data.
A9, according to the method of A8, acquiring dynamic data includes:
notifying the target device and a service server of a first communication protocol in a communication protocol set so that the target device and the service server perform data transmission by adopting the first communication protocol, wherein the communication protocol set comprises a plurality of communication protocols with a preset priority order;
acquiring sample data types and sample network parameters of data transmitted between the target equipment and a service server under the first communication protocol;
determining corresponding network connection conditions according to the sample data types;
in response to any one of the sample network parameters exceeding a corresponding parameter range set in the network connection condition, switching a communication protocol between the target device and a service server to a communication protocol of a next priority in the communication protocol set until a target sample network parameter is determined, wherein any one of the target sample network parameters does not exceed the corresponding parameter range set in the network connection condition;
determining the sample data type, the target sample network parameters and a corresponding target communication protocol as the forward dynamic data;
and determining the sample data type, the switched communication protocol and the corresponding sample network parameters before the target communication protocol as the negative dynamic data.
A10, the method of A9, the training method further comprising:
and determining each communication protocol in the communication protocol set according to the communication protocol type supported by the target equipment.
A11, according to the method of A9, the step of training the communication protocol decision model further comprises:
and in response to that the target sample network parameter is not determined, determining the communication protocol corresponding to the sample network parameter which satisfies the maximum number of network connection condition items as the target communication protocol.
A12, the method according to A11, wherein the communication protocols include UDP protocol, COAP protocol, TCP protocol, IP protocol, HTTP protocol, RPC protocol and MQTT protocol.
A13, the method of A8, the hardware parameters including at least one of device interface type, device ID, and device type.
A14, the method of A12, the network service parameters including at least one of network operator information, network type, domain name resolution, router address, WLAN service set identification, WLAN physical address, Internet protocol address, signal strength, and dynamic host configuration protocol.
A15, the method of A1, wherein the target device is an intelligent courier cabinet, an intelligent sales cabinet or an intelligent dining cabinet.
A16, the method of A1, the method further comprising:
optimizing the communication protocol decision model based on the device information, the communication-related data, and the target communication protocol.
The embodiment of the invention discloses B1 and a communication control device, wherein the device comprises:
the device comprises an acquisition unit, a service server and a service processing unit, wherein the acquisition unit is used for acquiring device information of target equipment and communication related data between the target equipment and the service server;
the determining unit is used for determining a target communication protocol based on a pre-trained communication protocol decision model by taking the equipment information and the communication related data as input;
a notification unit, configured to notify the target device and the service server of the target communication protocol, so that data transmission is performed between the target device and the service server by using the target communication protocol;
the communication protocol decision model is used for determining a communication protocol meeting the network transmission requirement of the target equipment, and the communication protocol is used for indicating a data transmission rule between the target equipment and a service server.
The embodiment of the invention discloses C1, a computer readable storage medium on which computer program instructions are stored, the computer program instructions, when executed by a processor, implement the method according to any one of A1-16.
The embodiment of the invention discloses D1 and electronic equipment, wherein the electronic equipment comprises:
a memory for storing one or more computer program instructions;
a processor, the one or more computer program instructions being executable by the processor to implement the method of any of A1-16.
The above description is only a preferred embodiment of the present invention and is not intended to limit the present invention, and various modifications and changes may be made by those skilled in the art. Any modification, equivalent replacement, or improvement made within the spirit and principle of the present invention should be included in the protection scope of the present invention.
Claims (10)
1. A method of communication control, the method comprising:
acquiring device information of target equipment and communication related data between the target equipment and a service server;
determining a target communication protocol based on a pre-trained communication protocol decision model by taking the equipment information and the communication related data as input;
informing the target device and a service server of the target communication protocol so as to transmit data between the target device and the service server by adopting the target communication protocol;
the communication protocol decision model is used for determining a communication protocol meeting the network transmission requirement of the target equipment, and the communication protocol is used for indicating a data transmission rule between the target equipment and a service server.
2. The method of claim 1, wherein the communication-related data comprises data types and network status parameters of data transmitted between the target device and a traffic server.
3. The method of claim 2, wherein determining a target communication protocol based on a pre-trained communication protocol decision model with the device information and the communication-related data as inputs comprises:
determining network transmission requirements in accordance with the data type;
responding to the condition that the network state parameter meets the network communication mode switching triggering condition, and determining the target communication protocol according to the equipment information, the data type and the network state parameter;
the network state parameter satisfies the network communication mode switching triggering condition and is used for representing that the network state parameter does not satisfy the network transmission requirement.
4. The method of claim 3, further comprising:
and determining the network state parameters according to the historical communication records of the target equipment and the service server in the statistical period.
5. The method of claim 4, wherein determining the network state parameter according to historical communication records of the target device and the traffic server during a statistical period comprises:
acquiring communication time and a corresponding communication result in the historical communication record;
and determining the network state parameter according to the communication time and the communication result.
6. The method of claim 5, wherein the network status parameters comprise at least one of a communication reach rate, a communication speed, and a number of consecutive failures in communication.
7. The method of claim 6, wherein the network state parameter satisfying the network communication mode switching triggering condition comprises:
any one of the network state parameters is out of the corresponding parameter range set in the network transmission requirements.
8. A communication control apparatus, characterized in that the apparatus comprises:
the device comprises an acquisition unit, a service server and a service processing unit, wherein the acquisition unit is used for acquiring device information of target equipment and communication related data between the target equipment and the service server;
the determining unit is used for determining a target communication protocol based on a pre-trained communication protocol decision model by taking the equipment information and the communication related data as input;
a notification unit, configured to notify the target device and the service server of the target communication protocol, so that data transmission is performed between the target device and the service server by using the target communication protocol;
the communication protocol decision model is used for determining a communication protocol meeting the network transmission requirement of the target equipment, and the communication protocol is used for indicating a data transmission rule between the target equipment and a service server.
9. A computer-readable storage medium on which computer program instructions are stored, which computer program instructions, when executed by a processor, implement the method of any one of claims 1-7.
10. An electronic device, characterized in that the device comprises:
a memory for storing one or more computer program instructions;
a processor, the one or more computer program instructions being executed by the processor to implement the method of any of claims 1-7.
Priority Applications (1)
Application Number | Priority Date | Filing Date | Title |
---|---|---|---|
CN202210055636.0A CN114449059B (en) | 2022-01-18 | 2022-01-18 | Communication control method and device |
Applications Claiming Priority (1)
Application Number | Priority Date | Filing Date | Title |
---|---|---|---|
CN202210055636.0A CN114449059B (en) | 2022-01-18 | 2022-01-18 | Communication control method and device |
Publications (2)
Publication Number | Publication Date |
---|---|
CN114449059A true CN114449059A (en) | 2022-05-06 |
CN114449059B CN114449059B (en) | 2024-07-23 |
Family
ID=81367031
Family Applications (1)
Application Number | Title | Priority Date | Filing Date |
---|---|---|---|
CN202210055636.0A Active CN114449059B (en) | 2022-01-18 | 2022-01-18 | Communication control method and device |
Country Status (1)
Country | Link |
---|---|
CN (1) | CN114449059B (en) |
Citations (7)
Publication number | Priority date | Publication date | Assignee | Title |
---|---|---|---|---|
US20130031033A1 (en) * | 2011-07-28 | 2013-01-31 | Quova, Inc. | System and method for implementing a learning model for predicting the geographic location of an internet protocol address |
CN110971614A (en) * | 2019-12-17 | 2020-04-07 | 软通动力信息技术(集团)有限公司 | Internet of things adaptation method and system, computer equipment and storage medium |
CN111510476A (en) * | 2020-04-03 | 2020-08-07 | 金蝶软件(中国)有限公司 | Communication method, communication apparatus, computer device, and computer-readable storage medium |
CN111641733A (en) * | 2020-06-07 | 2020-09-08 | 深圳市乙辰科技股份有限公司 | Network bridge equipment management method and device and readable storage medium |
CN111737076A (en) * | 2019-05-23 | 2020-10-02 | 北京京东尚科信息技术有限公司 | Server monitoring method, device, equipment and storage medium |
CN113395264A (en) * | 2021-05-26 | 2021-09-14 | 深圳市元征未来汽车技术有限公司 | Communication connection method, apparatus, server and medium |
US20210367856A1 (en) * | 2020-05-22 | 2021-11-25 | Wipro Limited | Method and system for providing seamless data transfer between communication devices |
-
2022
- 2022-01-18 CN CN202210055636.0A patent/CN114449059B/en active Active
Patent Citations (7)
Publication number | Priority date | Publication date | Assignee | Title |
---|---|---|---|---|
US20130031033A1 (en) * | 2011-07-28 | 2013-01-31 | Quova, Inc. | System and method for implementing a learning model for predicting the geographic location of an internet protocol address |
CN111737076A (en) * | 2019-05-23 | 2020-10-02 | 北京京东尚科信息技术有限公司 | Server monitoring method, device, equipment and storage medium |
CN110971614A (en) * | 2019-12-17 | 2020-04-07 | 软通动力信息技术(集团)有限公司 | Internet of things adaptation method and system, computer equipment and storage medium |
CN111510476A (en) * | 2020-04-03 | 2020-08-07 | 金蝶软件(中国)有限公司 | Communication method, communication apparatus, computer device, and computer-readable storage medium |
US20210367856A1 (en) * | 2020-05-22 | 2021-11-25 | Wipro Limited | Method and system for providing seamless data transfer between communication devices |
CN111641733A (en) * | 2020-06-07 | 2020-09-08 | 深圳市乙辰科技股份有限公司 | Network bridge equipment management method and device and readable storage medium |
CN113395264A (en) * | 2021-05-26 | 2021-09-14 | 深圳市元征未来汽车技术有限公司 | Communication connection method, apparatus, server and medium |
Also Published As
Publication number | Publication date |
---|---|
CN114449059B (en) | 2024-07-23 |
Similar Documents
Publication | Publication Date | Title |
---|---|---|
CN107864084B (en) | The transmission method and device of data packet | |
CN109617731A (en) | Adaptive gateway role configuration method and device under a kind of multi-gateway environment | |
CN110351198B (en) | Flow regulation method, data transmission system, storage medium and equipment | |
JP6097411B2 (en) | Data transmission method, apparatus and system | |
US20180278692A1 (en) | Communication device, communication system, and communication method | |
CN106612284A (en) | Streaming data transport method and streaming data transport device | |
CN111835682B (en) | Connection control method, system, device and computer readable storage medium | |
EP4070529A1 (en) | User plane function load control | |
JP2016514412A5 (en) | ||
US20010010061A1 (en) | Communication system, communication method, gateway apparatus, and client | |
US20210007031A1 (en) | Optimized transmission of application data to iot device | |
JP2000151606A (en) | Network monitoring system, network monitoring method, network management device, network device to be managed and recording medium | |
CN111050356B (en) | Data transmission processing method and device, storage medium and electronic device | |
CN111082996B (en) | Automatic configuration method, device and medium for in-band monitoring software | |
CN114449059A (en) | Communication control method and device | |
CN115883466A (en) | Switch control method and device, storage medium and electronic device | |
CN114125023B (en) | Method and device for determining data connection, storage medium and electronic device | |
CN117377024A (en) | Identification configuration method, device, terminal and storage medium | |
CN116846771A (en) | Service operation method, device, terminal and readable storage medium | |
EP3606136A1 (en) | Method and apparatus for monitoring wlan state, and terminal | |
CN110209474A (en) | The method and apparatus of task processing | |
CN105634810B (en) | method and system for accessing universal plug and play device and access device | |
CN107370820B (en) | Proxy AP automatic discovery device and system | |
US9219618B2 (en) | Information processing system, information processing device, management terminal device, and computer readable medium | |
CN113747415B (en) | Connection method and device of wireless access point, storage medium and electronic device |
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 |