Вы находитесь на странице: 1из 50

UBIQUITOUS COMPUTING

Bluetooth Piconet,
Scatternet, Protocol
Stack, Bluetooth Profile

Shivani Nanda
Assistant Professor
CSE Dept. SIT Bhubaneswar

B.Tech VIII IT
UNIT I
Bluetooth
One of the first modules (Ericsson).
Basic idea
Universal radio interface for ad-hoc wireless connectivity
Technology allows for the connection of one device to another
using a universal short-wave radio link
Interconnecting computer and peripherals, handheld devices,
PDAs, cell phones
Was considered a better replacement of IrDA mechanism
Was designed to e built-into and connect electronic appliances
without adding significant cost

2
Bluetooth
History
1994: Ericsson (Mattison/Haartsen), MC-link project
Renaming of the project: Bluetooth according to Harald Bltand
Gormsen [son of Gorm and Thyra], King of Denmark in the 10
th

century and united warring tribes throughout Scandinavia under
the umbrella of Christianity
1998: foundation of Bluetooth SIG, www.bluetooth.org
1999: erection of a rune stone at Ericsson/Lund ;-)
2001: first consumer products for mass market, spec. version 1.1
released
Special Interest Group
Original founding members: Ericsson, Intel, IBM, Nokia, Toshiba
Added promoters: 3Com, Agere (was: Lucent), Microsoft,
Motorola
Common specification and certification of products
3
History and hi-tech
1999:
Ericsson mobile
communications AB
reste denna sten till
minne av Harald
Bltand, som fick ge
sitt namn t en ny
teknologi fr trdls,
mobil kommunikation.
4
and the real rune stone
Located in Jelling, Denmark,
erected by King Harald Bltand
in memory of his parents.
The stone has three sides one side
showing a picture of Christ.
This could be the original colors
of the stone.
Inscription:
auk tani karthi kristna (and made
the Danes Christians)
Inscription:
"Harald king executes these
sepulchral monuments after Gorm,
his father and Thyra, his mother.
The Harald who won the whole of
Denmark and Norway and turned
the Danes to Christianity."
5
Bluetooth and IEEE 802.15
Research groups discussed WPANs under criteria
Market potential
Compatibility
Distinct Identity
Technical and Economic Feasibility

Bluetooth fulfilled these criteria as a result WPAN
group cooperated with Bluetooth consortium and
finally IEEE founded its own group for WPANs IEEE
802.15 which would develop standards for wireless
communications within a POS (defined as a radius
of 10 m in which the person or the devices of this
person communicate with other devices)

