CS6510 Dissertation Final Report Communication between ...hwchun/FYP/2004/Albert Chung.pdf ·...

32
1 CS6510 Dissertation Final Report Communication between Mobile Device and AI Robot Supervised by: Dr Andy Chun, Associate Professor Department of Computer Science City University of Hong Kong By Chung Yan Kit, Albert (Student ID: 50355532) Date: Dec 07 2004

Transcript of CS6510 Dissertation Final Report Communication between ...hwchun/FYP/2004/Albert Chung.pdf ·...

Page 1: CS6510 Dissertation Final Report Communication between ...hwchun/FYP/2004/Albert Chung.pdf · CS6510 Dissertation Final Report Communication between Mobile Device and AI Robot Supervised

1

CS6510 Dissertation

Final Report

Communication between Mobile Device and AI

Robot

Supervised by:

Dr Andy Chun, Associate Professor

Department of Computer Science

City University of Hong Kong

By

Chung Yan Kit, Albert

(Student ID: 50355532)

Date: Dec 07 2004

Page 2: CS6510 Dissertation Final Report Communication between ...hwchun/FYP/2004/Albert Chung.pdf · CS6510 Dissertation Final Report Communication between Mobile Device and AI Robot Supervised

2

I. Introduction ............................................................................................. 3 (1) Background:...................................................................... 3 (2) Objectives........................................................................ 4 (3) The usefulness of the topic.................................................... 5 (4) Potential outcome .............................................................. 6

II. Related work...........................................................................................18 (1) Techniques for Web Telerobotics ............................................ 18 (2) Remote Robot Control via Everyday Devices .............................. 19 (3) Html Web Interface for ER1 .................................................. 19

III. System modeling and structure ....................................................................20 IV. The methodology and algorithms used in the design/implementation of the system......................................................................................................23

Client / Server Architectures..................................................... 23 Internet-Enabled Client-Server .................................................. 23 Real-time remote-access control ................................................ 23 Socket programming ............................................................... 24 Fast Fourier transformation ...................................................... 24 Robot Control Architectures ...................................................... 24 Implementation & Outcome ...................................................... 24

V. Preliminary performance analysis of algorithm/system ........................................27 Findings ....................................................................................................28 Future forecast ...........................................................................................28 VI. Conclusion.............................................................................................29 VII. References............................................................................................30

Page 3: CS6510 Dissertation Final Report Communication between ...hwchun/FYP/2004/Albert Chung.pdf · CS6510 Dissertation Final Report Communication between Mobile Device and AI Robot Supervised

3

I. Introduction

(1) Background:

The word of “Robot” came up in 1921, the first robot was invented in 1960, robot

became popular since 1980[P1, AR]. Remoted-controlled arm designed for Atomic

Energy Commission in 1951 [P.7, RI].

Before the design or implement of a robot, every engineer, programmers should

keep in mind that the following three rules by a famous science fiction writer Isaac

Asimov,

Asimov’s Three Laws of Robotics:

1) A robot may not injure a human being, or, through inaction, allow a human

being to come to harm.

2) A robot must obey orders given it by human beings, except where such orders

would conflict with the First Law.

3) A robot must protect its own existence as long as such protection does not

conflict with the First or Second Law [P.7, RI].

Otherwise bad things could really happen like in the movie Matrix, Matrix reloaded,

Matrix Revolution and iRobot [However in iRobot, it bought us to think deeply that

these laws may have fatal flaw].

In 2003, 2 space projects uses similar rover Pathfinder to do research in Mars (first

one landed in 1997), Sony QRIO and Honda Asimo have demonstrate their humanoid

robots around the world. In summary of fields that can use robot are include space

Page 4: CS6510 Dissertation Final Report Communication between ...hwchun/FYP/2004/Albert Chung.pdf · CS6510 Dissertation Final Report Communication between Mobile Device and AI Robot Supervised

4

projects, military spy airplanes, deep sea searching submarine robot for the

discover of Titanic, medical surgery, fire extinguish robots, oil tank cleaning robot,

bomb disassembly, tiny blood vein investigation robot. In general, robots are use to

perform dangerous task and professional task. There are commercial use robots,

machine arm in factory assembly line, disk washer, microwave,…etc., are also some

forms of robot. In 2004, popular ones are Vacuum robot, robot pet, robot guard,

humanoid servant.

To build or to program a robot is very simple. Motors, sensors, actuators, body parts

and a processor; putting everything together, program the software that comes with

