• No results found

Extending FTT-SE protocol for Multi-Master/Multi-Slave Networks

N/A
N/A
Protected

Academic year: 2021

Share "Extending FTT-SE protocol for Multi-Master/Multi-Slave Networks"

Copied!
62
0
0

Loading.... (view fulltext now)

Full text

(1)

Extending the FTT-SE Protocol for

Multi-Master/Multi-Slave Networks

Master Thesis

Author:

Mohammad Hossein Ashjaei

Supervisor:

Moris Behnam

Examiner:

Thomas Nolte

School of Innovation, Design and Engineering (IDT) M¨alardalen University V¨aster˚as, Sweden

(2)

This theis is dedicated to my parents for their love, endless support and encouragement.

(3)

Abstract

Ethernet has established as the local area network protocol which is used at higher levels in the industrial applications. The main parameters such as easy in-tegration with Internet, cost effective and future expandability features make this protocol suitable for the industrial utilizations. The Ethernet protocol has been used for critical applications that have real-time requirements as well. Therefore, several methods proposed to make the protocol suitable for time-constrained communica-tions. For instance, after invention of Ethernet Switch several techniques based on the switches were proposed to support real-time communication in the Ethernet networks.

Ethernet Switches are widely used in real-time distributed systems as a solution to guarantee the real-time behavior in communication. In this solution there are still some limitations which are the important obstacles obtaining timeliness in the network. These limitations are the limited number of priority levels as well as the possibility of memory overruns with consequent messages. The mentioned limita-tions can be eliminated using a master/slave technique along with FTT paradigm.

The FTT-SE protocol which is a technique based on the master/slave and FTT methods was proposed to overcome the mentioned limitations. However, the FTT-SE protocol has been investigated for a small network architecture with a single switch and master node. Extension of this solution to larger networks is still an open issue. Three different architectures were suggested to scale the FTT-SE to large scale network. In this thesis we propose a solution that extends the FTT-SE protocol while keeping the real-time behavior of the network. In this solution, we divided the network into a set of sub-networks, each contains one switch, set of slave nodes and one master node that connected to the associated switch in the network. Moreover, the switches are connected together directly without gateways and form a tree topology network.

The solution includes both synchronous and asynchronous traffic in the network. We also show that the timeliness of the traffic can still be enforced. Moreover, to validate the solution we have designed and implemented a simulator based on the Matlab/Simulink which is a tool to evaluate different network architecture using Simulink blocks. All transmission can be visualized by the ordinary Scope block in the Simulink. Moreover, the end-to-end delay for all messages is calculated after the simulation running to show the response time of the network.

Furthermore, the response time analysis is done for both synchronous and asyn-chronous messages in this thesis according to the proposed solution. The results from simulation and the analysis are compared together to validate the investigations.

Keywords: Real time and embedded systems, Flexible Time Triggered over Switched Ethernet, Ethernet Switch, Network scheduling

(4)

Acknowledgement

I would like to thank my supervisor Moris Behnam for his recommendations and guid-ance during the thesis. He dedicated lots of his time and effort to help, specially during the simulator design and response time analysis. I am very thankful for all discussions we had in our meetings.

Moreover, I would like to express my thankfulness to Thomas Nolte who helped and supported me in publishing scientific paper from this thesis work. I am grateful for all his comments and feedbacks on my work.

Besides, I would like to show my gratitude to Luis Almeida in Porto University who dedicated his time to suggest and help me in publishing scientific paper from this thesis work. He gave me several skillful comments and suggestions on the paper.

Furthermore, I would like to thank Nima Moghaddami Khalilzad who gave me several advices about the simulator design and related tools.

In addition, I would like to acknowledge Mikael ˚Asberg who gave me a good information about socket programming.

Finally, I would like to take this opportunity to thank my beloved wife Sara for her supports on me for completing this thesis.

(5)

Contents

1 Introduction 1

1.1 Introduction . . . 1

1.2 Related Works . . . 2

1.2.1 FTT-CAN . . . 2

1.2.2 EDF Scheduled Switch . . . 2

1.2.3 EtheReal . . . 3

1.2.4 FTT-enabled Ethernet Switch . . . 4

1.2.5 Multi-Switch FTT-SE Network with Single Master . . . 4

1.3 Thesis Goal . . . 5 1.4 Thesis Outlines . . . 6 2 Theoretical Background 7 2.1 Ethernet Protocol . . . 7 2.2 Real-Time Ethernet . . . 7 2.3 FTT-Ethernet . . . 8 2.4 FTT-SE Protocol . . . 9

2.4.1 Synchronous Traffic Transmission in FTT-SE . . . 11

2.4.2 Asynchronous Traffic Transmission in FTT-SE . . . 12

3 System Model 13 3.1 Network Model . . . 13 3.2 Traffic Model . . . 14 4 Solution 15 4.1 Problem Formulation . . . 15 4.2 Protocol . . . 17

4.2.1 Confinement of Broadcast Domains . . . 17

4.2.2 Time Synchronization . . . 17

4.2.3 Periodic Message Scheduling . . . 18

4.2.4 Aperiodic Message Scheduling . . . 19

5 Response Time Analysis 23 5.1 Message Delay . . . 23

5.2 Local Message Response Time . . . 23

5.3 Global Periodic Message Response Time . . . 25

5.4 Global Aperiodic Message Response Time . . . 28

6 Simulator Design 32 6.1 Introduction . . . 32

6.2 Basic Requirements . . . 32

6.3 Simulator Settings . . . 34

6.4 Ready Queues Management . . . 34

(6)

6.6 Master Block Design . . . 36

6.7 Switch Model Design . . . 40

6.8 Slave Block Design . . . 41

6.9 Simulator Limitations . . . 43

7 Evaluation 45 7.1 Evaluation of Results . . . 45

8 Summary and Future Works 49 8.1 Summary and Conclusion . . . 49

8.2 Future Works . . . 50

9 Appendix A - Reference Manual for Simulator 53 9.1 Getting Started . . . 53

9.2 Creating a Model . . . 53

(7)

1

Introduction

1.1

Introduction

Communication among embedded systems is becoming large and complex due to increas-ing higher number of nodes and functionality of them. Therefore, to support these re-quirements several protocols are proposed to achieve real-time behavior while exchanging higher amounts of data. Moreover, flexibility of the networks along with keeping real-time guarantees have made new features to improve the protocols.

One of the network technologies that is considerably used in network embedded systems is the Switched Ethernet, which is low cost and wide available in the market. However, using Commercial Off-The-Shelf (COTS) Ethernet Switch in distributed real-time systems is still open issue because of its weaknesses such as lack of enough priority levels to support priority-based scheduling (which is up to 8 according to IEEE 802.1D standard) [19]. Furthermore, the switches have their own limitations based on hardware and software components inside them such as memory size, CPU speed and switch fabric delays.

Several techniques are proposed to guarantee real-time behavior in Ethernet Switches from modification of the medium access control to proposing additional transmission con-trol layers above Ethernet. These methods such as EDF scheduled switch developed by Hoang et al [7] [8] and the EtheReal protocol [22] are discussed in [16]. The former tech-nique uses real-time channel establishment before message transmission and the latter protocol using the same real-time establishment along with traffic and policy shaping [24]. The FTT-SE protocol [11] was proposed to guarantee real-time communication by com-bining the master/slave technique and Flexible Time-Triggered paradigm. This protocol was considered in a limited number of nodes with single switch. To extend the scalabil-ity of FTT-SE protocol to large networks, three different architecture were proposed in [24] assuming multiple COTS switches. The first approach was based on considering a network with multiple switches controlled by one master node which is connected to the root switch. The second approach was using multiple switches connected together with multiple master nodes (one master connected to one switch). Finally, the third solution was the same as second approach, however switches are connected via gateways.

