Home/Support/Support Forum/Change size of message object in python digi-xbee message object
Welcome to Digi Forum, where you can ask questions and receive answers from other members of the community.

Change size of message object in python digi-xbee message object

0 votes

I'm trying to transfer a 10MB long String using the device.send_data() methode.
The message is too long, so I manually found out, that I can transfer upto 92 letters of the string at once (if I go higher it throws an error).

Is there a way to increse this size? I made a workaround using string.split() and a for-loop. But I think there should be an automatic way to manage this?

Best regards
asked Dec 22, 2021 in Python by Wermut96 New to the Community (0 points)

Please log in or register to answer this question.

1 Answer

0 votes
Where did you obtain this digi-xbee message object from?

What Python version are you working with?
answered Dec 28, 2021 by mvut Veteran of the Digi Community (15,290 points)
I'm using python 3.10

I an using a try:except block and debugging. The digi-xbee message is temporarily created when I use the send_data() Methode and only visible in the debugging. I then can see the Exception, which states "message too long"

Took me a while to even find that since the actual exception only says "there was an error sending the message"... I had to find some variable which was then pointing to a string which had the actual error in it...