6
Characteristics
2.4 GHz ISM band, 79 RF channels, 1 MHz carrier spacing
Channel 0: 2402 MHz channel 78: 2480 MHz
G-FSK modulation, 1-100 mW transmit power
FHSS and TDD
Frequency hopping with 1600 hops/s
Hopping sequence in a pseudo random fashion, as decided by a
master
Time division duplex for send/receive separation(time slots each
625 microseconds in length
Voice link SCO (Synchronous Connection Oriented)
FEC (forward error correction), no retransmission, 64 kbit/s duplex,
point-to-point, circuit switched
Data link ACL (Asynchronous ConnectionLess)
Asynchronous, fast acknowledge, point-to-multipoint, up to 433.9
kbit/s symmetric or 723.2/57.6 kbit/s asymmetric, packet switched
7
Piconet
Collection of devices connected in an ad
hoc fashion(say a pc and a cellular
phone)

One unit acts as master and the others
as slaves for the lifetime of the piconet

Master determines hopping pattern,
slaves have to synchronize

Each piconet has a unique hopping
pattern

Participation in a piconet =
synchronization to hopping sequence

Each piconet has one master and up to
7 simultaneous slaves (> 200 could be
parked)

M=Master
S=Slave
P=Parked
SB=Standby
M
S
P
SB
S
S
P
P
SB
8
Major States of a Bluetooth Device and Typical Transitions
Standby: do nothing
Inquire: search for other devices
Page: connect to a specific device
Connected: participate in a piconet
Sniff: listen
periodically, not
each slot
Hold: stop ACL,
SCO still
possible, possibly
participate in
another piconet
Park: release
AMA, get PMA

standby
inquiry page
connected
AMA
transmit
AMA
park
PMA
hold
AMA
sniff
AMA
unconnected
connecting
active
low power
detach
9
Baseband States of a Bluetooth Device
Bluetooth controller operates in two major states:
Stand By Connection
Other sub states which are used to add slaves or
make connection in the piconet are :
Page Page Scan
MasterResponse SlaveResponse
Inquiry Inquiry Scan Inquiry Response
The Standby state is the default low-power state in
the Bluetooth unit where only the native clock is
running and there is no interaction with any other
device


10
This figure shows the different
types of sleep modes used in
a Bluetooth system. This
diagram shows that the
master control the sleep
modes of the devices within
the Piconet. In this example,
the master in the Piconet
commands a PDA to one time
sleep period (hold mode) for
500 msec. The master then
commands the mouse in the
Piconet to sleep periodically
(sniff mode) for 50 msec. The
master then commands the
scanner to give up its active
member address wait until 10
seconds before it will again
communicate with the
scanner.
Bluetooth Sleep Modes
11
Forming a piconet
All devices in a piconet hop together
Master gives slaves its clock and device ID
Hopping pattern: determined by device ID (48 bit, unique
worldwide)
Addressing
BD_ADDR-Bluetooth Device Address(48 bit divide into LAP & NAP)
AM_ADDR-Active Member Address (AMA, 3 bit)
PM_ADDR-Parked Member Address (PMA, 8 bit)
AR_ADDR-Access Request Address(Used by the parked slave

SB
SB
SB
SB
SB
SB
SB
SB
SB
M
S
P
SB
S
S
P
P
SB


















12
Scatternet
Linking of multiple co-located piconets through the sharing
of common master or slave devices
Devices can be slave in one piconet and master of
another
Communication between piconets
Devices jumping back and forth between the piconets
13
M=Master
S=Slave
P=Parked
SB=Standby
M
S
P
SB
S
S
P
P
SB
M
S
S
P
SB
Piconets
(each with a
capacity of
720 kbit/s)
Bluetooth protocol stack
Radio
Baseband
Link Manager
Control
Host
Controller
Interface
Logical Link Control and Adaptation Protocol (L2CAP)
Audio
TCS BIN SDP
OBEX
vCal/vCard
IP
NW apps.
TCP/UDP
BNEP
RFCOMM (serial line interface)
AT modem
commands
telephony apps. audio apps. mgmnt. apps.
AT: attention sequence
OBEX: object exchange
TCS BIN: telephony control protocol specification binary
BNEP: Bluetooth network encapsulation protocol
SDP: service discovery protocol
RFCOMM: radio frequency comm.
PPP
14
Bluetooth Protocol Stack

The Bluetooth protocol stack can be placed into
three groups:
Transport Protocol Group These protocols
carry audio and data traffic between devices and
supports both synchronous and asynchronous
transmission for telephony-grade services
Radio Layer
Baseband layer
Link Manager Layer
Logical Link Control and Adaptation
protocol(L2CAP) Layer
Host Controller Interface

15
Bluetooth Protocol Stack
16
Radio Layer
Several limitations were taken into account while
designing the Bluetooths radio layer and are as
follows:-
Bluetooth devices will be integrated onto small
mobile devices relying on battery power
Bluetooth should be a globally operational
technology
Bluetooth should support multimedia data

The standard developed in the light of above
restrictions had following features:-
Bluetooth operated in a license-free band of 2.4GHz
A FH/TDD scheme is used to mitigate interference
Hop rate is 1600/s an slot is an interval of 620s



17
Radio Layer(contd)
Bluetooth transceivers were available in three classes

Power class 1 Maximum power is 100mW and
minimum is 1mW. Power
control is mandatory

Power class 2 Maximum power is 2.5mW,
nominal power is 1mW and
minimum power is 0.25mW.
Power control is optional

Power class 3 Maximum power is 1mW
18
Baseband Layer
The baseband layer is responsible for the
process of searching other devices and
establishing connection between them

This layer also manages the links between the
devices and is responsible for determining the
packet types supported for synchronous and
asynchronous traffic

This layer also controls the Bluetooth units
synchronization and transmission frequency
hopping sequence

19
Bluetooth Packet Format
access code packet header payload
68(72) 54 0-2745 bits
AM address type flow ARQN SEQN HEC
3 4 1 1 1 8 bits
preamble sync. (trailer)
4 64 (4)
Access Code Channel Access Code(CAC)
May represent special codes during paging(Device Access
Code) and inquiry access code(IAC)
The access code consists of a 4-bit preamble, a
synchronization field and a trailer (if a packet header
follows)
The synchronization field is derived from the lower 24-bit
of an address(lower address part, LAP)

20
Bluetooth Packet Format
Fields of the packet header are:-
3-bit active member address representing the active
address of a slave
4-bit type field determining the type of the packet
1-bit flow field facilitating the flow control mechanism
for asynchronous data
A simple alternating bit protocol with a single bit
sequence number SEQN and acknowledgement number
ARQN can be used
An 8-bit header error check is used to protect packet
header
1/3-FEC is used to protect packet header





21
Connection setup between Master and Slave
Master Slave
Inquiry Scan
Inquiry response
Inquiry
Page
Page Scan
Slave Response
Connection
Master
Response
Connection
22
Connection setup between Master and Slave
Master uses GIAC and DIAC to inquire about
Bluetooth devices in the vicinity
Slave if listening responds by sending its device
address and clock information and then enters to
page listening stage
Master then pages the device for connection set up
Slave responds by sending device access code
Master responds by sending masters real time
clock, its BD-ADDR, BCH parity bits, class of the
device(FHS packet)
Slave on receiving FHS packet both enter into
connection state





23
Link Manager Protocol(LMP)
Authentication, pairing and encryption(generating and
maintaining link and encryption keys)

Synchronization(Updating the clock offset by master)

Capability Negotiation(agree to usage of multislot
packets, encryption, SCO links, switching between
park,sniff and hold modes)

Quality of Service Negotiation(Poll interval, Quality of
channel, number of repetitions for broadcast packets)

Power Control(increase or decrease transmitted power)

Link Supervision(controls activity on the link)
State and Transmission Mode Change(devices may switch
master/slave role, detach or change operating mode 24
Logical Link Control and Adaptation protocol(L2CAP) Layer
All data traffic is routed through the logical link control
and adaptation protocol layer

It is also responsible for segmenting larger packets from
higher layers into smaller packets, which are easier to
handle by the lower layer

The L2CAP layer in two peer devices facilitates the
maintenance of the desired grade of service

The L2CAP layer is responsible for admission control
based on the requested level of service and for
coordinating with the lower layers to maintain this level
of service.
25
Host Controller Interface(HCI)
The HCI allows higher layers of the stack, including
applications, to access the baseband, link manager,
etc., through a single standard interface

Through HCI commands, the module may enter
certain modes of operation

Higher layers are informed of certain events
through the HCI.

The HCI is not a required part of the specification. It
has been developed to serve the purpose of
interoperability between host devices and Bluetooth
modules.
26
Bluetooth Protocol Stack(Contd)
Middleware Protocol Group The protocols in this
group are needed for existing applications to operate
over Bluetooth links
The protocols in this group are
RFCOMM Layer
Service Discovery Protocol(SDP) Layer
Infrared data association(IrDA) interoperability
protocols
Object exchange(OBEX) protocol
Networking layers
Telephone control specification(TCS) layer and
audio
27
Middleware Protocol Group
RFCOMM Layer RFCOMM provides a virtual
serial port to applications. The advantage
provided by this layer is that it is easy for
applications designed for cabled serial ports
to migrate to Bluetooth

Service Discovery Protocol(SDP) - The SDP is a
standard method for Bluetooth devices to
discover and learn about the services offered
by the other device



28
Middleware Protocol Group
Infrared data association(IrDA) The Infrared
Object Exchange Protocol is designed to enable
units supporting infrared communication to
exchange a wide variety of data and comments

Object Exchange(OBEX) Protocol IrOBEX
(in short, OBEX) is a session protocol providing the
same basic functionality as HTTP and uses a client-
server model which is independent of the
transport mechanism and transport application
programming interface (API), provided it realizes a
reliable transport base
29
Middleware Protocol Group
Networking Layers - Once a dial-up connection
is established to an IP network, then standard
protocols like TCP, UDP, and HTTP can be used

Telephony control specification(TCS) Layer -
This layer is designed to support telephony
functions, which include call control and group
management. These are associated with setting
up voice calls. Once a call is established a
Bluetooth audio channel can carry the calls
voice content
30
Bluetooth Protocol Stack(Contd)
Application Group - This group consists of
actual applications that make use of
Bluetooth links and refers to the software
that exists above the protocol stack

The most interesting applications are those
that substantiate the Bluetooth profiles

The Bluetooth-SIG does not does not define
any application protocols nor does it specify
any application programming interface

31
Bluetooth Profile
Bluetooth Profiles
This figure shows how profiles
are used to standardize how
Bluetooth devices communicate
with each other independent of
who manufactured the device.

This diagram shows that profile
includes the required
communication protocols, the
service capabilities, and feature
operation of the Bluetooth
device.

In this example, the Bluetooth
profile also defines how the user
can interact (features and
optional features) with the device
and how the device will display
information to the user.
33
Bluetooth profile
A Bluetooth profile is a wireless interface
specification for Bluetooth-based communication
between devices.
A Bluetooth profile resides on top of the Bluetooth
Core Specification and (optionally) additional
protocols.
34
Bluetooth profile
At a minimum, each profile specification contains
information on the following topics:
Dependencies on other profiles
Suggested user interface formats
Specific parts of the Bluetooth protocol stack
used by the profile. To perform its task, each
profile uses particular options and parameters at
each layer of the stack. This may include an
outline of the required service record, if
appropriate.
35
Bluetooth Profile
Bluetooth Profile
Advanced Audio Distribution Profile
(A2DP)
Audio/Video Remote Control Profile
(AVRCP)
Basic Imaging Profile (BIP)
Basic Printing Profile (BPP)
Common ISDN Access Profile (CIP)
Cordless Telephony Profile (CTP)
Device ID Profile (DID)
Dial-up Networking Profile (DUN)
Fax Profile (FAX)
File Transfer Profile (FTP)
General Audio/Video Distribution Profile
(GAVDP)
Generic Access Profile (GAP)
Generic Object Exchange Profile (GOEP)
Hard Copy Cable Replacement Profile
(HCRP)
Hands-Free Profile (HFP)
Human Interface Device Profile (HID)
Headset Profile (HSP)
Intercom Profile (ICP)
LAN Access Profile (LAP)
Object Push Profile (OPP)
Personal Area Networking Profile (PAN)
Phone Book Access Profile (PBAP)
Serial Port Profile (SPP)
Service Discovery Application Profile
(SDAP)
SIM Access Profile (SAP, SIM)
Synchronisation Profile (SYNCH)
Video Distribution Profile (VDP)
Wireless Application Protocol Bearer
(WAPB)
Advanced Audio Distribution Profile (A2DP)
This profile defines how high quality audio
(stereo or mono) can be streamed from one
device to another over a Bluetooth connection.

For example, music streamed from a mobile
phone to a wireless headset.
38
Audio/Video Remote Control Profile (AVRCP)
This profile is designed to provide a standard
interface to control TVs, Hi-fi equipment, etc. to
allow a single remote control (or other device) to
control all of the A/V equipment to which a user has
access. It may be used in concert with A2DP or VDP.
Basic Printing Profile (BPP)
This allows devices to send text, e-mails, vCards, or
other items to printers based on print jobs. This
makes it more suitable for embedded devices such
as mobile phones and digital cameras which cannot
easily be updated with drivers dependent upon
printer vendors.
39
Basic Imaging Profile (BIP)
This profile is designed for sending images between
devices and includes the ability to resize, and
convert images to make them suitable for the
receiving device.
It may be broken down into smaller pieces:

Image Push Allows the sending of images from a
device the user controls

Image Pull Allows the browsing and retrieval of
images from a remote device.
40
Common ISDN Access Profile (CIP)
This provides unrestricted access to the services,
data and signaling that ISDN offers.
Cordless Telephony Profile (CTP)
This is designed for cordless phones to work using
Bluetooth.
General Audio/Video Distribution Profile
(GAVDP)
Provides the basis for A2DP, and VDP.
41
Device ID Profile (DID)
This profile allows a device to be identified above and
beyond the limitations of the Device Class already
available in Bluetooth.
It enables identification of the manufacturer, product id,
product version, and the version of the Device ID
specification version being met.
Generic Access Profile (GAP)
Provides the basis for all other profiles.
Generic Object Exchange Profile (GOEP)
Provides a basis for other data profiles.
Based on OBEX.

42
Dial-up Networking Profile (DUN)
This profile provides a standard to access the
Internet and other dial-up services over Bluetooth.
It is based on Serial Port Profile (SPP), and provides
for relatively easy conversion of existing products,
through the many features that it has in common
with the existing wired serial protocols for the same
task.
Personal Area Networking Profile (PAN)
This profile is intended to allow the use of
Bluetooth Network Encapsulation Protocol on Layer
3 protocols for transport over a Bluetooth link.
43
File Transfer Profile (FTP)
Provides access to the file system on another
device. This includes support for getting folder
listings, changing to different folders, getting files,
putting files and deleting files.
It uses OBEX as a transport and is based on GOEP.
Phone Book Access Profile (PBAP)
This profile allows exchange of Phone Book Objects
between devices.
It is likely to be used between a car kit and a mobile
phone to allow the car kit to display the name of
the incoming caller.

44
Hard Copy Cable Replacement Profile (HCRP)
This provides a simple wireless alternative to a
cable connection between a device and a printer.
Unfortunately it does not set a standard regarding
the actual communications to the printer, so drivers
are required specific to the printer model or range.
Service Discovery Application Profile (SDAP)
SDAP describes how an application should use SDP
to discover services on a remote device.
SDAP requires that any application be able to find
out what services are available on any Bluetooth
enabled device it connects to.
45
Hands-Free Profile (HFP)
This is commonly used to allow car hands-free kits to
communicate with mobile phones in the car.
It uses SCO (see Synchronous Connection Oriented link) to
carry a mono, Continuously variable slope delta modulation
or Pulse-code modulation with logarithmic a-law or law
quantization audio channel.
Human Interface Device Profile (HID)
Provides support for devices such as mice, joysticks,
keyboards, as well as sometimes providing support for
simple buttons and indicators on other types of devices.
Bluetooth HID is a lightweight wrapper of the Human
Interface Device protocol defined for USB.
46
SIM Access Profile (SAP, SIM)
This allows devices such as car phones with
built in GSM transceivers to connect to a SIM
card in a phone with Bluetooth, so the car
phone itself doesn't require a separate SIM
card.
Synchronisation Profile (SYNCH)
This profile allows synchronization of Personal
Information Manager (PIM) items.
47
Video Distribution Profile (VDP)
This profile allows the transport of a video
stream.
It could be used for streaming a recorded
video from a PC media center to a portable
player, or from a digital video camera to a TV.
Wireless Application Protocol Bearer (WAPB)
This is a profile for carrying Wireless
Application Protocol, (WAP) over Point-to-
Point Protocol over Bluetooth.
48
Bluetooth Topics
Advantages of Bluetooth
Bluetooth Applications
49
IEEE 802.11 topics
Basic Structure of an 802.11 MAC frame
Types of MAC frames
MAC Management
Synchronization
Power management
Roaming
IEEE 802.11 services
Distribution Integration
Association Reassociation
Disassociation Authentication
Deauthentication Privacy


50

Вам также может понравиться