[Bitcloud] Message transmitting to ED - Page 1
Forum section: electronics / general

author: danergo2
author_rank: Newbie
timestamp: April 22, 2016, 07:43:10 am
content: Hi,another question has been come up to me this morning.if CS_END_DEVICE_SLEEP_TIME is set correctly, and I call APS_DataReq from the Coordinator to send something to an ED,will the stack know that the ED might be in "sleep" at the moment, and do some kind of buffering?What I mean would the APS_DataConf be called right after APS_DataReq or it will wait for CS_END_DEVICE_SLEEP_TIME?So, in general is it enough and reliable to only do a simple APS_DataReq? Or I need to handle by hand to store a message in the memory until I hear from ED and then send to it?Thank you!

author: ataradov
author_rank: Super Contributor
timestamp: April 22, 2016, 09:54:00 am
content: Quote from: danergo2 on April 22, 2016, 07:43:10 amYes and yes.Quote from: danergo2 on April 22, 2016, 07:43:10 amIt will wait for ED to check in, but total timeout can be up to CS_END_DEVICE_SLEEP_TIME * 1.5 or some thing like this.Quote from: danergo2 on April 22, 2016, 07:43:10 amWith BitCloud, yes. In general ZigBee - no. According to IEEE 802.15.4 + ZigBee transaction will expire in ~7.5 seconds. Most manufacturers ignore this and hold the request for as long as required, but there may be some that don't.

author: danergo
author_rank: Regular Contributor
timestamp: April 26, 2016, 05:42:27 am
content: Thanks, Alex!Let me ask one more thing.Same scenario, but now ED wants to send data to C. If ED is sleeping at the moment, and I do an APS_DataReq(...), will it wake up immediately and send, or it will wait for the sleeping interval and send afterwards?Thank you!

author: ataradov
author_rank: Super Contributor
timestamp: April 26, 2016, 05:46:06 am
content: Quote from: danergo on April 26, 2016, 05:42:27 amIf it is sleeping, then how would you do APS_DataReq()? If device can run the code, it is not sleeping.And ED can send data at any time, it does not have to be synchronized with the parent in any way.But remember that if you request APS ACK, then this ACK will be received though normal polling (1 second default).

author: danergo
author_rank: Regular Contributor
timestamp: April 26, 2016, 05:57:52 am
content: For sleeping I mean "SYS_EnableSleepWhenIdle". Sorry for the wrong phrasing.So basically, ED is in idle, CS_END_DEVICE_SLEEP_PERIOD is quite large (like 30000 ms).If the ED is in the middle of this periodif it is addressed, its parent need to store the message and wait until this period ends. That's fine.if the ED wants to send something back to the network (to the Coordinator), does it need to wait for ending the "sleep period", or it will initialize the sending as soon as possible?Based on your previous answer I assume that it will send ASAP, correct me please if I'm wrong.

author: ataradov
author_rank: Super Contributor
timestamp: April 26, 2016, 06:02:31 am
content: Quote from: danergo on April 26, 2016, 05:57:52 amThis.There are 2 distinct time intervals that EDs follow:1. Poll interval. This is typically very short (1 second by default). C (or R) will only send data to the ED after ED sends poll message (Data Request in terms of IEEE 802.15.4). So data rate towards ED is defined by this interval. Even if ED is fully awake at the moment, it still can't receive data faster than this interval.2. Sleep duration. This is the bigger interval (can be minutes and hours). ED expected to send at least one poll request in this interval.

author: danergo
author_rank: Regular Contributor
timestamp: April 26, 2016, 06:16:36 am
content: Very clear and nice summary. Thank you very much.