This thesis proposes a solution for the second approach in which the periodic and ape-riodic traffic is handled in large scale FTT-SE networks with multiple switches connected directly together along with multiple points of control [4]. Moreover, in this thesis a sim-ulator based on Simulink/Matlab is developed to evaluate end-to-end delay of messages in a network based on the proposed solution. The response time analysis according to the proposed solution and the scheduling algorithm of the solution is presented in this thesis as well. The results of response time analysis for an example network along with the design structure of the simulator is described in this report. Moreover, the simulator has a modular framework consisting master node, slave node and switch models which helps to generate several FTT-SE network examples.

(8)

1.2

Related Works

In this section we describe different methods that use the FTT paradigm or Ethernet Switches to obtain real-time communication in the network embedded systems.

1.2.1 FTT-CAN

The FTT-CAN protocol fulfills time-triggered communication scheme and supports both time-triggered and event-triggered traffic with temporal isolation. The traffic is scheduled online and centrally in a special node, called master node, based on any scheduling policy such as Fixed Priority or Earliest Deadline Policy. The scheduled messages are transmitted within a fixed time slot called Elementary Cycle (EC). A specific message known as Trigger Message (TM) is broadcasted from the master node to all other nodes at the beginning of EC to synchronize the transmissions of all nodes [3].

Each EC is divided into two consecutive windows known as synchronous and asyn-chronous windows. The former is used for periodic message transmission and the latter is dedicated to aperiodic message transmission. The scheduled messages for current EC are encoded in Trigger Message and all recipient nodes are allowed to transmit the scheduled messages into the communication medium. Flexibility, timeliness and efficiency of this protocol has been studied in [3] and the experiments shows that mentioned features are achieved using flexible time-triggered paradigm in CAN protocol.

The communication services of FTT-CAN are performed within two sub-systems as Synchronous Messaging System (SMS) and the Asynchronous Messaging System (AMS). The SMS presents services based on producer-consumer, whereas the AMS services are formed by send and receive basics.

The SMS manages the synchronous messages which are synchronized with ECs. All the nodes decode the TM signal to check whether any messages are ready to send as producer node. This is performed by scanning a local message table that consists the identification of the messages to be produced or consumed by this slave node. However, the AMS services are responsible to handle asynchronous traffic. This sub-system is similar to the original CAN protocol which works as priority-based distributed arbitration mechanism. Another level of access control is used to prevent interference between asynchronous messages and periodic traffic. This is done by enforcing a strict temporal isolation between two sub-systems. The access control sets the beginning and end time of each asynchronous window, therefore the asynchronous traffic are pending to transmit outside of this window. Immediately during the asynchronous window, the nodes are permitted to transmit their requests [3].

1.2.2 EDF Scheduled Switch

This technique that supports both real-time and non-real-time messages which is based on Ethernet Switch is developed by Hoang et al [7]. In the proposed architecture both switch and end nodes need the addition of a real-time layer. This real-time layer is responsible for establishing a real-time channel, admission control, time synchronization and message

(9)

transmission control in the network. The switch and end node architecture in the proposed solution is depicted in Figure 1.

Figure 1: Layers of switch and end nodes [8]

The transmission is carried out within real-time channels which the bandwidths are already reserved. When a node needs to send real-time data, it sends a request to the switch to indicate source and destination nodes. After receiving such request from switch, it performs the feasibility check for source to switch communication as well as switch to destination rout. If the request is feasible from the switch point of view, the switch forwards the request to destination node. The target node checks the condition of receiving a message as well. When the real-time channel is established, the switch reply the source node to indicate the channel establishment.

The feasibility analysis is proposed in [8] considering EDF policy taking into account the overhead of control messages and non-preemptive traffic impact.

1.2.3 EtheReal

The EtheReal protocol is another technique which is based on Ethernet Switch with time-liness guarantee and the protocol supports both real-time and non-real-time messages. In this solution, some services are implemented on the switch to support the protocol. These services are accessible to the nodes as user-level libraries. This protocol is connection-oriented in which the nodes should follow connection setup protocol before sending mes-sages to the real-time channel. Therefore, the bandwidth reservation request sends to setup the real-time connection and the switch checks the resources to meet QoS requirements of the real-time connection [22].

When a real-time application tries to set a real-time connection, it sends the reservation request, known as the Real-time Communication Daemon (RTCD), to a user level of the node which is responsible to establish the real-time connection. The RTCD package contains destination IP address, the QoS parameters and the EtheReal connection ID. All the switches involved in the connection, creates new connection ID except the last switch that connect to destination node [22].

(10)

When the real-time connection request is accepted, all switches along the path creates a routing table with corresponding QoS and connection ID information. Finally, RTCD returns the proxy IP address to the sender application to show the connection establish-ment. Then the sender node starts to transmit the real-time data through the socket that the application open [22].

The traffic shaping and policing have been employed in EtheReal protocol to cover the smooth packet arrival time in switch and nodes. Moreover, the traffic policing is used to ensure the QoS requirements during run-time [16].

1.2.4 FTT-enabled Ethernet Switch

The FTT-enabled Ethernet Switch is a protocol which is based on the Flexible Time Trig-gered (FTT) paradigm and master/slave technique, however the master is implemented inside the switch. Although in this protocol the switch is not the COTS switch, there are other benefits such as the simplicity of asynchronous traffic handling and increasing the integrity of the system which are included in this protocol [20].

In the FTT protocols there are three kinds of traffic as periodic real-time traffic, ape-riodic or sporadic real-time traffic and the non real-time traffic [20]. The former one is activated by the master and for the asynchronous traffic the application with each node activates them automatically.

The channel establishment mechanism is used in order to guarantee timeliness behavior of the network. In order to set a real-time channel for transferring the messages, all switches in the path of the message form source to destination node are involved. When a node requires to send a message, it needs to setup the real-time channel by sending a request to its switch. The parameters of the message such as source node, destination node, priority, execution time and period is sent with the request. All the links between the source to the destination nodes check the feasibility and return the result as success or reject signal. If the reply to the source node is success, then the message will be transmitted through the established real-time channel. The evaluation of the proposed solution as well as modeling in Uppaal are performed in [23].

1.2.5 Multi-Switch FTT-SE Network with Single Master

The FTT-SE with multiple switches along with single master node connected to the root switch was proposed previously in [5]. In this approach a network composing several Ethernet switches, which are connected together as tree topology, was considered. All messages transmission are controlled via one master node which is connected to the root switch. According to the FTT-SE protocol, all messages are transmitted in a fixed time slot known as Elementary Cycle (EC). The master node scans all periodic messages in a table to check if any ready message available to be scheduled. If so, the ready message is inserted into a ready queue which is sorted according to the scheduling policy such as Fixed Priority or Earliest Deadline First. The scheduler gets the first message from the ready queue and checks if it fits into the specific bandwidth inside the EC. All messages which are scheduled by the master node are encoded in a particular message known as

(11)

Trigger Message (TM). The TM is sent at the beginning of the EC and the recipient slave nodes decode the TM and transmit the schedule messages.

