Remote Web operation of an inverted pendulum REV 2007 - www.rev-conference.org 1 Figure 1. Inverted pendulum test rig Remote Web operation of an inverted pendulum Manuel Rodrigues Quintas 1,2 , António Mendes Lopes 1,2 , Carlos Moreira da Silva 1,2 , Paulo Abreu 1,2 and Diego Sá 1 1 Universidade do Porto/Faculdade de Engenharia, Porto, Portugal 2 IDMEC – Pólo FEUP, Porto, Portugal Abstract — This article presents the developments made in the implementation of an inverted pendulum test rig with the possibility to be remotely operated throughout the Web. This laboratory experimental system was chosen due to its intrinsic rich nature in terms of non-linear control theory. It provides an experimental platform to study, develop and test different control strategies and control laws. The article starts with the description of the electromechanical system, including both the mechanical components and the sensing systems. The global architecture of the control system is then presented. The pendulum is controlled by a Personal Computer, using the Real-time Windows software available within the MATLAB/Simulink application. It is then described the graphical interface developed for local operation of the inverted pendulum. The user interacts with the system through this interface that enables the command and monitoring of the system. The interface software was developed using the C# language present in .Net Framework and communicates with the MATLAB/Simulink application through MATLAB Application Type Library. To remotely operate and monitor the system, a Web application was developed, using a server/client architecture. On the client side an application based on JAVA (applet) technology implements the graphical interface with the remote user. On the server side, it was developed a dedicated application using the same hardware/software platform used for the local graphical interface. Finally, the conclusions are presented. Index Terms — MATLAB/Simulink, Real-Time operating system, Remote laboratories, Web application. I. INTRODUCTION An inverted pendulum is a classical mechanical system that has been widely used in the demonstration of theoretical and practical aspects of control theory. The intrinsic non-linearity and unstable characteristics of the inverted pendulum are used to study the problem of stabilization of such systems and to validate different control strategies. Having this in mind, it was developed at the UISPA (“Unidade de Integração de Sistemas e Processos Automatizados”), IDMEC – Pólo FEUP, School of Engineering University of Porto (FEUP), Portugal, an inverted pendulum assembled on a moving carriage powered by an electric motor, having a control architecture totally opened (Fig. 1). The user can interact with the system, locally or remotely (through the internet), using graphical interfaces specifically developed, with identical functionalities. This capability of remote interaction with the system increases significantly the number of potential users, the security conditions and the availability of the system, while enabling an economy of resources. The implementation and the availability of remote experiments and remote laboratories had a large increase during the last few years due to the rapid expansion of Internet and associated technologies. These facts opened a window of opportunity, particularly in teaching institutions, to enlarge their target public, share resources, saving on equipments and human resources, as well as to create an additional motivation to their students. In designing the control system of any physical system, one of the most important aspects to consider lies on the selection of the real-time environment necessary to run the control application. If the hardware is based on personal computers, the main alternatives are the use of real-time operating systems (e. g. QNX, VxWorks, VRTX), real-time extensions for non real-time operating systems such as Windows and Linux (e. g. RTX, Intime, RTLinux, RTAI) or using applications integrating real-time modules with simulation and development environments (e. g. MATLAB/Simulink, LabVIEW). These later programming systems present clear advantages when the main objective is the development of an open control system, where the control algorithms and parameters must be easily modified, simulated, implemented and tested. Furthermore, the development environment that this type of application offers is user-friendly. Typically, they have real-time device drivers to interact with a wide variety of input/output boards and enable the development and/or integration of graphical interfaces, build on other standard environments (e. g. Visual Basic, C/C++, C#).