set the transmission channel

In peer to peer mode.
I want two RF modules can be connect and transmission data.
I already know the end device’s channel is set to 0x17(use ND command).
Now i try to set the CH(channel number) to 0x17,but it wrong .
When i set the CH to 0x17,the return value is “3”,not “1”(success) or “-1”(error).
What it’s mean? And what’s wrong?

Thanks for your reply.
eienLin

I think 3 means “Parameter error”. Can you post the exact command you’re sending, and also tell us what version of firmware you’re using?

The version of firmware that i using is “1097”.

The cmomand i’m sending is following:
chn=xb_setCH(7); //i use rabbit’s zigbee application kit. 7 is mean 0x12.
chn=xb_getCH(); //in watches windows chn=1(it mean 0x0c)
flag=xb_getDN(“002”);
flag=xb_getVR();

//i use X-CTU to set the RF module’s NI is “002”,but the value of flag is 0x0000.
And when i use xb_getVR() command the value of flag is also 0x0000.
i think the command is invalid.

what’s wrong?
Very thinks for your reply.

I’ve been trying to reproduce your problem, but Strange Things are happening.

On an XBee Pro Rev B running firmware version 10c8, I attempted to set the channel by sending this API packet:

7e // start of packet
00 05 // payload length 5 bytes
08 // packet type “immediate AT command”
01 // frame id
43 38 // CH *** Edit! that’s a typo - should be 43 48 ***
0c // channel 0x0c
5f // checksum

But what came back was this:

7e // start of packet
00 // first length byte (msb)
c6 00 ff // Huh?
88 // packet type “local AT response”
01 // frame id
43 48 // CH
00 // status ok
eb // checksum

That “c6 00 ff” sequence ought to have been a single “05” for the payload length. As it is, my software then hung because it was expecting the rest of a packet of length 0xc6 = 198 bytes.

I’ll obviously need to spend more time on this with a careful examination of my software, but meanwhile does anyone else have any observations?

To eienlin: when I asked you to post the exact command and response, I was hoping for something in the above format but I didn’t make that clear. Does the rabbit system let you see that?

Message was edited by: johnf