In this solution the TM may received by delay specially from the nodes in deep level of network hierarchy. Therefore, they will start the message transmission considering that delay. However, the aperiodic message handling is performed by sending a signal to the master node to show the state of aperiodic messages in the slave nodes. The architecture of the network affects on such signaling by inserting delay to them. Moreover, the failure in the master connection can destruct the network due to failure of single control in the network.

1.3

Thesis Goal

The FTT-SE protocol was studied for a simple network considering one switch and one master node. Three architectures using multiple COTS switches to scale the FTT-SE in large networks was proposed in [24]. These three architectures are stated below:

• Connecting multiple COTS switches with one master for whole network. Spanning Tree Protocol (STP) is considered to overcome cycling problem in forwarding the messages. The complexity of the master in this method is higher than the other proposed architecture. Moreover, any failure in the master node connection will bring down the whole network.

• Multiple switches connected together and each switch has a master node to schedule the messages of its switch slaves. In this architecture the load of the masters decrease rather than using one master for whole network, whereas the synchronization of the masters should be considered as a bottleneck.

• The third architecture is the same as the second one, however connecting the switches are considered via gateways. Synchronization among master nodes should be con-sidered in this method as well as the complexity and the cost of the architecture due to using gateways.

In this thesis we propose a protocol to support large scale FTT-SE networks using the second architecture mentioned above, in which we resolve the problem of synchronizing the scheduling in the master nodes. A tree topology network by connecting Ethernet Switches together is assumed for the proposed solution. Also, the solution covers both synchronous and asynchronous message transmissions. In this report, we show how this solution can be achieved keeping real-time behavior of the communications.

Furthermore, we develop a simulator using Simulink/Matlab to evaluate a network based on the proposed solution. This simulator developed in a modular way, which has separated blocks for master, slave and switch to simplify evaluating several different archi-tectures and protocols. The outputs of the simulator are message transmission on Matlab Scope and the end-to-end response time of all messages. Moreover, the response time analysis of the messages for the proposed solution is presented. We compare the results from simulation and response time analysis together and present them in the Evaluation chapter.

(12)

1.4

Thesis Outlines

The rest of the thesis is organized in the following way:

• Chapter 2 gives related knowledge which are summarized of some related works in the area of the thesis work. The Ethernet protocol, different techniques to obtain real-time Ethernet, FTT-Ethernet protocol and FTT-SE protocol are explained in this chapter.

• Chapter 3 presents the system model that contains both traffic and network models in the thesis work. The definitions which are used in the proposed solution and entire thesis report are defined in this chapter.

• Chapter 4 gives the problem formulation related to extend the FTT-SE for large networks. Also, the solution to solve the mentioned problems is proposed in this chapter. The solution covers both synchronous and asynchronous traffic handling in the protocol.

• Chapter 5 presents the response time analysis according to the proposed solution for synchronous and asynchronous traffic.

• Chapter 6 describes the design structure of a simulator to evaluate a network ac-cording to the proposed solution in this thesis. This simulator is based on the Simulink/Matlab which is developed in a modular way.

• Chapter 7 presents the evaluation of the proposed solution with both response time analysis and the simulator for one example. The end-to-end delay of messages from simulator and the response time analysis are compared together in this chapter. • Chapter 8 concludes the research in this thesis with describing the summary of the

research and possible future works.

• Appendix 9 contains the reference manual for the simulator and describes how to cre-ate an example model. Also, this appendix describes the outputs that the simulator can give in both visualize and report form.

(13)

2

Theoretical Background

In this chapter, the related knowledge to the thesis research are described. This theoretical knowledge consists of Ethernet protocol, the solutions based on the Ethernet protocol to support time-constraints communication and the solutions based on the Ethernet Switch. Moreover, the FTT-SE protocol is described in this chapter, which is the basic of the proposed solution in the thesis.

2.1

Ethernet Protocol

Ethernet is now popular in computerized equipments as a built-in interface. This protocol is also used in factory floor by adding various modification to support real-time commu-nication. Basically, Ethernet was developed in the 1970s and the first IEEE standard was published in 1985 as IEEE 802.3 [6]. Ethernet protocol uses the Carrier Sense Multiple Access with Collision Detection (CSMA/CD) arbitration. According to the CSMA/CD, a network node transmits data to the bus while the bus is free. Then the bus checks for the collision and if the collision occurs it stops sending data and waits for a random time. After waiting a specific time, the node tries to retransmit the data. Therefore, this feature of CSMA/CD mechanism is a problem to support hard real-time behavior in the protocol. The conventional Ethernet has been improved by adding a hub-based structure with N-port repeater. The hub repeat the data received from a port and broadcast to all other port. At the same time, the hub tries to check the possible collision and notifies to all ports if any collision occurs [6]. The hub was replaced by a MAC bridge which is called Ethernet Switch due to hub limitations. The main different of switches rather than hubs is when the switch regenerate the data, it sends to the port on which the destination is known. Basically, when a message arrives at a switch port, it is buffered, checked according to its destination and moved to the buffer concerning to that destination port.

Although changing of the Ethernet by adding switches improves the performance of the protocol, later on the other modifications have been proposed to support real-time behavior [6].

2.2

Real-Time Ethernet

The Ethernet protocol has an arbitration mechanism based on CSMA/CD which was the main obstacle of supporting real-time applications in Ethernet. Several techniques have been developed for applying the real-time behavior in Ethernet communication which are described in detail in [16]. These methods are listed as below:

• CSMA/CD based methods

These methods use the standard Ethernet adapters and the collision in the network is related to traffic properties. In fact, the probability of collision in the network is related to the traffic properties such as utilization factor and message length [9]. In these techniques the traffic properties are used to compute the probabilities of deadline misses.

(14)

• Modified CSMA protocols

This protocol uses the CSMA mechanism properties, however some modification have been added to obtain the real-time behavior. These modifications such as back off and retry mechanisms are implemented to improve the temporal behavior of the network. Two basic modifications in this category of the protocols are delaying the transmission to reduce the collision probability and control the collisions. The method known as Virtual Time CSMA is developed according to the first approach which delay the transmission to obtain the temporal behavior [15]. The other solu-tions such as CSMA/DCR [10] and EQuB [21] are presented according to the second approach.

• Time Division Multiple Access (TDMA) mechanism

In this system, the time slots are assigned to the messages and a frame of time slots transmitted periodically. Usually, a special mechanism has been used to synchronize the message transmission between nodes in the network [18].

• Master/Slave technique

In this technique there is a particular node known as master node which controls the traffic in the network among slave nodes. Basically, master node polls all slave nodes and they got permission to send data. Moreover, master node uses a specific signal as control message to poll all the slaves.

• Switched Ethernet

Using switches in the network reduce the non-deterministic behavior of Ethernet. Basically, a switch buffered the arrival message and checks the destination address of the message. The output ports have output buffer and the order of message sending is based on priority level.

2.3

FTT-Ethernet

Considering the goals to have the real-time communication based on the Ethernet protocol, the FTT-Ethernet is one of the approaches which has an ability to handle time-triggered and event-triggered messages, timeliness guarantee, temporal isolation support and uses the COTS Ethernet switches. In this protocol, two main features are fulfilled which are centralized message scheduling by a single node in the network called master and the other feature is using a master/multi-slave transmission method in the communication [17].

The FTT-Ethernet uses the addressing algorithm such that each message has a desti-nation node. Therefore, when a message is sent the destidesti-nation address belong to the data is being transmitted as well. According to this addressing scheme, the respect message in the Ethernet protocol are transmitted with a broadcast address in the destination field of the message [17].

