Home/Support/Support Forum/XBee S2C communication with Non Digi device

XBee S2C communication with Non Digi device

0 votes
Hello,
I am working with XBee S2C wire antenna device connected to the host controller and want to connect it with non-Digi manufactured zigbee device.

I have configured XBee S2C into Home Automation profile already as a router and put it into PAN ID where other devices are present.
Also, using XBee python library for communication purpose and acquainted with discovering the network, explicit API format for sending and receiving callbacks.

Here are some of my queries:
1. How to really configure the device apart from settings in XCTU?
2. There are 2 endpoints required as in to report 2 outputs to coordinator, but I am not able to find a way to configure endpoints on my XBee through python APIs or any other way. Can you please give me inputs? In that case, what values are applicable to Source and Destination endpoints fields in XCTU?
3. I am able to discover devices (nodes) in the same pan id in XCTU -> Scan but the response while discovering the nodes from python code is intermittent – sometimes the devices are not discovered. Is there any reason for this?
4. I can see the Tx and Rx messages being exchanged when port is closed in XCTU using explicit frames. But these messages are not received in my python code even though callback has been added to receive explicit frames (send_expl_data - 0x11). What could be the reason?


If you have any code examples, request you to share examples with me for connecting XBee with external devices.

Thank you very much.
asked Feb 24 in RF Solutions and XBee by gsshewalkar New to the Community (1 point)

Please log in or register to answer this question.

1 Answer

0 votes
Gsshewalkar,


You would be using API mode which mean that all of your data from your device entering into the radios UART will be in Digi's API format.

The information on the API can be found at https://www.digi.com/resources/documentation/digidocs/90002002/default.htm#Reference/r_send_ZDO_cmds.htm%3FTocPath%3DAPI%2520Operation%7C_____3 for sending ZDO or ZCL commands (using Zigbee end points).

Yes, if you issue the command when other data is occurring, the command would time out and no data would be provided.


I don't know what Python library you are working with. It could be simply that it does not support the Explicit frames.

Digi Support
answered Feb 24 by mvut Veteran of the Digi Community (11,963 points)
Thanks for the response.

I am working on xbee python library version 1.3.0

Yes, I am using API mode and I can connect two XBees, I can exchange explicit frames between them using python library.

Sample code as below:
device = ZigBeeDevice(SERIAL_PORT, BAUD_RATE)
device.open()
        
mode = APIOutputModeBit.calculate_api_output_mode_value(device.get_protocol(),                                 {APIOutputModeBit.EXPLICIT})

device.set_api_output_mode_value(mode)

#Receiving callback
device.add_expl_data_received_callback(explicit_data_callback)

#Send data
remote_device = xbee_network.discover_device(REMOTE_NODE_ID)
device.send_expl_data(remote_device, DATA_TO_SEND, SOURCE_ENDPOINT,
                              DESTINATION_ENDPOINT, CLUSTER_ID, PROFILE_ID)


But, my ultimate aim is to pair XBee radio with NonDigi Zigbee module, for which I am facing issues as in how to configure multiple endpoints, clusters and custom attributes using python APIs (or any other way) so as to report 2 sensor outputs to NonDigi Zigbee module.

Please guide.
...