dulu93
dulu93

Reputation: 11

Xbee 802.15.4 Waspmote & XCTU - configuration issue

I have a project that requires a 802.15.4 network. For that I am using 1x Xbee S1 connected via USB-dongle and 1x Xbee S1 on a waspmote.

Now heres the following problem:

If I configure both modules via XCTU, they can communicate. BUT if I configure one module via XCTU and the other one via WaspmoteIDE with the API v28 like this:

uint8_t panid[] = {0x12, 0x34};

void setup(){ 
  xbee802.ON(SOCKET0);
  xbee802.setPAN(panid);
  xbee802.writeValues();
}

From my understandig this should write these values to the xbeemodule and set the PAN-ID to 1234. Correct me if Im wrong but as far as I know these values should be stored in xbee802.PAN_ID[0] and xbee802.PAN_ID[1].

But if I want to retrieve the info wheter the data was written or not with

xbee802.getPAN(); 

The output is 01. But if I try:

xbee802.PAN_ID[0] = panid[0];
xbee802.PAN_ID[1] = panid[1];

and then when I print xbee802.PAN_ID[0] and xbee802.PAN_ID[1] I get the PAN-ID I wanted to set which is 1234. But then when I want to check the Pan-ID again with xbee802.getPan() I get this annoying 01.

And to confuse me a little more.. when I put the xbee module from the waspmote into the usb gateway and check the settings via XCTU, the changes I thought I made via the waspmote were not written and no communication is possible. Communication is only possible when I write the Settings to Both xbeemodules via XCTU.

On the other hand, when I configure the xbee module connected via usb dongle with the java driver and then check the settings in XCTU, they take effect. so no problems manipulating the parameters via java-driver.

What am I doing wrong that I cannot configure the xbee module through my waspmote.

Both modules: product family: XB24 function set: xbee 802.15.4 firmware version: 10ef

Upvotes: 0

Views: 188

Answers (1)

dulu93
dulu93

Reputation: 11

For anyone interested in using a xbee 802.15.4 module with a waspmote and experiencing a similar problem:

Make sure your xbee module is set to API-Mode, otherwise it will not react to the changes that are supposed to be written through the waspmote.

Upvotes: 0

Related Questions