There is a fixed duration timeslot which is used in the FTT-Ethernet protocol to al-locate the traffic on the network. This fixed timeslot is called Elementary Cycle (EC)

(15)

and within this cycle there can be several windows dedicated to specific types of mes-sages [18]. Two specific windows are defined in the EC as synchronous window to handle time-triggered traffic and asynchronous window to support event-triggered messages which are depicted in Figure 2.

Figure 2: Elementary Cycle Structure [18]

At the beginning of each EC, a Trigger Message (TM) is broadcasted to all nodes by the master node. This message contains the identification of synchronous messages that should transmit from related nodes as well as synchronizing the network. All the nodes on the network decode the TM message and the nodes which are addressed, transmit scheduled messages in the specific instants. For the asynchronous messages the polling mechanism is used to check whether there is any event-triggered message waiting to transmit [18].

All the synchronous messages are structured in a master node which is called System Requirements Database (SRDB). This SRDB contains the message properties of the net-work for synchronous messages as well as the status of them. The master node accesses this database and builds the EC schedules according to the current status of the messages. Moreover, the master node encode the identification of the ready messages and broadcasts the encoded message as TM to all slave nodes [18]. The structure of the trigger message is depicted in Figure 3.

The data frame for Trigger Message (TM) is the Ethernet frame and the data field contains the TM information. The first word (MST ID) presents the type of message which is TM in this case and the next word presents the number of messages that should be transmitted in the current EC.

2.4

FTT-SE Protocol

Flexible Time Triggered paradigm and master/multi-slave techniques are basic princi-ples in the FTT-SE protocol to support real-time communication. This protocol is an

(16)

Figure 3: Trigger Message Structure [17]

adaptation to the FTT-Ethernet which is a method to overcome the non-deterministic problem [11].

Adding the advantage of the micro-segmented switch-based features to the FTT-Ethernet protocol achieves the absence of collision and getting the parallel transmission in the network. The absence of collision obtains by existence of private collision domains for each port in the switch. Similar to the FTT-Ethernet, messages are transmitted immedi-ately after decoding TM by the slave nodes. In this protocol the TM frame is simplified and the specification of the transmission is eliminated from the TM frame.

The master node in the FTT-SE protocol keeps a data structure for identification, the associated physical addresses and ports of the messages. The master node may unicast the TM to the sender nodes or it can broadcast the TM to all nodes depends on the network. The communication architecture of the FTT-SE protocol is depicted in Figure 4 [11].

(17)

2.4.1 Synchronous Traffic Transmission in FTT-SE

The synchronous messages are structured in the master node which is called Synchronous Requirements Table (SRT) including the properties of messages such as sender and receiver nodes. The master node schedules the synchronous messages according to any online policy such as Fixed Priority Scheduling policy and it encodes the ready messages into the TM then the master node broadcasts the TM to all slave nodes. The TM message includes the ready messages that should be transmitted in the current EC. Each switch has M upload links which the receiving messages are stored before transmission. The messages are transmitted with latency  to the output ports and queued for transmission in the M download links [11]. Figure 5 shows the internal blocks of a COTS switch.

Figure 5: Typical switch internal blocks [11]

The periodic messages are transmitted in a fixed time slot which is called Elementary Cycle (EC). The master node broadcasts the TM to all slave nodes at the beginning of each EC. All periodic messages are transmitted in a specific window in the EC which is called synchronous window and this is the maximum time that nodes are allowed to send and receive messages [11]. The EC time slot of the FTT-SE protocol for periodic message is depicted in Figure 6.

(18)

The Tr is the time between the reception of the TM signal and the start of synchronous

transmission which is called turn around time in which the nodes decode the TM signal and send the messages according to that. Also, the SW is a bandwidth dedicated to synchronous messages to be transmitted in the EC.

For all links of the switch including uplinks and downlinks, one buffer associated to each of them are defined which the capacity of that equals to the synchronous window. This buffer is called bin that the scheduler checks the messages in that considering the delays that message may suffer during the message transmission [11].

The experiments that are performed in [11] show that using the FTT-SE protocol obtains the flexible communication in which messages are scheduled in a master node based on any scheduling policy with timeliness guarantee in the network.

2.4.2 Asynchronous Traffic Transmission in FTT-SE

In the FTT-SE protocol, using the master/slave mechanism substantially affect asyn-chronous traffic handling, since all transmission of slave nodes depend on the scheduling of the master node. Some methods have been proposed to overcome the mentioned limi-tation which are stated below: [13]

• Periodic polling by master node which is proposed in the FTT-Ethernet protocol, the master node periodically, with a period of minimum inter-transmission time (Tmit) of the asynchronous message, polls the slaves. While an aperiodic or sporadic

message are available, it schedules them in the current EC. In this method if the aperiodic message gets ready exactly after the master polling, the transmission of the asynchronous message can be delayed up to two Tmit at worst case.

• A bandwidth reclaiming mechanism can be used in which whether the master gets empty polls, the bandwidth will be used to improve the efficiency of the network throughput.

• An in-band backward signaling which is used in EPL protocol. In this technique, the backward channel has been used to report the asynchronous requests to the master node. The problems related to the cited method are: it uses additional bandwidth for the backward channel and asynchronous request handling is directly dependent on the rate of backward channel polling.

• A backward signaling mechanism in which the slave nodes are allowed to report their asynchronous message status periodically. This solution is optimal compared with the above methods which is investigated in [13].

For handling the asynchronous traffic in FTT-SE protocol a technique similar to the backward signaling has been proposed in [13]. In each EC, a specific window is dedicated to asynchronous traffic, in the same way as for the synchronous window. All aperiodic traffic is transmitted in the asynchronous window. During the time when the master broadcasts the TM to the slaves, the slave nodes send their status of asynchronous traffic to the master. The master node receives the status messages from slave nodes during

(19)

the guard window and turn around time and schedules them for the next EC. Figure 7 sketches the structure of asynchronous signaling.

Figure 7: FTT-SE asynchronous traffic requests

In the best case, this method takes at least one EC to schedule the aperiodic traffic [13]. Moreover, one or two additional ECs are required to send the request to the master. The aperiodic messages can be activated in any time during the EC. In the worst case it activates after sending aperiodic requests which needs to wait until next EC to send the request again. Another EC is needed to schedule the aperiodic message and encoded in the TM signal. Also, turn around time plays important role to handle the request of asynchronous messages. According to [13], the TM size and turn around time affect the number of nodes that master node can handle. Considering fast Ethernet network (100 Mbps), TM size equals 24µs, as the minimum Ethernet frame the request signal of aperiodic is 6.72µs and the turn around time is assumed 200µs. Based on Equation 1 [13], maximum node numbers (Nmax) for a system s is 33, where T r is turn around time,

T M size and SIG size are trigger message and aperiodic request signal transmission time respectively. Nmax(s) = T r(s) + T M size(s) SIG size(s) (1)

3

System Model

3.1

Network Model

In this report, we assume a network composed of several switches connected in a tree topology in which one switch on the top of the hierarchy is connected to one or more other switches in the second level of hierarchy. This may continue to many levels in this hierarchical architecture. Moreover, multiple nodes are connected to each switch in the network as well as one master node. In this thesis, the combination of a switch with the

(20)

master node and all other slave nodes which are connected to the switch is called a sub-network. Also, each level of the hierarchy in the architecture of the network is a parent sub-network for the lower level hierarchy connected to it and the top (first) level of the network hierarchy is called Root Level.

