Designing and Modeling a Hybrid PROFIBUS Network.pdf - Read

9 downloads 21 Views 349KB Size Report
Designing and Modeling a Hybrid PROFIBUS Network using. Discrete Event Simulation Technique. İbrahim Özçelik. Hüseyin Ekiz. Sakarya University, Faculty of ...
Paper ID: 155

Designing and Modeling a Hybrid PROFIBUS Network using Discrete Event Simulation Technique İbrahim Özçelik Sakarya University, Faculty of Engineering, Dep. of Computer Engineering,, Sakarya, Turkey [email protected]

Hüseyin Ekiz Sakarya University, Faculty of Technical Educational, Dep. of Electronic&Computer Education,, Sakarya, Turkey [email protected]

Abstract In this study, a hybrid (more than of one master and one slave) PROFIBUS network is designed and modeled to obtain the performance of the PROFIBUS medium access protocol. It is assumed that the designed system controls a production plant. The plant has six master nodes and six slave nodes. The designed system has been modeled using the CACI Network II.5 software which based on discrete event simulation technique.

1. Introduction PROFIBUS protocol is one of the most popular fieldbus defined with international standards (IEC61158, EN50170 and EN 50254). PROFIBUS defines the technical characteristics of a serial fieldbus system with distributed digital programmable controllers can be networked, from field level to cell level of CIM (Computer Integrated Manufacturing) architecture. PROFIBUS is a multi-master system and thus allows the joint operation of several automation, engineering or visualization systems with their distributed peripherals on one bus [1-3]. In this paper, a hybrid PROFIBUS model is presented. The model has been modeled using Network II.5 software that is written with Simscript. Network II.5 is based on discrete event simulation package from CACI Inc [4]. In many researches / studies Network II.5 were used to implement the designed models [5-7]. Its evaluation in reliable real-time communication environments is realized using the simulation results. The paper is organized as follows: Section 2 introduces the basics of the PROFIBUS; Section 3 details the designed hybrid PROFIBUS network. Section 4 presents the designed hybrid PROFIBUS model and its modeling.

2. PROcess FIeld BUS – PROFIBUS PROFIBUS (PROcess Field BUS) is one of the most popular fieldbus standards that meets all requirements and

offers a transparent solution for manufacturing as well as for process automation. PROFIBUS offers functionally graduated communication protocols (communication profiles): DP (Decentralize Periphery) and FMS (Fieldbus Message Specification). DP is the most frequently used communication profile of PROFIBUS, and permits monomaster or multi-master systems. This provides a high degree of flexibility during system configuration. FMS is designed for communication of programmable controllers (PLCs and PCs) – master devices- with each other [1-3]. PROFIBUS communication profiles use a uniform medium access protocol. PROFIBUS medium access control is based on a token-passing procedure used by master stations to grant the bus access to each one of them, and a master–slave procedure used by master stations to communicate with slave stations. These MAC mechanisms are implemented at the layer 2 of the open systems interconnection (OSI) reference model, which, in PROFIBUS, is called fieldbus data link. In addition to controlling the bus access and the token cycle time, the Fieldbus Data Link Layer (FDL) is also responsible for the provision of data transmission services for FDL user. PROFIBUS supports four data transmission services: 1) send data with no acknowledge (SDN); 2) send data with acknowledge (SDA); 3) send and request data with reply (SRD); and 4) cyclic send and request data with reply (CSRD). PROFIBUS DP, which is to be used in the simulation models, supports only SDN and SRD services. The SDN is an acknowledged service used for broadcast from a master station to all other stations on the bus.

Conversely, the SRD is based on a real dual relationship between the initiator (master station holding the token) and the responder (slave or master station not holding the token). Most data transfers are defined as SRD. A SRD service is a message cycle consisting of a request packet and an immediate response. A response can occur as a one byte acknowledgement or a data packet. During a message cycle an addressed station has to respond within a bounded time interval. Figure 1 shows the activity on the bus during an arbitrary time interval. In figure 1, While TSDI (station delay initiator) is the processing time the station needs to initialize the data request packet, TSDR (station delay responder) is the time the addressed station needs to process the request packet and to initialize the transmission of the response frame. After one master has finished a message cycle, if it is, other their message cycles are implement, otherwise the token is passed from one master to the next in order of increasing addresses. In order to ensure system stability PROFIBUS uses control timers. The most important is the slot time. It represents the maximum time that the requesting station waits for the response during a message cycle before initializing a retransmission [8,9].

