summer training report -...

27
Summer Training Report 1 College of Computer Sciences and Engineering Computer Engineering Department Summer Training Report - Term 073 Designing and Implementing Remotely Controlled Vehicle for Security Applications KFUPM - Research Institute (Center of Communications and Computer Research) Prepared by: Hamad Ali Hamad Al-Hajri ID# 206501 Advisor: Mr. Hazem Selmi Coordinator: Dr. Basem Al-Madani < September - 2008 > Abstract This report describes the summer training experience in the Center of Communications and Computer Research at KFUPM - Research Institute. I worked in USAD 1 project with a team of two students to design the controlling unit that is installed on a four wheels motorbike and a control station to send the user commands to the Robotic Warrior. In addition, we setup a wireless network to connect the control station with the controlling unit and also we designed the required software that is needed for the digital devices to work properly. In this report I describe all the components of the project and work done on them. Also, I demonstrate some of the software that I develop in this project. Remotely Controlled Vehicle for Security Applications "USAD 1" Hamad Al-Hajri

Upload: truongcong

Post on 21-Mar-2018

215 views

Category:

Documents


3 download

TRANSCRIPT

Page 1: Summer Training Report - student.kfupm.edu.sastudent.kfupm.edu.sa/s200065010/files/COE-399-Final-Report.pdfSummer Training Report 5 Those are the main systems that we designed. However,

Summer Training Report  1

College of Computer Sciences and Engineering

Computer Engineering Department

Summer Training Report - Term 073

Designing and Implementing Remotely Controlled Vehicle for Security Applications

KFUPM - Research Institute

(Center of Communications and Computer Research)

Prepared by:

Hamad Ali Hamad Al-Hajri

ID# 206501

Advisor: Mr. Hazem Selmi

Coordinator: Dr. Basem Al-Madani

< September - 2008 >

Abstract

This report describes the summer training experience in the Center of

Communications and Computer Research at KFUPM - Research Institute. I worked in

USAD 1 project with a team of two students to design the controlling unit that is

installed on a four wheels motorbike and a control station to send the user commands

to the Robotic Warrior. In addition, we setup a wireless network to connect the control

station with the controlling unit and also we designed the required software that is

needed for the digital devices to work properly. In this report I describe all the

components of the project and work done on them. Also, I demonstrate some of the

software that I develop in this project.

Remotely Controlled Vehicle for Security Applications "USAD 1" Hamad Al-Hajri

Page 2: Summer Training Report - student.kfupm.edu.sastudent.kfupm.edu.sa/s200065010/files/COE-399-Final-Report.pdfSummer Training Report 5 Those are the main systems that we designed. However,

Summer Training Report  2

Table of Contents

ACKNOWLEDGMENTS …………………………………………………………………….……….. 4

INTRODUCTION …………………………………………………………………….……….……….. 4

1. WORK PLACE ……….….………….………………………………………………………… 5

2. ACCOMPLISHED WORK ……………………………………………………….…………... 6

2.1 The Robotic Warrior System …………………………………………………………. 8

a) Four Wheels Motorbike …………………………………………...… 8

b) The Server PC …………….….………………………………………. 9

c) Wireless Router …………….…………….…………………………. 10

d) Controlling Unit ………………….…….….…………….….……..… 11

i) Microcontrollers' Board ……………………………………… 12

ii) H-Bridge ………………………………………………………… 14

iii) Relays Board …………………………………………………… 14

e) Actuators …………….………………………………….……………. 16

f) Power suppliers ……………………………..….…………..………… 17

g) Vision devices .……………………………………………..………… 17

2.2 The Control Station …………………………………………………………………… 18

a) Client PC …………………………………..………………………… 18

b) Joystick ……………………………………………………………….. 19

c) Steering Wheel ……………………………………………………… 19

3. PROBLEMS AND SOLUTIONS ………………………………………………………...…… 20

CONCLUSION ……………………………………………………………………………………… 21

REFERENCES ………………………………………………………………………………………… 23

APPENDIXES ………………………………………………………………………………………… 24

A. Progress Report 1 ……….…………………….…………………………………………… 24

B. Progress Report 2 ….………………………………………………………………….…… 25

C. Progress Report 3 …………………….……………………….…………………………… 26

CERTIFICATE ………………………………………………………………………………………… 27

Remotely Controlled Vehicle for Security Applications "USAD 1" Hamad Al-Hajri

Page 3: Summer Training Report - student.kfupm.edu.sastudent.kfupm.edu.sa/s200065010/files/COE-399-Final-Report.pdfSummer Training Report 5 Those are the main systems that we designed. However,

Summer Training Report  3

List of Figures

Figure 1: The project idea …………..…………………………………….………………… 6