An example of the mentioned architecture with five sub-networks is depicted in Fig-ure 8. Sub-network 1 contains SW1, master M1 and nodes A and B. SW1 is the parent switch for SW2 and SW3 and, in turn, SW2 is the parent switch for SW4 and SW5. Furthermore, the switches are considered as store-and-forward fashion which is most pop-ular in COTS switches. The other sort of switch is called cut-through in which it starts forwarding the message as soon as it has figured out the destination of that message. How-ever, in the former one, it will wait until it receives entire message and buffer that, then it will begin to forward the message. Although the store-and-forward switch is inherently slower rather than cut-through one, the received message is often checked for errors before sending.

Figure 8: An example of network with five switches

3.2

Traffic Model

Synchronous message stream are modeled using the periodic real-time model mi(Ci, M max

, Di, Ti, Oi, Si, Dsi, Ri), where Ci is the total transmission time of message, Di and Ti are

deadline and period of the message respectively, Oi is the offset, M max is the maximum

packet transmission time for the large messages which are fragmented to the packets by the protocol. Also, Ri denotes set of switches in the rout of message from source node Si

(21)

periodic model except the Ti is the minimum inter-arrival time of the message and there

is no offset Oi [5].

Moreover, when using multiple switches in a network, we define two kinds of messages. If the sender and receiver of a message are connected to the same switch, i.e., they belong to the same sub-network, the message is called local. Otherwise, a message is called global if the sender and receiver are connected to different switches. Also, the input and output ports of switches are called uplinks and downlinks respectively.

4

Solution

In this chapter we explain the problems due to extending of the FTT-SE protocol for multiple switches networks and we propose a solution to overcome the problems. The solution covers both synchronous and asynchronous messages in the network.

4.1

Problem Formulation

By assigning one master node to each switch in the architecture considered in this thesis, the complexity of the traffic scheduling are substantially increased due to following reasons: a) Confinement of broadcast domain

Within each sub-network, the respective master controls the traffic by broadcasting one TM per EC. By simply connecting sub-networks together, the broadcast nature of each TM will make them propagate through the entire network, generating unwanted interference. When the TM is generated with one master and broadcasted, all other nodes including the ones that are connected to other switches received this TM which may cause interference in other sub-networks.

b) Time synchronization

All Elementary Cycles (EC) for sub-networks should be timely synchronized which means, all Trigger Messages (TM) generated from all master node should be broad-casted at the same absolute time. Consequently, the message transmission between nodes in one sub-network is started simultaneously with the other sub-network’s nodes. For instance, a global message in one sub-network is scheduled in a certain time slot, however receiving of this message in the other sub-network may not occur at the same EC which may cause overrun within the FTT-SE protocol. For instance, the m1 is transmitted from one node and because of non-synchronicity it may face overrun which is depicted in Figure 9.

c) Scheduling synchronization

The other problem of extending the FTT-SE architecture is handling and scheduling global traffics in the network. In case of having a global message, transmission of

(22)

Figure 9: Overrun caused by EC non-synchronicity

the message from a node to the other node may cross many switches. Therefore, all master nodes connected to the switches between this transmission should be aware of the message which is passing through. For instance, considering the example shown in Figure 8, there is a global message from node C to node D. The M2 which handles the message of node C starts to schedule this message in the network, however it does not know about the load in SW1. Assume that in the same EC there are other messages to be transmitted from node A to node D and the bandwidth for this transmission is full. Therefore, the bandwidth state at the destination is unknown for M2 and may cause overrun as shown in Figure 10.

All masters that schedule global messages should do it consistently in order to limit the interference between global messages sharing communication path. Otherwise, global messages in one sub-network may suffer unwanted interference and miss their deadlines.

(23)

4.2

Protocol

4.2.1 Confinement of Broadcast Domains

In order to prevent interferences between TMs transmitted by all master nodes caused by the broadcast nature, we propose using multicast groups. Each master has its own multicast address that includes all the local slave nodes. Connection of the switch to the other sub-networks are excluded from multicast address. Thus, sending a TM to multicast address confines its distribution to the associated local slave nodes. Another alternative would be using one VLAN per sub-network which is more complex than the former approach due to the number of situations of traffic that needs to cross the VLANs boundaries.

4.2.2 Time Synchronization

One solution for time synchronization between the sub-networks, is by using a particular signal that is broadcasted from root master to the entire network. We call this synchronizer signal the Global Trigger Message (GTM) and it is a minimum size Ethernet packet. All masters in all sub-networks wait for the GTM to initiate their local ECs by sending their own TM. This mechanism affects on sub-networks in deeper levels due to switch delay, however we consider this delay acceptable given the minimum length of the GTM (Figure 11).

Figure 11: Global synchronization using a Global Trigger Message

There is a possible situation that GTM losses due to failure in part of the network. In order to recover this problem we define time out interval for each master node according to its position in the level of hierarchy. If a master does not receive a GTM after define time interval, it will generate one GTM and sends to master nodes in deeper levels.

(24)

4.2.3 Periodic Message Scheduling

According to the FTT-SE protocol, each EC has two scheduling windows to handle all kinds of traffic in the network, one window is dedicated to periodic message called syn-chronous window and other one for sporadic and non real-time messages called asyn-chronous window. An example architecture with related bins is depicted in Figure 12. The goal of scheduler is to schedule the local and global traffic as much as possible in the dedicated windows.

Figure 12: Sample Network with associated Bins

In this solution we have divided the global and local messages in each window. For each asynchronous and synchronous window, specific bandwidth for local and global traffic has been considered as shown in Figure 13. The bandwidth reservation for the local and global messages can be studied as an optimization problem taking into account the amount of the load in each of them, as they have a great effect on the response time of messages. However, this bandwidth should be considered constant for all master nodes in the network.

(25)

Basically, each master node, schedules its local messages and all global messages in the network. Scheduling of global messages are similar in all master nodes which means that the scheduler of each master should know the state of all global messages in the network. Since each global periodic message is scheduled in all master nodes, the scheduler ensure about enough bandwidth for its transmission along its path.

For instance, a global message m1 sent by node C to node D to be transmitted to SW1 and then continue to its destination through SW3. We have considered that each master node has a database of local message and all global messages in the network. Therefore, each master has a separate local ready queue which is ordered according to a certain scheduling policy and contains local messages of that sub-network. For global messages there is one global ready queue in each master node which contains all global messages of the network and it is ordered according to any scheduling policy such as FP or EDF. All global ready queues in the master nodes should be synchronized i.e. the global messages which are selected to be transmitted in the queue should be similar in all master nodes.

Return to the Figure 12, M2, after scheduling the local traffic, starts to schedule the global messages. The scheduler in M2 tries to process a request to send message from C to D, it checks the message in all bins associated to links that message will cross i.e. UC, DW2 = UW1, DW1 = UW3 and DD. UC is uplink connected to node C and DD is downlink connected to node D. Also, DW2 and UW3 are downlink of SW2 and uplink of SW3 respectively. To make sure that all links in the path have adequate bandwidth reserved for the message transmission in a given EC, all masters must schedule it consistently.

Furthermore, checking the message in the related bins should be done considering all delays that the message will suffer through its path to the destination node. This should be included inside the scheduler. These delays such as store-and-forward delay in switches and the delays which caused by higher priority messages that have share downlink with the message under consideration should be taken into account. Also, the transmission time of the message itself should be added into the related bins. The scheduling of the mentioned example is depicted in Figure 14.

