Title: Testing Android application (S2
Bluetooth Terminal)
- - To
test the Android application of S2 Bluetooth Terminal whether it is compatible
with the Bluetooth Module.
Interface
between Bluetooth Terminal and Bluetooth Module
PROCEDURE
This
process assumes the application of ‘S2 Bluetooth Terminal’ has been installed
on smartphone and the type of Bluetooth module used is ‘HC-05’. Below is the
procedure for communicating virtual communication between ‘S2 Bluetooth
Terminal’ and ‘HC-05’ Bluetooth module.
Bluetooth settings
This
is the first screen we will see when we want to let the virtual communication
begins. Since ‘S2 Bluetooth Terminal’ is all about connecting phone to the
Bluetooth module, the very first step to do is to search for Bluetooth device
that we want to talk to. Sometimes we would find more than one device because
of other Bluetooth devices around us. We need to find out which one is our device
which has been set to the Bluetooth module. If our device does not appear on
the phone screen, we should check if Bluetooth module is powered and
discover able.
Bluetooth pairing request
After found the device that we want
to connect, tap on the ‘HC-05’ device and the Bluetooth pairing dialog will pop
up. This is the part where we enter Bluetooth module’s PIN to begin pairing.
The PIN act as a password and the PIN set will be ‘1234’. Some modules will
have ‘0000’ but it is less common. Type it in and hit “OK”. If the PIN is
right, pairing is done.
After pairing request is
successful at the Bluetooth settings, we need to open up the ‘S2 Bluetooth
Terminal’ application to make a connection with Bluetooth module. This
application is terminal software for communication with the Bluetooth device by
using SPP (Serial Port Profile) and equivalently liked to a serial port line
connection including transmitter and receiver signal. Once again we need to
select ‘HC-05’ device to make a connection. Then, the ‘connected to HC-05’ will
pop op on the screen indicated that the connection between application and
HC-05 Bluetooth module is successful.
Successfully connected device
As shown Figure 4.3 above, if we
managed to add our Bluetooth device to application of ‘S2 Bluetooth Terminal’
we will see one new device, namely the device we added at the top of the phone
screen. This time it should connect successfully indicated by a dialog of
“connected: HC-05”. If not, repeat the pairing process.
Result and Analysis
First of all, power on the
Bluetooth. Then, at the Bluetooth settings, search for a device of HC-05 and
begin the pairing with this device. The Bluetooth module will ask for password.
Enter the correct password and it should start pairing. Later, take the
smartphone and open up the Android application to let the virtual communication
begin between the Bluetooth module and the smartphone. Hit the connect button
shown at the Android application it should start connecting. If connection
could be established the red LED on the Bluetooth module will double flicker
per second and the green LED will continually light up.