MQTT character limit issue

We are using a Arduino Uno board to communicate to a server via a MQTT message broker.
The board is connected to several sensors we are hoping to send multiple readings in one request.
Our request is being sent in JSON format and it's about 580 characters.
Unfortunately we are finding the device crashes when it tries to receive over 106 characters.
And simply cuts out most of the payload when we publish. We have increased the max packet size in the header file (no luck).

We are using the following client library to talk to the broker.

I know that MQTT does not have a character limit this small.
Is it possible for this board to handle packets this size?

Unfortunately we are finding the device crashes when it tries to receive over 106 characters.

There doesn't seem to be a thing that you can do on the sending end, to make more memory available to the receiver.

We are using a Arduino Uno board to communicate to a server via a MQTT message broker.

Yeah, we know, you told us that in your other identical thread (now no more)

jordanbeard12:
We are using a Arduino Uno board to communicate to a server via a MQTT message broker.
The board is connected to several sensors we are hoping to send multiple readings in one request.
Our request is being sent in JSON format and it's about 580 characters.
Unfortunately we are finding the device crashes when it tries to receive over 106 characters.
And simply cuts out most of the payload when we publish. We have increased the max packet size in the header file (no luck).

We are using the following client library to talk to the broker.

Arduino Client for MQTT · knolleary

I know that MQTT does not have a character limit this small.
Is it possible for this board to handle packets this size?

A UNO only has 2048 byte of RAM total, are you overflowing something? Verify that all of your character strings "messages", buffers (Serial takes 128 + overhead) are not exceeding what is available.

here is code from the playground that calculates free mem

int freeRam () {
  extern int __heap_start, *__brkval;
  int v;
  return (int) &v - (__brkval == 0 ? (int) &__heap_start : (int) __brkval);
}

add it to your code, display the result at various points in your program.

Chuck.