Resource scheduling method oriented to AUTBUS and TSN heterogeneous network
By constructing a cross-network transmission architecture in heterogeneous networks of AUTBUS and TSN, and adopting end-to-end priority time slot allocation and multi-stream collaborative routing algorithms, the interconnection problem of heterogeneous networks in the Industrial Internet of Things is solved, achieving efficient and reliable data transmission and improving the stability and security of industrial production.
Patent Information
- Application Number
- CN202511152607.6
- Authority / Receiving Office
- CN · China
- Patent Type
- Applications(China)
- Current Assignee / Owner
- Filing Date
- 2025-08-18
- Publication Date
- 2025-10-31
AI Technical Summary
In the Industrial Internet of Things (IIoT), the resource scheduling methods of AUTBUS and TSN heterogeneous networks have not yet effectively solved the problems of difficult network interconnection and low transmission efficiency. In particular, in smart factory environments, the needs for the integration of heterogeneous networks and efficient data transmission have not been met.
By constructing an AUTBUUS and TSN cross-network transmission architecture, and adopting an end-to-end priority-based time slot allocation scheduling algorithm and a multi-flow cooperative routing algorithm, the end-to-end latency requirements of data streams are allocated, and scheduling is performed separately on the AUTBUUS and TSN sides to ensure efficient and reliable transmission of data streams in their respective networks.
It enables efficient data transmission between heterogeneous networks, reduces transmission latency and jitter, improves the real-time performance and accuracy of data transmission, enhances the network's anti-interference capability and fault tolerance, and ensures the stability and reliability of industrial production.
Smart Images

