02-07-2023 12:06 PM
I agree, so the only good solution is to ask for the correct length, or add a length byte before the rest of the message.
Thenn first read the single length byte and immediately read the received length message.
02-11-2023 08:29 AM
Thank you everyone for all your support. We added a termination character and now I don't have any timing issues.