A7 Engineering EmbeddedBlue 505 User manual

EmbeddedBlue™505
User Manual

Part Number 0000112 – Revision A
Last revised on June 28, 2005 – Printed in the United States of America
A7 Engineering, Inc.
12860 C Danielson Court
Poway, CA 92064
Copyright ©2003-2005 A7 Engineering, Inc. All rights reserved. EmbeddedBlue is a
trademark of A7 Engineering, Inc. Bluetooth and the Bluetooth logo are registered
trademarks of the Bluetooth SIG. Windows is a registered trademark of Microsoft
Corporation. Other brand and product names are trademarks or registered trademarks of
their respective holders.
The information contained in this document is subject to change without notice. A7
Engineering, Inc. and its staff make no warranty of any kind for the correctness,
completeness, interpretation or use of the information contained herein. It is the user’s
responsibility to comply with all applicable copyright laws.
Life Support Policy and Use in Safety-Critical Applications:
A7’s products are not authorized for use in life-support or safety-critical applications. Use in
such applications is done at the sole discretion of the customer and A7 will not warrant or
authorize the use of its devices in such applications.

Table of Contents
Table of Contents
Introduction..............................................................................................................................1
Manual Conventions ............................................................................................................. 1
Getting More Information ...................................................................................................... 2
Bluetooth Overview.................................................................................................................3
What is Bluetooth? ................................................................................................................ 3
What is a Profile? .................................................................................................................. 4
Bluetooth and Wi-Fi............................................................................................................... 5
Security ................................................................................................................................. 5
The Basics................................................................................................................................7
Command Mode.................................................................................................................... 7
Data Mode............................................................................................................................. 7
Resetting the eb505 to the Factory Default Settings ............................................................ 8
Switching between Data Mode and Command Mode........................................................... 8
Hardware Connections ...........................................................................................................9
Command Set.........................................................................................................................11
Command Basics ................................................................................................................ 11
Connect ............................................................................................................................... 12
Delete Trusted Device......................................................................................................... 13
Disconnect........................................................................................................................... 14
Get Address ........................................................................................................................ 15
Get Connectable Mode ....................................................................................................... 16
Get Encrypt Mode ............................................................................................................... 17
Get Escape Character......................................................................................................... 18
Get Flow Control ................................................................................................................. 19
Get Link Timeout................................................................................................................. 20
Get Name ............................................................................................................................ 21
Get Security Mode............................................................................................................... 22
Get Visible Mode................................................................................................................. 23
Help ..................................................................................................................................... 24
List Trusted Devices............................................................................................................ 25
List Visible Devices ............................................................................................................. 26
Reset Factory Defaults........................................................................................................ 27
Return to Data Mode........................................................................................................... 28
Set Baud Rate..................................................................................................................... 29
Set Connectable Mode........................................................................................................ 30
Set Encrypt Mode................................................................................................................ 31
Set Escape Character ......................................................................................................... 32
Set Flow Control.................................................................................................................. 33
Set Link Timeout ................................................................................................................. 34
Set Name ............................................................................................................................ 35
EmbeddedBlue 505 User Manual ▪Page i

Table of Contents
Set Passkey.........................................................................................................................36
Set Security Mode ...............................................................................................................37
Set Visible Mode..................................................................................................................38
Switch to Command Mode...................................................................................................39
Version.................................................................................................................................40
Firmware Upgrade..................................................................................................................41
Upgrading the eb505 Firmware ...........................................................................................41
Error Codes.............................................................................................................................45
Technical Specifications.......................................................................................................47
Operating Parameters .........................................................................................................47
Dimensions ..........................................................................................................................48
Pin out..................................................................................................................................49
Frequently Asked Questions ................................................................................................51
Contact Information...............................................................................................................53
Page ii ▪EmbeddedBlue 505 User Manual

Table of Figures
Table of Figures
Figure 1: eb505 Module.............................................................................................................9
Figure 2: eb505 Dimensions....................................................................................................48
EmbeddedBlue 505 User Manual ▪Page iii

Table of Tables
Table of Tables
Table 1: eb505 Error Codes.................................................................................................... 45
Table 2: eb505 Operating Parameters.................................................................................... 47
Table 3: eb505 Dimensions .................................................................................................... 48
Table 4: eb505 Pin out Description......................................................................................... 49
Page iv ▪EmbeddedBlue 505 User Manual

