Dear sir:
I want to read a open\short signal in zigbee network by your product, coneectport X8 + xbee adaptor digital I/O.
And I had searched your documentation, I see that I can run the Python program on connectport x8 and access the xbee sognal. But I want to access the signal from my pc through connectport x8 using java or c# to access open\short signal in zigbee network. Can I implement this idea by using your product.
Thanks for your help.
Ted Chen
You can absolutely use the ConnectPort X8 to read the values of an XBee Digital I/O Adapter through the ConnectPort X8 gateway via a Java or C# application.
You can write a Python application which provides access to the I/O pins of an XBee Digital I/O adapter in a variety of ways. Here are a couple of options:
You could extend the zb_tcp_serial.py example Python application to support XML-RPC methods for reading the I/O pins on an arbitrary adapter.
You could write your own simple TCP or UDP based protocol as a Python application that allows you to specify the pin of an adapter you wish to query.
The Python engine of the gateway allows for much more sophisticated scenarios as well. For example, you could write a simple Python script that monitors the I/O pins of one Digi XBee Digital I/O Adapter for change and if a change is detected to sound an alarm by raising an I/O pin on another Digi XBee I/O Adapter connected to a piezo device. In this way the ConnectPort X8 could provide autonomous monitoring and control functions of the a ZigBee network without requiring a PC. However the ConnectPort X could still simultaneously provide IP connectivity to the ZigBee network in the same Python application for use with a PC application.
This offers the you the ability to define as many points of monitoring and control of the ZigBee device network as you would like in a way that you are able to define.
Thanks for your help.
So I need to use the program to connect the Python function in TCP I can get the xbee value.
Can you help me about your digital adaptor inforamtion.
I will try it.
thanks
We get a drop in network kit. We want to use connectport x8 as pan coordinator. We want to read/write information of the end devices that have joined the PAN. We have a program running on a pc connected to the ConnectPort X8 by using ethernet port. The problem we have is reading information of the mesh. When we use a embeded we just read the COM port data flow. We are tried to do this with the connectoPort using sockets but we had no results. Could you please help me? How could we get this data flow?
I thought that wasn’t necessary to program anything on the router. I’m using factory values of the router, so the default .py is running on connectPort. Do I have to program the ConnectPort for taking mesh data flow? Or maybe using default .py program I can do that?
I re-read your previous message and now I understand that you are using the default Python script ‘zb_tcp_serial.py’ which runs by default in the Drop-In starter kit.
By default this application will create a TCP socket for each XBee serial node discovered in the network. There is no default order for these TCP sockets and they may change from one power-on to the next.
This script is intended to be a demonstration of what can be accomplished with Python and the gateway.
What do your network look like? What sort of devices are you trying to communicate with?
Depending on what sort of things you are trying to communicate with, the default .py program may be sufficient in order to test your application.
We are using 3 XBee series 2. We want to use the connectport as coordinator’s PAN. We just want to know how can we get the mesh information by the ethernet connectport x8 port. We thoght that the default application let us do that. We developed a little program in JAVA that created a socket connection with 27000 port and we can’t get data from the mesh.
In the zb_tcp_serial.py script, port 27000 is the “control port” implements a simple control interface using XML-RPC. You should be able to use just about any XML-RPC compliant library to speak to this server. The URL is http://ip.of.device:27000/RPC2
The following methods are available:
discover()
list()
get_temperatures()
Included in the Drop-In Start Kit CD is a Windows program which demonstrates this interface.
The discover() method will inform you which XBee nodes are bound to which TCP socket. If you have 3 nodes the first will be bound to 27001, the second 27002, and so on.
Passing data into these sockets should cause the same data to flow over the mesh and out of the target node.
Do I understand you correctly that you want to connect to the XBee module directly in the ConnectPort?
You cannot do that as the ConnectPort manages the radio and provides abstracted interfaces in order to make the WebUI, CLI, and Python interfaces possible.
If you wish to get PAN information there are a number of APIs available to you including an XML interface to the ConnectPort called “RCI” or writing a little Python program to query the PAN information and present it to your Java application in any format you wish.
What sort of PAN information are you interested in?