Client Software (Java, cellphone)
This section is intended to give an overview of how the client software works. There are three sections. The first one is a theoretical overview which is intended for casual readers and the second is for programmers who want to get an internal overview of method calls. The third is about the GUI.

Over the months the program has evolved and one can say that it was born the 5th of January 2005 when the main file was first created. Two days later it was tested for the first time. Thanks to Mikael Lenneryd for letting us borrow his Sony Ericsson V800. A month later the code was reformatted and a couple of days after that Bluetooth code was implemented.

The main concern in the client software was the connection to the handheld. We spent many hours testing and rewriting that particular code fragment (~500 lines) to finally establish an active connection (2005-04-08).

Section one - introduction
What the client actually does is to establish a Bluetooth connection to our handheld and send command based on the user's input. When the software is started, we are presented with a splashscreen displaying a loading bar [Image #1].

In the background, Bluetooth searches all nearby devices and stores them in the memory. A second search checks every device for a matching service (A Bluetooth service is what kind of actions it provides, such as file transfers). If the client finds a match, it will attempt to establish a connection [Image #1]. When it does, the control panel appears with which the user can turn on [Image #2] the robot and send a command [Image #3].

The handheld receives the command, looks up the matching IR signal and sends it to the handheld. More about this under Client-Server communication (5.2).

Section two - Programmers overview
This section is intended for programmers who can follow the method calls throughout the MIDlet. It is a text document which can be found here

Section three - GUI
The images below are the sketches for the GUI made by the programmers, Niklas and Johan, in early development (somewhere around 2004-09-15). The paper it was written on is from Sony Ericsson's developer section. The terrible handwriting courtesy of Niklas..

Links - For SE developers, a must - Wireless Java articles - Sun's Java (Micro Edition) articles - Streaming video over Bluetooth - Getting started with Java/BT - J2ME gaming book - Bluetooth master thesis New to BT?

Johan reminded me about compilation instructions.. here they are. Full documentation is availible under Downloads.

Start by downloading the latest client source package

Copy the subfolder into your projects folder, probably

Open SonyEricsson J2ME Wireless toolkit, press "Open project".
Select MobileRobotics. You have successfully opened our project.
Now press settings and make sure you have these under "API selection:"

Target Platform: Custom
Profiles: MIDP 2.0
Configuration: CLDC 1.0
Optional: Bluetooth API (JSR 82)

To use it with your regular cellphone choose Project - Package
and then "Build Package". Then copy the .jar and .jad file created
(in bin/) to your cellphone and install.

Commands: Press 0 to toogle between modes. On a none-pointer cellphone
(everyone except P800/P900/P910) you will get a about screen.
On P910 you will get a draw-and-the-robot-will-follow screen,
try it. Logo  
Page viewed times mobileRobotics is powered by Source Forge