Figure 2: The robotic warrior system …………………………………….………………… 8

Figure 3: Four wheels motorbike …………………………………………………………… 8

Figure 4: Server PC …………………………………………………………………………… 9

Figure 5: Server program ……………………………………………………………………. 9

Figure 6: Wireless router ……………………………………………………………………… 10

Figure 7: Controlling unit ……………..……………………………………………………… 11

Figure 8: Microcontrollers' board ……….…………….…………………………………… 12

Figure 9: Microcontrollers' board ……….…………….…………………………………… 12

Figure 10: Microcontrollers' circuit diagram …….….…………………………………… 13

Figure 11: H-Bridge …………………………………………………………………………… 14

Figure 12: Relays board ………………….…………………….…………………………… 14

Figure 13: Controlling unit circuit diagram ……………………………………………… 15

Figure 14: Actuators – acceleration and break …….….……………………………… 16

Figure 15: Actuators – steering motor …………………………………………………… 16

Figure 16: Actuators – camera …………………………………………………………… 16

Figure 17: Actuators – camera …………………………………………………………… 16

Figure 18: Power supplies …………………………….………….………………………… 17

Figure 19: Vision devices …………………………………………………………………… 17

Figure 20: Client program ……………………….……………….………………………… 18

Figure 21: Camera program …………………………….………………………………… 18

Figure 22: Joystick …………………………………………………………………………… 19

Figure 23: Steering wheel …………………….……………………………….…………… 19

Remotely Controlled Vehicle for Security Applications "USAD 1" Hamad Al-Hajri

Page 4: Summer Training Report - student.kfupm.edu.sastudent.kfupm.edu.sa/s200065010/files/COE-399-Final-Report.pdfSummer Training Report 5 Those are the main systems that we designed. However,

Summer Training Report  4

ACKNOWLEDGMENTS The project team wishes to acknowledge the unlimited support of the USAD 1

project supervisors, Dr. Mansour Al-Dajani, Dr. Moustafa ElShafiai and Dr. Abdul-Hafid

Bouharaoua. The team would also like to thank faculty who work previously in this

project, or who attend the final demo of the project. The project team members also

appreciate each other and their fervor during this project.

INTRODUCTION In this report I will explain my role in designing and implementing remotely

controlled vehicle for security applications. I worked in small team of me and Mr.

Mohammed Al-Marouf who is a student in System Engineering Department at KFUPM.

We worked in the Center of Communications and Computer Research (CCCR) at

KFUPM - Research Institute. We started our work in the 5th of July 2008 and finished the

summer training after eight weeks in the 27th of august 2008.

In our summer training, we worked under the supervision of Dr. Mansour Al-Dajani,

who is the director of the center in which we worked. In addition, Dr. Moustafa

ElShafiai and Dr. Abdul-Hafid Bouharaoua advised, directed and monitor us through

whole the training period; and they attended our final demo of the USAD 1 project in

25th of august 2008.

In the training period we designed and solved many systems. The main problems

and systems that we solved and designed are:

• User interface that was installed in the control station (client PC) to send the user

commands to the vehicle.

• Commands (receiver/sender) software that was installed in the server PC to

receive the commands wirelessly from the control station PC and send them to the

control unit through serial connection.

• The hardware of the control circuit that was set in the vehicle besides software that

was installed in the main part of the control circuit which is a PIC microcontroller.

Remotely Controlled Vehicle for Security Applications "USAD 1" Hamad Al-Hajri

Page 5: Summer Training Report - student.kfupm.edu.sastudent.kfupm.edu.sa/s200065010/files/COE-399-Final-Report.pdfSummer Training Report 5 Those are the main systems that we designed. However,

Summer Training Report  5

Those are the main systems that we designed. However, we designed and

prepared some other systems such vision system and power supplying system.

1. WORK PLACE The summer training program was at KFUPM and specifically at the Center of

Communications and Computer Research (CCCR) - Research Institute. The research

institute (RI) plays an important role in the field of research and development at

KFUPM. The RI's projects benefit both the kingdom's private and public sectors. At the

same time, it has responded effectively to provide new research and technical

services as the needs have arisen. The RI is divided into six main centers as the

following:

• Center of Communications & Computer Research (CCCR).

• Center of Economics & Management (CEMS).

• Center of Environment & Water (CEW).

• Center of Engineering Research (CER).

• Center of Petroleum & Minerals (CPM).

• Center of Refining & Petrochemicals (CRP).

The RI's clients are more than 250 clients during the few past years in both fields:

projects and laboratories services. Those clients include big names of international and

local companies and organizations such as Petroleum Energy Center (PEC) - Japan,

Johns Hopkins University - USA, Saudi Arabian Oil Company (Saudi Aramco) - KSA,

