In a previous post I reviewed the Bluegiga WT11 Bluetooth module, now I’m going to show how to create a serial link.
Bluetooth standard defines some profiles, which are definitions of possible applications using a Bluetooth link. WT11 features several profiles; among them I’m going to use the Serial Port Profile which emulates a serial link using the RFCOMM protocol:
Connection from WT11
The first example is about a connection opened by Bluegiga module to a PC running Windows 7.
First you need to configure the OS adding a new virtual serial port:
Port type is incoming because the connection will be opened by the Bluegiga module:
Note the serial port’s name:
and connect to it using a terminal emulator (like PuTTY):
Open a connection to WT11 module as shown in the previous post and type the following commands:
SET PROFILE SPP ON – activates the SPP profile;
SET BT AUTH * 1234 – sets “1234” as pairing code;
INQUIRY 10 NAME – looks for Bluetooth devices;
CALL bt_addr 1101 RFCOMM – opens a connection with the specified device.
On the PC, you will receive a popup warning for a new connection:
enter the pairing code (1234):
If everything is ok, if you type something in the WT11 terminal, you’ll see it in the one connected to the virtual serial port. Type +++ to change into command mode and CLOSE to close the connection:
In the next page, how to open the connection from the PC…
Pages: 1 2