Introduction
Introduction
Congratulations on your purchase of the EmbeddedBlue 505 (eb505) serial Bluetooth
module. The eb505 is designed for direct connection to microcontrollers with a 5V serial
interface enabling wireless communications with other Bluetooth devices including cellular
phones, handheld computers, PCs, and other serial port adapters. Hobbyists, developers,
and OEMs can take advantage of advanced wireless connectivity with this easy to use
module.
The eb505 module provides a point to point connection much like a standard serial cable.
Connections are made dynamically and can be established between two eb505 modules or
an eb505 module and a standard Bluetooth v1.1, v1.2, or v2.0 device. Devices can be
dynamically discovered and connected in an ad-hoc manner.
Manual Conventions
Below is a list of typographical conventions used in this manual:
Text in this font
•Is used to show data that is sent to the eb505.
•Inside a gray box is used to show data that is sent from
the eb505.
Text in this font
•Is used to show source code
In the command set section of this manual
•Required parameters and placeholders appear in standard lowercase type.
•Placeholders appear in
italics. For example, if address shows up in a syntax
line, the actual address of the device must be entered.
•Required parameter options are separated by a vertical bar |.
•Optional parameters are enclosed in brackets [ ].
EmbeddedBlue 505 User Manual ▪Page 1

Introduction
Getting More Information
The Bluetooth website, www.bluetooth.com, contains the Bluetooth specification, profiles,
and other documents relevant to Bluetooth.
General information regarding the eb505 module, EmbeddedBlue, and other Bluetooth
products from A7 Engineering can be found on the A7 website at www.a7eng.com.
A7 Engineering provides technical support for EmbeddedBlue products through an online
discussion forum at www.a7eng.com/support/forum/forum.htm. When you visit the forum you
can search through previously asked questions for information or post new ones. The forum
is monitored by A7 Engineering employees so that your question will be answered in a
thorough and timely manner. If your question involves sensitive information you can request
A7 Engineering also provides professional design services on a contract basis to anyone
requiring assistance with their design and/or development of Bluetooth products. For further
information visit the A7 Engineering website www.a7eng.com/services/services.htm.
Page 2 ▪EmbeddedBlue 505 User Manual

Bluetooth Overview
Bluetooth Overview
What is Bluetooth?
To put it simply, Bluetooth is a technology standard for electronic devices to communicate
with each other using short-range radio. It is often referred to as a “cable replacement”
technology, because it is commonly used to connect things, such as cameras, headsets, and
mobile phones that have traditionally been connected by wires. Bluetooth is much more than
simply a way to cut the cord between today’s existing electronic devices. It is an enabling
technology that will take these devices to new levels of productivity and functionality and
enable a whole new class of devices designed with communications and connectivity in mind.
The Bluetooth Special Interest Group (SIG) defines Bluetooth a bit more broadly as the
"worldwide specification for small-form-factor, low-cost radio solutions that provide links
between mobile computers, mobile phones, other portable devices, and connectivity to the
Internet." In defining Bluetooth, the SIG has taken a very different approach than the IEEE
802.11 Committees did. Rather than build Bluetooth as an adjunct to TCP/IP, it was defined
as a standalone protocol stack that includes all layers required by an application. This means
that it encompasses not only wireless communications but also service advertisement,
addressing, routing, and a number of application-level interfaces referred to as profiles.
Bluetooth is based on a frequency hopping spread spectrum (FHSS) modulation technique.
The term spread spectrum describes a number of methods for spreading a radio signal over
multiple frequencies, either simultaneously (direct sequence) or in series (frequency
hopping.) Wi-Fi devices are based on direct sequence spread spectrum transmission which
uses multiple channels simultaneously. While this technique increases the speed of
transmission (for example in Wi-Fi from 1.5MHz to 11MHz), it is more susceptible to
interference from other radio sources as well as being a greater source of interference to the
surrounding area.
In contrast, Bluetooth utilizes the frequency hopping method of spread spectrum which uses
multiple radio channels to reduce interference and increase security. The signal is rapidly
switched from channel to channel many times per second in a pseudo-random pattern that is
known by both the sender and receiver(s). This provides robust recovery of packet errors
caused by interference from another radio source at a particular frequency. Also, data is
generally more secure because it is not possible to receive more than a fraction of the data
EmbeddedBlue 505 User Manual ▪Page 3

