Disclosure of Invention
The embodiment of the invention provides a data scheduling method based on a time sensitive network. The technical scheme is as follows:
acquiring current network data in a transmission network based on a time sensitive network;
determining a transmission path used by the current network data;
acquiring target network data which uses the same transmission path as the current network data in the transmission network;
judging whether the current network data or the target network data can be scheduled at the current industrial moment or not, and obtaining a judgment result;
and scheduling data according to the judgment result.
In an embodiment, the performing data scheduling according to the determination result includes:
when the judgment result is that only the current network data can be scheduled at the current industrial moment, transmitting the current network data to a destination node through the transmission path;
when the judgment result is that only the target network data can be scheduled at the current industrial moment, transmitting the target network data to the destination node through the transmission path;
when the judgment result is that the current network data and the target network data can be scheduled at the current industrial moment, acquiring the transmission level of the current network data and the transmission level of the target network data;
and transmitting the current network data and the target network data to the destination node through the transmission path according to the transmission level of the current network data and the transmission level of the target network data.
In one embodiment, the transmitting the current network data and the target network data to the destination node through the transmission path according to the transmission level of the current network data and the transmission level of the target network data includes:
when the transmission level of the current network data is higher than that of the target network data, transmitting the current network data to the target node through the transmission path in priority to the target network data;
when the transmission level of the target network data is higher than that of the current network data, transmitting the target network data to the target node through the transmission path in priority to the current network data;
and when the transmission level of the target network data is the same as that of the current network data, transmitting the current network data and the target network data to the target node through the transmission path according to the target network data and the time of the current network data reaching the current node on the transmission path.
In one embodiment, the method further comprises:
determining the characteristic information of the current network data and the characteristic information of the target network data;
respectively setting respective transmission levels for the current network data and the target network data according to the characteristic information of the current network data and the characteristic information of the target network data, wherein the characteristic information comprises at least one of the following items: time, data volume, data importance degree of reaching the current node on the transmission path;
when the current network data and the target network data are transmitted on the transmission path, monitoring whether the characteristic information of the current network data and the characteristic information of the target network data are updated in real time;
when the characteristic information of the current network data and/or the characteristic information of the target network data are updated, the transmission level of the current network data and/or the target network data is adaptively adjusted.
In one embodiment, the setting respective transmission levels for the current network data and the target network data according to the characteristic information of the current network data and the characteristic information of the target network data includes:
a1, determining the weight values of the characteristic information of the current network data and the target network data;
in the above-mentioned formula,
is the first of the current network data
The weight value of the individual characteristic information,
is the first of the target network data
The weight value of the individual characteristic information,
in order to be able to determine the number of characteristic information,
is the first of the current network data
The characteristic information is relative to
A preset importance coefficient of the individual characteristic information,
is the first of the target network data
The characteristic information is relative to
Presetting an important coefficient of each characteristic information;
a2, calculating evaluation coefficients of characteristic information of the current network data and the target network data;
wherein,
is the first of the current network data
The evaluation coefficient of the individual characteristic information is,
is the first of the target network data
Personal character informationThe evaluation coefficient of the information is calculated,
and
respectively being the first of the current network data and the target network data
A limit value of the size of the individual characteristic information,
is the first of the current network data
The size of the individual characteristic information is,
is the first of the target network data
The size of the individual characteristic information;
a3, determining the transmission level of the current network data and the target network data;
in the above-mentioned formula,
for the transmission level of the current network data,
for the target network dataThe level of the transmission is such that,
rounding to an integer function.
In one embodiment, the determining whether the current network data or the target network data can be scheduled at the current industrial time to obtain a determination result includes:
determining a transmission zone bit of the current network data and a transmission zone bit of the target network data;
when the transmission flag bit of the current network data is transmission-allowed and the transmission flag bit of the target network data is transmission-forbidden, the judgment result is that only the current network data can be scheduled at the current industrial time;
when the transmission flag bit of the target network data is transmission-allowed and the transmission flag bit of the current network data is transmission-forbidden, the judgment result is that only the target network data can be scheduled at the current industrial time;
and when the transmission zone bit of the current network data and the transmission zone bit of the target network data are both allowed to be transmitted, the judgment result is that both the current network data and the target network data can be scheduled at the current industrial moment.
In one embodiment, the method further comprises:
respectively determining source equipment from which the current network data and the target network data come;
acquiring first device information of source equipment from which the current network data comes and second device information of the source equipment from which the target network data comes; the first device information and the second device information include at least one of: the method comprises the steps of determining the current transmission bandwidth of source equipment, the memory of the source equipment, the importance level of the source equipment, the residual transmission data volume of the source equipment and whether the source equipment indicates that a transmission flag bit exists;
and respectively configuring the transmission zone bit of the current network data and the transmission zone bit of the target network data according to the first equipment information and the second equipment information.
In one embodiment, the method further comprises:
determining the transmission cut-off time of the current network data and the transmission cut-off time of the target network data;
when the transmission deadline of the current network data is reached but the transmission deadline of the target network data is not reached, if the judgment result is that only the target network data can be scheduled, changing the judgment result into the priority transmission of the current network data, or delaying the transmission deadline of the current network data;
when the transmission deadline of the target network data is reached but the transmission deadline of the current network data is not reached, if the judgment result is that only the current network data can be scheduled, the judgment result is changed into that the target network data is transmitted preferentially, or the transmission deadline of the target network data is delayed.
The technical scheme of the invention can realize the following technical effects:
by acquiring target network data using the same transmission path as the current network data, whether the current network data or the target network data can be scheduled at the current industrial time can be judged, and then reasonable data scheduling is performed according to the judgment result, so that transmission conflicts of different network data on the same transmission path are avoided.
Additional features and advantages of the invention will be set forth in the description which follows, and in part will be obvious from the description, or may be learned by practice of the invention. The objectives and other advantages of the invention will be realized and attained by the structure particularly pointed out in the written description and claims hereof as well as the appended drawings.
The technical solution of the present invention is further described in detail by the accompanying drawings and embodiments.
Detailed Description
Reference will now be made in detail to the exemplary embodiments, examples of which are illustrated in the accompanying drawings. When the following description refers to the accompanying drawings, like numbers in different drawings represent the same or similar elements unless otherwise indicated. The implementations described in the exemplary embodiments below are not intended to represent all implementations consistent with the present disclosure. Rather, they are merely examples of apparatus and methods consistent with certain aspects of the present disclosure, as detailed in the appended claims.
In order to solve the above technical problem, an embodiment of the present invention provides a data scheduling method based on a time-sensitive network, as shown in fig. 1, the method includes steps S101 to S105:
in step S101, current network data in a transmission network based on a time sensitive network is acquired; a transmission network, i.e., an ethernet network or the like, which can be used to transmit data;
in step S102, determining a transmission path used by the current network data;
in step S103, target network data in the transmission network using the same transmission path as the current network data is acquired;
in step S104, determining whether the current network data or the target network data can be scheduled at the current industrial time, and obtaining a determination result;
in step S105, data scheduling is performed according to the determination result.
By acquiring target network data using the same transmission path as the current network data, whether the current network data or the target network data can be scheduled at the current industrial time can be judged, and then reasonable data scheduling is performed according to the judgment result, so that transmission conflicts of different network data on the same transmission path are avoided.
In an embodiment, the performing data scheduling according to the determination result includes:
when the judgment result is that only the current network data can be scheduled at the current industrial moment, transmitting the current network data to a destination node through the transmission path;
when the judgment result is that only the target network data can be scheduled at the current industrial moment, transmitting the target network data to the destination node through the transmission path;
when the judgment result is that the current network data and the target network data can be scheduled at the current industrial moment, acquiring the transmission level of the current network data and the transmission level of the target network data;
and transmitting the current network data and the target network data to the destination node through the transmission path according to the transmission level of the current network data and the transmission level of the target network data.
According to the judgment result of whether the current network data or the target network data can be scheduled at the current industrial moment, the current network data or the target network data can be scheduled and transmitted on the same transmission path according to a reasonable sequence, and the condition that different network data on the same path conflict or the transmission sequence is disordered in the transmission process is avoided.
In one embodiment, the transmitting the current network data and the target network data to the destination node through the transmission path according to the transmission level of the current network data and the transmission level of the target network data includes:
when the transmission level of the current network data is higher than that of the target network data, transmitting the current network data to the target node through the transmission path in priority to the target network data;
when the transmission level of the target network data is higher than that of the current network data, transmitting the target network data to the target node through the transmission path in priority to the current network data;
and when the transmission level of the target network data is the same as that of the current network data, transmitting the current network data and the target network data to the target node through the transmission path according to the target network data and the time of the current network data reaching the current node on the transmission path. The transmission path has a plurality of devices, and network data may also pass through a plurality of transmission devices in the middle of the process of reaching the target device from the source device on the transmission path, and each transmission device on the transmission path is a node.
In the process of transmitting different network data to the same target node on the same transmission path, the different network data can be transmitted according to the transmission level, specifically, if the transmission level of the current network data is higher, the current network data is transmitted preferentially on the transmission path, if the transmission level of the target network data is higher, the target network data is transmitted preferentially on the transmission path, and if the transmission level of the target network data is the same as that of the current network data, the different network data is transmitted in the sequence of arrival time, that is, if the time of the target network data arriving at the current node on the transmission path is earlier than that of the current network data arriving at the current node on the transmission path, the target network data is transmitted on the transmission path in preference to the current network data, and if the time of the current network data arriving at the current node on the transmission path is earlier than that of the target network data arriving at the current node on the transmission path, the current network data is transmitted on the transmission path prior to the target network data, so that different network data can be scheduled and transmitted on the same transmission path according to a reasonable sequence, and collision or transmission sequence disorder of different network data on the same path is avoided in the transmission process.
In one embodiment, the method further comprises:
determining the characteristic information of the current network data and the characteristic information of the target network data;
respectively setting respective transmission levels for the current network data and the target network data according to the characteristic information of the current network data and the characteristic information of the target network data, wherein the characteristic information comprises at least one of the following items: time, data volume, data importance degree of reaching the current node on the transmission path;
when the current network data and the target network data are transmitted on the transmission path, monitoring whether the characteristic information of the current network data and the characteristic information of the target network data are updated in real time;
when the characteristic information of the current network data and/or the characteristic information of the target network data are updated, the transmission level of the current network data and/or the target network data is adaptively adjusted.
By determining the feature information of the current network data and the feature information of the target network data, respective transmission levels can be set for the current network data and the target network data according to specific feature information, for example: if the data importance degree of the current network data is greater than the data importance degree of the target network data, the transmission level of the current network data is higher than the transmission level of the target network data, if the data amount of the current network data is greater than the data amount of the target network data, the transmission level of the current network data is higher than the transmission level of the target network data, if the time for the current network data to reach the current node on the transmission path is earlier than the target network data, the transmission level of the current network data is higher than the transmission level of the target network data, of course, the specific transmission level is up to what, depending on the specific characteristic information, the corresponding relation between the characteristic information and the transmission level can be preset in advance, so that the transmission level can be accurately configured for the network data according to the characteristic information to ensure that the network data can be reasonably scheduled on the transmission path, the conflict or disorder of the transmission sequence of different network data on the same path in the transmission process is avoided. Meanwhile, the transmission level can be dynamically adjusted according to the change of the characteristic information, so that the flexibility of network data scheduling is improved.
In one embodiment, the setting respective transmission levels for the current network data and the target network data according to the characteristic information of the current network data and the characteristic information of the target network data includes:
a1, determining the weight values of the characteristic information of the current network data and the target network data;
in the above-mentioned formula,
is the first of the current network data
The weight value of the individual characteristic information,
is the first of the target network data
The weight value of the individual characteristic information,
in order to be able to determine the number of characteristic information,
is the first of the current network data
The characteristic information is relative to
A preset importance coefficient of the individual characteristic information,
is the first of the target network data
The characteristic information is relative to
Presetting an important coefficient of each characteristic information;
a2, calculating evaluation coefficients of characteristic information of the current network data and the target network data;
wherein,
is the first of the current network data
The evaluation coefficient of the individual characteristic information is,
is the first of the target network data
The evaluation coefficient of the individual characteristic information is,
and
respectively being the first of the current network data and the target network data
A limit value of the size of the individual characteristic information,
is the first of the current network data
The size of the individual characteristic information is,
is the first of the target network data
The size of the individual characteristic information;
a3, determining the transmission level of the current network data and the target network data;
in the above-mentioned formula,
for the transmission level of the current network data,
is that it isThe level of transmission of the target network data,
rounding to an integer function.
The technical scheme determines the transmission levels of the current network data and the target network data to be comprehensively solved through the rating coefficients of the characteristic information of the current network data and the target network data and the weight of the characteristic information, and eliminates the non-integer phenomenon caused by comprehensively determining the transmission levels of the current network data and the target network data by utilizing a rounding function, so that the transmission levels of the current network data and the target network data are quickly and accurately obtained.
In one embodiment, the determining whether the current network data or the target network data can be scheduled at the current industrial time to obtain a determination result includes:
determining a transmission zone bit of the current network data and a transmission zone bit of the target network data;
when the transmission flag bit of the current network data is transmission-allowed and the transmission flag bit of the target network data is transmission-forbidden, the judgment result is that only the current network data can be scheduled at the current industrial time;
when the transmission flag bit of the target network data is transmission-allowed and the transmission flag bit of the current network data is transmission-forbidden, the judgment result is that only the target network data can be scheduled at the current industrial time;
and when the transmission zone bit of the current network data and the transmission zone bit of the target network data are both allowed to be transmitted, the judgment result is that both the current network data and the target network data can be scheduled at the current industrial moment.
When the transmission flag bit of the network data is allowed to be transmitted, the network data can be scheduled currently, otherwise, if the transmission is prohibited, the network data cannot be scheduled currently, so that whether the network data can be scheduled can be accurately judged according to the transmission flag bit of the current network data and the transmission flag bit of the target network data.
In one embodiment, the method further comprises:
respectively determining source equipment from which the current network data and the target network data come;
acquiring first device information of source equipment from which the current network data comes and second device information of the source equipment from which the target network data comes; the first device information and the second device information include at least one of: the method comprises the steps of determining the current transmission bandwidth of source equipment, the memory of the source equipment, the importance level of the source equipment, the residual transmission data volume of the source equipment and whether the source equipment indicates that a transmission flag bit exists;
and respectively configuring the transmission zone bit of the current network data and the transmission zone bit of the target network data according to the first equipment information and the second equipment information.
According to the first device information of the source device from which the current network data comes and the second device information of the source device from which the target network data comes, the transmission flag bits can be reasonably and accurately allocated to the current network data and the target network data, for example: determining whether data needs to be transmitted next and how much data needs to be transmitted according to the remaining transmission data volume of the source device from which the current network data comes, and if the data needs to be transmitted next and even more data needs to be transmitted, configuring the transmission flag bit of the current network data as allowed to be transmitted, so as to avoid that the data scheduling transmission on the source device from which the current network data comes is not timely, and certainly, if the current transmission bandwidth of a certain source device is larger, the data transmission of the source device is fast, so that in order to adapt to the source device, the transmission flag bit of the network data corresponding to the source device can also be set as allowed to be transmitted; or, if the memory of a certain source device is large and the importance level of the source device is high, the transmission flag bit of the network data corresponding to the source device may also be set to allow transmission.
In one embodiment, the method further comprises:
determining the transmission cut-off time of the current network data and the transmission cut-off time of the target network data;
when the transmission deadline of the current network data is reached but the transmission deadline of the target network data is not reached, if the judgment result is that only the target network data can be scheduled, changing the judgment result into the priority transmission of the current network data, or delaying the transmission deadline of the current network data;
when the transmission deadline of the target network data is reached but the transmission deadline of the current network data is not reached, if the judgment result is that only the current network data can be scheduled, the judgment result is changed into that the target network data is transmitted preferentially, or the transmission deadline of the target network data is delayed.
If the transmission deadline of the network data is reached, the network data is scheduled and transmitted, and the network data cannot be continuously detained on a transmission path, so that when the transmission deadline of the current network data is reached but the transmission deadline of the target network data is not reached, if the judgment result is that only the target network data can be scheduled, the judgment result is changed into the prior transmission of the current network data so that the current network data can be transmitted on the transmission path in time, or the transmission deadline of the current network data is directly delayed; similarly, when the transmission deadline of the target network data is reached but the transmission deadline of the current network data is not reached, if the judgment result is that only the current network data can be scheduled, the judgment result is changed into the priority transmission of the target network data so that the target network data can be transmitted on a transmission path in time, or the transmission deadline of the target network data is delayed, thereby ensuring that the network data can be scheduled and transmitted in time according to the transmission deadline of the network data.
Finally, it is clear that: the above embodiments can be freely combined by those skilled in the art according to actual needs.
Other embodiments of the disclosure will be apparent to those skilled in the art from consideration of the specification and practice of the disclosure disclosed herein. This application is intended to cover any variations, uses, or adaptations of the disclosure following, in general, the principles of the disclosure and including such departures from the present disclosure as come within known or customary practice within the art to which the disclosure pertains. It is intended that the specification and examples be considered as exemplary only, with a true scope and spirit of the disclosure being indicated by the following claims.
It will be understood that the present disclosure is not limited to the precise arrangements described above and shown in the drawings and that various modifications and changes may be made without departing from the scope thereof. The scope of the present disclosure is limited only by the appended claims.