# Xbee endpoints randomly stop transmiting

**URL:** <https://forums.digi.com/t/xbee-endpoints-randomly-stop-transmiting/21988>\
**Category:** XBee - Zigbee\
**Tags:** xbee3, zigbee\
**Created:** [November 12, 2020, 10:14am UTC](https://forums.digi.com/t/xbee-endpoints-randomly-stop-transmiting/21988 "2020-11-12T10:14:39Z")\
**Posts on this page:** 20\
**Page:** 1

<div class="post-metadata">

**Author:** ![StfBbt](https://avatars.discourse-cdn.com/v4/letter/s/e56c9b/32.png) [@StfBbt](https://forums.digi.com/u/StfBbt)\
**Post date:** [November 12, 2020, 10:14am UTC](https://forums.digi.com/t/xbee-endpoints-randomly-stop-transmiting/21988/1 "2020-11-12T10:14:39Z")

</div>

Hello!  
I have a network consisting of the coordinator, two routers under the coordinator and 9 endpoints under each router. The coordinator and endpoints have been programmed with pycharm, so they run my micropython code, while the routers function in the default mode with no custom programs.  
The endpoints consist of an Xbee 3 Zigbee that is connected to a SHTC3 temperature and humidity sensor. The role of the endpoints is to send the measured temperature and humidity value to the coordinator once every minute.  
The code on the coordinator is simply polling and checking if there are any packets to be received on the RF, while the endpoint code is comunicating with the sensor, reading the temperature and humidity values and sending them to the coordinator, after which it sleeps for 1 minute and then begins the cycle again.  
The problem is that after 3 days of running, the endpoints under one of the routers stop transmitting, while the ones under the other router are fine, even if the routers are identically configured.  
I can’t figure out why this might be so any help will be greatly apreciated.

Thank you!

---

<div class="post-metadata">

**Author:** ![mvut](https://sea2.discourse-cdn.com/flex016/user_avatar/forums.digi.com/mvut/32/31_2.png) [@mvut](https://forums.digi.com/u/mvut)\
**Post date:** [November 12, 2020, 11:15am UTC](https://forums.digi.com/t/xbee-endpoints-randomly-stop-transmiting/21988/2 "2020-11-12T11:15:22Z")

</div>

What firmware version are you working with?

Are you able to query any settings from the radio via a different radio?

---

<div class="post-metadata">

**Author:** ![StfBbt](https://avatars.discourse-cdn.com/v4/letter/s/e56c9b/32.png) [@StfBbt](https://forums.digi.com/u/StfBbt)\
**Post date:** [November 13, 2020, 8:38am UTC](https://forums.digi.com/t/xbee-endpoints-randomly-stop-transmiting/21988/3 "2020-11-13T08:38:01Z")

</div>

The firmware version is 100B. I have never thought of query over RF, usually I just do it by manually inserting the xbee into the programmer and reading the parameters with xctu.

---

<div class="post-metadata">

**Author:** ![mvut](https://sea2.discourse-cdn.com/flex016/user_avatar/forums.digi.com/mvut/32/31_2.png) [@mvut](https://forums.digi.com/u/mvut)\
**Post date:** [November 13, 2020, 1:32pm UTC](https://forums.digi.com/t/xbee-endpoints-randomly-stop-transmiting/21988/4 "2020-11-13T13:32:20Z")

</div>

Doing so can tell you a great deal of what is going on. That is, is it an RF issue where you can’t reach the node or is it with the device connected to the XBee?

---

<div class="post-metadata">

**Author:** ![StfBbt](https://avatars.discourse-cdn.com/v4/letter/s/e56c9b/32.png) [@StfBbt](https://forums.digi.com/u/StfBbt)\
**Post date:** [November 13, 2020, 4:14pm UTC](https://forums.digi.com/t/xbee-endpoints-randomly-stop-transmiting/21988/5 "2020-11-13T16:14:04Z")

</div>

Which of the parameters would be of importance? I can read them at the endpoint and attach them to the payload alongside the temperature and humidity data.

---

<div class="post-metadata">

**Author:** ![mvut](https://sea2.discourse-cdn.com/flex016/user_avatar/forums.digi.com/mvut/32/31_2.png) [@mvut](https://forums.digi.com/u/mvut)\
**Post date:** [November 16, 2020, 8:17am UTC](https://forums.digi.com/t/xbee-endpoints-randomly-stop-transmiting/21988/6 "2020-11-16T08:17:05Z")

</div>

Frankly any of the commands would work. The point being, that you can talk to the radio over the air. So while it may be possible to modify your Python code to read an AT command and include it in your response, it defeats the purpose.

---

<div class="post-metadata">

**Author:** ![StfBbt](https://avatars.discourse-cdn.com/v4/letter/s/e56c9b/32.png) [@StfBbt](https://forums.digi.com/u/StfBbt)\
**Post date:** [November 19, 2020, 9:08am UTC](https://forums.digi.com/t/xbee-endpoints-randomly-stop-transmiting/21988/7 "2020-11-19T09:08:59Z")

</div>

After the problematic endpoints stop transmiting, they wont connect to the coordinator again. Only if I put each one of them in the Xbee Explorer and flash the AT parameters and the program again, only then will they connect again and transmit.

---

<div class="post-metadata">

**Author:** ![mvut](https://sea2.discourse-cdn.com/flex016/user_avatar/forums.digi.com/mvut/32/31_2.png) [@mvut](https://forums.digi.com/u/mvut)\
**Post date:** [November 19, 2020, 12:12pm UTC](https://forums.digi.com/t/xbee-endpoints-randomly-stop-transmiting/21988/8 "2020-11-19T12:12:49Z")

</div>

do they respond to a Node Discovery or to the ATDN command?

---

<div class="post-metadata">

**Author:** ![StfBbt](https://avatars.discourse-cdn.com/v4/letter/s/e56c9b/32.png) [@StfBbt](https://forums.digi.com/u/StfBbt)\
**Post date:** [November 20, 2020, 8:24am UTC](https://forums.digi.com/t/xbee-endpoints-randomly-stop-transmiting/21988/9 "2020-11-20T08:24:04Z")

</div>

I reflashed the program on the coordinator so that it does a discovery, and after I did this the nodes that stopped transmitting did connect to the network, even if their programs were not changed, this makes me think the problem lies with the coordinator…

---

<div class="post-metadata">

**Author:** ![mvut](https://sea2.discourse-cdn.com/flex016/user_avatar/forums.digi.com/mvut/32/31_2.png) [@mvut](https://forums.digi.com/u/mvut)\
**Post date:** [November 20, 2020, 8:26am UTC](https://forums.digi.com/t/xbee-endpoints-randomly-stop-transmiting/21988/10 "2020-11-20T08:26:46Z")

</div>

Actually it sounds more like a broken RF path or something to that nature. You might want to adjust your code to do a DN from the node to the coordinator also if this issue occurs again.

---

<div class="post-metadata">

**Author:** ![DystopianFerret](https://avatars.discourse-cdn.com/v4/letter/d/71e660/32.png) [@DystopianFerret](https://forums.digi.com/u/DystopianFerret)\
**Post date:** [November 20, 2020, 6:08pm UTC](https://forums.digi.com/t/xbee-endpoints-randomly-stop-transmiting/21988/11 "2020-11-20T18:08:59Z")

</div>

How long are the endpoints awake? They need to be awake long enough to perform a route discovery to the coordinator if they lose connection.

-Matthew  
Digi Technical Support

---

<div class="post-metadata">

**Author:** ![StfBbt](https://avatars.discourse-cdn.com/v4/letter/s/e56c9b/32.png) [@StfBbt](https://forums.digi.com/u/StfBbt)\
**Post date:** [November 30, 2020, 9:24am UTC](https://forums.digi.com/t/xbee-endpoints-randomly-stop-transmiting/21988/12 "2020-11-30T09:24:13Z")

</div>

For the sleep I used the default python sleep function which to my knowledge does not really put the xbee in sleep. I want to replace it with the proper function (sleep\_now) in the future, but for now I dont think the XBee ever properly sleeps.

---

<div class="post-metadata">

**Author:** ![StfBbt](https://avatars.discourse-cdn.com/v4/letter/s/e56c9b/32.png) [@StfBbt](https://forums.digi.com/u/StfBbt)\
**Post date:** [November 30, 2020, 9:23am UTC](https://forums.digi.com/t/xbee-endpoints-randomly-stop-transmiting/21988/13 "2020-11-30T09:23:40Z")

</div>

You mean to call xbee.discover() from the endpoints?

---

<div class="post-metadata">

**Author:** ![mvut](https://sea2.discourse-cdn.com/flex016/user_avatar/forums.digi.com/mvut/32/31_2.png) [@mvut](https://forums.digi.com/u/mvut)\
**Post date:** [November 30, 2020, 9:35am UTC](https://forums.digi.com/t/xbee-endpoints-randomly-stop-transmiting/21988/14 "2020-11-30T09:35:23Z")

</div>

From what I recall, the Micro Python sleep function can tell the XBee to sleep as well. See [http://cms.digi.com/resources/documentation/digidocs/90002219/#reference/r\_sleep\_mp.htm?Highlight=sleep](http://cms.digi.com/resources/documentation/digidocs/90002219/#reference/r_sleep_mp.htm?Highlight=sleep)

---

<div class="post-metadata">

**Author:** ![mvut](https://sea2.discourse-cdn.com/flex016/user_avatar/forums.digi.com/mvut/32/31_2.png) [@mvut](https://forums.digi.com/u/mvut)\
**Post date:** [November 30, 2020, 9:41am UTC](https://forums.digi.com/t/xbee-endpoints-randomly-stop-transmiting/21988/15 "2020-11-30T09:41:24Z")

</div>

Yes I was referring to the sleeping end device to run the discovery.

---

<div class="post-metadata">

**Author:** ![StfBbt](https://avatars.discourse-cdn.com/v4/letter/s/e56c9b/32.png) [@StfBbt](https://forums.digi.com/u/StfBbt)\
**Post date:** [November 30, 2020, 12:44pm UTC](https://forums.digi.com/t/xbee-endpoints-randomly-stop-transmiting/21988/16 "2020-11-30T12:44:18Z")

</div>

Yes, the function you linked is correct and is sleep\_now. What I used, on the other hand, is sleep, which as far as I know is not initiating a ‘real’ sleep.

---

<div class="post-metadata">

**Author:** ![StfBbt](https://avatars.discourse-cdn.com/v4/letter/s/e56c9b/32.png) [@StfBbt](https://forums.digi.com/u/StfBbt)\
**Post date:** [December 17, 2020, 9:24am UTC](https://forums.digi.com/t/xbee-endpoints-randomly-stop-transmiting/21988/17 "2020-12-17T09:24:20Z")

</div>

As the endpoints are not connected to any PC, I can’t really see the result of the discovery function after it’s called. I doubt just calling it will solve the problem so I suppose you are you suggesting to call it for debugging purposes to see if it sees the coordinator? In that case is it possible to save the output in file on the endpoint or something like that?

---

<div class="post-metadata">

**Author:** ![mvut](https://sea2.discourse-cdn.com/flex016/user_avatar/forums.digi.com/mvut/32/31_2.png) [@mvut](https://forums.digi.com/u/mvut)\
**Post date:** [December 23, 2020, 9:07am UTC](https://forums.digi.com/t/xbee-endpoints-randomly-stop-transmiting/21988/18 "2020-12-23T09:07:45Z")

</div>

This is to determine where the actual issue is. Or if it is a broken link.

---

<div class="post-metadata">

**Author:** ![liemmayer](https://avatars.discourse-cdn.com/v4/letter/l/a698b9/32.png) [@liemmayer](https://forums.digi.com/u/liemmayer)\
**Post date:** [December 30, 2020, 1:28pm UTC](https://forums.digi.com/t/xbee-endpoints-randomly-stop-transmiting/21988/19 "2020-12-30T13:28:46Z")

</div>

An interesting situation, I want to model it for myself and check everything, then I can write a comment!

---

<div class="post-metadata">

**Author:** ![StfBbt](https://avatars.discourse-cdn.com/v4/letter/s/e56c9b/32.png) [@StfBbt](https://forums.digi.com/u/StfBbt)\
**Post date:** [January 4, 2021, 10:37am UTC](https://forums.digi.com/t/xbee-endpoints-randomly-stop-transmiting/21988/20 "2021-01-04T10:37:46Z")

</div>

From what I talked to support it seems that my micropython code on the endpoints is the cause, I will try to monitor it to see the error when it occurs.