Saudi Basic Industries Corporation (SABIC) - KSA, and others.

The Center of Communications & Computer Research (CCCR) which the summer

training program was in it introduces many services to companies and organizations

such as consultations, training and performing projects in communication and

computer areas. The center also contains many labs such as:

Remotely Controlled Vehicle for Security Applications "USAD 1" Hamad Al-Hajri

Page 6: Summer Training Report - student.kfupm.edu.sastudent.kfupm.edu.sa/s200065010/files/COE-399-Final-Report.pdfSummer Training Report 5 Those are the main systems that we designed. However,

Summer Training Report  6

• Communications & Signal Processing Laboratory (CSPL).

• Computer Networking and Information Security Laboratory (CNISL).

• Database & Web Applications Laboratory (DWAL).

• Smart Systems Laboratory (SSL), that "USAD 1" project is done in it.

• E-Business Consultation and Training Unit (eBU).

2. ACCOMPLISHED WORK When we start working in the smart systems laboratory at Center of

Communications and Computer Research, we was asked to finish all required things

that are needed for the USAD 1 project to work properly; by designing and

implementing and testing any software and hardware that required for the project. In

addition we were responsible to coordinate the work of other departments on some

parts of the project.

The USAD 1 project is divided into two main systems. We can name first system as

the robotic warrior system (the vehicle), and the second system as the control station.

The main components of the robotic warrior system is a four wheels motorbike, PC

works as server, wireless router, microcontroller circuit, actuators and power suppliers.

For the control station, the main components are PC works as client, steering wheel

with its pedals and joystick. The following figure will illustrate the idea of the project:

Figure 1: The project idea

Remotely Controlled Vehicle for Security Applications "USAD 1" Hamad Al-Hajri

Page 7: Summer Training Report - student.kfupm.edu.sastudent.kfupm.edu.sa/s200065010/files/COE-399-Final-Report.pdfSummer Training Report 5 Those are the main systems that we designed. However,

Summer Training Report  7

The purpose of this project is to perform a dangers actions or operations by this

vehicle instead of humans. These actions can be (for example) fighting enemies by

weapon, destroying bombs, or any kind of security application. USAD 1 project (in its

current version) is designed to hold and use a weapon and for that we sometimes

called the vehicle with a robotic warrior.

As I mentioned before, I worked in a small team of me and Mr. Mohammed Al-

Marouf. We worked together in all jobs required for the project. However, there were

some parts that done mostly by me and other by him. The software of the

microcontroller and the hardware that related to it were the parts that Mr.

Mohammed Al-Marouf concentrated on, while I concentrated more on installing the

wireless connection and creating software to make a wireless connect between the

two main systems of USAD 1 project. The following list includes all tasks and all activities

that I did in this project:

• Fixing the project components on the bottom wood plate such as PIC microcontrollers, H-Bridge, Relays board and fans.

• Making connections between those components.

• Testing all the connections (wires and cables).

• Fixing the wireless router and the server PC parts on the upper wood plate.

• Installing and configuring the wireless components such as the wireless network adapter and the wireless router.

• Testing all the connections.

• Writing a program that deal directly with the PIC microcontroller through serial cable (visual basic language).

• Writing programs to make a wireless connection between the client PC and the server PC (visual basic language).

• Modifying the code of those programs, so that the joystick and the steering wheel can be used now to perform actions.

• Installing and configuring the cameras program.

• Fixing the power supplies system, cameras and the DC to AC converter.

• Testing the project, again.

Remotely Controlled Vehicle for Security Applications "USAD 1" Hamad Al-Hajri

Page 8: Summer Training Report - student.kfupm.edu.sastudent.kfupm.edu.sa/s200065010/files/COE-399-Final-Report.pdfSummer Training Report 5 Those are the main systems that we designed. However,

Summer Training Report  8

In the following sections I will give detailed descriptions and explanations about

each part of the main systems of the USAD 1 project and the work done on it.

2.1 The Robotic Warrior System 

This part of the USAD 1 project is much bigger and more complicated than the

other, figure 2. The main objective of our work in this

project is to remotely control all functions of this system

through wireless medium. The most important functions of

that system are the ability of carrying some kind of

weapon with good aiming to the targets, the ability to

move with high maneuverability and the ability to give a

good vision for the surrounding environment to the

controller. To this functions and achieving the project

objectives we built this system with the following

components.

a) Four Wheels Motorbike 

The Robotic Warrior System was built on a four whe

facilitate its movement. The objective of using this kind

system a high maneuverability. Also this

vehicle is capable to be derived on

ordinary or rugged ways. In addition, its

speed, size, power and durability make it

more suitable for our project than the other

