Download as ppt, pdf, or txt
Download as ppt, pdf, or txt
You are on page 1of 21

MOBILE BLUETOOTH SERVICES

(Final Year B.Tech Project Presentation)

Project Guide
Asst. Prof. Balu John
Presented By
Anup Antony (Reg. No. 06401003)
Deepu M.P. (Reg. No. 06401006)
Prashant Arvind (Reg. No. 06401020)
CONTENTS
1. Introduction
2. Software Requirements
3. Hardware Requirements
4. System Design
5. System Implementation
6. Screenshots
7. Results
8. Conclusion
1. INTRODUCTION
Mobile Bluetooth Service enables the user to chat with the
neighboring Mobile Bluetooth devices and perform file
transferring. It also allows us to control certain applications
in PC e.g. PowerPoint, Winamp. Mobile Bluetooth Service is
divided into 2 modules:

 PC Controller
Bluetooth Chat
2. SOFTWARE REQUIREMENTS
Tools and Technologies Used

Operating System: Windows XP or above


Net Beans 6.1
Sun Java Wireless Toolkits
J2ME, J2SE
JDK 6
Bluetooth Drivers for Windows
Bluecove-2.1.0
3. HARDWARE REQUIREMENTS
Hardware Requirements
 Processor: Pentium 4 or above
 512MB RAM
 40 GB Hard Disk
 Bluetooth Dongle

Java and Bluetooth enabled phones


Technologies Used
Java
Java is a platform independent programming language
developed by Sun Microsystems. There are mainly three
variations of it - J2SE, J2ME and J2EE. J2SE is the
standard edition of Java.

J2ME
 It is a lighter platform of Java.
 Intended to design applications for mobile devices
 Contains ‘profiles’ – e.g. MIDP (a de facto standard in
mobile phones) to develop mobile user GUI called
MIDlets.
Technologies Used (contd…)
Sun Java Wireless Toolkit

 Comprehensive set of tools for building MIDP


applications
 Helps develop wireless applications using J2ME
 Enhances the functionality of J2ME’s CLDC and MIDP
 Contains emulation environments, tuning features and
documentation
4. SYSTEM DESIGN
PC Controller
SYSTEM DESIGN (…contd)
Bluetooth Chat
5. SYSTEM IMLEMENTATION
5.1 PC Controller

There are two parts in this module:


Server
Client

The SERVER part runs in the desktop PC and the


CLIENT is deployed in the java supporting mobile
phone.
5.1 PC Controller (contd)

SERVER

 Written in J2SE, imports various Bluetooth packages


using Bluecove protocol stack
 Uses an object of LocalDevice class to set various
bluetooth parameters such as discoverable mode, using
setDiscoverable() method.
 A unique service id is created using the UUID class in
javax.bluetooth package and a url is created for this service
using the btspp (bluetooth serial port profile) protocol.
 A stream connection is then opened with this URL and an
input and an output stream objects are created
 A thread is spawned off implicitly to handle incoming
stream messages from the client.
5.1 PC Controller (contd)

SERVER (contd)

The receiver thread takes the input as byte stream, converts


into string and takes corresponding actions to control the
various applications by simulating keystrokes

Keystrokes are simulated using an object of Robot class by


calling keyPress() and keyRelease() methods

Programs are invoked using an instance of Runtime class


by calling the exec() command. It returns an instance of
Process class which handles the various subprocesses
5.1 PC Controller (contd)

CLIENT

Written in J2ME and deployed in a mobile phone as .jar file


It’s a MIDP application, providing user interface & functions
 Once it is launched startDeviceInquiry() method is invoked
which searches for active devices in Bluetooth range.
After discovery is complete, all devices are listed using an
object of List class by appending them to the list
The user can select the intended PC after which service
discovery routine is invoked.
If the corresponding UUID is matched, the user is
successfully connected
Stream is created to handle data flow between the PC and
phone using a Sending thread and a Receiving thread
5.1 PC Controller (contd)

CLIENT (contd)
User can select Winamp or Powerpoint listed in the MIDlet
In Winamp, a list of operations (play, pause etc.) are
displayed using an instance of ChoiceGroup class
Upon selection of a function, the index corresponding to
the item in the choice group is retrieved and a string is
written onto an instance of OutputStream and sent to the PC

In Powerpoint, the implementation is similar, except that a


Form displays a choice of predefined PPTs.
User can select any and the operations will be provided
Windows batch file(.bat) is used to invoke files in the PC
using the exec() method in Robot class
5.2 Bluetooth Chat

There are two modules in this application

Initiate Chat

Join Chat

Initiate Chat
The application starts off with the startDeviceInquiry()
method and lists all available bluetooth enabled devices in
vicinity
This is followed by service discovery which finds and
finally allows user to connect to the other end, checking the
UUID
5.2 Bluetooth Chat (contd)

After the various security prompts the user is displayed a


Form in the Midlet which acts as the chat window. It has a
TextField to enter text
The message typed is written onto the form using the
append() method
Two threads –to send and receive- are created when
connection is established to handle data transfer
Join Chat
This is similar to entering a chat room, as the name says
Here, the user’s mobile is published to the network by
making it discoverable
It can wait for messages from the sender which initiates a
chat
The other device which initiates a chat can select this
device
6. SCREENSHOTS

Application Select in MBServices PC Controller Main Screen


SCREENSHOTS(contd)

Chat Option Selection


SCREENSHOTS(contd)

Chat Window
7. RESULTS
PC Controller was successfully implemented
Various windows applications could be opened and
switched between each other

One-to-one chatting between two mobile users was


successfully implemented
Integration of both the modules was successfully done;
the user could switch between PC controller and Bluetooth
Chat.
8. CONCLUSION
Mobile Bluetooth Services used the client-server model to
accomplish the various tasks and functions
The message passing between PC and mobile and
mobile-to-mobile was facilitated using Threads in java

The PC controller could efficiently run and control the


windows applications.
 Chat module though efficient, had minor issues with the
phones in which they were deployed due to certain
mismatches in the phone software and its support for .jar
files

You might also like