4.2.4 Aperiodic Message Scheduling

Similar to synchronous window for handling periodic messages, we have divided the asyn-chronous window into two specific bandwidth as local and global for aperiodic messages. Therefore, global aperiodic messages have their own bandwidth for transmission. Local aperiodic message handling is similar to the original FTT-SE protocol. Master node is in-formed about the status of aperiodic messages inside a node and it will schedule messages in the next EC exactly as the case of single switch presented in [13].

For handling the global asynchronous messages, another method should be used to inform all master nodes in the path of aperiodic message in the network. Return to the example which was depicted in Figure 12, assume that there is a global aperiodic message which is requested by node C and the destination is node D. In this example, the M2 not only should know about the status of aperiodic global bins within its sub-network, but also

(26)

Figure 14: Scheduling m1 in example network in Figure 12

it should be informed about the bandwidth availability in SW1, SW2 and the destination node bandwidths.

We propose two solutions to solve the problem of handling global aperiodic messages in this architecture as below:

1. Bandwidth reservation per sub-networks

In this solution we divided the bandwidth which is dedicated to the global asyn-chronous sub-window into a number of sub-slots, each will be dedicated to each sub-networks in the network hierarchy. This sub-window may be divided equally or based on the load of each sub-networks. Consider the network architecture as de-picted in Figure 15. In this architecture, there are five switches which are connected in three levels of hierarchy. Therefore, the EC window, by considering both periodic and aperiodic message looks like Figure 16 in which the global asynchronous sub-window is divided into five slots as there are five sub-networks in the architecture. In this method each sub-network has its dedicated bandwidth for scheduling the aperiodic messages which are requested by its nodes. There will be no interfere from aperiodic messages that belong to other sub-network’s nodes and a similar technique as the single switch case can be used to schedule global aperiodic messages. A similar approach was proposed in [14] but with the bandwidth being reserved for each node instead. There are some disadvantages regarding to this method as following:

• Idle time should be considered for each windows assigned to each sub-network in order to avoid window overrun in the EC. However, by dividing the window into more sub-windows,the idle time will increase in the EC window which decreases the bandwidth utilization and efficiency. For instance, in Fig-ure 16, the global asynchronous sub-window is divided into five slots because

(27)

of five sub-networks in the network. Each slot has an idle time due to prevent-ing the overrun problem. Therefore, five idle time is considered in the global asynchronous window.

• In certain ECs, there may be sub-network, without having aperiodic messages. Therefore, that part of bandwidth will be wasted and thus it decreases the efficiency of that specific EC window.

Figure 15: Three level hierarchy network architecture

Figure 16: Global asynchronous message bandwidth

2. Bandwidth reservation per clusters

We propose another solution to handle the global aperiodic messages which is ba-sically similar to the former approach but the bandwidth assignment is performed in a different way. We define a cluster which encompasses all the sub-networks hav-ing the same parent switch. Return to Figure 15, SW4 and SW5 in third level of hierarchy are grouped as one cluster and consequently SW2 and SW3 are grouped

(28)

as another cluster with the root sub-network SW1. We divide the bandwidth of the global asynchronous window among clusters instead of sub-networks. The number of sub-windows in global asynchronous window will decrease as shown in Figure 17. Also, by considering this solution the overall idle time of global asynchronous win-dow decreases significantly. All request of global aperiodic message from slave nodes are transmitted directly to the parent master in upper level of hierarchy and the master of that cluster is responsible to schedule the global aperiodic message.

Figure 17: Global asynchronous reservation for clusters

If there is an aperiodic signal from node E to node F, then this signal is still global but inside one cluster. Therefore, node E sends the request to M2 as parent master directly and M2 schedules the aperiodic messages for the next EC. On the other hand, if node E has a request for aperiodic message to node D, then node E sends the request to M2 the same as first example, however the sender and receiver nodes have separate dedicated bandwidth due to separate cluster dedication. The advantages and drawbacks of this solution are:

• The idle time for the global asynchronous window will be decreased by merg-ing the windows of sub-networks that have the same parent switch. Thus, any bandwidth slack can be used more efficiently than the first solution. For in-stance, in Figure 17, the global asynchronous sub-window is divided into two slots. By considering idle time for each slots, in compare with previous solution, there will be less idle time.

• Forming the clusters, assigning respective bandwidths as well as extra signaling and trigger messages which are needed in this solution, add more complexity to the protocol.

(29)

5

Response Time Analysis

In this chapter we present the response time analysis according to the proposed solution in FTT-SE. The local and global traffic due to their different bandwidth and scheduling algorithms studied separately.

5.1

Message Delay

A message which is sent from a node in all Switched Ethernet networks, suffers from several delays which were studied in [5]. These delays categorized as below:

1. SLD - The switch latency delay which is based on the hardware and software imple-mented inside the switch. This is defined as the maximum time that switch needs to execute the internal forwarding.

2. SFD - The store-and-forward delay which appears in the store-and-forward type switches. In this thesis all the switches considered as this type due to popularity of them. This delay is the time that switch needs to store the message before forwarding it into the uplink.

3. NQD - The delay inside the source node caused by higher priority messages from the same source node.

4. SQD - The delay inside the switch downlink caused by all other messages with the same downlink.

5. IFD - This is the maximum delay between two consecutive frames which is included in the message transmission time in this analysis.

Some of these delays are appeared because of the network and switch architecture such as SLD, SFD and IFD. However, the others are related to the FTT-SE protocol. In this analysis, we distinguished local and global messages due to their specific bandwidth in the network which make them independent.

5.2

Local Message Response Time

To find the response time for a message mi, which is a local periodic message, we define

all interfering messages that affect the response time of the message mi. Similar to the

local message response time analysis has been studied in [5] but for an architecture with multiple switches while single master controls the transmission. All the messages that interfere to the message mi are local periodic message which have the same bandwidth in

the EC. In the following equations, {uli} is the uplink number i of the switch, {dli} is the

downlink number i of the switch, hp(mi) is the set of messages that have the priority higher

than mi and {LS} is the set of local synchronous messages. The interfering messages are

(30)

Store and forward delay: This is the delay related to the store-and-forward fashion of COTS switches. This delay depends on the transmission time of the message itself in the local message response time analysis. Therefore, we define the delay in (2).

SF D(mi) = ci (2)

Source node interference messages: The set of messages in the same source node of mi that makes N QD delay. As described before, this delay is caused by all higher

priority messages in the same source node. Therefore, the set of messages that interfere the message mi is the messages with the same source node and higher priority than mi.

These set of messages is defined in (3).

S interf (mi) = ∀mj ∈ {uli} & mj ∈ hp(mi) & mj ∈ {LS} (3)

The switch queuing delay: This delay is generated due to all messages that have the share downlink in the switch with mi. This delay is defined as SQD which is described

in the message delay definitions. In analyzing of local messages, there is one switch connecting the source and destination nodes of the local messages. Therefore, the message interferences is defined just in single switch downlinks in (4).

D interf (mi) = ∀mj ∈ {dli} & mj ∈ hp(mi) & mj ∈ {LS} (4)

The source message of the direct interference: We define the direct interference message set as the messages that have share downlink in the switch with the message mi.

Also, the messages that have the same source node with the direct interference message can affect on the response time of the message mi. These set of messages interference

called indirect effect in this response time analysis which is obtained according to (5). I interf (mi) = ∀mj ∈ {ulq} & mq ∈ D interf (mi) & mj ∈ {LS} (5)