choices. However, using this motorbike is not

better than design a special vehicle that

satisfies all the requirement of this project;

but the long time, much of effort and the high cost tha

build such vehicle make this choice undesirable.

Remotely Controlled Vehicle for Security Applications "USAD 1

Figure 2: The robotic warrior system

el motorbike, figure 3, to

of vehicle is to give the

e

Figure 3: Four wheels motorbik t needed to design and

" Hamad Al-Hajri

Page 9: Summer Training Report - student.kfupm.edu.sastudent.kfupm.edu.sa/s200065010/files/COE-399-Final-Report.pdfSummer Training Report 5 Those are the main systems that we designed. However,

Summer Training Report 

ri

9

The Work Done on This Motorbike: This motorbike was sent to the mechanical

workshop to change and add some parts that facilitate controlling the motor and

make fixing the electronic components possible. First thing they take out the seat

and attach a metal plate. Then they fix two sticks to carry the vision devices and

the w

b) Server PC 

portant

parts are fixed such as motherboard, power

isk drive and CD – Rom drive

while

en the operating system

(windo

eapon. Also they put carrier for the two servo motors that are responsible for

holding and releasing the break and accelerator pedals; and connecting these

pedals to the servo motors by metallic wires. In addition they set a holder for

steering motor and place gear disk under the steering wheel to connect the

steering wheel with the steering motor.

The server PC is disassembled and then fixed on the upper wood plate in the

motorbike as it appears in figure 4. Im

supply, hard d

some parts are ignored to save a space

on the wood plate such as floppy disk drive.

This PC is connected to the wireless router by

an Ethernet cable and also connected to the

PIC microcontroller by a serial cable through

COM1 port.

The server/client programs are written by v

Microsoft Visual Basic 6.0. The server

program works automatically in the

server PC wh

isual basic language and by using

Figure 4: Server PC

ws) starts. This program keeps

listening until it receives a connection

request from the client PC (figure 5).

After the server program accepts this Figure 5: Server program

Remotely Controlled Vehicle for Security Applications "USAD 1" Hamad Al-Haj

Page 10: Summer Training Report - student.kfupm.edu.sastudent.kfupm.edu.sa/s200065010/files/COE-399-Final-Report.pdfSummer Training Report 5 Those are the main systems that we designed. However,

Summer Training Report  10

Figure 6: Wireless router

on"

which

server

PC. Th

c) Wireless Router 

outer (SpeedTouch 585 v6) figure 6, as mention before is

conne

ed by "WPA-PSK" to make this

request, the client PC can now sends commands to the server PC and the server

PC itself receives those commands, transfers them to COM1 port to the PIC

microcontroller that executes those commands.

By knowing the IP address of the server PC, "Remote Desktop Connecti

is a program under Windows operating system, can be used to access the

server PC wirelessly from the client PC. This program is very helpful feature to make

any necessary corrections of problems that may happen in the server PC.

The program that is dealing with videos transmission is installed in the

is program is called "CamGuard Security System" and its version is 4.0.12.133.

It is required to be installed only on the server PC, because the user can see the

videos in the client PC without installing this program again in the client PC.

The wireless r

cted to the server PC by an Ethernet

cable and it has the following static IP address:

192.168.1.64. The power cable of the router is

connected to the DC to AC converter. The

wireless standard of this router is IEEE 802.11 (g)

which works in the 2.4 GHz band with a

maximum bit rate of 54 Mbit/s and an

approximately maximum coverage range of 38

meters (Indoor). The wireless network is encrypt

network more secure. WPA is a more powerful security technology for WiFi

networks than Wired Equivalent Privacy (WEP). It provides strong data protection

by using encryption as well as strong access controls and user authentication. WPA

utilizes 128-bit encryption keys and dynamic session keys to ensure your wireless

network's privacy and enterprise security. There are two basic forms of WPA: WPA

Enterprise and WPA Personal (WPA-PSK). WPA-PSK is basically an authentication

mechanism in which users provide some form of credentials to verify that they

Remotely Controlled Vehicle for Security Applications "USAD 1" Hamad Al-Hajri

Page 11: Summer Training Report - student.kfupm.edu.sastudent.kfupm.edu.sa/s200065010/files/COE-399-Final-Report.pdfSummer Training Report 5 Those are the main systems that we designed. However,

Summer Training Report  11

should be allowed access to a network. This requires a single password entered

into each WLAN node (wireless routers for example). As long as the passwords

match, a client will be granted access to a WLAN. WEP is sometimes inaccurately

referred to as Wireless Encryption Protocol. The "SpeedTouch" management

interface is reachable by two ways: either by the Internet Explorer or by using the

telnet through command prompt. This management interface enables the user to

