AT command XBee from atmega to disable DIO5 (associated led) I community! I need put ATcommand to my XBee from my atmega using a "xbee library" and a function that I have found in internet. I think the ATComand is "ATD50" to change the DIO5 to value "0" (disabled). My intention is to turn off a led connected into DIO5 (digital input/output 5 (associated led)) after X second/minutes of turning on the device (so that it doesn't turn one again after initial check). 

This is a part of my code:

#include &lt;XBee.h&gt;
XBee xbee = XBee();
uint8_t atdCmd[] = {'A','T','D','5','0'}; //&lt;---command to put DIO5 to "0" (disabled)
AtCommandRequest atRequest = AtCommandRequest();
AtCommandResponse atResponse = AtCommandResponse();  
void setup()
{ 
delay(30000); 
atRequest.setCommand(atdCmd);
xbee.send(atRequest);
}
void loop()
{}


...but it doesn't work!
Thanks guys!
finally I solved the problem with this code:

uint8_t atdCmd[]={'D','5'};
uint8_t value[]={4};///pongo DIO5 a output LOW
uint8_t length=1;
AtCommandRequest atRequest = AtCommandRequest(atdCmd, value, length);
xbee.send(atRequest);


The problem was that I tried to put command with 5 caracters,... and only accepts 2 caracters for "AT command"