A Remote Laboratory for a Basic Course on Control Engineering

The current work presents a remote laboratory for a basic course in control engineering over which several experiments may be performed. The proposed experiments have been carefully selected in order to illustrate the maximum number of concepts learnt in the classroom over a unique plant, a Ball & Hoop system. In this work, Labview has been used to acquire and handle process data whereas OPC technology is used to connect remote servers with webintegrated front-end applications. This choice has been made on the basis that these tools do not require very advanced skills and may be a reasonable approach for a wide range of simple remote laboratories.

INTRODUCTION e-Learning is becoming popular in academic courses due to several reasons such as introducing flexibility or promoting active learning. On the other side, some disciplines (specially scientific and technical ones) cannot be taught without the interaction with scale models where the students have to think how to apply the concepts learnt in the classroom to the real world. Traditionally, this objective has been achieved with hands-on laboratories that required the physical presence of the students. Nevertheless, the irruption of the Internet technologies opens new possibilities by making possible the creation of virtual (when the models only exist in the computers) and remote laboratories (when remote interaction with real equipment is involved). Although virtual/remote laboratories cannot be compared with the physical presence of the students in the laboratory it seems to be the next best thing. Thus, they have become essential in e-Learning education as well as a valuable resource in traditional education.
Unfortunately, building remote laboratories is more complicated that setting up local laboratories. Of course, it is still necessary to configure the equipment to perform the experiment, but, in addition, a remote access infrastructure must be created and properly configured ensuring certain characteristics, such as the integration of different types of traffic (such as process data, multimedia, or configuration parameters), integration within Internet Web Browsers, etc. [3]. When the complexity of a remote laboratory is high, systematic methodologies such as that presented in [1] may be helpful, as they provide some guidelines to build the remote laboratories. However, when the functionality of the laboratory is not so exigent some commercial packages like Matlab or Labview may became a good alternative as they provide different modules that are relatively easy to configure. Namely, Labview (by National Instruments), which was the tool used in the present work, is a software package developed to create test, control and acquisition applications. It does not require high programming skills and it is commonly used in the engineering and scientific communities. Moreover, it provides drivers for a big number of acquisition and control devices as well as a lot of libraries and modules to perform complex functions, including processing acquired data, control algorithms or Internet servers that distribute data to remote applications.
Another matter to consider at the creation of remote laboratories is the cost of the equipment. In general, physical plants are expensive. In addition, remote laboratories require robust plants that must be available during long intervals of time without human interaction what requires a careful design of the remote laboratories in order to show as many concepts as possible maximizing their use.
This work presents a Web based remote laboratory to interact with a Ball & Hoop system. This plant was initially proposed by Prof. Wellstead in [7] to study the control of the oscillations of a liquid in a container when the container is moving and undergoing changes in velocity and direction. The plant consists of a steel ball that is free to roll on the inside of a rotating circular hoop, which is moved by a DC motor. This plant is proposed to create a remote laboratory that it is being used in a basic course on control engineering for electrical and electronics engineers due to its rich dynamics and versatility. On one side it may be used as a simple DC motor, which is one of the most common plants with which the future engineers will have to deal in their future professional live, and on the other side, its interesting dynamics may be used to show more advanced concepts such as resonance or nonminimum phase systems. Moreover, the control of the oscillations of a liquid in a container constitutes an interesting control problem.
Namely, the proposed remote laboratory will include several experiments that cover the following topics: (1) Experimental modelling of a DC motor, (2) speed and position control of a DC motor, (3) study of resonance of the Ball & Hoop system, (4) study of non-minimum phase systems and (5) the study of the analogy between the system and the real problem of controlling the oscillations of a liquid in a container. The laboratory has been implemented with Labview/OPC technology on the server side and an ActiveX control which was integrated on Web pages on the client side. Webcams were also used to provide visual feedback to the students.
The layout of the paper is as follows: Section 2 describes the Ball & Hoop system. The following section outlines the remote access infrastructure. Next section comments the experiments provided by the remote laboratory. The article finishes with some concluding remarks.