configure and control many features and many properties of the wireless router.

Figure 7: Controlling unit

d) Controlling Unit 

unit in the Robotic Warrior System is responsible to recognize

the us

is

comp

rs for conn nents.

The controlling

er command then carry out them by

sending the suitable signal to the various

actuators of the Robotic Warrior System.

Moreover, this unit must monitor the system

performance and take the appropriate

action in some specific cases like losing the

connection with the control station.

The controlling unit, figure 7,

osed of microcontrollers' board, H-

bridge, relays board and electrical connecto

The microcontroller is the intelligent part in this unit. It is responsible to recognize the

received command and send a various signals to the right actuators. Moreover, it

is the intelligent unit that has to take the appropriate action once an emergency

case occurs. The H-bridge controls the power delivered to the steering motor by a

PWM signal that is generated from the microcontroller. The last component of the

controlling unit is the relays board. It has sixteen relays work as on/off switches that

can be controlled by digital signal from the microcontroller.

ection those compo

Remotely Controlled Vehicle for Security Applications "USAD 1" Hamad Al-Hajri

Page 12: Summer Training Report - student.kfupm.edu.sastudent.kfupm.edu.sa/s200065010/files/COE-399-Final-Report.pdfSummer Training Report 5 Those are the main systems that we designed. However,

Summer Training Report  12

Figure 8: Microcontrollers' board Figure 9: Microcontrollers' board

i) Microcontrollers' Board

We have used two microcontrollers. They are PIC 18F452. Each

microcontroller is fixed on a flash lab board. And we fixed those two flash lab

boards with electrical connectors on one bigger board to facilitate the

connectivity to the microcontrollers, figure 8 and 9.

One of those microcontrollers receives the commands from the server

PC through RS232 serial connection. This microcontroller is considered as a

master microcontroller whiles the other as slave. The master microcontroller

receives the commands from the server PC; and recognizes these

commands and takes the appropriate actions or delivers them to the slave

microcontroller if they are related to the two servo motors and the steering

motor. In addition, the master microcontroller is responsible about

preventing the occurrence of any type of contradiction between the

currently running functions. Moreover, this microcontroller monitors the

connectivity status with the control station and the continuity of receiving

updates for the various functions from the control station and trying to save

the system from collision when the control is lost because of losing the

connectivity with control station.

Remotely Controlled Vehicle for Security Applications "USAD 1" Hamad Al-Hajri

Page 13: Summer Training Report - student.kfupm.edu.sastudent.kfupm.edu.sa/s200065010/files/COE-399-Final-Report.pdfSummer Training Report 5 Those are the main systems that we designed. However,

Summer Training Report  13

The other microcontroller works as slave under the managing of the

master one. The slave microcontroller is responsible to generate pulses that

are needed to operate the servo motors and the steering motor. Those

pulses are generated through a software functions instead of using the PWM

generator hardware, because this generator has no enough channels and

its pulse period is too short than the required one. Also these functions are

created in speared microcontroller to obtain higher accuracy in generating

the required pulses. It is clear that generating a software pulses in

microcontroller that carrying out a

long program will end with

decreasing the accuracy of the

pulses.

The master microcontroller is

connected to the PC through 9 pins

serial port. This connection is used to

program the microcontroller and to

send the command to the controller.

In the slave microcontroller, the same

connector is used only for

programming it; and direct

connection between the master and

slave under the SPI serial connection

protocol is used to carry the

commands from the master to slave

microcontroller. The user should note that when he wants to program the

master microcontroller he must place a jumper in the reset pins to connect

them and remove it when he want to send a normal command under the

RS232 protocol. The position of the reset jumper and schematic diagram of

the micro controller circuit is shown in the figure 10. This diagram shows the

orientation of the connection terminals of the two microcontrollers. In this

board there is voltage regulator. It gets 12 volt input and gives 5 volt output.

The

Ports of

the

Master

PIC

The Ports of the

Slave PIC

Figure 10: Microcontrollers' circuit diagram

Remotely Controlled Vehicle for Security Applications "USAD 1" Hamad Al-Hajri

Page 14: Summer Training Report - student.kfupm.edu.sastudent.kfupm.edu.sa/s200065010/files/COE-399-Final-Report.pdfSummer Training Report 5 Those are the main systems that we designed. However,

Summer Training Report  14

These power terminals is separated from the microcontroller power

connectors that are connected to the main 12 V power supply. However,

the ground connectors are common with all devices in the board.

Figure 11: H-Bridge

ii) H-Bridge

To derive and control the steering motor, an H-Bridge board is used.

This device control the current following to

the motor according to the signal received

from the microcontroller. The microcontroller

sends pulses with period of 20 mille second.