Figure 1. Activity on the bus during a message cycle. PROFIBUS frame format includes 0-246 bytes of variable data and 3-9-bytes of protocol control information (i.e. Start Delimiter Length, Source and Destination Addresses, Frame Control and CRC data) as shown Figure 2. More detail about PROFIBUS can be found in [1].

Figure 2. PROFIBUS frame format.

3. Designing a Hybrid PROFIBUS Network In industrial applications, a fieldbus (network) provides communication between the different microcontrollers / PLCs or computer based systems. As mentioned, PROFIBUS is one of the most popular fieldbus standards that meets all requirements and offers a transparent solution for manufacturing as well as for process automation.

The PROFIBUS contains the following types of devices: • Master devices determine the data communication on the bus. A master can send messages without an external request when it holds the bus Access rights (the token). • Slave devices are peripherals such as I/O devices, valves, drives and measuring transducers. They do not have bus access rights and they can only acknowledge received messages or send messages to the master when requested to do so. Master and slave nodes/stations allow implementations of the following system configuration in the PROFIBUS systems: • Pure master-slave system. • Pure master-master system (token passing) • A combination of the two – hybrid system Manufacturing, process control and building automation systems can need one of the above systems. However, some of the implementations can have a considerable need multimaster / hybrid systems. In this study, an example hybrid system has been designed to meet the necessity. The range of PROFIBUS implementations is so versatile that there is no general model for a PROFIBUS application or even a benchmark [8]. Despite of this, to illustrate the communication behavior and to discuss the system performance a PROFIBUS example can be used. Figure 3 shows an example hybrid PROFIBUS network model. It is assumed that the PROFIBUS network controls a production plant. The plant has with 6 master nodes which each one has different requirements and 6 its assigned slave nodes. The 6 master form a logical token ring. 6 master nodes use 17 various messages, 9 is between master-to-master device and 8 is between master-slave devices, defined at the beginning (Table 1). In the table 1, while MFramex represents a request frame from a master to a master, SFramex indicates a request frame from a master to its assigned slave. A slave can be used by more than one master (in master’s token holding time) depending of configuration. As an example, slave 1 has been used by two masters (Con1 and Con2) in the designed system. The relation between slaves and masters are shown in the last column (SA/DA) of the table 1.

Logical token ring between master devices Master devices (Con1, Con2, Con3, Con4, Con5, Con6)

PROFIBUS

Slave devices (Slave1, Slave2, Slave3, Slave4, Slave5, Slave6)

Figure 3. An example configuration for a hybrid PROFIBUS network Table 1. Master (M) and Slave (S) Request/Response Frame models that constitute for PROFIBUS.

In PROFIBUS communication profiles, user data is transmitted with the SRD service of layer 2. The PROFIBUS frame format given in Figure 2 represents general form of the PROFIBUS frames given in the figure 4. SRD transmission provides a service for five different frame format given in the figure 4.

Hardware devices are specified in Network II.5 by using building blocks based on the functions of the device being modeled. There are three kinds of hardware components: Processing Element (PE), Transfer Device (TD), and Storage Device (SD). These hardware components perform three functions in a network system: Process Data, Transfer Data, and Store Data.

SD1 DA SA FC FCS ED Fixed length request/response frame without data SD2 LE LEr SD2 DA SA FC

Data

FCS ED

Variable data length request/response frame SD3 DA SA FC

Data

FCS ED

Fixed data length request/response frame SD4 DA SA Token frame SC Short Acknowledgement Figure 4: Different PROFIBUS frame formats used in PROFIBUS systems [1].