In the FTT-SE protocol all the messages are transmitted in their specific windows depends on the message types. According to the proposed solution in this thesis, the EC duration time is divided into four windows besides the TM transmission window. These windows are dedicated to transmit local periodic, local aperiodic, global periodic and global aperiodic traffic. Due to specified windows for message transmission, the messages are not allowed to send in any time only within its associated window. Therefore, an inflation factor should be taken into account when performing the response time analysis. This issue is considered previously in [12] and the proposed solution was to inflate the transmission time of the message by percentage of the bandwidth availability. Therefore, the inflation factor is defined in (6), where LW LS is the length window of local periodic traffic, the I is the idle time that is used to prevent overrun problem in the mentioned bandwidth which is the maximum transmission time of the message with higher priority than mi.

α = LW LS − I

EC where I =∀mt∈hp(mmaxi) & mt∈{LS}

(31)

Then all transmission times should be divided by the inflation factor α. According to the interference definitions for the local messages, the response time of mi is evaluated in

(7). Also, to consider the store-and-forward delay in the response time, the transmission time of the message itself should be added.

xl= ci α + SF D(mi) α + X mj∈S interf (mi) dx l−1 Tj e(cj α)+ X mt∈D interf (mi) dx l−1 Tt e(ct α) + X mp∈I interf (mi) dx l−1 Tp e(cp α) (7)

Finally, the response time of the message mi is calculated as (8).

RT (mi) = xlwhen xl = xl−1 (8)

The local asynchronous messages response time equation is the same as the local syn-chronous traffic response time because the algorithm of the scheduling are the same in both kind of messages. Moreover, transmission bandwidth of local asynchronous messages is distinguished to the local synchronous traffic. Therefore, the response time that ana-lyzed is accepted for the asynchronous traffic except that all interfering messages should be considered as local aperiodic and the inflation factor is changed by using length window of local aperiodic traffic (LW LA) instead of LW LS.

Moreover, the request signal of the aperiodic messages are generated by the source node. The aperiodic messages can be activated in any time during the EC. The worst case scenario occurs when an aperiodic message invokes exactly after sending the signal request. Therefore, the aperiodic request will be sent in the next following EC and the master node will need additional EC to be included in the scheduling. To compute worst case end-to-end delay, two EC should be added to (7).

5.3

Global Periodic Message Response Time

According to the proposed solution based on multiple switch with multiple master node, we defined specific bandwidth for handling the global periodic messages. Therefore, the global periodic messages are transmitted independent to the local messages. In the global periodic message response time equations, {dlj,k} is the downlink number j of the switch

number k, {ulj,k} is the uplink number j of the switch number k and the {GS} is the set of

messages which are global and synchronous type. However, the delays and the interference messages that a global message mi will face are classified as follow:

Store and forward delay: This is the delay related to the store-and-forward fashion of COTS switch. The same as local message analysis, this delay is related to the transmis-sion time of the message itself and the messages that share downlinks with the message under consideration and higher priority. This delay is defined per each switch in (9). Note that, all interference messages are global synchronous message in this analysis due to the specific bandwidth for global periodic messages. It means that other kind of messages such as global aperiodic messages are transmitted independently.

(32)

SF D(mi, k) = max

∀mt∈{dlj,k} & mt∈hp(mi) & mt∈{GS}

(ct) (9)

Where mt is the global periodic message with higher priority than mi that use the

same downlink in the same switch. Also, k represents the switch number in which the delay is calculated.

Source node interference messages: This interference is similar to the local mes-sage except that the function is defined considering the switch that the source node is connected to. Therefore, the set of message that have mentioned interference is presented in (10).

S interf (mi) = ∀mj ∈ {uli,k} & mj ∈ hp(mi) & mj ∈ {GS} (10)

The switch queuing delay: The set of messages that interfere to mi which caused

SQD. This is similar to the local message analysis except that the contribution of all interference of messages in all switches should be taken into account. This interference includes all messages that have same links with the message mi and the messages that

was considered in previous switches should be excluded. The queuing delay is presented in (11).

D interf (mi) = ∪∀SWk∈RiD interf (mi, k) (11)

Where, the Ri is the set of switches in rout of the message and D interf (mi, k) is

defined in (12).

D interf (mi, k) = ∀mj ∈ {dlj,k} & mj ∈ hp(mi) & mj ∈ {GS}

& mj ∈ D interf (m/ i, l)|∀SW l ∈ SWs−1, . . . , SWk−1

(12) Where, SWl is the set of the switches that message mi should pass to reach to the

destination node. Moreover, the SWs−1is the switch in which the source node is connected

and the D interf (mi, s − 1) = S interf (mi).

The indirect interference: Besides the interference of the messages due to having share links in the path of message transmission, other effect is available as interference of the message without any share links with the message mi. This effect was studied in [5]

known as indirect effect. Let us consider an example depicted in the Figure 18, where three switches connected together to form a network consisting six slave nodes.

We define four global messages in the example network where the message mAD is sent

from Node A to Node D, the message mBF which is transmitted from Node B to Node

F, the message mEF that transmit from Node E to Node F, and the message from Node

C to Node D as mCD. We assume that all the messages that are defined need one EC

to be transmitted. Also, the message mAD has the lowest priority among all messages

and we will study the response time of this message according to activation time of other messages. We assume that the message mCD has the highest priority, the messages mEF

and mBF have the priority lower than mCD, however the priority of the message mEF is

(33)

Figure 18: Example to show indirect effect

• In the first scenario, all of messages are activated simultaneously. Therefore, the messages mCD and mEF are transmitted in the first EC due to higher priority and

different links. In the second EC, the message mBF is transmitted and finally the

message mAD is scheduled to be transmit in the third EC due to its lowest priority.

• We assume that the messages mAD and mCD are activated in the first EC, and the

messages mBF and mEF are activated in the second EC. Then, the message mCD

is scheduled in the first EC because of having priority higher than mAD and having

share links. In the second EC, two other messages are activated, therefore mEF is

transmitted in the second EC since it has the priority higher than mBF. Still the

message mAD is pending due to delay by mBF. Then in the third EC the message

mBF is transmitted and finally the message mAD will be transmitted in the fourth

EC.

From the two scenarios mentioned, we can conclude that two messages without share links may interfere together when they have a common message in a share links. In above example the message mAD is delayed because of mBF transmission which itselt delayed by

mEF. Therefore, the message mEF has delayed the message mAD, although they have no

share links with each other.

To add this effect into the response time analysis, not only all messages that have share links with the message under consideration should be taken into account, but also all the messages that have share links with the message that delay the considered message should be taken into account. Therefore, the (13) presents the set of messages that interfere with the message mi.

(34)

Where, the mj is computed in D interf (mi). Also, D ineterf (mj) and S interf (mj)

presents the messages that interfere to the message mj.

The inflation factor as explained in local message analysis, can be defined by consid-ering global synchronous window in (14).

α = LW GS − I

EC where I =∀mt∈hp(mmaxi) & mt∈{GS}

(Ct) (14)

Therefore, the response time is evaluated in (15). xl = ci α + X SWk∈Ri SF D(mi, k) + SLD α + X mj∈S interf (mi) dx l−1 Tj e(cj α)+ X mt∈D interf (mi) dx l−1 Tt e(ct α + X SWk∈Rt SF D(mt, k) + SLD α )+ X mq∈I interf (mi) dx l−1 Tq e(cq α) (15)

Finally, the response time for the message mi is calculated in (16).