Bluetooth Overview
unless the hopping pattern is known. Bluetooth utilizes frequency hopping in the 2.4GHz
radio band and hops at a relatively fast pace with a raw data rate of about 1 Mbps. This
translates to about 700 kbps of actual useful data transfer. The eb505 module supports a
maximum sustained bidirectional data rate of 230.4kbps.
What is a Profile?
Bluetooth devices can support interoperability with one or more types of devices. In order for
two Bluetooth devices to communicate with each other, they must share at least one common
profile. If I want a Pocket PC to communicate with my EmbeddedBlue radio I need to make
sure that they both support the same profile. EmbeddedBlue devices support the Serial Port
Profile (SPP) which is one of the earliest
and most widely supported profiles.
The main elements of the Bluetooth
stack are shown in the figure to the right.
As with a typical diagram of the TCP/IP
stack, there are a number of details that
are hidden by the apparent simplicity of
the stack. Specifically, there are a
number of profiles that sit roughly on top
of the L2CAP layer that provide much of
the power (and also the complexity) of
the Bluetooth protocols.
These profiles are the primary entry into
the stack for an application. Essentially,
they define the set of services that are
available to that application. Currently
there are more than 25 different profiles
defined or in the process of being
defined by the Bluetooth SIG. With so
much variety, acquiring an in-depth
understanding of Bluetooth is not a trivial
task. However, the abstraction by a
single profile can provide an application
the use of the profile without such detailed knowledge.
There are a number of profiles that are exposed in very familiar forms. The eb505 module, for
instance, implements the SPP profile which enables it to appear like a traditional serial port.
This virtually eliminates the need for the user to have specific Bluetooth knowledge and
allows the radios to be integrated into applications very quickly.
Page 4 ▪EmbeddedBlue 505 User Manual

Bluetooth Overview
Bluetooth and Wi-Fi
Bluetooth and Wi-Fi are often compared to each other because they are both capable of
providing networking on the 2.4GHz consumer frequency band. Many of the differences
between these two technologies can be traced to the fact that networking was not the primary
design goal for Bluetooth as it was for Wi-Fi. With a greater transmission range (about 100
meters indoors) and larger bandwidth (about 11Mbps), Wi-Fi is typically the better choice for
wireless LANs and Internet connectivity.
Bluetooth on the other hand was designed for driverless, cordless connectivity between
devices. Because Bluetooth transmitters are smaller in size, have lower power demands, a
more limited range (10 - 100 meters) and narrow bandwidth (1Mbps), they are better suited
for use in embedded and mobile devices that exchange smaller amounts of information while
conserving power and space.
While their functionality does not compete directly, 802.11b and Bluetooth do compete for the
airwaves. Since they both operate on the 2.4GHz band of the ISM radio spectrum, these two
wireless technologies may interfere with each other. Bluetooth devices minimize interference
by employing a frequency-hopping spread spectrum scheme that changes the frequency
used about 1600 times per second. Unfortunately, since Wi-Fi uses a direct sequence spread
spectrum method, this also means that Bluetooth transmissions will collide with those of any
nearby 802.11b devices and slow Wi-Fi data transmission rates. The Bluetooth SIG and its
member companies have put a lot of effort into coexistence solutions for these two standards
and are very committed to ensuring that these devices work well together.
While 802.11b was designed solely for data communications, Bluetooth takes things quite a
bit further. A key component of the Bluetooth standard is its notification and service discovery
mechanism. This allows Bluetooth devices to identify themselves and describe their
capabilities to other Bluetooth devices in the area. For instance, the Dial-Up Networking
profile defines how discoverability can be used to locate and connect to other devices such
as a cellular phone that supports the same profile. The profile then describes how to dial the
phone, connect to either analog or data services, and control the connection seamlessly. This
combination of dynamic discovery of services and built in definitions of the services goes well
beyond anything offered by the 802.11b protocol.
Security
Bluetooth security is defined by three main elements: availability, access, and confidentiality.
It is important to distinguish between these elements because Bluetooth security is also
highly configurable so that it can meet the needs of devices in many different scenarios. An
understanding of the basics will provide the knowledge that you need to choose a security
strategy for your device.
The first important element of Bluetooth security is availability. If a device cannot be seen or
connected with, it is obviously quite secure. Bluetooth defines both of these features as part
EmbeddedBlue 505 User Manual ▪Page 5