These pulses are changing periodically

between 0 and 5 volts. As the average of

the received pulses increased the H-bridge

raises the supplied current to the steering

motor.

This kind of H-bridge has several operation modes. The mode that was

used in this project was the analog mode. The H-Bridge recognizes the

digital pulses from the microcontroller as analog input by obtain the

average of these pulses, figure 11.

Figure 12: Relays board

iii) Relays Board

The relays were used as switches that can be controlled electronically

to replace the manual of the

motorbike. In addition, some relays

were used to control the motion of

the turning/tilting metal boxes.

The relays board that was used

has 16 relays. Each relay can be

controlled by logic signal. To control

these relays a 20 pins cable connects

the input port in the relays board and

Remotely Controlled Vehicle for Security Applications "USAD 1" Hamad Al-Hajri

Page 15: Summer Training Report - student.kfupm.edu.sastudent.kfupm.edu.sa/s200065010/files/COE-399-Final-Report.pdfSummer Training Report 5 Those are the main systems that we designed. However,

Summer Training Report  15

Figure 13: Controlling unit circuit diagram

Work done on the controlling unit We start by testing and recognizing the

opera

the port B and port D in the master microcontroller. Each one of these 16

pins in the microcontroller sends signals for one of those relays, figure 12.

tion of each device in the controlling unit. Then we worked in developing the

software for the two microcontrollers. Finally, we worked in the connection

between the various parts of the controlling unit. Figure 13 shows the schematic

diagram of the controlling unit.

Remotely Controlled Vehicle for Security Applications "USAD 1" Hamad Al-Hajri

Page 16: Summer Training Report - student.kfupm.edu.sastudent.kfupm.edu.sa/s200065010/files/COE-399-Final-Report.pdfSummer Training Report 5 Those are the main systems that we designed. However,

Summer Training Report  16

Figure 14: Actuators – acceleration

Figure 15: Actuators – steering motor

e) Actuators 

Different types of actuators were used in the Robotic Warrior System. To

holding and releasing the breaker and the

accelerator pedals, two servo motors were used.

The servo motor works depending on the signals

received from the microcontroller. These signals

have to have period of 20 millisecond and duty

time of one millisecond to two milliseconds.

According to the received signal, the servo

motor changes the angle of its pulley. This, in

turn, changes the position of the breaker or the

accelerator pedals. The pulley of each servo motors has range of movement of

180 degrees. The servo motors used were GWServo S777/6BB, figure 14.

To turning the handlebars of the motorbike, a high current DC motor was

used. This DC motor is fixed under the handlebars. Its speed and motion direction is

controlled by the current provided from the H-Bridge. The servo name is "Parvalux",

6 A and 12 DC volts shown in figure 15. Other actuators are the turning/tilting metal

boxes. The main function of these actuators is to carry the vision device and the

weapon and aiming those to specific points by turning or tilting its upper part. Each

one of these turning/tilting boxes is controlled by four relays. The turning/tilting

boxes appear clearly in figures 16, 17.

Figures 16, 17: Actuators – camera

Remotely Controlled Vehicle for Security Applications "USAD 1" Hamad Al-Hajri

Page 17: Summer Training Report - student.kfupm.edu.sastudent.kfupm.edu.sa/s200065010/files/COE-399-Final-Report.pdfSummer Training Report 5 Those are the main systems that we designed. However,

Summer Training Report  17

Figure 18: Power supplies

f) Power Suppliers 

To providing the required power, a high current +12V and tow 6V batteries

(two 6 V are parallel connected) were used. Moreover, DC to AC Inverter was

used to generate an alternative current of 220V to supply the PC and wireless

router. This DC to AC power inverter takes DC input voltage between 10 to 15 volts

and gives 220 volts as an AC output voltage. Also, it has a continuous output

power of 500 watts. All these power suppliers are shown in figure 18.

Figure 19: Vision devices

g) Vision Devices 

Vision devices in this project are the cameras. There are two cameras fixed

on the motorbike. The first camera (front camera) is

used to see the destination and the surrounding

areas of the motorbike, while the second camera

(weapon camera) which is in a higher level than the

first one, is used for the weapon. Both cameras are

from the type "Creative PC-CAM 350" as shown in

figure 19.

The cameras are connected to the server PC by USB cables. Videos are

transmitted to the client PC wirelessly by using "CamGuard Security System"

program (UDP Protocol).

Remotely Controlled Vehicle for Security Applications "USAD 1" Hamad Al-Hajri

Page 18: Summer Training Report - student.kfupm.edu.sastudent.kfupm.edu.sa/s200065010/files/COE-399-Final-Report.pdfSummer Training Report 5 Those are the main systems that we designed. However,