the package or some vendor’s API then the robot can do many things. For example, a

LEGO MindStorm Robotic system is a toy robot that can perform many tasks; ER1

from Revolution Co. is a professional robotic system. These two systems are the

basic platform uses for this paper. Communications can be classified into at least 5

types which include inter-robot, human-robot, computer-robot, Web-robot, mobile

device-robot. The tools that can be use for communications are USB cables, sensors,

microphone and speakers (voice recognition), view or web cam (object recognition),

Wireless 802.11a/b/g/n, WiMAX, Radio Frequency, Inferred, Bluetooth, Internet, 3G

telephone network The discussion of their different are in section 3.

(2) Objectives

This paper is all about using mobile phone to communicate with Robot.

The goal is to develop an Internet application that allows users to communicate with

a robot through mobile phone web browser.

Page 5: CS6510 Dissertation Final Report Communication between ...hwchun/FYP/2004/Albert Chung.pdf · CS6510 Dissertation Final Report Communication between Mobile Device and AI Robot Supervised

5

(3) The usefulness of the topic

Wire, USB cable, Inferred, Radio Frequency, Bluetooth, wireless 802.11a/b/g, 3G

WCDMA are all available methods of remote control up to this day at Hong Kong.

Wire and USB cable are not convenient because of the physical wire connected.

Inferred does not allow anything block in between the sender and receiver because

it is a light form. RF, Bluetooth and wireless 802.11a/b/g are radio frequency, there

are federation rules on using RF, it is hard to use RF protocol with computer since it

is not design for it, wireless 802.11a/b/g are suitable for this project, it has long

range support but high power consumption for notebook computer. Bluetooth has

low power consumption but short range active 10 meter class 2 (class 1 would be

100m) [BFJ]. Both way are suitable for robot side notebook computer adaptor. If

longer range is preferred then use wireless 802.11/a/b/g. If the battery

consumption is concerned then use Bluetooth LAN setting instead, but the

performance will be degraded because of the bandwidth different. 3G WCDMA

covers almost the whole city of my living region Hong Kong which implies that I

almost have no limitation on the access distance and the power consumption is

relatively close to Bluetooth, it is the best choice of platforms for remote

controlling a robot.

Apply this technology to other home appliance, remote start an air-conditioning

before arrives home during the hot summer, remote turn off the electric oven that

you forget to turn off, remote door lock of your BMW, remote your car to pick you up

if the law permit, and all of these features are done by your handy cellular phone.

Page 6: CS6510 Dissertation Final Report Communication between ...hwchun/FYP/2004/Albert Chung.pdf · CS6510 Dissertation Final Report Communication between Mobile Device and AI Robot Supervised

6

(4) Outcome

Application software:

An Internet application specialized for Mobile phone and let user communicate to

Robot ER1.

The software would make use of Socket programming technique, Java 2ME(Not

suitable due to 3G phone hardware limitation), Servlet (Mainly), give up Python(Too

slow), ER1 control center, iVista 4.0(for testing only), webcamXP (javascript format

output), Tomcat Web Server(for Servlet), LeJos (for MindStorm testing only),

XML(not necessary), xhtml (application worked well even in normal html), WAP

Gateway(Not necessary after research), wml(for testing only).

Servlet handle the server side process, it accepts input from HTML form then

translate and send command to ER1 API control center. Below is the sample coding:

import javax.servlet.http.*;

import javax.servlet.*;

import java.io.*;

import java.net.Socket;

