Setting up Xbee3 to mobile app BLE

In this tutorial, you will learn how to set up the Xbee3 using XCTU, communicate with Digi mobile app via bluetooth.

What you need before you begin:

  • Xbee3 development board with a cellular internet connection
  • A serial terminal on a PC/Mac
  • Basic understanding of the Xbee3 and Digi XCTU software
  • Install Xbee relay sample APK (https://github.com/Medium-One/XbeeRelayTestApp)  (IOS is not supported for now)

Notes:

  • This tutorial uses a Mac OS but any terminal software would work
  • This tutorial uses the Digi XCTU Version: 6.5.0
  • This tutorial use the Digi XBee® 3 Cellular Smart Modem, LTE-M/NB-IoT, Development Kit, AT&T kit (part number: XK3-C-A2-UT-U).  Theoretically, other cellular Xbee3 boards such as Zigbee should work.

Step 1: Setting Up the Xbee3 board on XCTU

Important: This tutorial assumes you're starting with the default settings of the Xbee3. 

Plug the XB3 dev board into PC and launch XCTU.

 

Make sure you have the latest firmware on the Xbee3, we currently have version 11415.

 

 mceclip0.png

 

Make sure bluetooth is enabled, click configure and set a password: we used 123456

mceclip2.png

 

Set API mode without escapesWe didn't try this with escapes so it might work fine in that mode too.

mceclip3.png

 

 

Step 2: Pair with Phone

Open the App and look for the Xbee device and click on it to pair.

mceclip4.png

 

Enter the password specified in the earlier step. (123456)

mceclip5.png

Get the this screen and you're ready to send and receive data.

mceclip6.png

 

Step 3: Send Data from Board to Phone Via XCTU

Next, we will send data from board to phone via XCTU

 

Use the Frames Generator to construct the frames. Go to Tools and click Frames Generator

mceclip7.png

 

Fill in the fields below and click Copy frame

Notes:

Mode: API1 - API Mode Without Escapes

Frame type: 0x2D - User Data Relay

Dest. interface: Bluetooth

mceclip8.png

 

Go to Tools and click Serial Console

mceclip9.png

 

In Serial Console window, click Open.

mceclip11.png

Click + button by send packet, click HEX and paste the frames copied from earlier step.

Click Add Packet

mceclip10.png

 

Click Send selected packet, this will send the packet to the Mobile app and over BT from board

mceclip12.png

Confirm that you get the message on your phone.

mceclip13.png

 

 

Step 4: Send Data from Phone to XCTU

To send data from your phone, click Send User Data Relay button. Select Serial (will send the data out the serial port of the Xbee). Type "hello from app" and SEND.

mceclip15.png

 

Confirm you see the data in XCTU.

mceclip16.png