Bluetooth Overview
of the security model and they are exposed by the EmbeddedBlue device through the set
visible and set connectable commands. This is a very coarse level of control, but it is also
quite effective and can be used in combination with other security features.
The second and most complex element of Bluetooth security is access control. This type of
security is only relevant when the module is connectable and is designed to provide
protection in this case. The general idea is that remote devices must become trusted before
they will be allowed to connect and communicate with the EmbeddedBlue module. In order to
become trusted, a remote device must present a passkey that matches the stored local
passkey. This only needs to be done once, as both devices will remember their trusted status
and allow future connections with that specific device without exchanging passkeys again.
The EmbeddedBlue module uses the set security command to configure access control.
There are three possible settings for security, off, open, and closed. When security is turned
off, connection attempts will be allowed from all remote devices. When security is set to open,
connections are only allowed from trusted devices, but new devices can become trusted by
presenting the correct passkey. Forming a trusted relationship is carried out automatically in
this mode the first time that a remote device connects with the EmbeddedBlue module. When
security is set to closed, only connections from trusted devices will be allowed and no new
devices may become trusted. Closed security is the most restrictive setting and therefore the
most secure.
The last element of Bluetooth security is confidentiality. Once a link with a trusted device has
been established, it may be important to know that the data being transmitted cannot be
intercepted by a third party. All transmitted data can be encrypted by configuring the encrypt
setting to on. This only has an effect when security is set to either open or closed. The
EmbeddedBlue module supports 56-bit encryption by default, but 128-bit encryption is
available. Due to export restrictions to certain countries, firmware supporting 128-bit
encryption is only available with proper approval from A7 Engineering.
Page 6 ▪EmbeddedBlue 505 User Manual

The Basics
The Basics
Most of the complexity of working with Bluetooth has been encapsulated in the
EmbeddedBlue module in order to make it easier to use. The specific application profile that
is supported is SPP, or the Serial Port Profile. This is the most popular and convenient
protocol for many embedded applications of Bluetooth since it emulates a simple serial port
link between devices. Once the connection is set up, it is a simple matter to communicate
between the endpoints of that connection using familiar and well-supported programming
constructs.
Command Mode
The eb505 supports two main operating modes: command mode and data mode. Upon
power up, the eb505 enters command mode and is ready to accept serial commands. The
factory default communication parameters are 9600 Baud, 8 Data Bits, 1 Stop Bit, No Parity,
and No Flow Control. The eb505 supports commands to modify the baud rate and flow
control settings.
In this mode there are a number of commands that can be sent to change the baud rate,
locate other devices that are in range, check the firmware version, etc. All commands are
sent using visible ASCII characters (123 is 3 bytes “123”). Upon the successful transmission
of a command, the ACK string will be returned. If there is a problem in the syntax of the
transmission then a NAK string is returned. After either the ACK or NAK, a carriage-return
<CR> character is returned. When a prompt (<CR> followed by a ‘>’) is returned, it means
that the eb505 radio is in the idle state and is waiting for another command. White space is
used to separate arguments of the command and a carriage-return <CR> (ASCII 13) is used
to mark the end of the command.
Data Mode
Once the eb505 radio is connected to another Bluetooth device, the eb505 automatically
switches into data mode. All data transmitted while in this mode will be sent to the remote
device and, therefore, NO further commands can be sent until the eb505 radio is
disconnected or switched back to command mode by use of the mode control I/O line or the
Switch to Command Mode sequence.
EmbeddedBlue 505 User Manual ▪Page 7

The Basics
The connection status line of the eb505 module can be monitored to determine if there is an
active connection. Additionally, whenever a connection is present, the Connection Status
LED on the eb505 module will be on.
Resetting the eb505 to the Factory Default Settings
There are two different mechanisms to reset the eb505 module to the factory default settings.
Either by shorting the STATUS and MODE pins (pin 8 and pin 9) and then applying power to
the eb505 module, or by issuing the reset command to the eb505; see the command set
reference at the back of this manual for the syntax of the reset command.
Switching between Data Mode and Command Mode
When a Connection command is issued, the eb505 attempts to establish a connection to the
device with the address specified in the command. Once a connection is established, the
eb505 switches into data mode. At this point all data sent to the eb505 is transmitted to the
remote Bluetooth device over the wireless link. It is possible to switch from data mode to
command mode, issue commands, and then return to data mode, while maintaining a
connection. The eb505 allows you to switch between data mode and command mode by
issuing the Switch to Command Mode and Return to Data Mode commands or by driving the
MODE control I/O line (P6) of the eb505 module.
Page 8 ▪EmbeddedBlue 505 User Manual

Hardware Connections
Hardware Connections
The eb505 module is designed to interface with a 5V signal environment. It supports a power
supply of 5 – 12V and can be connected directly to 0.1” breadboards and 10 x 2 sockets. All
of the required connections are contained on header CN1. In the diagram below, Pin 1 of
connector CN1 is marked with a white dot (Figure 1). A full device pin out is available in the
Technical Specifications section of this manual.
Pin 1 Marked
by White Dot
Figure 1: eb505 Module
EmbeddedBlue 505 User Manual ▪Page 9

