**3. Framework proposed based on multitier programming**

Now, we will introduce the software descriptions that are used in the proposed platform.

Figure 3 shows the tiers of the proposed framework called *Teleoption*, which has more performance than a classical telepresence framework application. *Teleoption* allows the interaction between different elements in hardware and software. Furthermore, it is possible to work under the three schemes of telepresence, i.e. teleoperation + telecontrol + teleprogramming.

The top level of the framework is the HTTP server, winsock services, webcam server and RS232 server. The second level of the framework implements the PHP script modules, DLL library and database services. All services can be shared by the VNC Server.

This distribution of software presents great advantages: i) Security in the platform, ii) several ways to transmit information from the hardware.

Fig. 3. Multitier architecture proposed.

Figure 2.B shows a **teleoperation** scheme through the Internet working with a single channel of communication. This channel is used to change the parameters of the controller devices and/or plant. However, the effects of these changes will depend on the server layer. Figure 2.A shows a **telecontrol** scheme through the Internet, in which the two channels of communications are required (closed-loop system), i.e. forward path *Ch1* and feedback path *Ch2*. In this case, it is necessary to maintain the stability of the closed-loop system. A solution to stability problem is that the time dalay must be less than the sampling period

Furthermore, there exists a different interpretation about the **teleprogramming**. One of them is extending the distance between software programmer and the microcontroller or control board. On the other hand, it is possible to programming a remote system using two systems, called the master system and slave system, separated by the communication channel. In

Now, we will introduce the software descriptions that are used in the proposed platform. Figure 3 shows the tiers of the proposed framework called *Teleoption*, which has more performance than a classical telepresence framework application. *Teleoption* allows the interaction between different elements in hardware and software. Furthermore, it is possible to work under the three schemes of telepresence, i.e. teleoperation + telecontrol +

The top level of the framework is the HTTP server, winsock services, webcam server and RS232 server. The second level of the framework implements the PHP script modules, DLL

This distribution of software presents great advantages: i) Security in the platform, ii)

(Jiang et al., 2006) the teleprogramming method is based on teleoperation.

library and database services. All services can be shared by the VNC Server.

several ways to transmit information from the hardware.

Fig. 3. Multitier architecture proposed.

**3. Framework proposed based on multitier programming** 

(Hyrun & Jong, 2005).

teleprogramming.

*Presentation tier*. The HTTP Server is the presentation tier. This tier contains several Web pages with information of the platform services.

Furthermore it includes the instructions and regulation of the platform

*Logic tier*. In this tier, we have the programming layer. Three programming languages are used in the platform: PHP, Visual Basic and SQL. In the logic tier interacts the blocks: *i)* "PHP scripts" (which contain several programs in PHP) , *ii)* the block of the data base MySql and, *iii)* the block of the DLL libraries (designed in VBasic).

*Database tier*. The database tier contains information about of the platform, i.e. the users list, logbook. In fact, logic tier and database tier provide security to platform, since it is possible to use restrictions proportioned by a PHP script. This script allows the use of the platform only if the user has the permission.

*Communication tier*. The platform allow establish several ways of communication with the hardware: i) using *Serial Server Component* (RS232 Server), ii) using Windows sockets (Winsock) or DLL's library, and iii) using the PHP script services (see figure 4).

*Serial Server Component* is a software based RS232 to TCP/IP converter. RS232 Server allows any of the RS232 serial ports on the PC laboratory to interface directly to a TCP/IP network.

On the order hand, also is possible the remote access using the sockets of Windows or DLL's library. The remote user uses its own programs to send instructions to program modules of the platform.

Finally, the platform has modules designed in PHP, here, the remote user can to access to hardware using a Web page of the platform.

Fig. 4. Communication tier.

Web-Based Laboratory Using Multitier Architecture 243

**Computer A** allows establishing a communication both textual and oral between the local and remote user, in such way, this computer provides help on line and uses the following

**Computer B** has the task of sharing several resources through the Internet. The architecture

• TCPComm server. It is a RS232 server, which allows sharing the serial ports (COMM) of the computer. Serial port is used commonly as communication channel between PC and

• WebcamXP. Allow sharing the images from the webcams, these webcams can show the

**Computer C** has an interface with the data acquisition board (DAQ), and does not share any resources on the Web. This computer is only used to share information with Computer B throughout the remote control. Furthermore, this computer protects the access to the plant

The methodology described in the above section is applied to show remote access to the setup of electrical motor located in the IRCCyN laboratory in Nantes France (figure 6), from the

The set-up located at IRCCyN is composed of an induction motor, a synchronous motor, inverters, a real time controller board of dSPACE DS1103 and interfaces which allow to measure the position, the angular speed, the currents, the voltages and the torque between the tested machine and the synchronous motor. The motor used in the experiments has the following values: 1.5 kW normal rate power; 1430 rpm nominal angular speed; 220V nominal voltage; 7.5A nominal current; np = 2 number of pole pairs, with the motor nominal parameters: Rs = 1.633 Ohms stator resistance; Rr = 0.93 Ohms rotor resistance; Ls = 0.142H stator self-inductance; Lr = 0.076H rotor self-inductance; Msr = 0.099H mutual inductance; J = 0.0111/rad/s2 inertia (motor and load); fv = 0.0018Nm/rad/s viscous damping

Furthermore, this laboratory is equipped with the remote technology described above, and can present several time delays that can appear during any real time experiments and are

(experimental equipment) in order to avoid damages caused by unauthorized users.

proposed is installed in this computer. This computer uses the following software:

• ControlDesk. It is a graphical tool for controlling in real-time the equipment.

freeware software:

• LogmeIN. It is ESS software.

equipments.

necessary to analyze:

equipment details.

**5. Experimental setup: Study cases** 

**5.1 Remote experimentation of an electrical machine** 

CIIDIT-Mechatronic laboratory in Monterrey, Mexico.

coefficient. The experimental sampling time T is equal to 200 s.

• Transmission delay thought Internet (TI). • Control algorithm computation (TC). • Sampled time of the Data Acquisition (TS).

• Messenger: Textual communication and webcam.

• Skype: Oral communication, IP Telephony and videoconference.

• Matlab/Simulink. This Software is used typically in control systems.

• UltraVNC server. It is software belonging to the VNC family