public class ER1ControllerServlet extends HttpServlet {

String address = "127.0.0.1";

int port = 9500;

Socket socket = null;

boolean _verbose = true;

DataOutputStream write_stream = null;

BufferedInputStream read_stream = null;

Thread _connect_wait = null;

Page 7: CS6510 Dissertation Final Report Communication between ...hwchun/FYP/2004/Albert Chung.pdf · CS6510 Dissertation Final Report Communication between Mobile Device and AI Robot Supervised

7

boolean _more_data = false;

//name in request scope of the er1 command

private static final String reqParamName = "er1Command";

//name in request scope of the er1 command

private static final String reqPageRedirectName = "pageRedirect";

//command we will execute if for some reason the request

//parameter containing the command is not available

private static final String defaultCommand = "\n";

public void doPost(HttpServletRequest request, HttpServletResponse response)

throws ServletException, IOException {

performTask(request, response);

}

public void doGet(

HttpServletRequest request, HttpServletResponse response)

throws javax.servlet.ServletException, java.io.IOException {

performTask(request, response);

}

public boolean performTask(HttpServletRequest request, HttpServletResponse response) throws

IOException{

String er1command = getER1CommandString(request);

//execute the command

sendCommand(er1command);

//redirect back to the users page

response.sendRedirect(request.getParameter(reqPageRedirectName));

return true;

}

public void init(ServletConfig servletConfig) throws ServletException {

super.init(servletConfig);

address = servletConfig.getInitParameter("host");

port = Integer.parseInt(servletConfig.getInitParameter("port"));

//create a socket connection and initialize the

Page 8: CS6510 Dissertation Final Report Communication between ...hwchun/FYP/2004/Albert Chung.pdf · CS6510 Dissertation Final Report Communication between Mobile Device and AI Robot Supervised

8

//input and output datastreams

System.out.println("Attempting to connect to ER1 Control Center");

System.out.println("at " + address + ":" + port);

connect(address, port);

System.out.println("Successfully connected to ER1 Control Center");

}

public String getER1CommandString(HttpServletRequest request){

String er1Command = request.getParameter(reqParamName);

if(er1Command == null || er1Command.equals("")){

//set the command to be the default command

er1Command = defaultCommand;

}

return er1Command + "\n";

}

public boolean connect(String address, int port)

{

if (socket != null) { disconnect(); }

try {

// Create a new socket connection.

socket = new Socket(address, port);

try {

// Set the output stream.

write_stream = new DataOutputStream(socket.getOutputStream());

read_stream = new BufferedInputStream(socket.getInputStream());

}

catch (Exception ex) {

System.out.println(ex.toString());

}

return true;

}

catch (Exception ex) {

System.out.println(ex.toString());

//throw ex;

return false;

Page 9: CS6510 Dissertation Final Report Communication between ...hwchun/FYP/2004/Albert Chung.pdf · CS6510 Dissertation Final Report Communication between Mobile Device and AI Robot Supervised

9

}

}

public String sendCommand(String command){

if (_verbose) {

System.out.print("Sending command: " + command);

}

if (!sendString(command)) {

return null;

}

String recvMsg = readString();

if (!checkResponse(recvMsg, command))

{

return null;

}

else {

return recvMsg;

}

}

public boolean sendString(String s) {

return sendBuffer(s.getBytes(), s.length());

}

boolean sendBuffer(byte[] bytes, int size) {

if (write_stream == null) {

return false;

}

try {

write_stream.write(bytes, 0, size);

write_stream.flush();

}

catch (Exception ex) {

disconnect();

System.out.println(ex.toString());

return false;

Page 10: CS6510 Dissertation Final Report Communication between ...hwchun/FYP/2004/Albert Chung.pdf · CS6510 Dissertation Final Report Communication between Mobile Device and AI Robot Supervised

10

}

return true;

}

public boolean checkResponse(String response, String command){

if (response == null) {

System.out.println("Error sending command " + command + "!");

return false;

}

else {

if (_verbose) {

System.out.print("Response: " + response);

}

return true;

}

}

public void disconnect() {

try {

if (socket != null) {

socket.close();

socket = null;

write_stream = null;

}

}

catch (Exception ex) {

System.out.println(ex.toString());

}

}

public String readString()

{

try

{

if (read_stream == null) {

System.out.println("Error: _read_stream is null.");

return null;

}

try {

Page 11: CS6510 Dissertation Final Report Communication between ...hwchun/FYP/2004/Albert Chung.pdf · CS6510 Dissertation Final Report Communication between Mobile Device and AI Robot Supervised

11

int size;

String msg;

do {

size = read_stream.available();

if (size != 0) {

byte[] buffer = new byte[size];

read_stream.read(buffer, 0, size);

msg = new String(buffer);

return msg;

}

Thread.sleep(50);

} while (size == 0);

}

catch (Exception ex) {

System.out.println(ex.toString());

return null;

}

}

catch (RuntimeException ex)

{

System.out.println(ex.toString());

return null;

}

return null;

}

}

webcamXP is a Web Cam broadcast server software that can handle video transfer

from robot web cam to mobile phone WAP Browser. However the 3G phone’s web

browser is not fully support of the java enabled features like J2ME application. So

either using 2 3G phones (using one phone for the vendor’s application to gain video)

or use a browser with fully java support to achieve view and control the robot but

there is no such product exists yet.