4. Modeling the Designed System In discrete event simulation technique, the simulation clock is advanced and modules are executed at the occurrence of events such as the arrival of messages. Systems such as communication networks and computer systems can be categorized as discrete systems and can be simulated using discrete event simulation [5]. In this method, the state changes occur at the specific finite number of times and changes are instantaneous. Each state change is called an event (the occurrence of something). A PROFIBUS system with master and slave stations may be an example for discrete systems. Network II.5, a simulator, is a design tool which takes a computer system description you specify and provides measures of hardware utilization, software execution, message delivery times, response times, contention, etc,. Network II.5 can be used to model the smallest level of processing or a large network of different systems. Its flexibility allows portions of a simulated computer system to be modeled at a detailed level while the rest of system can be modeled on a large scale. Network II.5 consist of an object oriented programming structure [4]. In this study, to model the PROFIBUS network and other components and to evaluate performance analysis was used Network II.5.

Figure 5: PROFIBUS MAC Message Handling Procedure [9]. Processing Elements are used to model devices in a simulation that executes instructions or makes decisions. The PE may be defined as one of the computer system devices: a personal computer, a gateway, a sensor, an entire arithmetic logic unit, a bus controller, a processor or a display. Each PE has a cycle time and instruction set that characterizes the PE. There are four types of instruction building blocks: processing instructions, message instructions, read/write instructions, and semaphore instructions. In Network II.5, the PE has been

used to model the PROFIBUS master and slave nodes / devices. Transfer devices are the links between processing elements and storage devices. They can represent buses in a computer, links in a computer network, or a complete local area network. The transfer devices are characterized by their data transfer rate, data transfer protocol, and connections. Each TD has a user defined specification giving the transfer speed, transfer overhead, and protocol definition. The TD can support predefined network protocols such as FCFS, Ethernet, FDDI, etc, but it can not support fieldbus protocols especially PROFIBUS, CAN, WorldFIP, etc. So, the PROFIBUS medium access protocol should be created using Network II.5 features. To create the PROFIBUS medium access control protocol, First Come First Served protocol has been used depending upon an algorithm given figure 5.

Network II.5. Performance assessment of the network model is carried out depending upon such parameters as PROFIBUS utilization, token rotation time and message cycles.

5. Conclusion In this paper, a hybrid PROFIBUS network is designed and modeled to obtain the performance of the PROFIBUS medium access protocol. The designed system has been modeled using the CACI Network II.5 software which based on discrete event simulation technique. The performances indices can be easily computed by giving the needed parameters and simulating using the model. The simulation and performance analysis of the designed and modeled system are remained as future works.

References 1. PROFIBUS Specification, International Standard, IEC 61158, April 2000.

2. PROFIBUS Technical Description, PROFIBUS Brochure, No. 4.002, September 1999.

3. PROFIBUS Technology and Application, PROFIBUS Brochure, No.4.0002_v, October 2002.

4. CACI Products Company, “Network II.5 User’s Manual”, Release 12, November 1997.

5. Ekiz, H., DPhil Thesis, “Design, Implementation and 6. 7.

Figure 6: Modeling of the designed systems in Network II.5. Figure 6 shows the modeling of the designed system in Network II.5. The hardware devices use software components of the Network II.5 to create message traffic in the system. The dynamics of the modeled system are characterized by software components which are represented as modules, instructions, messages semaphores. The request and response messages in the PROFIBUS system (detailed in table 1) are created using messages and instructions in the PEs. The semaphores are used for measurement and evaluation of time constraints that are used in the PROFIBUS systems. The software components that were created to obtain PROFIBUS system are located in the modules of related PE in the

8. 9.

Performance Analyisis of CAN/CAN and CAN/Ethernet Bridges”, the University of Sussex, Brighton, May, 1997. Kutlu, A., DPhil Thesis, “Wireless Medium Access Control Protocols for Real-Time Industrial Applicaitons”, The University of Sussex, Brighton, England, 1997. Aydoğan, T., DPhil Thesis, “Bridge Design between WorldFIP and ATM and Interconnecting of WorldFIP and CAN Industrial Networks through ATM” (Turkish), Sakarya University, Sakarya, Turkey, 2005. Kunert, O., Zitterbart, M.: Interconnecting field buses through ATM, Proceedings of the 22nd Conference on Local Computer Networks, LCN, Minneapolis, 1997. Tovar, E., Vasques, F., “Real-Time Fieldbus Communications Using PROFIBUS Networks,” IEEE Trans. On Industrial Electronics, Vol. 46, No. 6, pp. 12411251, December 1999.