Summer Training Report  18

2.2 The Control Station 

a) Client PC 

The client PC is a normal desktop PC that is connected to "BelKin" USB

wireless 802.11 (g) adapter. This adapter will enable

the client PC to communicate wirelessly with the

server PC. The client program as shown in figure 20

requires from the user to enter the IP address of the

server PC. After entering the IP and pressing button

"Connect", a connection request will be send from

the client PC to the server PC. If there are no errors

and the server PC accepts the request, a message

"Now you are connected to USAD Server" will

appear in the title bar of the program.

There are two versions of the client program:

standard version (using buttons only) and steering

wheel and joystick version. This gives a choice for

the user to choose the version he wants.

Video can be viewed in the client PC monitor through an Internet Explorer

window by written in the URL

the IP address of the server

PC followed by ":" and then

the specified port number in

the setting of the camera

program. Figure 21 shows

the videos in the client PC

screen.

Figure 20: Client program

Figure 21: Camera program

Remotely Controlled Vehicle for Security Applications "USAD 1" Hamad Al-Hajri

Page 19: Summer Training Report - student.kfupm.edu.sastudent.kfupm.edu.sa/s200065010/files/COE-399-Final-Report.pdfSummer Training Report 5 Those are the main systems that we designed. However,

Summer Training Report  19

b)  Joystick 

In the client program (joystick and steering wheel version), the x and y

coordinates of the joystick are very important to perform actions in USAD 1 project.

The joystick of type "Genius" has 8 buttons, and for every button there is a specific

value for it. The joystick is responsible for controlling the turning/tilting boxes. For

example if the joystick is moved to the right, then the x

value will increase and if the joystick is moved to the left,

then the x value definitely will decrease. Similarly, the

same things repeated here for the y value and the

movement of the joystick (forward/backward), figure 22.

Depending on the x and y coordinates and on the

programming conditions in client program, some actions

will be performed if the joystick is moved to a specific

direction. If the user moves the joystick to the right, then

the turning/tilting box will turn to the right. However, if the

user moves the joystick to the left, then the turning/tilting box will turn to the left

and so on. Selecting any one of the turning/tilting boxes (one for front camera and

the other for weapon camera) can be done through the joystick buttons.

Figure 22: Joystick

c) Steering Wheel 

The same scenario of the joystick applies

here, turning the wheel will change the x

coordinate and pressing the pedals will change the

y coordinate. The "Genius" steering wheel is

responsible for three things in the USAD 1 project:

acceleration, steering and breaking. Steering is

done by turning the steering wheel to the right or to

the left whereas the acceleration and the break

can be performed by using the pedals, figure 23.

Figure 23: Steering wheel

Remotely Controlled Vehicle for Security Applications "USAD 1" Hamad Al-Hajri

Page 20: Summer Training Report - student.kfupm.edu.sastudent.kfupm.edu.sa/s200065010/files/COE-399-Final-Report.pdfSummer Training Report 5 Those are the main systems that we designed. However,

Summer Training Report  20

Different speeds of the steering can be achieved through the speed wheel

buttons.

3. PROBLEMS AND SOLUTIONS There are several problems and challenges we face during the project period.

Some of these problems are:

• Problem: Inability to communicate with the Rabbit microcontroller (which we

were using it before PIC microcontroller) due to connectivity problem in the

connector cable and this cable is not available in the local market.

• Solution: This problem was solved by using PIC 18F microcontroller that is

available in the System Engineering Department and we also agree that the

Rabbit microcontroller which we have is not suitable for this project.

• Problem: Insufficient number and the short period of PWM channels in the

PIC 18F microcontroller.

• Solution: To solve the problem of the short period of the PIC 18F we created

three programmed PWM channels for controlling the tow servo motors and

the steering motor. However, the programmed PWM channel is so accurate

especially with big programs. To decrease the affects of this problem we

used two PIC 18F microcontrollers. One of these microcontrollers, which is the

slave one, was dedicated for controlling the two servo motors and the

steering motors only, and the other one, which is the master one, for

performing the rests tasks.

• Problem: Inability to Connect the PIC Microcontroller directly to the Wireless

Router.

• Solution: We connect the PIC microcontroller to the server PC on the USAD

motorbike. We used the RS232 serial connection as a medium of the

communication. In this case the server PC will receive the commands from

Remotely Controlled Vehicle for Security Applications "USAD 1" Hamad Al-Hajri

Page 21: Summer Training Report - student.kfupm.edu.sastudent.kfupm.edu.sa/s200065010/files/COE-399-Final-Report.pdfSummer Training Report 5 Those are the main systems that we designed. However,

Summer Training Report  21

the control station through wireless connection. Then, these commands are