Page 12: CS6510 Dissertation Final Report Communication between ...hwchun/FYP/2004/Albert Chung.pdf · CS6510 Dissertation Final Report Communication between Mobile Device and AI Robot Supervised

12

The web page design has to be format to wireless friendly like xhtml, XML or WML

specification. (Not really necessary after tested)

Code sample:

<script language="JavaScript"> //Url of this page. //This page will be reloaded after it is submitted var REDIRECT_PAGE_URL_SUBMIT = "http://but-but-home.no-ip.info:8080/ER1/drive_robot.htm"; </script> <html> <head> <meta http-equiv="Content-Language" content="en-us"> <meta http-equiv="Content-Type" content="text/html; charset=windows-1252"> <title>3G Remote Robot</title> <script language="JavaScript"> function submitForm(submitClick, submitData) { var er1Command = "move "; if(submitClick == "backwards" ||submitClick == "right" ) { er1Command += "-"; } var unitsFieldName = "units" + submitData; var distanceFieldName = "distance" + submitData; //get the distance for the submitted click var distanceIndex = document.er1Form.elements[distanceFieldName].selectedIndex; var distanceValue = document.er1Form.elements[distanceFieldName].options[distanceIndex].value; //get the units var unitsIndex = document.er1Form.elements[unitsFieldName].selectedIndex; var unitsValue = document.er1Form.elements[unitsFieldName].options[unitsIndex].value; er1Command += distanceValue + " " + unitsValue; //alert(er1Command);

Page 13: CS6510 Dissertation Final Report Communication between ...hwchun/FYP/2004/Albert Chung.pdf · CS6510 Dissertation Final Report Communication between Mobile Device and AI Robot Supervised

13

//set the value of the er1Command document.er1Form.er1Command.value = er1Command; //set the value of this page so we can return to this page after submit document.er1Form.pageRedirect.value = REDIRECT_PAGE_URL_SUBMIT; //submit form to server document.er1Form.submit(); } </script> </head> <body> <center> <SCRIPT LANGUAGE="JavaScript"> <!-- errorimg1= 0; function LoadImage1() { uniq1 = Math.random(); document.images.webcam1.src = "http://but-but-home.no-ip.info:8081/cam_1.jpg?uniq="+uniq1; } function ErrorImage1() { errorimg1++; if (errorimg1>1) { document.images.webcam1.onload = ""; document.images.webcam1.src = "http://www.darkboard.net/webcam/offline.jpg"; } else { uniq1 = Math.random(); document.images.webcam1.src = "http://but-but-home.no-ip.info:8081/cam_1.jpg?uniq="+uniq1;

Page 14: CS6510 Dissertation Final Report Communication between ...hwchun/FYP/2004/Albert Chung.pdf · CS6510 Dissertation Final Report Communication between Mobile Device and AI Robot Supervised

14

} } function DoIt1() { errorimg1=0; window.setTimeout("LoadImage1();", 15); } document.write('<img src="loading.jpg" id="webcam1" name="webcam1" onload="DoIt1()" onerror="ErrorImage1()" width=80 height=60 border=0 style="border-color:#000000; border-style:solid;">'); //--> </script> </center> <form method="GET" name="er1Form" action="http://but-but-home.no-ip.info:8080/ER1/ER1Controller"> <!--127.0.0.1:8080 --> <input type="hidden" name="er1Command"> <input type="hidden" name="pageRedirect"> <div align="center"> <center> <font size="1"> <a onClick="submitForm('forward', '0'); return false;" href="x">Front </a> <select size="1" name="distance0"> <option selected value="2">2</option> <option value="4">4</option> <option value="6">6</option> <option value="8">8</option> </select> <select size="1" name="units0"> <option selected value="ft">ft</option> <option value="in">in</option> </select> </font>

Page 15: CS6510 Dissertation Final Report Communication between ...hwchun/FYP/2004/Albert Chung.pdf · CS6510 Dissertation Final Report Communication between Mobile Device and AI Robot Supervised

15

<br/> <font size="1"> <a onClick="submitForm('left', '1'); return false;" href="x">Left </a> <select size="1" name="distance1"> <option value="15">15</option> <option selected value="35">35</option> <option value="55">55</option> </select> <select size="1" name="units1"> <option selected value="degrees">deg</option> </select> </font> <br/> <font size="1"> <a onClick="submitForm('right', '2'); return false;" href="x">Right </a> <select size="1" name="distance2"> <option value="15">15</option> <option selected value="35">35</option> <option value="55">55</option> </select> <select size="1" name="units2"> <option selected value="degrees">deg</option> </select> </font> <br/> <font size="2"> <a onClick="submitForm('backwards', '3'); return false;" href="x">Back </a> <select size="1" name="distance3"> <option selected value="2">2</option> <option value="4">4</option> <option value="6">6</option> <option value="8">8</option> </select>

