# communication issue between two xbee modules in API mode

**URL:** <https://forums.digi.com/t/communication-issue-between-two-xbee-modules-in-api-mode/894>\
**Category:** XBee - Zigbee\
**Created:** [May 22, 2012, 2:43pm UTC](https://forums.digi.com/t/communication-issue-between-two-xbee-modules-in-api-mode/894 "2012-05-22T14:43:40Z")\
**Posts on this page:** 3\
**Page:** 1

<div class="post-metadata">

**Author:** ![ikuzar](https://avatars.discourse-cdn.com/v4/letter/i/7cd45c/32.png) [@ikuzar](https://forums.digi.com/u/ikuzar)\
**Post date:** [May 22, 2012, 2:43pm UTC](https://forums.digi.com/t/communication-issue-between-two-xbee-modules-in-api-mode/894/1 "2012-05-22T14:43:40Z")

</div>

Hi,

My goal is to establish communication between Xbee module connected to my PC and another Xbee module connected to an arduino. I 'll put program on the arduino in order to send data (Hello world) to the PC.

The first step consists in trying to establish comm using X-CTU. I met problem at this stage.

I 'm using Xbee S2. I try establish communication (characters exchange) between two Xbee S2 Module. But when I type characters in the terminal 1, I get nothing in the terminal 2.

Please see the attached file to see the configurations.  
Thanks for your help

---

<div class="post-metadata">

**Author:** ![kavya](https://avatars.discourse-cdn.com/v4/letter/k/e480ec/32.png) [@kavya](https://forums.digi.com/u/kavya)\
**Post date:** [May 23, 2012, 9:27am UTC](https://forums.digi.com/t/communication-issue-between-two-xbee-modules-in-api-mode/894/2 "2012-05-23T09:27:07Z")

</div>

Hi,

You have programmed the modules in API mode, so better to use API frames. But as a general rule of thumb, API firmware is recommended when a device:  
•sends RF data to multiple destinations  
•sends remote configuration commands to manage devices in the network  
•receives IO samples from remote devices  
•receives RF data packets from multiple devices, and the application needs to know which device sent  
which packet  
•must support multiple ZigBee endpoints, cluster IDs, and/or profile IDs  
•uses the ZigBee Device Profile services.

If the above conditions do not apply (e.g. a sensor node, router, or a simple application), then AT firmware might be suitable.

Refer the following link for generating API frame, ftp://ftp1.digi.com/support/utilities/digi\_apiframes.htm  
You can make use of ZigBee Transmit Request frame (type - 0x10)

In AT mode you can just follow the below steps  
open the Terminal tab and issue the following in order,  
+++ (OK response is returned)  
atdh=sh of receiver  
atdl=sl of receiver  
wait…  
(send the data you want)  
Hello World …  
…

In both the case, check the sleep settings of end devices.

---

<div class="post-metadata">

**Author:** ![ikuzar](https://avatars.discourse-cdn.com/v4/letter/i/7cd45c/32.png) [@ikuzar](https://forums.digi.com/u/ikuzar)\
**Post date:** [May 23, 2012, 1:29pm UTC](https://forums.digi.com/t/communication-issue-between-two-xbee-modules-in-api-mode/894/3 "2012-05-23T13:29:42Z")

</div>

what is the difference between API frames and API firmware ?  
do these configurations (API frames, API firmware) correspond to AP=1 and AP=2 ?

What should be the sleep settings ? I 'd like the xbee not sleeping.

Thanks for your help
