xbee3: how to send data received from serial via ble

Hey all,

My goal is to transfer all data received in the Rx pin of the serial of the xbee3 via ble to an other ble device.

Could someone point me to some documentation or/and example of how to do this?

Also, can this be achieved only with micropython (any helpful link on that?) or can it be done with simple xctu setting configurations?

Thanks in advance

You need to use API mode on the XBee 3 modules.

As for an example, I would use the XCTU Mobile app as it will allow you to do what you want.

Hi and thanks for your response.

Unfortunately, despite following the suggested principle (the usage of api mode), i have not managed to succeed.
In detail, i have set the xbee in API mode 1 (or 2) and enabled the BLE (BT=1).
Then, i sent in the serial of the xbee3, bytes which form an API frame (In example, i sent the following sequential bytes:
0x7E, 0x00, 0x07, 0x2D, 0x00, 0x01, 0x74, 0x65, 0x73, 0x74, 0x11, which based on the API frame generator it should correspond to the message “test”, with frame type 0x2d (user relay frame) and for API mode 1). Then, i connected to the xbee3 through the XCTU Mobile app(although my final target is to send to another xbee3. By the way is that possible or xbee3’s can only be ble servers?). Then nothing happened (unfortunately).

Do i miss some extra configuration from the BLE settings of the xbee3 or am i doing something wrong with the data-api frame i am sending?

Any help or suggestion is more then welcomed.

Thanks in advance

In the XCTU Mobile app, you need to discover the XBee first. Then once added, go to the Frames Relay Console found under the triple dot menu in the upper right. They send your data back and forth. Your frame worked for me and this worked for me as well.


glad that my api frame worked in your test, but in mine setup nothing happened…I connect to the XBee, provide the password, open relay console and tried to send a frame…it just doesn’t work…

Could you please provide me with the xctu settings you have configured, if that’s not a problem for you?

Thanks in advance!

Other than API mode being enabled, I have firmware version 100B installed, BT Enabled, and BI set.

I also have the XCTU set for the terminal emulator on the same COM port and open.


my bad, I was creating the wrong api frame (wrong frame type). Fixing that enabled me to send with ble! Thanks for your input.

May I ask though, can I also transmit to an other XBee3 via BLE? Or XBee3 can not act as a BLE client?
In the latter case, can I then transmit to an other ble device? And if so, is there any guide/example or could you please provide me some guidelines?

PS: shall I post this in a new post or is it ok?

Thanks in advance!

No, you can connect two XBee 3 modules via BLE and communicate.


thanks for your reply!
So, how exactly do i do this?
All I need to do is to set BT, BI and set for API Frames (which I send through serial) and it is good to go?

Thanks in advance!

That is correct.

Hi again,

Unfortunately, I just keep failing…
I have sent the frame:
7E 00 07 2D 00 01 54 45 53 54 91
which never reaches the other xbee…Instead all I get is the following transmit status message (in the xbee which transmits): 7E 00 03 89 00 7D F9
(Interface not accepting frames)

Do you have any ideas or suggestions?

Thanks in advance!

That sounds like you don’t have both BLE interface options enabled and connected.


thanks for your reply!
So, what do you suggest?
I have already enabled BLE with BT option (both enabled).
How do I get them connected?

Thanks in advance!




Thank you! Thanks for all the resources given.

I am going to check them thoroughly. Untill then I would like to mention though that it seems like you refer to xbee3 cellular…Hopefully, it’s the same for the xbee3.
Also, considering that only one link is not strictly about micropython and it specificallly regards how to unlock API, does it mean that in order to send api frames, I firstly have to unlock the api?
But how do I make the first steps like scan for advertisements, turn on indications and connect to gatt server via xctu?

Thanks in advance!

For what you want to do, it is done in the Micro Python code instead. I referenced the API options so you can see how some of that would be done outside of Micro Python.