ZDO_IEEE_ADDR_REQ

hi there,

Can someone shed a little light on how can I do a ZDO call for ZDO_IEEE_ADDR_REQ command base on a arbitrary set network address?

I know how to do it in Python on the X4, but not so sure how to use the XBee’s Freescale’s Libary to do so over C on the Programmable Module…

If there’s an example project code that utilizes any ZDO call in CodeWarrior’s IDE; I could trace my way backwards to see how to do it. But unfortunately, there isn’t unless I’m mistaken

You have looked through the Programmable Xbee SDK? You imply perhaps you have, but don’t actually say it.

I don’t know the answer, but will see if I can find one.

Here is one answer I got from Digi programmers:

The current version of the stack includes an API for sending a NWK_addr request (see zdo_send_nwk_addr_req), but not an IEEE_addr request. It should not be difficult to use the NWK_addr code as a template for writing something to do an IEEE_addr request.

I’m not sure if that function was included in the latest release of the PXBee dev kit.

There really hasn’t been an instance where I’ve needed to go from network address to IEEE address – any packet that comes in will include both, and even the discovery will result in responses that have both.

Hi Lynn… thanks for the reply… Been waiting for the updates even from the Online Support Request site… it’s still in Pending Engineering status.
Yes I’ve looked through the SDK.

My application (in ZB Pro 2007 Stack Profile mode) requires my ZED (ZB End Device) to send a string of data upon awake status. Included in the string will have the parent’s IEEE address. But to do so, the SDK did not show (or at least I’m not aware of) how can I retrieve the parent’s IEEE address (this is a must-have feature).

Thus I figured out an idea, poll using AT method to retrieve the NWK address of the parent via MP command, then do a ZDO_IEEE_ADDR_REQ just like in python (tested on a CPX device), or format the packet manually using the Digi API Frame maker . Problem is, the SDK did not show any write-ups on how can I use the existing ZDO features in the XBee firmware via a C-API. However, the SDK did couple some additional ZDO features that was missing in the XBee firmware. (E.g.: match descriptor, zdo_mgmt_leave_req, zdo_send_bind_req), and even created APIs for data structures on the existing ZDO library present on Ember, but not any scripts to interact with them.

My guess is, to write my own byte frame packet in C and execute it in main() and then retrieve the output … but even that I’m not sure how to do and presently seeking assistance for it… (Note: this method uses the radio)

Of course, ideally if I can access the HCS08 memory and retrieve the Parent’s IEEE addr would be better so I can minimize radio talk… but for now, I’m open to the easiest method I’m most familiar with or guided to do…

So… I’ve got some updates here from Digi’s Software Team…
They had sent me a pre-released library and header file for the ZDO API library used by the Freescale HCS08 uC. The following is an email respond from the Digi,

Hello, I have a response from Software. They have given me a pre-released library and header file with the following information:

The current version of the stack includes an API for sending a NWK_addr request (see zdo_send_nwk_addr_req), but not an IEEE_addr request. It should not be difficult to use the NWK_addr code as a template for writing something to do an IEEE_addr request.

This library has not been officially released and is being provided on an as-is basis to you. Let me know if this takes care of your issue.
Still… here I’m still stuck several days now to write the correct script on main.c to call and execute the API for zdo_send_nwk_addr_req().
I’ve to admit, my limited but growing C Knowledge is to blame. But that’s also includes the ambiguity of the API’s correct usage (not much comment threads, wiki or examples to dig)
For example, at line 923 and line 924, address of req was pointed to the envelope.payload pointer… but what’s the payload then when the beginning of the function did not declare a value for req ???

envelope.payload = &req; 
envelope.length = sizeof req;

I’m really loss since there are very little examples on utilizing the ZDO library shared between Ember and Freescale. I’ll be posting updates if I do find an answer eventually. But as for now, I welcome any ideas to anyone out there willing to try what I’m pursuing or had already done so… :slight_smile: