Hello, while I can perfectly receive and print messages with my CPX8 on the standard Data Endpoint 0xe8, when I try the same thing e.g. on Command Endpoint 0xe6, with the similar program (only changed is 0xe6 instead of 0xe8)
from socket import *
sd = socket(AF_ZIGBEE, SOCK_DGRAM, ZBS_PROT_TRANSPORT)sd.bind( (‘’, 0xe6, 0, 0) )
buf, addr = sd.recvfrom(128)
print “Received ‘%s’ from ‘%s’” % (buf, str(addr))
I need this because I need to intercept non-Digi traffic.
Also I tried endpoint 0x01 with no result.
Also I tried substituting ZBS_PROT_TRANSPORT with ZBS_PROT_APS without seeing anything.
Please note that I can see the messages exchanged between these endpoints with my Ember sniffer.
What went wrong ? Anyone has some hint ?
Forgive my potential butchery of terms, but allow me to try to better understand your request…
Are you trying to sniff traffic that is not “broadcast” traffic that is not destined for your radio?
I’m trying to get a sense of the application environment.
Sure, you’re right, I have not well explained my environment.
I have my CPX8 with two Digi nodes from the Networking Kit, a RS232 adapter and a Sensor.
I have also other Ember-based nodes, which I will introduce later in this reply.
I have modified an example Python software to receive and print traffic on an endpoint passed as an argument to the program. It behaves well on endpoint 0xE8 (Digi Data EP) and prints out a frame when I start it on EP=0xE8 and I press the reset button on my Digi modules.
First problem: when I start the program on EP=0xE6 (Digi Command EP) and then I command a Node Discovery with the WEB interface of CPX8 (XBee Network, Refresh with Clear List checkbox checked), the program does not gather the Node Discovery response (I see it with a sniffer, on EP=0xE6).
Is it a particularity of E6 endpoint ?
Second problem: I made this experiment because my real target is to capture (and in future to transmit over TCP/IP) the traffic of my Ember-based nodes, who talk presently over EP=0x01. My Ember nodes now join to the CPX8 network and are seen correctly in the “XBee Network” view, because I implemented in their firmware the Digi Node Discovery response.
So I made a second test, by launching my Python program on EP=0x01, but got no success.
Currently, the traffic over EP=0x01 (sensor traffic, a sensor node sends packets to a sink node) is not directed to the Digi gateway (= coordinator), so I think you are right, I’m really trying to sniff traffic not directed to my radio.
Must I implement a message from my (sink) Ember node to the gateway ?
I hope I now explained my environment (I also made another post named “connecting non-DIGI nodes …” and also got there useful hints). Thank a lot for your patience …
Have the CP-X8 and the RS232/Sensor Adapters been migrated over to the ZB firmware? Also, has the CP-X8’s EOS firmware been updated to the latest 2.8.1.x release? These would be necessary to allow the CP-X8 to funtion with non-Digi Zigbee devices.
Yes, all was updated … and, yes, now I correctly receive and print my data on endpoint 0x01 !
Previously, I tried to “sniff” data transmitted from my sensor nodes to my sink node (I have an Ember-based network) and got no success. Now (after the hint received in previous reply, thanks …) I implemented a new message: when a sink node receives a data message from a sensor, it formats and sends the same data to the coordinator, and now the Python program correctly receives and prints these data. You think this is the right approach ?
Now I will proceed with my tests … thank you.