RT (mi) = xlwhen xl = xl−1 (16)

5.4

Global Aperiodic Message Response Time

According to the solution that proposed in this thesis report, two approaches was proposed to handle global aperiodic messages. The first one is based on dividing the bandwidth into a number of sub-windows equal to number of sub-networks. In this approach each sub-network has its own bandwidth to schedule its global aperiodic messages. However, due to the lower efficiency of using EC, the second approach was proposed to overcome this problem. In the second approach, all sub-networks having the same parent sub-network are grouped as one cluster. Therefore, the global asynchronous bandwidth is divided into the number of clusters instead. This solution decreases the idle time in the bandwidth and increase the efficiency of using EC. In this response time analysis, we assume the second approach. The delays that a message suffers from are as follow:

Store and forward delay: The same as the global periodic message response time analysis, the messages are delayed because of the store-and-forward delay of the switch. This delay is equal to the transmission time of the message itself and the message with share downlink with higher priority. The effect of the other kind of messages such as synchronous messages is excluded from this delay since they have their own bandwidth. Then, the SF D delay is calculated from (17).

SF D(mi, k) = max

∀mt∈{dlj,k} & mt∈hp(mi) & mt∈{GAS}

(ct) (17)

Where mt is the global aperiodic message with higher priority than mi that use the

same downlink in the same switch. Also, the mtis the global asynchronous message which

(35)

Source node interference messages: The source node of the message may have other messages with the priority higher than the message under consideration. Then all of those messages will delay the message which is calculated from (18).

S interf (mi) = ∀mj ∈ {uli,k} & mj ∈ hp(mi) & mj ∈ {GAS} (18)

The switch queuing delay: Delay generated by the set of messages that add inter-ferece to mi which caused SQD. This delay is caused by higher priority messages in all

switches which have the same downlink with the message under consideration. Moreover, the messages that was considered in the previous switches should be excluded. One dif-ference from the global periodic messages regarding the switch queuing delay is that, in this part the messages in the same cluster should be analyzed. The messages from other cluster have their specific bandwidth. Then, all messages in the different cluster cannot affect on the message in other cluster. This set of message is presented in (19).

D interf (mi) = ∪∀SWk∈RiD interf (mi, k) (19)

Where, Ri is the set of switches in the rout of the message and D interf (mi, k) is

defined in (20).

D interf (mi, k) = ∀mj ∈ {dlj,k} & mj ∈ hp(mi) & mj ∈ CLt& mj ∈ GAS

& mj ∈ D interf (m/ i, l)|∀SW l ∈ SWs−1, . . . , SWk−1

(20) Where, SWl is the set of the switches that message mi should pass to reach to the

destination node. Moreover, the SWs−1is the switch in which the source node is connected

and the D interf (mi, s−1) = S interf (mi). Also, the CLtis the cluster that the message

mi is inside and defined as mi ∈ CLt.

The indirect interference: The same as the periodic global messages, the indirect effect is available in the asynchronous global message scheduling. However, the difference between these two analysis is that, in the aperiodic study for indirect effect, just the messages from the same cluster should be taken into account. To realize this effect in the asynchronous global message scheduling, an example of a network with two clusters is depicted in Figure 19. This network consists of seven switches with master nodes and seven slave nodes. The cluster 1 contains SW2 and SW3 with SW1 as the parent master node, whereas cluster 2 consists of SW4, SW5, SW6 and SW7 with M2 as the parent master for this cluster.

In this example we declare four messages that each one need one EC to be transmitted in the network. Note that the messages associated to cluster 2 cannot have any affect on the messages associated to cluster 1. For instance, all four messages are defined in cluster 2. The message mAD with priority 4 (lowest priority among other messages) is sent from

Node A to Node D in cluster 2, the message mBG with priority 3 to be transmitted from

Node B to Node G, the message mF G with priority 2 from Node F to Node G and the

message mCE with the highest priority (priority 1) among the messages which is sent from

(36)

Figure 19: Example to show indirect effect in the same cluster

• In this scenario, we assume that all messages activate at the same time. Then, the messages mCE and mF G are scheduled to be transmitted in the first EC due to

having higher priority than the others and different links. In the second EC, the message mBG is transmitted and in the third EC the message mAD is scheduled to

be transmitted.

• In the second scenario we assume that, both messages mAD and mCE are activated in

the first EC and the other messages are activated in the second EC. Therefore, in the first EC the message mCE is scheduled which has the higher priority than mAD. In

the second EC, since the mF Gand mBG are activated which have the higher priority

than mAD, then the message mF G is scheduled. In the third EC the message mBG

and in the fourth EC the message mAD are scheduled to be transmitted.

From the above example and scenarios we can conclude that, the worst case in not necessarily occurs by activating all messages at the same time in this network. Moreover, the message mF G can affect the message mAD, even though they do not have share links.

The message mF G affects the message mBG by their share link and indirectly affects on

mAD which has the share link with the mBG. Therefore, this indirect effect should be

considered in the response time analysis. The set of messages that delayed the message mi as indirect effect is presented in (21). Also, D interf (mi) is the set of messages in the

same cluster as mentioned in switch queuing delay for asynchronous global messages. I interf (mi) = ∪∀mj∈D interf (mi)(D interf (mj) ∪ S interf (mj)) (21)

The same as local message response time analysis, we need to specify the inflation factor since the bandwidth is not always available for the messages to transmit. we can define this inflation factor by considering global bandwidth dedicated to each cluster as

(37)

calculated in 22. The CL represents the bandwidth which is dedicated to cluster of the message under consideration. Also, the I is the idle time in the cluster bandwidth which caused by the maximum transmission time of higher priority messages.

α = CL − I

EC where I =∀mt∈hp(mmaxi) & mt∈GAS

(Ct) (22)

Therefore, the response time can be evaluated as 23. xl = ci α + X SWk∈Ri SF D(mi, k) + SLD α + X mj∈S interf (mi) dx l−1 Tj e(cj α)+ X mt∈D interf (mi) dx l−1 Tt e(ct α + X SWk∈Rt SF D(mt, k) + SLD α )+ X mq∈I interf (mi) dx l−1 Tq e(cq α) (23)

Finally, the response time for the message mi is calculated as 24.

Figure

Figure 2: Elementary Cycle Structure [18]
Figure 4: FTT-SE architecture [11]
Figure 5: Typical switch internal blocks [11]
Figure 7: FTT-SE asynchronous traffic requests
+7

References

Related documents

This thesis work will investigate machine learning methods for improving 5G network performance by automatically tuning key network parameters to their optimal values..

This thesis will investigate the handover procedure and related handover parameter optimization for different types of performance enhancements in a 5G network.. For example,

Detta betyder med andra ord att min hypotes om att personer som lyssnar på RnB skulle vara mer mottagliga för Digster inte stämmer?. Detta är aningen underligt med tanke på att

10 2 nd paragraph, last sentence: “per kg body mass” should

As we want to investigate how the Marikana incident was portrayed in the press a critical discourse analysis will provide tools to uncover underlying values within the content and

It occurs in a wide range of woodland communities: alder woods (Alnion glutinosae with drier soil conditions later in the growing season, as opposed to permanently wet soils

If we consider the FAOstat area data for Cropland as realistic (the FAOstat data for Grassland seem to be an overestimation), the annual CO 2 emissions from drained organic soils

tydliggöra att hans författarskap verkar handla om mer än bara underhållning. Det blir tydligt ju mer man läser att ett av Neil Gaimans mest intressanta berättargrepp är