Home/Support/Support Forum/Connectport X4 802.15.4 uses socket.recvfrom but can not return address?
Welcome to Digi Forum, where you can ask questions and receive answers from other members of the community.

Connectport X4 802.15.4 uses socket.recvfrom but can not return address?

0 votes
Hi everyone,
My connectport X4 version is 802.15.4, and the firmware is 2.17.0.5. I have already received the message from XBee s1 by using socket.recvfrom() function.
However, as we know that through its function we can get two returning values, one is the message and the other is the sender's address.
The problem that puzzles me too much is that I can not get the sender's address. Instead, I get the address is "('[0000]!', 0, 0, 0, 0, 0)".

Here are some parts of my python codes:
sock = socket(AF_XBEE, SOCK_DGRAM, XBS_PROT_TRANSPORT)
print "Binding to Digi Mesh"
sock.bind(("", 0x00, 0, 0))##If I change to sock.bind(("", 0xe8, 0, 0)), I could not receive any message.
while 1:
data,add=sock.recvfrom(255)
print data
print add


I don't know how to distinguish the messages from different Xbee s1 when they send messages at the same time.
asked Jul 29, 2014 in Python by M201370387 New to the Community (0 points)

Please log in or register to answer this question.

1 Answer

0 votes
did you remove the xbee radio from the X4? That's strange your getting a 0000 address for the source. It's like your receiving packets from the local radio. I don't think it would do that.

Your bind settings look correct.

Do you have another remote node that is sending data to your X4? what kind of radio and firmware does it have?
answered Aug 4, 2014 by kjensen8 Veteran of the Digi Community (623 points)
...