Computer Networks and Remote Control Michal KUBÍK Slovak University of Technology Faculty of Informatics and Information Technologies Ilkovičova 3, 842 16 Bratislava, Slovakia kubik_michal@pobox.sk Abstract. This contribution deals with possibility of using computer networks in automation for remote control and brings design of possible solution for remote control calibration workplace that is used for calibration of digital electricity meters. In the first part the differences between local and remote control are explained. The possibility of using various network protocols, which can be used in automation (TCP, HTTP, FTP, SMTP, RDP) is analyzed too. It is important to discern between remote control inside and outside of LAN and related security. 1 Introduction The requirement of quality increase, sharing resources or cost saving, which cause, that control technique is still more and more including information systems, is necessary. Usually, the first step is virtual or whole virtual laboratories, which purpose is control process simulation. In the next step virtual s are substituted with real s and control process are made inside laboratories. This step is kind of preparation for employment control process in real control applications. Computer networks are relatively new part of control technique. They offer possibility of remote control. For operator this fact allows to move away from control process or even to become a mobile and control process from almost any place of the world. Supervisor: Ing. Čičáková Oľga, Department of Measurement, Faculty of Electrical Engineering and Information Technology, doc. Ing. Kotočová Margaréta, Institute of Computer Systems and Networks, Faculty of Informatics and Information Technologies STU in Bratislava M. Bieliková (Ed.), IIT.SRC 2005, April 27, 2005, pp. 84-89.
2 Control possibility Computer Networks and Remote Control 85 In present time it is possible to control process in local or remote mode so these two terms should be explained. Local mode control is the form of control, where the signals are transported by electric conductor, RS234, GPIB, VXI, PROFIBUS etc. Individual parts of working place can be interconnected with each other or with control computer. The control computer controls whole working place [fig. 1]. In this case control computer is only control element in entire system. Very often, in local mode control, all parts of control system are placed near each other. GPIB,VXI Control computer Fig.1. Local control. Remote mode control. Control is becoming remote if a network and next one or more computers are connected to the local control system. After that control computer is called local client and other computers are called remote clients. One of the remote clients can control process. In this case this remote client is called control client [fig. 2]. Some present control s have RJ45 interface and can be connected directly to network. remote client local client network control client GPIB,VXI Fig.2. Remote control. Tab.1. Remote control advantage and disadvantage comparison. Positives of remote mode control Negatives of remote mode control Sharing expensive s High attack risk Real time presentation of control process Access to computer network Possibility to participate on control process Higher primary investment from any place of the world
86 Michal Kubík 3 Control process and network protocols Often requirement in industry is to make real time control or control with at least certain define delay. Although this requirement can not be fulfilled by Internet, network protocols penetrate to this area. The most widely used protocol is TCP. It creates a base for higher application protocols e.g. HTTP, SMTP, FTP HTTP is protocol for transporting web pages. HTTP server can be used for actual values presentation of state values on web pages. For user the advantage of HTTP protocol is in the same way of work as with Internet [2]. SMTP is the most often used protocol for e-mail transport. Besides that, it can be used for states transport occurred during control process. Present PLC s contain SMTP client for delivering data directly to the data part of PLC or in opposite direction from PLC s to operator. FTP protocol is suitable for transporting a big amount of data. For this reason it can be used for technologic process transport. Remote Desktop is next solution for extension of local mode control to remote mode control without any changes made in existing software. With the Remote Desktop your computer can be remotely controlled from another place. It is allowed to use the data, applications, and network resources that are on local client, without being in the same room [4]. 4 Existing solutions Control system development is complicated and expensive work. Companies developing control systems deliver remote control possibility as a small part of whole system. The most widely used products are SIMATIC, Matlab, DataSocket [3]. Existing solution advantage are easy implementation and support. On the other side disadvantage are higher price and more complicated scalability. 5 Design The system was split into tree mutually communicate parts: local client, remote client and server. TCP is used as a network protocol. 5.1 Local client In the present time local client is the system for local control workplace for calibration of digital electricity meters [1]. Local client functions: receiving of commands from the server and their transformation to suitable format for the connected
Computer Networks and Remote Control 87 transformation of data received from to right format suitable for the server and subsequently, sending of transformed data to the server update of list of ports and connected s. 5.2 Remote client Remote client allows remote control workplace. It is necessary to ensure mutual exclusion algorithm for exclusive workplace control, if more remote clients are connected to server at one. The control client is remote client which has got permission to control process. The other clients are called passive clients. They can only watch control process between local client and control client in passive mode. Remote client functions: remote client authentication on the server before control process connection to the local client over the server if it s possible (no other control client) sending and receiving of commands from local client over server preparing of list of commands in the case of batch processing update of list of ports and connected s logout at the end of control process. It is necessary to have an operator for preparation and configuration workplace before calibration. 5.3 Server This part is separated because of the security and better user management. Server functions: remote client s identification and authentication ensure mutual exclusion for remote clients data distribution from the control client to the local client distribution of respond from local client to all remote clients update of list of clients and their activity.
88 Michal Kubík 5.4 Data format As it was mentioned above one of the tasks for local client is data transform from control client to the right and back. Present workplace contains s with different data format. The general data format to abstract from type was designed. General data format TYPE PRIORITY ADDRESS DATA EXTENSION TYPE - data type in field DATA (COMMAND, RESPOND, ERROR, LOGIN, LOGOUT). PRIORITY - message type priority ADDRESS - address. This field is used if field TYPE contains data (COMMAND, RESPOND, and ERROR) DATA - this content field depends on field TYPE (see part COMMAND data type and RESPOND data type) EXTENSIONS - not used in present a) COMMAND data type. This message is from control client to local client sent. COMMAND PARAMETERS DURATION TTSC COMMAND - command code PARAMETERS - command parameters DURATION - command time duration TTSC - time to send command. How many time will be command sent. b) RESPOND data type. This message is from local client to remote clients sent. ICOMMAND RESPOND ICOMMAND RESPOND - (input command) original command for which is respond sent. Fields COMMAND, PARAMETERS and DURATION contain. - respond to command from There are two reasons why original message is sent in RESPOND message 1. Respond from local client is to all remote clients routed. In this message has to be information to which command respond comes. 2. Remote client can in batch mode work and so sent batch of commands sent. Responds one by one with a delay comes and if field PRIORITY is used, then also in different order. In this case all remote clients would have to keep list of commands for which respond wait. This solution disadvantage is that respond can be shorter than command often.
5.5 Remote control over Internet Computer Networks and Remote Control 89 It is assumed, that local client and server will be placed inside of the LAN. Remote clients will be connected from outside of the LAN [fig. 3.]. For remote clients access to LAN is established by VPN. Connection security is made by IPSec on network layer. IPsec works in tunnel mode. Security is the priority of connection so ESP protocol is used. local client server Tunnel passive client Tunnel control client GPIB,VXI LAN Internet Fig. 3. Remote control over Internet. 6 Conclusions This article shortly describes possible remote control process solution and briefly existing commercial solutions in this field. Design describes remote control calibration workplace which is used for calibration of digital electricity meters inside of LAN. It is assumed that the ports for TCP protocol are permitted and access to the LAN will be able only for authorized users. There is also short design of remote control over Internet. In the future the implementation of remote control over LAN should be made, design for remote control over Internet should be finished and implemented. References 1. Skladan, B.: Programové vybavenie pre kalibračné pracovisko s EKS 05-3. Bachelor final project, Bratislava, 2004. 2. Halva, T.: Internetové procesy usnadňují řízení procesů na dálku. Automa, Vol.10, No.4 (2004), 6-7. 3. Integrating the Internet into Your Measurement System. DataSocket Technical Overview. 4. http://www.microsoft.com/slovakia/windows/xp/pro/evaluation/overviews/remotea ccess.asp, 22.03.2005.