Figure CN120880970A_ABST
Abstract
Description
Technical Field
[0001] This invention belongs to the field of industrial Internet of Things (IoT) technology and relates to a resource scheduling method for heterogeneous networks such as AUTBUS and TSN. Background Technology
[0002] The Industrial Internet of Things (IIoT), acting as a bridge connecting the physical and digital worlds, is driving the transformation and upgrading of the manufacturing industry at an unprecedented pace. By enabling interconnectivity of underlying devices and equipment, the IIoT provides robust network support for smart factories, accelerating the industry's intelligent transformation. However, as the application of the IIoT deepens, the challenges it faces are becoming increasingly prominent.
[0003] Currently, industrial networks encompass various communication protocols, such as 5G, AUTBUS, TSN, and WIA-PA, each with its own unique advantages and application scenarios. However, different field devices often employ different communication protocols, resulting in the coexistence of multiple industrial communication protocols in industrial settings. Therefore, the Industrial Internet of Things (IIoT) faces challenges such as numerous protocols and diverse communication methods. These issues lead to difficulties in network interconnection and interoperability, low transmission efficiency, and severely restrict the rapid development of the IIoT. Especially in the context of the rapid development of smart factories, the IIoT needs to undergo a transformation to a new model and promote the integration of heterogeneous networks to adapt to more complex and changing industrial environments and provide more efficient and reliable technical support for industrial data transmission. Therefore, the networking, configuration, and scheduling of heterogeneous networks have become critical issues that urgently need to be addressed.
[0004] To promote the heterogeneous integration and application of the Industrial Internet of Things (IIoT), academia and industry are actively exploring the integration paths of various emerging technologies with industrial network technologies. Among them, AUTBUS bus technology and Time-Sensitive Networking (TSN), as two important industrial communication technologies, are gradually becoming research hotspots. AUTBUS bus technology, with its high bandwidth, high real-time performance, and long-distance transmission capabilities, provides strong support for the rapid transmission of data in industrial fields; while TSN technology, through precise time synchronization, traffic scheduling, and queue management mechanisms, achieves deterministic data transmission in Ethernet, providing a solution for the real-time requirements of the IIoT. Therefore, the integration of AUTBUS bus technology and TSN networking to achieve efficient data transmission between AUTBUS and TSN networks is an important evolutionary trend in industrial networks.
[0005] How to perform resource scheduling in the cross-network transmission system architecture of AUTBUS and TSN is a hot issue that urgently needs to be studied. Summary of the Invention
[0006] In view of this, the purpose of this invention is to provide a resource scheduling method for heterogeneous networks such as AUTBUS and TSN.
[0007] To achieve the above objectives, the present invention provides the following technical solution:
[0008] A resource scheduling method for heterogeneous networks of AUTBUS and TSN is proposed. This method is based on the cross-network transmission system architecture of AUTBUS and TSN, as well as the network model and traffic model under this architecture, and performs the following steps:
[0009] S1. Obtain the data stream to be transmitted f i Basic information;
[0010] S2, transfer data stream f i End-to-end transmission delay Del i According to the AUTBUS side delay weighting coefficient and TSN-side delay weighting coefficient Divided into two parts;
[0011] S3, For the data stream transmitted on the AUTBUS side f i The time slot allocation and scheduling algorithm based on end-to-end priority is used for time slot allocation, and the delay on the AUTBUS side is checked. If the check fails, the scheduling is recalculated until the check passes.
[0012] S4, For the data stream f transmitted on the TSN side i Perform scheduling;
[0013] S3 includes the following sub-steps:
[0014] S31. Process real-time aperiodic data, and regard the average transmission interval of the real-time aperiodic data stream as the period.
[0015] S32, Transfer data stream f i The end-to-end priority is used as a reference basis, and the end-to-end latency requirement is taken into account. i End-to-end priority Pr i Data Stream Type i Data length FL i and transmission period T i Calculate AUTBUS side priority
[0016] S33. Allocate time slots according to the parameters related to time slot allocation. The relevant parameters include: scheduling period, basic period and number of basic periods, transmission mode, time slot length, number of bytes transmitted in a single time slot, and number of time slots and transmission times required for data stream transmission.
[0017] S34. Perform AUTUS-side delay verification, calculate the AUTUS-side transmission delay, compare the actual transmission delay with the allocated delay requirement, and adjust the AUTUS-side delay weighting coefficient based on the comparison result. Until the stopping iteration condition is met;
[0018] S4 includes the following sub-steps:
[0019] S41. Employ a multi-flow cooperative routing algorithm to calculate the transmission path for each data flow;
[0020] S42. Obtain the optimal transmission path, and calculate the list of switch doors and the first transmission time of each data stream on its transmission path by using the constraint of conflict-free transmission.
[0021] The beneficial effects of this invention are as follows:
[0022] This invention effectively solves the interoperability problem caused by the coexistence of multiple communication protocols in industrial settings by constructing a cross-network transmission architecture based on AUTBUS and TSN. The high bandwidth, high real-time performance, and long-distance transmission capabilities of AUTBUS bus technology, combined with the precise time synchronization, traffic scheduling, and queue management mechanisms of TSN technology, enable efficient data transmission between heterogeneous networks, providing solid network support for the intelligent development of the Industrial Internet of Things (IIoT).
[0023] This invention improves data transmission efficiency and reliability: The proposed resource scheduling method rationally allocates the end-to-end latency requirements of data streams to both the AUTBUS and TSN networks, and ensures efficient and reliable transmission of data streams within their respective networks through priority-based time slot allocation and multi-stream cooperative routing algorithms. This refined scheduling strategy significantly reduces transmission latency and jitter, improving the real-time performance and accuracy of data transmission, which is particularly important for industrial applications requiring high reliability and low latency.
[0024] This invention improves the network's anti-interference capability and fault tolerance by optimizing resource scheduling strategies, ensuring the stability and reliability of data transmission. This is of great significance for ensuring the safe and stable operation of industrial production.
[0025] Other advantages, objectives, and features of the invention will be set forth in part in the description which follows, and in part will be apparent to those skilled in the art from the following examination, or may be learned from practice of the invention. The objectives and other advantages of the invention can be realized and obtained through the following description. Attached Figure Description
[0026] To make the objectives, technical solutions, and advantages of the present invention clearer, the preferred embodiments of the present invention will be described in detail below with reference to the accompanying drawings, wherein:
[0027] Figure 1 This is a diagram illustrating the architecture of the AUTBUS and TSN transmission system according to an embodiment of the present invention.
[0028] Figure 2 This is a schematic diagram of the overall process of the resource scheduling method for heterogeneous networks of AUTBUS and TSN according to an embodiment of the present invention.
[0029] Figure 3 This is a schematic diagram of the end-to-end delay allocation process according to an embodiment of the present invention. Detailed Implementation
[0030] The following specific examples illustrate the implementation of the present invention. Those skilled in the art can easily understand other advantages and effects of the present invention from the content disclosed in this specification. The present invention can also be implemented or applied through other different specific embodiments, and various details in this specification can be modified or changed based on different viewpoints and applications without departing from the spirit of the present invention. It should be noted that the illustrations provided in the following embodiments are only schematic representations of the basic concept of the present invention. Unless otherwise specified, the following embodiments and features can be combined with each other.
[0031] The accompanying drawings are for illustrative purposes only and are schematic diagrams, not actual pictures. They should not be construed as limiting the invention. To better illustrate the embodiments of the invention, some parts in the drawings may be omitted, enlarged, or reduced, and do not represent the actual product dimensions. It is understandable to those skilled in the art that some well-known structures and their descriptions may be omitted in the drawings.
[0032] In the accompanying drawings of the embodiments of the present invention, the same or similar reference numerals correspond to the same or similar components. In the description of the present invention, it should be understood that if terms such as "upper," "lower," "left," "right," "front," and "rear" indicate the orientation or positional relationship based on the orientation or positional relationship shown in the drawings, they are only for the convenience of describing the present invention and simplifying the description, and do not indicate or imply that the device or element referred to must have a specific orientation, or be constructed and operated in a specific orientation. Therefore, the terms used to describe positional relationships in the drawings are only for illustrative purposes and should not be construed as limiting the present invention. For those skilled in the art, the specific meaning of the above terms can be understood according to the specific circumstances.
[0033] Please see Figures 1-3 This is a resource scheduling method for heterogeneous networks such as AUTBUS and TSN.
[0034] This embodiment first introduces the AUTBUS and TSN cross-network transmission system architecture, as well as the network model and traffic model under the architecture.
[0035] like Figure 1 The diagram shown illustrates the cross-network transmission architecture of AUTBUS and TSN. The entire network system architecture consists of three layers: the user plane, the control plane, and the data plane.
[0036] The user interface consists of the user app, whose core function is to provide users with intuitive network data display and convenient operation options.
[0037] The control plane consists of a scheduling controller, a centralized user configurator (CUC), a centralized network configurator (CNC), and an AUTBUS network manager. Its main function is to configure and schedule resources for the entire network. The scheduling controller primarily receives data flow information and allocates latency. The CUC has two main functions: sensing TSN data flow information and sending it to the CNC, and configuring TSN terminals. The CNC is the main operating entity for TSN network routing and scheduling methods and is also responsible for configuring TSN switches. The AUTBUS network manager is responsible for configuring the entire AUTBUS-side network.
[0038] The data plane is divided into the AUTBUS-side network and the TSN-side network. The AUTBUS-side network consists of several terminal nodes (TNs) and one AUTBUS-TSN gateway connected to a single bus. The TNs are responsible for data transmission and reception, while the AUTBUS-TSN gateway handles protocol conversion between the AUTBUS and TSN networks, enabling cross-network data transmission. The AUTBUS-TSN gateway integrates an AUTBUS management node (MN) and a TSN module. The MN distributes AUTBUS network manager configuration information to the entire AUTBUS-side network, configuring it. The TSN module enables cross-network connectivity and data transmission between the AUTBUS and TSN networks. On the TSN side, several TSN terminals and several TSN switches are interconnected to form the TSN network structure. The TSN switches handle data reception and forwarding, while the TSN terminals handle data transmission and reception.
[0039] The AUTUBUS-side network mainly consists of AUTUBUS terminal nodes (TN) and the bus, with all AUTUBUS TN terminals connected via the bus. The TSN-side network comprises three basic elements: TSN terminals, TSN switches, and links, all interconnected to form the network.
[0040] TSN terminals and AUTBUUS terminal nodes, acting as data stream receiving and sending devices, are denoted as ES. TSN switches are denoted as SW, and AUTBUUS-TSN gateways are denoted as G. All devices in the entire network are collectively denoted as E. A link is the physical connection between all devices in the network, including the AUTBUUS bus, the physical connection between TSN terminals and TSN switches, and the physical connection between TSN switches. The physical connection between any two directly connected devices is denoted as e. The total number of direct physical connections between all devices is denoted as K. The set of direct physical connections between all devices E is denoted as S, where S = {e1, e2, ..., e...} K If the network is defined as follows, then the entire network can be represented by an undirected graph Gr = {E, S}. Furthermore, let N be the number of AUTBUS terminal nodes (TN) and M be the number of TSN terminals.
[0041] In this network architecture, all transmitted data streams are periodically sent; on the AUTBUS side, they are real-time periodic data, and on the TSN side, they are TT streams. Any data stream f transmitted in this AUTBUS-TSN network architecture... i You can use octet (Src) i ,Dst i ,FL i ,T i ,Pr i Del i Type i ,t i ) indicates that Src i For data stream f i The sending end, Dst i For data stream f i The receiver, FL i For data stream f i Data length, T i For data stream f i The sending period, Pr i For data stream f i priority, Del i For data stream f i The end-to-end latency requirement, Type i For data stream f i The data type t i For data stream f i The request is sent at the specified time. Assume that within a scheduling period SC, the number of data streams is M. F Then the set of all data streams can be represented as F = {f1, f2, ..., f...} MF}
[0042] The overall idea of the resource scheduling method for heterogeneous networks of AUTBUS and TSN in this embodiment is to allocate the end-to-end latency requirements of the data flow to both networks, and then perform scheduling on both networks separately. Figure 2 As shown, the resource scheduling process of AUTBUS and TSN heterogeneous networks can be divided into the following steps:
[0043] Step 1: The user inputs data stream information to the scheduling controller.
[0044] Step 2: The scheduling controller will send the data stream f i The end-to-end delay is allocated as the delay requirement for transmission on the AUTBUS side and the transmission delay requirement on the TSN side.
[0045] Step 3: Schedule and allocate time slots on the AUTBUUS side, and check whether the AUTBUUS side latency meets the requirements.
[0046] Step 4: Schedule on the TSN side and calculate the transmission delay on the TSN side, and check whether the allocated delay is met.
[0047] In step 1, the user inputs basic information about the data stream to be transmitted to the scheduling controller, including end-to-end latency requirements, transmission period, data stream length, data type, end-to-end priority, request transmission time, source node, and destination node.
[0048] In step 2, data stream f i End-to-end transmission delay Del i Based on the delay weighting coefficient on the AUTBUS side and TSN-side delay weighting coefficient Divided into two parts, the AUTBUS side allocates a delay of and Del i The product, the TSN side allocation delay is and Del i The product, where
[0049] The end-to-end latency allocation process is as follows: Figure 3 As shown. In the initial state, the user provides... The value of is in the range (a, b), where a = 0, b = 1. A binary search is used to select . The value of . During the first search, The value is (a+b) / 2, that is Given the latency requirements, the AUTBUS network manager calculates whether the AUTBUS-side network can perform scheduling normally under the allocated latency requirements.
[0050] If the data stream f on the AUTBUS side i Actual transmission delay Less than the AUTBUS side allocation delay requirement If the time delay weight coefficient is too large, it is necessary to continue iterating downwards to reduce it. The value of b is chosen to compress the AUTBUS delay allocation, providing more leeway for TSN-side scheduling. Therefore, let b be the value at this time. The value of 'a' remains unchanged, so let 'a' be constant. Continue binary search selection The value of, update Then reschedule. When The value being too small causes the data stream f to... i Actual transmission delay Greater than the allocated delay on the AUTBUS side If the timer fails, it indicates a scheduling failure, and the process proceeds to the next iteration, increasing the timer value. Value selection. When ba ≤ 0.01, the iteration step size is too small, so the search stops, and finally... Take the weight coefficient of the last successful scheduling.
[0051] If the data stream f on the AUTBUS side i Actual transmission delay Greater than the allocated delay on the AUTBUS side If the time delay weight coefficient is too small, it is necessary to continue iterating upwards and increase it. The value increases the AUTBUUS latency allocation. Let... The value of b remains unchanged. Continue binary search selection The value of, update Rescheduling. When data stream f i Actual transmission delay Less than the AUTBUS side allocation delay If the timer fails, it indicates a scheduling failure, and the process proceeds to the next iteration, increasing the timer value. Values. When ba < 0.05, the iteration step size is too small, so the search stops, and finally... Take the weight coefficient of the last successful scheduling.
[0052] After multiple iterations, the AUTBUS network manager can achieve optimal performance. With a smaller AUTBUS side delay This ensures successful AUTBUS scheduling, while the weighting coefficients on the TSN side... This weighting coefficient is derived under the condition of compressed AUTBUS-side latency allocation. If scheduling can be successfully completed on the TSN side, the scheme is feasible. If scheduling cannot be completed on the TSN side, it means that the flow cannot complete cross-network scheduling between AUTBUS and TSN.
[0053] In step 3, data stream f i When transmitting data on the AUTBUS side, the AUTBUS network manager needs to comprehensively consider the data flow. i End-to-end latency requirements Del i Data stream f i end-to-end priority Pr i Data stream f i Data Stream Type i Data stream f i Data length FL i and data stream f i Transmission period T i Considering factors such as time slot allocation, this method designs a time slot allocation and scheduling algorithm based on end-to-end priority. The core steps of the algorithm are as follows:
[0054] Step 31: The AUTBUS network manager processes real-time aperiodic data and uses the average transmission interval of the real-time aperiodic data stream as a period in subsequent scheduling.
[0055] Step 32: The AUTBUS network manager will transfer the data stream f i Using end-to-end priority as a reference, then consider Del. i Type i FL i and T i Factors such as priority The impact of this was used to calculate the transmission priority on the AUTBUS side. This comprehensive priority metric is used to determine who has a higher demand for time slots.
[0056] Step 33: The AUTBUS Network Manager generates a scheduling sequence based on the priority list and a static resource scheduling table based on the scheduling sequence. Finally, the AUTBUS Network Manager sends the static resource scheduling table configuration information to the AUTBUS Management Node (MN) to complete the configuration.
[0057] In step 31, since real-time aperiodic data does not have a transmission period parameter, the AUTBUS network manager needs to calculate the real-time aperiodic data stream f based on existing operational data. i The average transmission time interval is used as a period in scheduling calculations. The data stream f is statistically determined. i All transmission time intervals are calculated, and then the average interval is taken as the f of the real-time aperiodic data stream. i Sending period T i Participate in scheduling calculations.
[0058] In step S32, a time slot allocation scheduling algorithm based on end-to-end priority is used to determine the priority, with the data stream f as its input. i end-to-end priority Pr i Data stream f i Data Stream Type i Data stream f i Data length FL i and data stream f i Transmission period T i The output is: data stream f i AUTBUS side priority The specific algorithm process is as follows:
[0059] Step 321: Construct the initial priority vector Pr_List:
[0060]
[0061] In the formula, Pr i Represents data stream f i The end-to-end priority, where i∈(1,M) F M F This represents the number of data streams.
[0062] Step 322: Construct the data stream transmission constraint matrix X:
[0063]
[0064] In the formula, Del i For data stream f i End-to-end latency, Type i For data stream f i The data type is 0 when the data stream is real-time periodic data, and 1 otherwise. FL i For data stream f i Data stream length, T i For data stream f i The sending cycle.
[0065] Step 323: Normalization: Data with different dimensions cannot be directly compared because their physical meanings are different. Therefore, it is necessary to perform dimensionless processing on the data. Normalization is a commonly used dimensionless processing method. Before eliminating dimensions, it is necessary to distinguish between positive and negative indicators.
[0066] Due to data stream f i End-to-end latency requirements Del i The smaller the value, the better the data flow f. i The higher the priority required, the more negative the indicator becomes, which is normalized to Del. i ′:
[0067]
[0068] When all other conditions are the same, but the data stream lengths differ, the shortest job first principle should be adopted, allocating time slot resources to data streams with shorter lengths first to reduce transmission waiting time. Therefore, data stream f i Data stream length FL i The smaller the value, the higher the priority of time slot allocation; this is a negative indicator, and is normalized to FL. i ′:
[0069]
[0070] All other things being equal, if the data streams have different transmission periods, time slots should be allocated preferentially to the data stream with the shorter transmission period. Therefore, data stream f i Data stream length T i The smaller the value, the higher the priority of time slot allocation, so it is a negative indicator, normalized to T. i ′:
[0071]
[0072] Finally, the normalized transfer constraint matrix X′ is calculated:
[0073]
[0074] Step 324: Construct the weight vector Λ:
[0075]
[0076] Where, λ Del Let λ be the weight of the impact of F's end-to-end delay on AUTBUS priority. Type Let λ be the weight of the influence of F's data type on AUTBUUS priority. L Let λ be the weight of the impact of the data length of F on the AUTBUS priority. T The weight of the impact of the transmission period of F on the AUTBUS priority.
[0077] In the weight vector Λ, the four weight coefficients should be set according to actual needs, but should satisfy condition λ. Del +λ Type +λ L +λ T =1. If the end-to-end latency of the data stream has a greater impact on the priority on the AUTBUS side, then λ will be set to 1. Del Set them to be larger; if the four attributes of the data stream have the same impact on the priority of the AUTBUS side, then set the four weight coefficients to be equal.
[0078] Step 325: Calculate the AUTBUS-side priority influence factor vector:
[0079]
[0080] Step 326: Calculate the AUTBUUS-side priority:
[0081]
[0082] in, Pr_List is the initial priority vector, and AUTBUS_IF is the priority influence factor vector, which is the vector formed by multiplying the corresponding elements of the vectors.
[0083] In step 33, the AUTBUS-side time slot allocation includes the following process:
[0084] Step 331: Determine the relevant parameters for time slot allocation, including: scheduling period, basic period and number of basic periods, transmission mode, time slot length, number of bytes transmitted per time slot, and the number of time slots and transmission times required for data stream transmission; among which,
[0085] The scheduling period, basic period, and number of basic periods are calculated as follows:
[0086] SC AUTBUS =LCM(T)
[0087] BC AUTBUS =GCD(T)
[0088] Among them, SC AUTBUS For the AUTBUS scheduling period, BC AUTBUS Let F be the basic period of AUTBUS, LCM(T) be the least common multiple of the data stream set F with respect to the transmission period T, GCD(T) be the greatest common divisor of the data stream set F with respect to the transmission period T, and T be the set of data stream transmission periods. T i For data stream f i The transmission period, i∈(1,M) F M F The number of data streams in the data stream set. n basic periods BC AUTBUS Forming a scheduling cycle SC AUTBUS , where n is:
[0089]
[0090] The process for confirming the transmission mode and time slot length is as follows: The AUTBUS network manager determines the transmission mode and time slot length based on the BC settings. AUTBUS Determine the length T of a frame in an AUTBUS network Frame ,in:
[0091] T Frame =BC AUTBUS
[0092] In the AUTBUS network, each transmission mode m corresponds to a different T. Frame Each frame is further divided into 64 time slots, and the length of each time slot is Δt:
[0093]
[0094] Therefore, the transmission mode is m, and the frame length is T. Frame The correspondence between the time slot length Δt and the other three is shown in Table 1.
[0095] Table 1
[0096]
[0097] The process for determining the number of bytes transmitted in a single timeslot is as follows: Since the length of each data stream is fixed, the number of timeslots required for each data stream transmission is determined by the number of bytes (q) that can be transmitted in a single timeslot. The number of bytes (q) that can be transmitted in each timeslot is determined by the transmission mode and the encoding modes of the upper and lower sidebands. Generally, the encoding modes of the upper and lower sidebands are set to the same, so different transmission modes and sideband encoding modes result in different numbers of bytes (q) transmitted in a single timeslot. The corresponding relationships are shown in Table 2.
[0098] Table 2
[0099]
[0100] The calculation process for the number of time slots and transmission times required for data stream transmission is as follows:
[0101] Based on the transmission mode and encoding mode, and referring to Table 2, the number of bytes transmitted in a single timeslot can be determined. Considering that in the AUTBUS bus protocol, the terminal node TN has a fixed pilot timeslot before transmitting the data stream, therefore the data stream f i Number of time slots required for transmission (m) i for:
[0102]
[0103] in, Round up, FL i For data stream f i The data stream length is given by q, where q is the number of bytes that can be transmitted in a single slot on the AUTBUS bus. Within a scheduling cycle SC... AUTBUS Inside, data stream f i Number of transmissions n i for:
[0104]
[0105] Step 332: Generate a scheduling sequence: Based on the priorities in the calculated AUTBUS-side priority list, the AUTBUS network manager generates a scheduling queue. The sorting principle is that the higher the priority, the earlier the time slot is allocated. If two data streams have the same priority, the time slot is allocated first according to the terminal node sequence number, thus obtaining the scheduling queue.
[0106] Step 333: Time Slot Allocation: In the AUTBUS network, n basic cycles constitute a scheduling cycle, and each basic cycle can be divided into 64 time slots. The entire scheduling cycle can be abstracted as a two-dimensional rectangle S, with a length of 64 and a width equal to the number of basic cycles n. Then, the data stream f is allocated... i Each frame is abstracted as a frame of length m i A rectangle with a width of 1. In one scheduling cycle, the data flow f... i The number of transmissions is n i However, due to the periodic transmission of the data stream, each frame transmission is separated by a period T. i In a two-dimensional rectangle, this manifests as non-contiguous occupation of the area of the two-dimensional rectangle S. This situation causes problems in calculating the data flow f. i When considering the optimal time slot occupancy, the complexity of the two-dimensional time slot allocation algorithm increases. To reduce computational complexity, f can be... i All frames combined within a scheduling period are abstracted into a single frame of length m. i Width is n i,j rectangle S i Then, calculate the rectangle S for each data stream in the sequence to be scheduled. i The occupancy of S is maximized to increase the area occupancy of S and improve bus transmission efficiency.
[0107] In step 34, an AUTBUS-side delay check is performed. After time slot allocation, the AUTBUS-side data stream transmission delay mainly consists of link transmission delay and transmission delay. The AUTBUS-side transmission delay calculation formula is as follows:
[0108]
[0109] In the formula, It refers to the transmission latency of the data stream on the AUTBUS side. The data stream transmission delay is determined by the transmission mode and encoding mode of the AUTBUS network, m i For data stream f i The number of time slots occupied, where Δt is the time length of each time slot on the AUTBUS bus.
[0110] The actual transmission delay is compared with the allocated delay requirement. If the actual transmission delay is greater than the allocated transmission delay, the delay weighting factor on the AUTBUS side is reduced. Then the calculation is rescheduled until the stopping iteration condition is met; if the actual transmission delay is less than the allocated transmission delay, the delay weighting coefficient on the AUTBUS side is increased. Then the computation is rescheduled until the stopping iteration condition is met.
[0111] In step 4, TSN-side scheduling is performed. The core idea of TSN-side scheduling mainly consists of the following two steps:
[0112] Step 41: The CNC uses a multi-flow collaborative routing algorithm to calculate the transmission path of each data stream and achieve globally optimized path selection.
[0113] Step 42: After the CNC calculates the optimal transmission path for all data streams, it then uses the constraint of conflict-free transmission to calculate the list of switch doors and the first transmission time for each data stream along its transmission path.
[0114] In step 41, the multi-flow cooperative routing algorithm includes the following steps:
[0115] Step 411: Calculate the set of possible paths for each data stream.
[0116] Each data stream f i There may be an available transmission path from the source node to the destination node, and the data flow f i The set of available transmission paths is called f. i The set of candidate paths, denoted as R i ,Right now Where p ij Let j be the j-th transmission path of data stream i from the source node to the destination node, satisfying the condition j∈[1,k] i ], where k i For data stream f i The number of optional transmission paths. For a set of optional transmission paths of R i The calculation mainly consists of three steps: shortest path generation, redundant path expansion, and path selection and optimization.
[0117] Calculating the shortest path: Data flow transmission delay consists of transmission delay, propagation delay, processing delay, and queuing delay. Transmission delay is determined by the data length of the data flow, propagation delay by the transmission link length, processing delay by the performance of the TSN switch equipment, and queuing delay by the collision situation. To ensure that the data flow meets the delay requirements allocated to the TSN, it is necessary to minimize propagation delay and queuing delay as much as possible. Theoretically, transmitting all data flows along the shortest path can minimize propagation delay. Therefore, the shortest path algorithm of Dijkstra is used to calculate the data flow f. i By Src i To Dst i Shortest transmission path p i1 .
[0118] Redundant path extension: In practical applications, if all data streams are transmitted along the shortest path, multiple data streams may be transmitted on the same link. This causes multiple data streams to compete for transmission resources, and data streams that do not get a transmission opportunity can only wait for the previous data stream to complete, resulting in queuing delay. Queuing delay is uncertain and is the main cause of jitter. To reduce queuing delay and ensure deterministic transmission of data streams, a suboptimal path needs to be calculated for each data stream.
[0119] Optional transmission paths are generated through redundant path expansion, by using the shortest path p i1 Each link in the path is removed, the shortest path is recalculated, and several topologically independent suboptimal paths are generated.
[0120] Path selection and optimization: The final step is the selection and optimization of redundant paths to ensure the feasibility and effectiveness of link transmission. First, latency constraint verification needs to be performed, calculating the latency f of all data streams. i Does the theoretical transmission delay of the redundant path p meet the delay requirements of the TSN side? Let the suboptimal path p = {e1, e2, ..., e l-1 ,e l}, where j is the number of links on path p, then the TSN-side latency calculation formula is:
[0121]
[0122] Among them, D i (p) represents the data stream f i In the end-to-end transmission delay of path p, e j For the i-th link on path p, FL i For data stream f i Data length, For link e j bandwidth, For link e jThe physical length, For the signal in link e j The speed of propagation on the surface For data stream f i The maximum latency requirement. This formula verifies the data flow f. i If the total latency on path p is less than the maximum latency requirement, the path is removed from the suboptimal paths. Since the processing latency is determined by the performance of the TSN switch and is generally in the μs range, it can be disregarded.
[0123] The multi-flow cooperative routing algorithm calculates the data flow f through Dijkstra's shortest path algorithm, redundant path expansion, and path filtering and optimization. i k i A set of optional paths Where k i For data stream f i The number of optional transmission paths.
[0124] Step 412: Traverse all candidate paths for all data streams and select the optimal transmission path for all data streams to maximize the overall network utility.
[0125] The utility function is the core module of the multi-flow cooperative routing algorithm. Its design needs to comprehensively reflect multiple optimization objectives of path selection, such as latency, load, and collision probability, and balance the influence weight of each objective through weight coefficients.
[0126] In TSN, to ensure low-latency deterministic transmission of data streams, three conditions must be met: low latency, load balancing, and collision-free transmission. Low latency ensures data arrives at the destination node within the experimental requirements; load balancing avoids network congestion and improves network resource utilization; and collision-free transmission prevents multiple data streams from competing for time slots on the same link, increasing queuing delays and causing significant jitter. Therefore, for data stream f... i Design a utility function for each alternative path:
[0127]
[0128] Among them, H i (p), L i (p), C i (p) represents the path p delay, load degree, and conflict degree, all of which are minimized indicators. α, β, and γ are weighting coefficients that satisfy α+β+γ=1.
[0129] Data stream f i The delay term H of a certain optional path p i (p) The calculation formula is:
[0130]
[0131] Among them, D i (p) represents the end-to-end transmission delay of path p. For data stream f i The TSN side allocation delay.
[0132] In a transmission path, the bandwidth utilization of each link collectively determines the overall congestion level of the path. Calculating the load level of path p requires considering the load of all links in the entire path. To reduce computational complexity, the bandwidth utilization of the entire path is calculated to indirectly represent the load level. Based on the bottleneck effect, the path with the highest load level directly determines the congestion level of the entire path. Therefore, the maximum bandwidth utilization of all links in the path is chosen to represent the load level of that path. When L... i The smaller (p) is, the more balanced the load on path p is.
[0133] Data stream f i A given optional path p = {e1, e2, ..., e l-1 ,e l}, where j is the number of links on path p, then the load factor L i (p) reflects the bandwidth utilization of the path, and its calculation formula is:
[0134]
[0135] Among them, e j For a link segment on transmission path p, For link e j The bandwidth already used For link e j Maximum bandwidth, The calculation formula is:
[0136]
[0137] Among them, FL i For data stream f i Data stream length, T i For data stream f i The sending cycle.
[0138] In TSN, when multiple data streams with different transmission periods are transmitted on the same link, transmission collisions may occur, causing uncontrollable jitter and increased latency in data stream transmission. The higher the traffic density, the more likely transmission collisions will occur. Therefore, the traffic density E(e) can be used to represent the traffic busyness of link e, and its calculation formula is as follows:
[0139]
[0140] Among them, A e Let T be the number of data streams passing through link e. avg Let be the average period of the entire network, and be the average period of all data stream transmissions, t. avg The average transmission time per frame across the entire network is calculated using the following formula:
[0141]
[0142] in, For link e i Bandwidth, K, number of all links, FL i For data stream f i Data stream length, M F This represents the number of data streams.
[0143] Data stream f i The collision degree of path p can be represented by the sum of the transmission densities of all links along the entire path. Let path p = {e1, e2, ..., e...} l-1 ,e l The formula for calculating the degree of conflict is:
[0144]
[0145] Multi-flow cooperative routing algorithms, through multiple rounds of traversal, ensure that the overall network utility of path selection for all data tends to stabilize: any path change to a single data flow cannot improve the overall network utility. The total utility, H, is calculated using the following formula:
[0146]
[0147] Determining the traversal order: If the frame length of the data stream is larger and the transmission period is shorter, the tendency for this data stream to conflict with other data streams is also greater. Therefore, the amount of data transmitted per unit time, v, is defined. i =FL i / T i That is, v i The smaller the value, the greater the tendency for transmission conflicts to occur, the easier the scheduling, and the easier it is to transmit without conflict with other data streams in the same link. Therefore, according to v... i Arrange all data streams in descending order to generate a set F of sorted data streams. r .
[0148] Traverse all data streams: Initially, all data streams select the shortest path as the transmission path, and calculate the total network path utility and H1 at this point. Then traverse the data stream set F. r For each data stream in the network, change the transmission path of the currently selected data stream and recalculate the overall network utility and H. k If H k >Hk-1 If the change is successful, it is retained; otherwise, it is discarded and the next data stream is traversed. The overall condition for iteration is that the utility of the entire network has not increased in τ consecutive iterations, or the number of iterations exceeds the maximum number of iterations τ. max .
[0149] After the algorithm iteration is complete, the CNC will obtain the set of optimal transmission paths for all data streams, F. Where p i For data stream f i The optimal transmission path.
[0150] In step 42, the transmission time offset and link status are calculated. Specifically, this includes:
[0151] Step 421: Calculation of scheduling period and number of transmissions: Scheduling period SC TSN The calculation formula is for one cycle of all data stream transmissions:
[0152] SC TSN =LCM(T)
[0153]
[0154] Where LCM(T) is the least common multiple of the data stream set F with respect to the transmission period T, and T is the set of periods of all data streams. i For data stream f i The transmission period, i∈(1,M) F M F This represents the number of data streams in the data stream set.
[0155] Within a scheduling cycle, data flow f i The number of transmissions is N i The entire scheduling cycle is divided into k slot If there are 1 time slot, then the time length of each time slot is t. slot The expression is:
[0156]
[0157] Step 422: Determine the constraints: The scheduling problem of TSN data streams can be understood as a periodic time slot planning problem on each link. When the data stream parameters are determined, the time slot planning problem is the calculation problem of the transmission time of each data stream on each link. Therefore, the TSN scheduling problem can be transformed into the problem of solving the start time of each data stream on each path. Its core idea is to solve the problem of satisfying the constraints.
[0158] Data stream periodicity constraint: Due to the periodic nature of data stream transmission, for data stream f...i Once the start time of its first frame is determined, the start time of all subsequent frames can be determined by its period T. i Calculations show that the defined data flow f i The start time of the transmission of the j-th frame of data on link e is Then for The initial transmission time on link e should satisfy the formula:
[0159]
[0160] This constraint guarantees the data flow f i Each frame on link e must be completed within one cycle and transmitted without collisions.
[0161] Data stream transmission constraints: Each data stream must undergo multiple hops via a TSN switch from the sender to the receiver. Therefore, the initial transmission times of the data stream between two adjacent links must adhere to a strict time sequence to achieve collision-free transmission. Thus, the data stream f is defined as follows: i The difference between the start time of the subsequent link and the start time of the preceding link must be greater than or equal to the data stream f. i The switching processing latency, transmission latency, and clock skew are related to the switch's processing latency, transmission latency, and clock skew. It should satisfy the formula:
[0162]
[0163] In the formula, For data stream f i The transmission time of the j-th frame of data, e k With e k+1 This represents a successor-successor link relationship. For data stream f i The transmission delay, For TSN switches, for data flow f i The processing delay is δ, which is the clock skew and is used to compensate for clock skew between switches.
[0164] Link constraints: For any link e, only one data frame is allowed to be transmitted at a time to avoid transmission collisions and delays. Delay needs to be specified so that the start time of data frames transmitted on the same link must be greater than or equal to the completion time of the previous frame. Its initial transmission time should satisfy the formula:
[0165]
[0166] In the formula, For data stream f i The transmission time of the k-th frame, T iFor data stream f i Transmission period, For data stream f i The transmission delay, and satisfying k∈(1,N) i ),l∈(1,N j ), α∈(0,N i -1), β∈(0,N j -1).
[0167] Frame isolation constraint: When multiple data streams arrive at a queue simultaneously, the transmission order becomes uncertain, violating the deterministic transmission principle and time-sensitive nature of TSN. Therefore, the frame isolation constraint stipulates that a queue can only store one data stream at a time; a new frame can only enter the queue after the previous frame has been sent. Assume link e has two predecessor links e1 and e2. For data stream f on link e1... i Data flow f on link e2 i It should satisfy the formula:
[0168]
[0169] In the formula For data stream f i The transmission time of the k-th frame, T i For data stream f i Transmission period, For data stream f i In the link e i The processing delay satisfies k∈(1,N) i ),l∈(1,N j ), α∈(0,N i -1), β∈(0,N j -1).
[0170] Latency requirement constraint: Since each data stream has an end-to-end latency requirement, for any data stream f i Its end-to-end delay requirement must be less than the end-to-end delay requirement Del i That is, the following conditions need to be met:
[0171]
[0172] In the formula, e1 represents the data flow along path p. i The first link on, then e final For the last link For data stream f i The transmission time of the j-th frame on link e1 For data stream f i Allocation delay on the TSN side.
[0173] Step 423: Establish the objective function:
[0174] This method uses the sum of end-to-end delays Δ of all frames in all data streams as the optimization objective, aiming to minimize Δ as much as possible while ensuring collision-free transmission. The calculation formula is as follows:
[0175]
[0176] In the formula, For data stream f i In path p i At the initial transmission time, For data stream f i In path p i The transmission time of the last link segment, p i For data stream f i The optimal transmission path that satisfies condition p i ∈P, where P is the set of transmission paths ultimately calculated for all data streams. For data stream f i The processing latency on the last link segment, For data stream f i The processing latency on the last link.
[0177] Based on the optimal transmission path calculated using the routing method, the state and transmission time offset of each link are calculated according to the above constraints.
[0178] Step 424: Calculate the final result:
[0179] The scheduling calculation results are divided into a data stream transmission offset vector V and a set of link time slot state vectors S. e The data stream transmission offset vector V is defined as:
[0180]
[0181] V contains M F Number of data streams sent at offset, M F The total number of data streams, v i i = {1, 2, ..., M} F} is the data stream f i The initial transmission offset of the slot offset, v i ∈[0,k slot -1] and is an integer, k slot This represents the number of time slots divided within a scheduling cycle.
[0182] Link slot state vector set S e The definition of is:
[0183] Se ={w1,w2,…,w K-1 ,w K}
[0184] In S e It contains K time slot state vectors w j K is the total number of links, w j For the link set S e Link e in the j-th path j The time slot state vector. The link's time slot state vector w j The definition of is:
[0185]
[0186] Where μ x ∈{0,1},x={1,2,...,k slot} and k is an integer. slot The number of time slots to be divided within a scheduling cycle. The state vector w for each time slot. j Includes k slot A 0 or 1 is used to describe k during the entire scheduling period. slot The switching state of each time slot. Link time slot state vector w j medium μ x =1 indicates link e j Data can be transmitted when time slot x is open; otherwise, it cannot. The configuration is then distributed based on the calculation results, thus completing the scheduling process.
[0187] In this embodiment, the parameters involved are defined as shown in Table 3 below:
[0188] Table 3
[0189]
[0190] Continued from Table 3
[0191]
[0192] Continued from Table 3
[0193]
[0194] Finally, it should be noted that the above embodiments are only used to illustrate the technical solutions of the present invention and are not intended to limit it. Although the present invention has been described in detail with reference to preferred embodiments, those skilled in the art should understand that modifications or equivalent substitutions can be made to the technical solutions of the present invention without departing from the spirit and scope of the present invention, and all such modifications or substitutions should be covered within the scope of the claims of the present invention.
Claims
1. A resource scheduling method for heterogeneous networks of AUTBUS and TSN, characterized in that: The resource scheduling method is based on the AUTBUS and TSN cross-network transmission system architecture and the network and traffic models under this architecture, and performs the following steps: S1. Obtain the data stream to be transmitted f i Basic information; S2, transfer data stream f i End-to-end transmission delay Del i According to the AUTBUS side delay weighting coefficient and TSN-side delay weighting coefficient Divided into two parts; S3, For the data stream transmitted on the AUTBUS side f i The time slot allocation and scheduling algorithm based on end-to-end priority is used for time slot allocation, and the delay on the AUTBUS side is checked. If the check fails, the scheduling is recalculated until the check passes. S4, For the data stream f transmitted on the TSN side i Perform scheduling; S3 includes the following sub-steps: S31. Process real-time aperiodic data, and regard the average transmission interval of the real-time aperiodic data stream as the period. S32, Transfer data stream f i The end-to-end priority is used as a reference basis, and the end-to-end latency requirement is taken into account. i End-to-end priority Pr i Data Stream Type i Data length FL i and transmission period T i Calculate AUTBUS side priority S33. Allocate time slots according to the parameters related to time slot allocation. The relevant parameters include: scheduling period, basic period and number of basic periods, transmission mode, time slot length, number of bytes transmitted in a single time slot, and number of time slots and transmission times required for data stream transmission. S34. Perform AUTUS-side delay verification, calculate the AUTUS-side transmission delay, compare the actual transmission delay with the allocated delay requirement, and adjust the AUTUS-side delay weighting coefficient based on the comparison result. Until the stopping iteration condition is met; S4 includes the following sub-steps: S41. Employ a multi-flow cooperative routing algorithm to calculate the transmission path for each data flow; S42. Obtain the optimal transmission path, and calculate the list of switch doors and the first transmission time of each data stream on its transmission path by using the constraint of conflict-free transmission.
2. The resource scheduling method for heterogeneous networks of AUTBUS and TSN according to claim 1, characterized in that: In S1, the basic information of the data stream to be transmitted includes end-to-end latency requirements, transmission period, data stream length, data type, end-to-end priority, request transmission time, source node, and destination node.
3. The resource scheduling method for heterogeneous networks of AUTBUS and TSN according to claim 1, characterized in that: In S2, the AUTBUS side allocation delay is and Del i The product, the TSN side allocation delay is and Del i The product, where Among them, the delay weighting coefficient on the AUTBUS side and TSN-side delay weighting coefficient The method for determining it is as follows: In the initial state, the user provides The value of is in the range (a, b), where a = 0, b = 1. A binary search is used to select . The possible values of ; During the first search, Take the value (a+b) / 2; Under the given delay requirements, calculate whether the AUTBUS side network can perform scheduling normally under the allocated delay requirements; If the data stream f on the AUTBUS side i Actual transmission delay Less than the AUTBUS side allocation delay requirement Then, continue iterating downwards, letting b take the value at this point. The value of 'a' remains unchanged, so let 'a' be constant. Continue binary search selection The value of, update Then reschedule; when The value being too small causes the data stream f to... i Actual transmission delay Greater than the allocated delay on the AUTBUS side If the timer fails, it indicates a scheduling failure, and the process proceeds to the next iteration, increasing the timer value. Value selection. The search stops when the iteration step size is less than the threshold, and finally... Take the weight coefficient of the last successful scheduling; If the data stream f on the AUTBUS side i Actual transmission delay Greater than the allocated delay on the AUTBUS side Then, continue iterating upwards; let The value of b remains unchanged. Continue binary search selection The value of, update Rescheduling; when data stream f i Actual transmission delay Less than the AUTBUS side allocation delay If the timer fails, it indicates a scheduling failure, and the process proceeds to the next iteration, increasing the timer value. The value is determined; the search stops when the iteration step size is less than the threshold, and finally... Take the weight coefficient of the last successful scheduling; After multiple iterations, the optimal weight coefficients for the AUTBUS side are obtained. TSN side weighting coefficient 4. The resource scheduling method for heterogeneous networks of AUTBUS and TSN according to claim 1, characterized in that: In S31, the real-time aperiodic data stream f is calculated based on the existing operational data. i The average transmission time interval is used as a period in scheduling calculations; the data flow f is calculated using statistical methods. i All transmission time intervals are calculated, and then the average interval is taken as the f of the real-time aperiodic data stream. i Sending period T i Participate in scheduling calculations.
5. A resource scheduling method for heterogeneous networks of AUTBUS and TSN according to claim 1, characterized in that: In S32, data stream f i AUTBUS side priority The calculation process is as follows: S321. Construct the initial priority vector Pr_List: In the formula, Pr i Represents data stream f i The end-to-end priority, where i∈(1,M) F M F Number of data streams; S322. Construct the data stream transmission constraint matrix X: In the formula, Del i For data stream f i End-to-end delay; Type i For data stream f i The data type is 0 when the data stream is real-time periodic data, and 1 otherwise; FL i For data stream f i Data stream length, T i For data stream f i The sending cycle; S323. Perform dimensionless processing on the data through normalization; let the data stream f i End-to-end latency requirements Del i As a negative indicator, it is normalized to Del′ i : Data stream f i Data stream length FL i As a negative indicator, it is normalized to FL′ i : Data stream f i Data stream length T i As a negative indicator, normalized to T i ′: Finally, the normalized transfer constraint matrix X′ is calculated: S324. Construct the weight vector Λ: Where, λ Del Let λ be the weight of the impact of F's end-to-end delay on AUTBUS priority. Type Let λ be the weight of the influence of F's data type on AUTBUUS priority. L Let λ be the weight of the impact of the data length of F on the AUTBUS priority. T Let F be the weight of the transmission period on the AUTBUUS priority; in the weight vector Λ, the four weight coefficients satisfy condition λ. Del +λ Type +λ L +λ T =1; S325. Calculate the AUTBUS-side priority influence factor vector: S326. Calculate the AUTBUS side priority: in, Pr_List is the initial priority vector, and AUTBUS_IF is the priority influence factor vector, which is the vector formed by multiplying the corresponding elements of the vectors.
6. A resource scheduling method for heterogeneous networks of AUTBUS and TSN according to claim 1, characterized in that: In S33, the AUTBUS-side time slot allocation includes the following process: S331. Calculate the scheduling cycle, basic cycle, and number of basic cycles: SC AUTBUS =LCM(T) BC AUTBUS =GCD(T) Among them, SC AUTBUS For the AUTBUS scheduling period, BC AUTBUS Let F be the basic period of AUTBUS, LCM(T) be the least common multiple of the data stream set F with respect to the transmission period T, GCD(T) be the greatest common divisor of the data stream set F with respect to the transmission period T, and T be the set of data stream transmission periods. T i For data stream f i The transmission period, i∈(1,M) F M F The number of data streams in the data stream set; n basic periods BC AUTBUS Forming a scheduling cycle SC AUTBUS , where n is: The process for confirming the transmission mode and time slot length is as follows: The AUTBUS network manager determines the transmission mode and time slot length based on the BC settings. AUTBUS Determine the length T of a frame in an AUTBUS network Frame ,in: T Frame =BC AUTBUS In the AUTBUS network, each transmission mode m corresponds to a different T. Frame Each frame is further divided into 64 time slots, and the length of each time slot is Δt: The process for confirming the number of bytes transmitted in a single time slot is as follows: the number of bytes q that can be transmitted in each time slot is determined by the transmission mode and the encoding modes of the upper and lower sidebands; The calculation process for the number of time slots and transmissions required for data stream transmission is as follows: The number of bytes transmitted per time slot is determined by the transmission mode and encoding mode. Considering that in the AUTBUUS bus protocol, the terminal node TN has a fixed pilot time slot before transmitting the data stream, the data stream f... i Number of time slots required for transmission (m) i for: in, Round up, FL i For data stream f i The data stream length, q is the number of bytes transmitted in a single slot on the AUTBUS bus; in a scheduling cycle SC AUTBUS Inside, data stream f i Number of transmissions n i for: S332. Generate a queue to be scheduled: Based on the priorities in the calculated AUTBUS priority list, the AUTBUS network manager generates a queue to be scheduled. The sorting principle is that the higher the priority, the earlier the time slot is allocated. If two data streams have the same priority, the time slot is allocated first according to the terminal node sequence number, thus obtaining the queue to be scheduled. S333, Time Slot Allocation: The entire scheduling cycle is abstracted as a two-dimensional rectangle S, with a length of 64 and a width equal to the number of basic cycles n. Then, the data stream f is used... i Each frame is abstracted as a frame of length m i A rectangle with a width of 1; in one scheduling cycle, the data flow f i The number of transmissions is n i ; will f i All frames combined within a scheduling period are abstracted into a single frame of length m. i Width is n i,j rectangle S i Then, calculate the rectangle S for each data stream in the sequence to be scheduled. i The occupancy of S will maximize the area occupancy rate of S.
7. A resource scheduling method for heterogeneous networks of AUTBUS and TSN according to claim 1, characterized in that: In S34, an AUTBUUS-side delay check is performed. After time slot allocation, the AUTBUUS-side data stream transmission delay mainly consists of link transmission delay and transmission delay. The AUTBUUS-side transmission delay calculation formula is as follows: In the formula, It refers to the transmission latency of the data stream on the AUTBUS side. The data stream transmission delay is determined by the transmission mode and encoding mode of the AUTBUS network, m i For data stream f i The number of time slots occupied, where Δt is the time length of each time slot on the AUTBUS bus; The actual transmission delay is compared with the allocated delay requirement; if the actual transmission delay is greater than the allocated transmission delay, the delay weighting coefficient on the AUTBUS side is reduced. Then the computation is rescheduled until the stopping iteration condition is met; If the actual transmission delay is less than the allocated transmission delay, then increase the delay weighting factor on the AUTBUUS side. Then the computation is rescheduled until the stopping iteration condition is met.
8. A resource scheduling method for heterogeneous networks of AUTBUS and TSN according to claim 1, characterized in that: In S41, the multi-flow cooperative routing algorithm includes the following steps: S411. Calculate the set of possible paths for each data stream: data stream f i The set of available transmission paths is called f. i The set of candidate paths, denoted as R i ,Right now Where p ij Let j be the j-th transmission path of data stream i from the source node to the destination node, satisfying the condition j∈[1,k] i ], where k i For data stream f i The number of optional transmission paths, and its construction process includes: Calculate the shortest path: The data flow f is calculated using Dijkstra's shortest path algorithm. i By Src i To Dst i Shortest transmission path p i1 ; Redundant path expansion: Calculates a suboptimal path for each data stream; generates alternative transmission paths through redundant path expansion, by finding the shortest path p. i1 Each link in the path is removed, the shortest path is recalculated, and several topologically independent suboptimal paths are generated. Path selection and optimization: Perform latency constraint verification and calculate f for all data streams. i Does the theoretical transmission delay of the redundant path p meet the delay requirements of the TSN side? Let the suboptimal path p = {e1, e2, ..., e l-1 ,e l }, where j is the number of links on path p, then the TSN-side latency calculation formula is: Among them, D i (p) represents the data stream f i In the end-to-end transmission delay of path p, e j For the i-th link on path p, FL i For data stream f i Data length, For link e j bandwidth, For link e j The physical length, For the signal in link e j The speed of propagation on the surface For data stream f i Maximum latency requirement; S412. Traverse all candidate paths for data streams and select the optimal transmission path for all data streams to maximize the overall network utility; for data stream f i Design a utility function for each alternative path: Among them, H i (p), L i (p), C i (p) represents the path p delay, load, and conflict, all of which are minimized indicators. α, β, and γ are weighting coefficients that satisfy α+β+γ=1; Data stream f i The delay term H of a certain optional path p i (p) The calculation formula is: Among them, D i (p) represents the end-to-end transmission delay of path p; For data stream f i TSN-side allocation delay; Data stream f i A given optional path p = {e1, e2, ..., e l-1 ,e l }, where j is the number of links on path p, then the load factor L i (p) reflects the bandwidth utilization of the path, and its calculation formula is: Among them, e j For a link segment on transmission path p, For link e j The bandwidth already used For link e j Maximum bandwidth, The calculation formula is: Among them, FL i For data stream f i Data stream length, T i For data stream f i The sending cycle; The transmission density E(e) represents the traffic congestion level of link e, and its calculation formula is as follows: Among them, A e Let T be the number of data streams passing through link e. avg Let be the average period of the entire network, and be the average period of all data stream transmissions, t. avg The average transmission time per frame across the entire network is calculated using the following formula: in, For link e i Bandwidth, K, number of all links, FL i For data stream f i Data stream length, M F Number of data streams; Data stream f i The collision degree of path p is represented by the sum of the transmission densities of all links along the entire path. Let path p = {e1, e2, ..., e...} l-1 ,e l The formula for calculating the degree of conflict is: Multi-flow cooperative routing algorithms, through multiple rounds of traversal, ensure that the overall network utility of path selection for all data tends to stabilize: any path change to a single data flow cannot improve the overall network utility. The total utility, H, is calculated using the following formula: Determine the traversal order: Define the amount of data transferred per unit time, v. i =FL i / T i According to v i Arrange all data streams in descending order to generate a set F of sorted data streams. r ; Traverse all data streams: Initially, all data streams select the shortest path as the transmission path, and calculate the total network path utility and H1 at this time. Then, traverse the data stream set F. r For each data stream in the network, change the transmission path of the currently selected data stream and recalculate the overall network utility and H. k If H k >H k-1 If the change is positive, it is retained; otherwise, the change is discarded and the next data stream is traversed. The overall condition for iteration is that the utility of the entire network has not increased in τ consecutive iterations or the number of iterations exceeds the maximum number of iterations τ. max ; After the algorithm iterations are complete, the optimal transmission path set F for all data streams is obtained. Where p i For data stream f i The optimal transmission path.
9. A resource scheduling method for heterogeneous networks of AUTBUS and TSN according to claim 1, characterized in that: S42 includes the following sub-steps: S421. Scheduling period and transmission count calculation: Scheduling period SC TSN The calculation formula is for one cycle of all data stream transmissions: SC TSN =LCM(T) Where LCM(T) is the least common multiple of the data stream set F with respect to the transmission period T, and T is the set of periods of all data streams. i For data stream f i The transmission period, i∈(1,M) F M F The number of data streams in the data stream set; Within a scheduling cycle, data flow f i The number of transmissions is N i The entire scheduling cycle is divided into k slot If there are 1 time slot, then the time length of each time slot is t. slot The expression is: S422. Determine the constraints, including: Data flow cycle constraint: Define data flow f i The start time of the transmission of the j-th frame of data on link e is Then for The initial transmission time on link e should satisfy the formula: This constraint guarantees the data flow f i Each frame on link e must be completed and transmitted without collision within one cycle; Data stream transmission constraints: Data stream f i The difference between the start time of the subsequent link and the start time of the preceding link must be greater than or equal to the data stream f. i The switching processing latency, transmission latency, and clock skew are related to the switch's processing latency, transmission latency, and clock skew. Satisfying the formula: In the formula, For data stream f i The transmission time of the j-th frame of data, e k With e k+1 This represents a successor-successor link relationship. For data stream f i The transmission delay, For TSN switches, for data flow f i The processing delay is δ, which is the clock skew and is used to compensate for the clock skew between switches. Link constraints: For any link e, only one data frame is allowed to be transmitted at a time. The start time of data frames transmitted on the same link must be greater than or equal to the completion time of the previous frame. Its initial transmission time should satisfy the formula: In the formula, For data stream f i The transmission time of the k-th frame, T i For data stream f i Transmission period, For data stream f i The transmission delay, and satisfying k∈(1,N) i ),l∈(1,N j ), α∈(0,N i -1), β∈(0,N j -1); Frame isolation constraint: When multiple data streams arrive at a queue simultaneously, a queue can only store one data stream at a time. A new frame can only enter the queue after the previous frame has finished sending. Assume link e has two predecessor links e1 and e2. For data stream f on link e1... i Data flow f on link e2 i It should satisfy the formula: In the formula For data stream f i The transmission time of the k-th frame, T i For data stream f i Transmission period, For data stream f i In the link e i The processing delay satisfies k∈(1,N) i ),l∈(1,N j ), α∈(0,N i -1), β∈(0,N j -1); Latency requirement constraint: Since each data stream has an end-to-end latency requirement, for any data stream f i Its end-to-end delay requirement must be less than the end-to-end delay requirement Del i That is, the following conditions need to be met: In the formula, e1 represents the data flow along path p. i The first link on, then e final For the last link For data stream f i The transmission time of the j-th frame on link e1 For data stream f i Allocation delay on the TSN side; S423. Establish the objective function: Using the sum of end-to-end delays Δ of all frames in all data streams as the optimization objective, minimize Δ while ensuring collision-free transmission. The calculation formula is as follows: In the formula, For data stream f i In path p i At the initial transmission time, For data stream f i In path p i The transmission time of the last link segment, p i For data stream f i The optimal transmission path that satisfies condition p i ∈P, where P is the set of transmission paths ultimately calculated for all data streams. For data stream f i The processing latency on the last link segment, For data stream f i The processing latency on the last link. Based on the optimal transmission path calculated using the routing method, the state and transmission time offset of each link are calculated according to the above constraints; S424. Calculate the final result: The scheduling calculation result is divided into the data stream transmission offset vector V and the link slot state vector set S. e The data stream transmission offset vector V is defined as: V contains M F Number of data streams sent at offset, M F The total number of data streams, v i i = {1, 2, ..., M} F } is the data stream f i The initial transmission offset of the slot offset, v i ∈[0,k slot -1] and is an integer, k slot The number of time slots to be divided within a scheduling cycle; Link slot state vector set S e The definition of is: S e ={w1,w2,…,w K-1 ,w K } In S e It contains K time slot state vectors w j K is the total number of links, w j For the link set S e Link e in the j-th path j The time slot state vector; Link slot state vector w j The definition of is: Where μ x ∈{0,1},x={1,2,...,k slot } and k is an integer. slot The number of time slots to be divided within a scheduling cycle; the state vector w in each time slot j Includes k slot A 0 or 1 is used to describe k during the entire scheduling period. slot The switching state of each time slot; the link time slot state vector w j medium μ x =1 indicates link e j When time slot x is in the open state, the configuration will be distributed according to the calculation results, that is, the scheduling is completed.