# Need help for Xbee s2c API mode C/C++ code

**URL:** <https://forums.digi.com/t/need-help-for-xbee-s2c-api-mode-c-c-code/20214>\
**Category:** XBee - 802.15.4\
**Tags:** c, s2c, transmitter, code, xbee\
**Created:** [January 28, 2019, 7:46am UTC](https://forums.digi.com/t/need-help-for-xbee-s2c-api-mode-c-c-code/20214 "2019-01-28T07:46:44Z")\
**Posts on this page:** 1\
**Page:** 1

<div class="post-metadata">

**Author:** ![VinayakaSp](https://avatars.discourse-cdn.com/v4/letter/v/7ba0ec/32.png) [@VinayakaSp](https://forums.digi.com/u/VinayakaSp)\
**Post date:** [January 28, 2019, 7:46am UTC](https://forums.digi.com/t/need-help-for-xbee-s2c-api-mode-c-c-code/20214/1 "2019-01-28T07:46:44Z")

</div>

I need to transmit the data between two computers using xbee s2c. I have to use C or C++ language to do the task. This need to be done using the API mode instead of AT mode. I’m unable to find an example for the same.  
I have already looked into the digi Python library, Java library and ANSI C library. Both Java and Python library github page gives examples for implementation of these libraries to transmit the data in API mode ([https://github.com/digidotcom/XBeeJavaLibrary/tree/master/examples/communication](https://github.com/digidotcom/XBeeJavaLibrary/tree/master/examples/communication) and [https://github.com/digidotcom/python-xbee/tree/master/examples/communication](https://github.com/digidotcom/python-xbee/tree/master/examples/communication)), but the ANSI C library fails to give one such example.  
I tried to understand the library source and implement, but I couldn’t do it.  
I request to help me in this regard.

PS: I’m implementing this on a normal computer, hence I cannot use anything related to Arduino code.