II. DESCRIPTION OF THE BALL & HOOP SYSTEM
The Ball & Hoop system was introduced by Prof. Wellstead in [7] when he was studying the control of the oscillations of a liquid in a container which is moving and undergoing changes in velocity and direction. As Figure 1 shows, the Ball & Hoop system simulates the movement of a liquid in a container with a steel ball that is free to roll on the inside of a rotating circular hoop. This system was first thought as a demonstrator to show how control can change the oscillations of the liquid in interesting ways.
Basically, the Ball & Hoop system is composed of the following elements: • A hoop which can rotate with a steel ball on its inner periphery.  The model of the system is described in refs [8,9]. This model, after being linearized and approximated is described by the following differential equations: Where, I a and I b are respectively the moment of inertia of the hoop and the ball, b m and b b are the friction coefficients for the rotation of the hoop and the rolling of the ball, R and r are the radius of the Hoop and the rolling radius of the ball, m is the mass of the ball and g is gravitational constant. θ(t) is the hoop angle, τ(t) is the applied torque and y(t) is the position of the ball inside the hoop.
By using the Laplace transform, the second equation may be represented as a transfer function: Where it is clear that the transfer function has purely imaginary zeroes at s=±j g/R, what provides an interesting behaviour as it will be described ahead.
In our laboratory, the scale model of the ball & hoop was provided by TQ Education. As figure 3 shows this equipment consists of the physical plant (the ball & hoop system and the DC motor that moves it) as well as the instrumentation box. III. REMOTE ACCESS ARCHITECTURE The remote architecture implemented in this case was a simplified version of the general architecture proposed in [1]. Figure 4 shows its main actors.
In this case, the electrical signals generated at the Physical Device (the Ball & Hoop system) were conditioned with an instrumentation box (see figure 3) which is connected to the Application Server via an USB acquisition board. The Application Server is based on Labview, which even though has certain limitations for complex remote laboratories, it is a valuable tool. In fact, Labview is a more than reasonable solution for low complexity remote laboratories and as such it has been adopted extensively. As a consequence, it is easy to find in the literature examples of remote laboratories built with this technology [2,4,5,6]. Labview provides interesting advantages such as providing a great number of modules that solve specific problems for different tasks or a programming language that does not require high programming skills. In our case, the Application Server consisted of a Labview application with three threads responsible for the following tasks:

Manage the acquisition information and produce the control outputs:
This thread treats the acquired signals converting them into engineering units and processes the control algorithms in order to produce a control output. It is also responsible for other tasks such as showing locally the signals in the local graphical interface, logging the data, or generating the alarms. This thread is executed once every sampling rate units of time. 3. Manage the remote access: This thread is responsible for serving data to remote applications. It is based on an OPC server. It will also accept the requests from the remote applications. Finally, Remote Applications are the remote HMI that students' computers will execute inside a Web browser. They were programmed with Visual Basic as ActiveX controls that were integrated within Internet Explorer. This Active X established a connection to the OPC server available at the Application Server who provided the process variables in which remote users were interested. It also allowed remote applications to send request/replay operations in order to execute certain operations with the equipment, involving setting configuration parameters or controller parameters. This application allowed the visualization of downloaded files with the results of previous experiments.
In parallel to Remote Applications, a dedicated Video camera was used in order to provide remote visual feedback to the students, as it was considered essential that the students could see the actions of their operations.

IV. REMOTE APPLICATION
This section describes briefly the functionality of the remote application. This application consists of an ActiveX control embedded in a Web page, which is downloaded from the Application Server. This application allows the students to select from a set of experiments. As pointed out above, all these experiments are performed over only one versatile plant, the Ball& Hoop. After all, this plant may be considered as a DC motor with "something else", the Ball&Hoop dynamics. Thus, remote users may choose from the following experiments: A. Obtaining an experimental model for a DC motor B. Speed control of a DC motor C. Position control of a DC motor D. Analysis of resonance and zeros of transmission A. Experimental model for the DC motor Typically, the relation between the input voltage and the angular speed of a DC motor may be approximately modelled by a first order system. If a pure integrator is added, the angular position may be also obtained, as it is shown in figure 5.  figure 5, it is clear that in order to obtain the model of the motor G (Gain of the motor), T (Time constant) and H (Gain of the tachometer) coefficients must be obtained. Students will have to obtain experimentally these coefficients with a set of diverse experiments as described below:

1) Measuring the gain (G).
This parameter is obtained from the speed of the motor at a permanent state. Obtaining this parameter requires the creation of the following diagram (shown in Fig 6) where Reference is plotted against Speed. This graph also shows the concept of dead band, as students will only see that the DC moves when the reference is over a certain threshold.
This parameter could also be estimated applying the method of least squares. Students should calculate the steady state response of the DC motor (4) and compare it with the analytical expression for the speed response (5).
Then a linear least square problem is proposed. Students should repeat several times the experiment applying different voltage levels, and by using the method of least squares, calculate observation matrix in order to obtain the estimated value for G.  Again, the estimation of the time constant, T, is an interesting problem itself, as the students should choose the best way of tune the least squares method.

3) Measuring the gain of the tacho (G)
This parameter may be easily obtained when the DC motor is spinning at a constant speed. As figure 5 shows, once the speed is known it is possible to obtain the value of H. This has been illustrated in Fig 8, where the students may obtain this parameter from the period of the oscillations. In this case, the gain of the tacho should be estimated by a linear least square method, as the student should have done for the estimation of the gain G.

B. Tuning a speed controller for a DC motor
This experiment consists of the tuning of a PID controller which is provided as a block of Labview software that the students must tune according to certain parameters that will be provided by the instructors. Students may carry out following different approaches, either analyzing the system with simulation tools after obtaining the model from the previous experiment, or by using tuning methods found in the literature, such as Ziegler-Nichols (which is explained in the classroom). It is also interesting that the students compare the behaviour of the plant, when used in open loop (see figure 9) and in close loop with a PID controller (see figure 10) so they may draw some conclusions. Once the students have selected the parameters of the PID controller, they must generate a file that will be left in the Application Server for further evaluation by the instructors.

C. Tuning a position controller for a DC motor
Similarly to the tuning of the PID for controlling the speed, students have to tune the system in order to control the position of the DC motor. In this case a different control strategy will be followed consisting of adding a speed feedback control as shown in figure 11. Figure 11. Tuning the position controller sidroAgain students will have to select the values of the controllers in order to achieve certain specifications required by the instructors.

D. Analysis of resonance and effect of zeros of transmission
This experiment consists of analysing the behaviour of the Ball & Hoop system, that is the relationship between the ball position and the angular position of the hoop, which is obtained with the DC Motor Position Control (see Figure 10). The transfer function that describes this behaviour was written in equation (3).
As part of this analysis it may be interesting to have a look into the Bode diagram (see figure 10) of equation (3). There it can be appreciated how there is a resonance peak situated at 1.44 Hz and a transmission-zero frequency at 1.70 Hz. So, when the motor is under signals of these frequencies the behaviour is interesting to analyse by the students.  Figure 15. Excitation of the system at resonance frequency As described in [8,9] students must compare experimentally the effect of changing the frequencies of excitation of the system. Figure 14 shows the zero transmission effect where as Fig 15 shows the resonance behaviour of the system. V. CONCLUSIONS This paper has presented a remote laboratory with a Ball & Hoop system, and has detailed how this system may be used to complement a basic course on control engineering. The proposed experiments range in different degrees of difficulty and are incremental. Moreover, the system is interesting because of its rich dynamics and the similitude with the real problem of studying the oscillations of a liquid inside a container. It has been implemented using a very popular tool, which does not require high programming skills as Labview is. Remote applications are embedded in Web pages, what provides a familiar interface to students, as they are very familiar with them. The remote laboratory also requires that the students use simulation tools in order to tune the controllers and find the resonance and zeros of transmission frequencies.