Xbee3 BLU Silent exit

I have an Xbee BLU -TH device running firmware version 4001 that is sending an array of data via a bluetooth connection to a windows PC.

my send function is very simple and works well. However, after around ~3000 iteration my xbee restarts without any notifications. I have put Try: statements around my main loop and I am parodically checking memory usage. below is a snippit of my code. Has anyone else observed this behavior?

def send_user_data(int16_values):

p = build_payload(int16_values)

try:

    relay.send(relay.BLUETOOTH, p)

    return True, None

except Exception as e:

    print("\[SEND\] ERROR: %s" % str(e))

    return False, str(e)

I have not heard of this. Are you running any source of GC collection?

The issue ended up being with the a hardware watchdog on the external board the xbee was connected to. We were previously using pin 6 on the Xbee Pro to wack the watchdog but the Xbee BLU does not allow that pin to be referenced. I am now having issues with ERROR: [Errno 7105] ENOBUFS but that is a separate issue.

That means that the buffers are full and you have not cleared them properly.

That what i figured. I am trying to send data at the maximum possible rate so I am seeing how fast and how much data I can send. My goal is to send integer data at ~500 Hz (100 points every 0.2 seconds). Other than just slowing down, are there commands to set larger buffers or do you suggest a different method of sending data. My current code can run for about 10 minuets before the buffers get full.

No, there are no commands you can issue to change the size of the internal buffers. Your just going to have to slow down on how often you are transmitting.

My starting point was calling relay.send(relay.BLUETOOTH, payload) 5 time a second. I can get up to 116 values in my payload before I start getting the error “ message too long”.

You are likely exceeding the max payload size for the version of the BLE standard that has been implemented. From what I recall, you are limited to 244 bytes. But I could be off.