Page 16: CS6510 Dissertation Final Report Communication between ...hwchun/FYP/2004/Albert Chung.pdf · CS6510 Dissertation Final Report Communication between Mobile Device and AI Robot Supervised

16

<select size="1" name="units3"> <option selected value="ft">ft</option> <option value="in">in</option> </select> </font> </center> </div> </form> <center> <form method="POST" action="http://but-but-home.no-ip.info:8080/ER1/ER1Controller"> <font size="1">Voice: </font> <input type="text" name="er1Command" size="20" value="play phrase &quot;Hello&quot;"> <input type="submit" value="send" name="Submit"> </form> </center> </body> </html>

The Optional Java 2ME format is not possible to implement for my 3G phone since

the J2ME program upload required a WAP gateway and I don’t have the facility.

Performance analysis:

Comparison on the speed of using 3G mobile phone, 2/2.5 G GPRS/WAP phone and

desktop computer. (EDGE 2.75G was not available at the time when I did the testing)

Even using a 384kbs download and 64kbs upload’s 3 G phone for the command send

to Robot, it still had 5-8 seconds delay, so for the GPRS’s 53.6kbs download and even

less upload speed, the GPRS is useless for this application, for example the robot

would keep hitting the wall when you still stopping it for minutes.

Page 17: CS6510 Dissertation Final Report Communication between ...hwchun/FYP/2004/Albert Chung.pdf · CS6510 Dissertation Final Report Communication between Mobile Device and AI Robot Supervised

17

Comparison on Bluetooth LAN and wireless LAN

To test the performance of the wireless LAN, I use the same web application control

page to control the robot. The performance is very good I don’t see any delay

significantly. I have tested the range for 50 feet and it will work fine. (Linksys

Wireless-G router 54Mbs and Buffalo wireless LAN card 11Mbs used) However,

sometimes my wireless network connection drops but that’s basically normal.

Since I haven’t purchase all required hardware for Bluetooth network, so I don’t

have a comparison here. For the theoretical aspect, Bluetooth should do and have a

better performance on power saving only if no video transfer is required, in the

other words it is not good for this application since web cam real time transfer is

required.

Page 18: CS6510 Dissertation Final Report Communication between ...hwchun/FYP/2004/Albert Chung.pdf · CS6510 Dissertation Final Report Communication between Mobile Device and AI Robot Supervised

18

II. Related work

Hundreds of robot related work have done in the pass decades, AI, behaviors,

mechanical robot arm, Chess opponent, robot architecture, softbot, simulation,

circuits, design, implementation…etc but 3G Application related work is very

difficult to find.

The most related work that I have found is the following 3 sources.

Note: A French company Wany Robotics said during the Robotics Trends & IDG World

Expo Oct 2004, they are currently focusing on development of 3G home monitor and

remote operation products.

(1) Techniques for Web Telerobotics

Details: Given that web telerobots are appearing in increasingly large numbers with

many varying applications, the motivation for this research was to identify,

implement, and evaluate techniques for

controlling robots (and other devices) over the web.

P.S. There are plenty similar remote robotic labs in the world. (Extra software may

required)

http://telerobot.mech.uwa.edu.au/ (The robot is not working)

The problem as associated with existing systems is this web application can’t run

under a mobile phone’s web browser. You must have an Internet connected

computer to access the robot.

Page 19: CS6510 Dissertation Final Report Communication between ...hwchun/FYP/2004/Albert Chung.pdf · CS6510 Dissertation Final Report Communication between Mobile Device and AI Robot Supervised

19

(2) Remote Robot Control via Everyday Devices

Details: three ways to control the robot remotely at your leisure: through a web

controller, with a standard joystick, and using telephony with any phone through a

standard phone line.

The Autonomous Mobile Robot Group

Department of Computer Science

Northwestern University

http://www.cs.northwestern.edu/research/groups/amrg/courses/final-projects-20

00/everyday.html

The problem as associated with existing systems is no image support, cannot obtain

the robot’s vision.

(3) Html Web Interface for ER1

Details: Allow family and friends anywhere on the internet to drive and control your

