2

I'm currently working on a project in which I use antennas such as XBee 2 mW Wire Antenna - Series 2 (ZigBee Mesh).

How can I configure my antenna to go sleep mode using software in API mode (without using XCTU)?

How am I supposed to wake up the antenna?

Peter Mortensen
  • 30,738
  • 21
  • 105
  • 131

1 Answers1

2

There are many ways to put your device to sleep. If you don't have access to X-CTU you can give the END-DEVICE antenna (it has to be an end device cause for obvious reasons routers and coordinators can't stop responding) a remote AT command through another antenna (usually the coordinator with the help of any microcontroller)

There are 4 types of sleep you can configure (SM) depending on the value you assign

  • 0 - NO SLEEP
  • 1 - PIN HIBERNATE //I believe this one will wake the device only when Sleep_Rq, module pin 9, transitions from a high to a low state.There is not much documentation on this mode
  • 4 - Cyclic SLEEP //This mode depends on the SP and SN parameters. SP (20 to AF0) is the period of sleep in milliseconds and SN (0000 to FFFF) is the number of periods to sleep before waking
  • 5 - Cyclic SLEEP with pin wake //same as before but you can wake the device also when Sleep_Rq, module pin 9, transitions from a high to a low state.

This is a typical api message that configures your end device for sleep mode 4

7E //start delimiter 
00 0F //length 
17 //frame type identifier (remote AT message)
01 //frame ID 
00 7D 33 A2 00 40 5C 42 //64bit END-DEVICE address 
0C FF //16bit destination network address 
02 //command options 
83 77 //command name ( SM in ASCII ) 
04 //command data 
** //checksum 

In general X.CTU saves you a lot of time, if for some reason you can't use it check out this valid alternative Zigbee Operator

Mike
  • 573
  • 2
  • 4
  • 18
  • Can I send AT commands to the antenna with API firmware? I write code to arduino that has xbee antenna, for now I'm working in mode API. My goal is to create a arduino client so that it's power consumption nature set by software. And my question: Can I configure the antenna with arduino and AT commands while running the controller, when the antenna mode - zigbee end device API, it will go to sleep every certain period of time or not go to sleep at all (depending on the nature of the client)? thanks! – Sasha Imanilov Nov 06 '12 at 12:34
  • Yes, the one I described above is a packet for a remote AT command in api mode. Just remember that while the end device is sleeping it will not receive any command. So you might have to send it in response of the antenna waking up. – Mike Nov 06 '12 at 16:52
  • Any other doubt I can help you with? – Mike Nov 19 '12 at 10:00