Author Topic: [Bitcloud] Message transmitting to ED  (Read 3628 times)

0 Members and 1 Guest are viewing this topic.

Offline danergo2Topic starter

  • Newbie
  • Posts: 4
  • Country: hu
[Bitcloud] Message transmitting to ED
« on: April 22, 2016, 07:43:10 am »
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!
 

Online ataradov

  • Super Contributor
  • ***
  • Posts: 11803
  • Country: us
    • Personal site
Re: [Bitcloud] Message transmitting to ED
« Reply #1 on: April 22, 2016, 09:54:00 am »
will the stack know that the ED might be in "sleep" at the moment, and do some kind of buffering?
Yes and yes.

What I mean would the APS_DataConf be called right after APS_DataReq or it will wait for CS_END_DEVICE_SLEEP_TIME?
It 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.

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?
With 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.
Alex
 

Offline danergo

  • Regular Contributor
  • *
  • Posts: 111
  • Country: hu
Re: [Bitcloud] Message transmitting to ED
« Reply #2 on: April 26, 2016, 05:42:27 am »
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!
 

Online ataradov

  • Super Contributor
  • ***
  • Posts: 11803
  • Country: us
    • Personal site
Re: [Bitcloud] Message transmitting to ED
« Reply #3 on: April 26, 2016, 05:46:06 am »
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?
If 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).
Alex
 

Offline danergo

  • Regular Contributor
  • *
  • Posts: 111
  • Country: hu
Re: [Bitcloud] Message transmitting to ED
« Reply #4 on: April 26, 2016, 05:57:52 am »
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 period
  • if 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.
 

Online ataradov

  • Super Contributor
  • ***
  • Posts: 11803
  • Country: us
    • Personal site
Re: [Bitcloud] Message transmitting to ED
« Reply #5 on: April 26, 2016, 06:02:31 am »
or it will initialize the sending as soon as possible?
This.

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.
Alex
 

Offline danergo

  • Regular Contributor
  • *
  • Posts: 111
  • Country: hu
Re: [Bitcloud] Message transmitting to ED
« Reply #6 on: April 26, 2016, 06:16:36 am »
Very clear and nice summary. Thank you very much.
 


Share me

Digg  Facebook  SlashDot  Delicious  Technorati  Twitter  Google  Yahoo
Smf