ER1 robot from a simple HTML webpage.

http://www.assensa.com/er1 (This site is not operating anymore)

The problem as associated with existing systems is that the HTML webpage cannot

be run under mobile phone environment. An Internet connected computer is

required.

Page 20: CS6510 Dissertation Final Report Communication between ...hwchun/FYP/2004/Albert Chung.pdf · CS6510 Dissertation Final Report Communication between Mobile Device and AI Robot Supervised

20

III. System modeling and structure

Page 21: CS6510 Dissertation Final Report Communication between ...hwchun/FYP/2004/Albert Chung.pdf · CS6510 Dissertation Final Report Communication between Mobile Device and AI Robot Supervised

21

Forward 1 inLeft 1 in

Backward 1 inRight 1 in

Video broadcastingHttp://but-but-home.no-ip.info:3161/

Web Server TomcatHttp://but-but-home.no-

ip.info:8080/ER1/drive_robot.html

Page 22: CS6510 Dissertation Final Report Communication between ...hwchun/FYP/2004/Albert Chung.pdf · CS6510 Dissertation Final Report Communication between Mobile Device and AI Robot Supervised

22

Page 23: CS6510 Dissertation Final Report Communication between ...hwchun/FYP/2004/Albert Chung.pdf · CS6510 Dissertation Final Report Communication between Mobile Device and AI Robot Supervised

23

IV. The methodology and algorithms used in the

design/implementation of the system.

Client / Server Architectures

The term client/server was first used in the 1980s in reference to personal

computers (PCs) on a network. The actual client/server model started gaining

acceptance in the late 1980s. The client/server software architecture is a versatile,

message-based and modular infrastructure that is intended to improve usability,

flexibility, interoperability, and scalability as compared to centralized, mainframe,

time sharing computing.

A client is defined as a requester of services and a server is defined as the provider

of services. A single machine can be both a client and a server depending on the

software configuration. For details on client/server software architectures see

Schussel and Edelstein [Schussel 96, Edelstein 94].

Internet-Enabled Client-Server

With Internet-enabled client-server applications, the Internet is used to connect directly to remote

Robot with the help of socket programming and ER1 API.

Real-time remote-access control

With combine a Web server, a Video broadcasting server and a control center

Page 24: CS6510 Dissertation Final Report Communication between ...hwchun/FYP/2004/Albert Chung.pdf · CS6510 Dissertation Final Report Communication between Mobile Device and AI Robot Supervised

24

application. The real-time remote-access control can be achieved.

Socket programming

To develop client/server applications in the TCP/IP domain. We needed

fundamental concepts including network addressing, well known services, sockets

and ports.

The communication between Web Server and Robot Control Center (RCC) is through

Socket, actually all function of RCC would be disabled during API remote

connecting.

Fast Fourier transformation

Finding Similarity between Images, although I didn’t implement this transformation

myself but the RCC itself use similar technique to identify object.

Robot Control Architectures

There are three broad types of robot control architectures (Mataric (1997)):

Deliberative

Purely Reactive

Hybrid

Behavior-based

Implementation & Outcome

Page 25: CS6510 Dissertation Final Report Communication between ...hwchun/FYP/2004/Albert Chung.pdf · CS6510 Dissertation Final Report Communication between Mobile Device and AI Robot Supervised

25

Steps and Approaches:

1) Setup and testing with LEGO Mindstorm to gain API programming experiences.

Pic1, 2. LEGO Mindstorm, a 4 wheels vehicle with touch sensor front bumper and 1

inferred sensor.

Outcome: It can go to some predefined path or follow some Black lines.

2) Setup and testing with Evolution ER1 to gain the RCC software experience.

Pic 15-16 Connected to my notebook. A purple night within the webcam which is

really cool. Noted that the RCC can only works under the notebook in an uncharging

mode plus the robot battery charger must be unplugged.

Page 26: CS6510 Dissertation Final Report Communication between ...hwchun/FYP/2004/Albert Chung.pdf · CS6510 Dissertation Final Report Communication between Mobile Device and AI Robot Supervised

26

Outcome: I can program it to find me (around 2 feet) and say Hi master Albert.

3) Setup Tomcat & Servlet for the communication between RCC and Servlet

program.

Outcome: make sure the path is correct and the port numbers for the program use.

4) Setup webcamXP to get image from the view cam and broadcast to the web.

Pic 5 Panasonic notebook computer, running the Robot Control Center of ER1;

5) Write Html forms and pages for the user interface on Mobile phone’s browser