sent to the master PIC microcontroller. In addition, the master microcontroller

controls the servo motors and the steering motor by sending the commands

to the slave microcontroller to the through SPI serial communication.

CONCLUSION At the end of our training period we finished our assignments. We presented and

made a demo for our work in the last day of the training. That demo showed that we

successfully did all the assignments. In general, in this project we tried to reach the

highest quality as much as we can, while we maintain a low cost and short time.

By completing all of our assignment, the first phase of the USAD project has been

completed. The second phase of this project which will be USAD 2 will start from the

base of our work and will take our comments and suggestion in account.

I have learned many things in this training period and I got a lot of experiences.

That can be summarized in the following points:

• Get experience in dealing with projects that are used in the real world-working

environment.

• Improved my ability in taking responsibility of a given works and projects.

• Improved my ability in finding problems solutions.

• Improved my ability in self-learning.

• Improved my ability in working under the pressure and short of time.

• Improved my ability in working within a team.

• How to communicate with the employees from different departments.

• Improved my knowledge in PIC microcontrollers.

• Getting familiar with visual basic language which is a new programming

language for me.

• Improved my knowledge by working with the different components of the

project such as relays board and actuators.

Remotely Controlled Vehicle for Security Applications "USAD 1" Hamad Al-Hajri

Page 22: Summer Training Report - student.kfupm.edu.sastudent.kfupm.edu.sa/s200065010/files/COE-399-Final-Report.pdfSummer Training Report 5 Those are the main systems that we designed. However,

Summer Training Report  22

Beside all the above experiences, it was the first time to do a complete project

and dealing with some issues that not related directly to my major like the mechanical

issues in this project.

In fact, I benefit a lot from COE courses in the summer training, specially

networking courses such as COE 344 (computer networks), COE 441 (local area

networks) and COE 446 (mobile computing). Also, I benefit a lot from course COE 400

(system design laboratory) that is closer to what I took in the summer training. We

learnt design, implementation, debugging, and documentation of a system and here

in the summer training, we did the same thing.

Really, the summer training period goes very fast and I really enjoyed it. A lot of

knowledge, experiences, stresses, and challenges during this few weeks. I found that

these weeks are valuable and full of knowledge, experiences, and relationships which

can be gained from the real work environment and its challenges.

I would like to suggest that before starting the summer training or the coop

program, a meeting should be done between the students and the coordinator to

prepare the students before they surprise with real life work. Regarding the courses, I

think that it will be useful if the student take COE 400, COE 344 and any other elective

network course before going to the summer training or the coop since it is used a lot in

the real life.

Remotely Controlled Vehicle for Security Applications "USAD 1" Hamad Al-Hajri

Page 23: Summer Training Report - student.kfupm.edu.sastudent.kfupm.edu.sa/s200065010/files/COE-399-Final-Report.pdfSummer Training Report 5 Those are the main systems that we designed. However,

Summer Training Report  23

REFERENCES 1. The Research Institute Annual Report (2005-2006).

2. www.kfupm.edu.sa/ri

3. www.wikipedia.org

4. www.thetech.org

5. http://computer.howstuffworks.com

6. www.microsoft.com

7. www.dslreports.com

Remotely Controlled Vehicle for Security Applications "USAD 1" Hamad Al-Hajri

Page 24: Summer Training Report - student.kfupm.edu.sastudent.kfupm.edu.sa/s200065010/files/COE-399-Final-Report.pdfSummer Training Report 5 Those are the main systems that we designed. However,

Summer Training Report  24

APPENDIXES A. Progress Report 1

Remotely Controlled Vehicle for Security Applications "USAD 1" Hamad Al-Hajri

Page 25: Summer Training Report - student.kfupm.edu.sastudent.kfupm.edu.sa/s200065010/files/COE-399-Final-Report.pdfSummer Training Report 5 Those are the main systems that we designed. However,

Summer Training Report  25

B. Progress Report 2

Remotely Controlled Vehicle for Security Applications "USAD 1" Hamad Al-Hajri

Page 26: Summer Training Report - student.kfupm.edu.sastudent.kfupm.edu.sa/s200065010/files/COE-399-Final-Report.pdfSummer Training Report 5 Those are the main systems that we designed. However,

Summer Training Report  26

C. Progress Report 3

Remotely Controlled Vehicle for Security Applications "USAD 1" Hamad Al-Hajri

Page 27: Summer Training Report - student.kfupm.edu.sastudent.kfupm.edu.sa/s200065010/files/COE-399-Final-Report.pdfSummer Training Report 5 Those are the main systems that we designed. However,

Summer Training Report  27

CERTIFICATE

Remotely Controlled Vehicle for Security Applications "USAD 1" Hamad Al-Hajri