Hardware Connections
This page intentionally left blank.
Page 10 ▪EmbeddedBlue 505 User Manual

Command Set
Command Set
The EmbeddedBlue command set is comprised of visible ASCII characters. Therefore, a
command can be issued from a terminal application, such as HyperTerminal, or directly from
a custom application program, written in a programming language such as C++ or Visual
Basic, running on a PC, using an RS232 adapter. From a microcontroller application, these
commands can be issued directly using the provided serial port functions.
Command Basics
Commands may only be sent to the module when it is in Command Mode. White spaces are
used to separate parameters of the command and a carriage-return is used to mark the end
of the command. Upon receipt of a command the eb505 begins to parse the parameters. If
the syntax of the command is correct the eb505 returns an ACK string, not the ACK character
(0x06); otherwise, a NAK string is returned. Following the ACK or NAK string is a carriage-
return (0x0D) character. If an error occurs while processing the command an error string is
returned followed by a carriage-return followed by the prompt (>) character. If the command
executed successfully the module will issue the prompt (>) character. Please see the Error
Codes section for a description of the error codes.
The following example shows the basic structure of a command. A prompt (>) is issued by
the EmbeddedBlue module. A command followed by a carriage-return is sent to the module.
The module responds with either an ACK or NAK string followed by a carriage-return. If an
error occurs, the module responds with an Err string followed by a space followed by an
ASCII string numeric value followed by a carriage-return. A prompt (>) is then issued by the
module.
>command<CR>
ACK | NAK<CR>
Err number<CR>
>
EmbeddedBlue 505 User Manual ▪Page 11

Command Set
Connect
The connect command establishes a connection to another Bluetooth device. The
connect command may be canceled before a connection is established by issuing a
carriage-return to the EmbeddedBlue device. It can take up to four seconds to cancel
the connection request.
Syntax
con address [timeout]<CR>
Parameters
address The Bluetooth address of the remote device. The Bluetooth
device address is the 48-bit IEEE address which is unique
for each Bluetooth unit. The format of a Bluetooth device
address is a series of six hexadecimal byte values separated
by colons, i.e., 00:0C:84:00:05:29.
timeout An optional parameter used to abort the connection request
after the specified number of seconds. The maximum value
is 120 seconds.
Example
>con 00:0C:84:00:05:29<CR>
ACK<CR>
>
Page 12 ▪EmbeddedBlue 505 User Manual

Command Set
Delete Trusted Device
The delete trusted device command removes the remote device from trusted status
and prevents it from being able to connect with the EmbeddedBlue device when
security is set to closed. A delete can be performed for either a single device by
passing its device address or for all trusted devices by specifying the keyword all.
Syntax
del trusted all | address<CR >
Parameters
all This parameter is used to remove all devices from trusted
status.
address The Bluetooth address of the device that should be removed
from trusted status. The Bluetooth device address is the 48-
bit IEEE address which is unique for each Bluetooth unit.
The format of a Bluetooth device address is a series of six
hexadecimal byte values separated by colons, i.e.,
00:0C:84:00:05:29.
Example
>del trusted 00:0C:84:00:05:29<CR>
ACK<CR>
>
EmbeddedBlue 505 User Manual ▪Page 13

Command Set
Disconnect
The disconnect command closes the connection with the remote Bluetooth device.
Syntax
dis<CR>
Example
>dis<CR>
ACK<CR>
>
Page 14 ▪EmbeddedBlue 505 User Manual
Table of contents
Popular Control Unit manuals by other brands

Invacare
Invacare HomeFill HF2E540M9 Operator's manual

Agilent Technologies
Agilent Technologies HP E1355A user manual

turck
turck TBEN-LH-8IOL Configuration guide

IBA
IBA ibaMS4xUCO manual

Samson
Samson 3281 Mounting and operating instructions

Bell and Gossett
Bell and Gossett Circuit Sentry Flo-Setter instruction manual

Dixon
Dixon BV2C Series instruction & operation manual

Radiometrix
Radiometrix TR2I-464-5-12.5K Implementation guide

SpeakerCraft
SpeakerCraft VST45 owner's manual

Mitsubishi Electric
Mitsubishi Electric GT1055-QSBD General description

Kodak
Kodak Carousel S-RA2000 instruction manual

Lincoln Electric
Lincoln Electric APEX 3000 Operator's manual