Pic 7. NEC c303 3G phone running remote view cam from ER1; Pic 8, remote control

web interface

Page 27: CS6510 Dissertation Final Report Communication between ...hwchun/FYP/2004/Albert Chung.pdf · CS6510 Dissertation Final Report Communication between Mobile Device and AI Robot Supervised

27

Pic 9, lower part of web interface; Pic 10, ER1 control center must be running to

provide remote port services

Outcome: control interface are modified to fit in for 1 screen, sorry, picture not

updated here.

6) Write Servlet for the forms handling and socket programming

V. Preliminary performance analysis of algorithm/system

Testing and Comparison stage.

Outcome: The speed running on different mobile phone and different network.

Compare with the theoretical measurements.

The broadband internet connection I used was 10Mb with average download speed

1031 Kbits/sec and upload speed 232 Kb/s.

The 3G connection was maximum 384 Kb/s download and 64 Kb/s upload.

Download and Upload ratio is about 5:1 and the 232 Kb/s compare to 64 Kb/s is

about 4 times slower. My result shows that a 3~6 seconds delay during 3G operation

testing which is quite reasonable.

Page 28: CS6510 Dissertation Final Report Communication between ...hwchun/FYP/2004/Albert Chung.pdf · CS6510 Dissertation Final Report Communication between Mobile Device and AI Robot Supervised

28

Findings

Approximately every 60 Kb/s upload bandwidth drops would cause a 1 second delay on the

reaction of a remote robot while starting from 240 Kb/s upload with no delay.

Future forecast

Since ISP broadband is not the bottle neck, it doesn’t improve performance if using Gigabit LAN. We do not need 802.11n 100Mbps+ transmission rate, since 802.11g 54 Mbps would match 4G perfectly. However WiMAX allow the remote control Range increase to 30 miles. 4G allow better image resolution transfer and reduce delay for instruction transmission by increase data transmission rates up to about 20-40 Mbps.

Page 29: CS6510 Dissertation Final Report Communication between ...hwchun/FYP/2004/Albert Chung.pdf · CS6510 Dissertation Final Report Communication between Mobile Device and AI Robot Supervised

29

VI. Conclusion

After my previous interim report submitted on March 15th 2004, City Daily News on

March 31st 2004 had an article about Japanese Company NTT DoCoMo’s new plug in

for 3G FOMA video phone which can remote control a SONY Aibo but extra hardware

DOCOMO’s FOMA Appliance controller is required. On April 14th 2004, an article in

EasyFinder Magazine introduce a Japanese robot called Nuvo by ZMP Inc. and they

claim Nuvo is the first 3G remote interactive Humanoid robot in the history (voice

commands). On April 16th 2004, another article in E-ZONE Magazine introduce a four

legs robot called Banryu by Sanyo and Waseda University and it can be remote

control by Fujitsu’s FOMA 900i mobile phone. All of these robots are very expensive!

They can perform many tasks!

This Dissertation topic Communication between Mobile Device and AI Robot become

very hot because of the popularity of 3G mobile network. At the time that 4G and

WiMAX are available, the robot and computer battery should also be improved a lot;

so all the bottle neck are eliminated. I am confidence that we will see more and

more similar products in the market soon.

Page 30: CS6510 Dissertation Final Report Communication between ...hwchun/FYP/2004/Albert Chung.pdf · CS6510 Dissertation Final Report Communication between Mobile Device and AI Robot Supervised

30

VII. References

[RI] Robot invasion, 7 Cool and Easy Robot Projects, Dave Johnson, Mc Graw Hill

[LSPT] LEGO Software Power Tools, Including LDraw, MLCad, LPub, and LSynth,

Syngress

[EM] ER1: Manual

[BFJ] Bluetooth for Java, Hopkins & Antony, Apress

[WJ] Wireless Java: Developing with Java 2, Micro Edition, Jonathan Knudsen,

Apress

[FMN] Future mobile networks: 3G and beyond, Edited by Alan Clapton, The

Institution of Electrical Engineers

[PR] PDA Robotics, Douglas H. Williams, Mc Graw Hill

[AJ] Advanced Java 2 Platform How to program, Deitel Deitel Santry, Deitel Prentice

Hall

[AR] Anatomy of a Robot, Charles M. Bergren, Mc Graw Hill

[AIANS] Artificial Intelligence A New Synthesis, Nils J. Nilsson, Morgan Kaufmann

[AIAMA] Artificial Intelligence: A Modern Approach, Stuart Russell Peter Norvig,

Pearson Education

Web sites:

Evolution robotics, 2002, http://www.evolution.com/product/consumer/er1/

Sullivan B., 2002, http://www.msnbc.com/news/817145.asp?0dm=C11KT

HTML 4.0 Guidelines for Mobile Access,

http://www.w3.org/TR/NOTE-html40-mobile/

Mobile Access Activity Statement, http://www.w3.org/Mobile/Activity

J2ME, http://java.sun.com/j2me/

Page 31: CS6510 Dissertation Final Report Communication between ...hwchun/FYP/2004/Albert Chung.pdf · CS6510 Dissertation Final Report Communication between Mobile Device and AI Robot Supervised

31

J2ME Wireless Toolkit 2.1,

http://java.sun.com/products/j2mewtoolkit/download-2_1.html

Sun ONE Studio 4 update 1, Mobile Edition,

http://wwws.sun.com/software/sundev/jde/studio_me/

python.org website, http://www.python.org/

Jython, http://www.jython.org/

Tomcat, http://jakarta.apache.org/tomcat/

LEGO Mindstrom, http://mindstorms.lego.com/eng/default.asp?bhcp=1

leJOS, http://lejos.sourceforge.net/

Better tools for creating mobile 3D graphics on the way,

http://www.nokia.com/nokia/0,,42207,00.html

JSR 184: Mobile 3D Graphics API for J2METM,

http://www.jcp.org/en/jsr/detail?id=184

Symbian, http://www.symbian.com/

Socket and connectBlue Demonstrate Bluetooth-based Robotics,

http://www.socketcom.com/about/press/read.asp?ID=39

The official Bluethooth website, http://www.bluetooth.com/index.asp

Grand Challenge, http://www.darpa.mil/

Robocup, http://www.robocup.org/

NCC AI & Robotics, http://www.ncc.com/misc/ai_sites.html

The most advanced android in the world,

http://www.androidworld.com/prod19.htm

More links: http://ecom3.cs.cityu.edu.hk/50355532/bookmark.htm

Papers:

[BoeBot] Phoenix & Dragon Parallax BoeBot! Lego Technique Hybrid Solution to the

Page 32: CS6510 Dissertation Final Report Communication between ...hwchun/FYP/2004/Albert Chung.pdf · CS6510 Dissertation Final Report Communication between Mobile Device and AI Robot Supervised

32

Reactive Maze Traversal & Deliberative “Cheese” Location Problems, D. Boucugnani,

D. Barnhard, D. Caveney

[LRC] Learning Robotic Control: PhD. Thesis Proposal,

http://www.autonlab.org/autonweb/showPaper.jsp?ID=moore-proposal

[92A011-Bluetooth] Bluetooth conference, 14 Aug 1992

[5NC] 5NeuralControllers for Intellego, Graeme Bell, 24 April 2002

[ai_lecture1-slides] CS C384: Intro to AI, Fahiem Bacchus

[BHT] Bluetooth-how-to, Bradley J. Wimpey, 12 Jan 2004

[DERSP] Datasheet, ERSP 2.0, Evolution Co.

[GS] ERSP_Get_Started, Evolution Co.

[UM] ERSP_User_Manual, Evolution Co.

[KIT] evolution_robotics_press_kit, Evolution Co.

[final_report], Final Project, Evolution in the Micro-Sense: An Autonomous Learning

Robot, Chuang Hue Moh, May 15 2002

[HTP] HajimeThesisProposal, Behavior-Based Perceptual Navigatual Navigation

Systems For Powerd wheel chair operation, Hajime Uchiyana

[DRT]Distributed Robotic Target Acquisition using Bluetooth Communication, J.T.

McClain, B.J. Wimpey, D.H. Bamhard, & W.D. Potter

[O&H] Odin & Hodur: Using Bluetooth Communication for Coordinated Robotic

Search, D.H. Barnhard, J.T. McClain, B.J. Wimpey, & W.D. Potter

[CN] Corridor Navigation of a Mobile Robot using a camera & sensors—multi-agent

approach by Yuki Ono

[B&R] Bluetooth & Robotics, Pasi Myllymaki, University of Washington, Spring 2002

[ABG] A Beginners Guide to Programming For the PPPK, Sam Utley, Dec 2003

[HTD] How to design your own robot cat for the Melexis Safety Trophy?, Melexis,

Microelectronic integrated Systems